mirror of
https://github.com/SquidDev-CC/CC-Tweaked
synced 2026-01-28 14:31:17 +00:00
Initial update to 1.12
- Convert most recipes to JSON - Add JSON factories for impostor and turtle recipes. - Several mappings changes - Migrate to Forge's new registry system
This commit is contained in:
@@ -34,6 +34,7 @@ import net.minecraft.client.renderer.ItemMeshDefinition;
|
||||
import net.minecraft.client.renderer.block.model.ModelBakery;
|
||||
import net.minecraft.client.renderer.block.model.ModelResourceLocation;
|
||||
import net.minecraft.client.renderer.color.IItemColor;
|
||||
import net.minecraft.client.util.ITooltipFlag;
|
||||
import net.minecraft.entity.player.EntityPlayer;
|
||||
import net.minecraft.entity.player.InventoryPlayer;
|
||||
import net.minecraft.item.Item;
|
||||
@@ -44,6 +45,7 @@ import net.minecraft.util.ResourceLocation;
|
||||
import net.minecraft.util.SoundEvent;
|
||||
import net.minecraft.util.math.BlockPos;
|
||||
import net.minecraft.world.World;
|
||||
import net.minecraftforge.client.event.ModelRegistryEvent;
|
||||
import net.minecraftforge.client.event.RenderGameOverlayEvent;
|
||||
import net.minecraftforge.client.event.RenderHandEvent;
|
||||
import net.minecraftforge.client.event.RenderPlayerEvent;
|
||||
@@ -76,6 +78,13 @@ public class ComputerCraftProxyClient extends ComputerCraftProxyCommon
|
||||
m_tick = 0;
|
||||
m_renderFrame = 0;
|
||||
|
||||
// Setup client forge handlers
|
||||
registerForgeHandlers();
|
||||
}
|
||||
|
||||
@SubscribeEvent
|
||||
public void registerModels( ModelRegistryEvent event )
|
||||
{
|
||||
// Register item models
|
||||
registerItemModel( ComputerCraft.Blocks.computer, new ItemMeshDefinition()
|
||||
{
|
||||
@@ -174,9 +183,6 @@ public class ComputerCraftProxyClient extends ComputerCraftProxyCommon
|
||||
"advanced_pocket_computer", "advanced_pocket_computer_on", "advanced_pocket_computer_blinking",
|
||||
"pocket_computer_colour", "pocket_computer_colour_on", "pocket_computer_colour_blinking",
|
||||
} );
|
||||
|
||||
// Setup client forge handlers
|
||||
registerForgeHandlers();
|
||||
}
|
||||
|
||||
@Override
|
||||
@@ -304,7 +310,7 @@ public class ComputerCraftProxyClient extends ComputerCraftProxyCommon
|
||||
public String getRecordInfo( @Nonnull ItemStack recordStack )
|
||||
{
|
||||
List<String> info = new ArrayList<String>( 1 );
|
||||
recordStack.getItem().addInformation( recordStack, null, info, false );
|
||||
recordStack.getItem().addInformation( recordStack, null, info, ITooltipFlag.TooltipFlags.NORMAL );
|
||||
if( info.size() > 0 ) {
|
||||
return info.get( 0 );
|
||||
} else {
|
||||
|
||||
Reference in New Issue
Block a user