Browse Source

Countertop 3D access and rendering

Added build.gradle to git
Qwertygiy 3 years ago
parent
commit
ff1572ee36

+ 0
- 1
.gitignore View File

@@ -13,7 +13,6 @@
13 13
 /.classpath
14 14
 /.directory
15 15
 /.project
16
-/build.gradle
17 16
 /CREDITS-fml.txt
18 17
 /forge-1.7.10-10.13.4.1566-1.7.10-changelog.txt
19 18
 /gradlew

+ 132
- 0
build.gradle View File

@@ -0,0 +1,132 @@
1
+buildscript {
2
+    repositories {
3
+        mavenCentral()
4
+		maven {
5
+        name = "gt"
6
+        url = "http://gregtech.overminddl1.com/"
7
+		}
8
+		maven {
9
+			name = "forge"
10
+			url = "http://files.minecraftforge.net/maven"
11
+		}
12
+		maven {
13
+			name = "OC repo"
14
+			url = "http://maven.cil.li/"
15
+		}
16
+        maven {
17
+            name = "sonatype"
18
+            url = "https://oss.sonatype.org/content/repositories/snapshots/"
19
+        }
20
+    }
21
+    dependencies {
22
+        classpath 'net.minecraftforge.gradle:ForgeGradle:1.2-SNAPSHOT'
23
+    }
24
+}
25
+
26
+apply plugin: 'forge'
27
+
28
+version = "1.0.0-a.27"
29
+group= "com.kbi.qwertech" // http://maven.apache.org/guides/mini/guide-naming-conventions.html
30
+archivesBaseName = "qwertech"
31
+
32
+minecraft {
33
+    version = "1.7.10-10.13.4.1614-1.7.10"
34
+    runDir = "eclipse"
35
+}
36
+
37
+dependencies {
38
+    // you may put jars on which you depend on in ./libs
39
+    // or you may define them like so..
40
+    //compile "some.group:artifact:version:classifier"
41
+    //compile "some.group:artifact:version"
42
+      
43
+    // real examples
44
+    //compile 'com.mod-buildcraft:buildcraft:6.0.8:dev'  // adds buildcraft to the dev env
45
+    //compile 'com.googlecode.efficient-java-matrix-library:ejml:0.24' // adds ejml to the dev env
46
+
47
+    // for more info...
48
+    // http://www.gradle.org/docs/current/userguide/artifact_dependencies_tutorial.html
49
+    // http://www.gradle.org/docs/current/userguide/dependency_management.html
50
+	compile fileTree(dir: 'lib', include: '*.jar')
51
+	//compile "li.cil.oc:OpenComputers:MC1.7.10-1.6.2.1078-dev:dev"
52
+	//compile 'net.industrial-craft:industrialcraft-2:2.2.828-experimental:api'
53
+	//compile group: 'com.gregoriust.gregtech', name: 'gregtech_1.7.10', version: '6.05.48', classifier: 'dev'
54
+}
55
+
56
+processResources
57
+{
58
+    // this will ensure that this task is redone when the versions change.
59
+    inputs.property "version", project.version
60
+    inputs.property "mcversion", project.minecraft.version
61
+
62
+    // replace stuff in mcmod.info, nothing else
63
+    from(sourceSets.main.resources.srcDirs) {
64
+        include 'mcmod.info'
65
+		exclude 'thumbs.db'
66
+                
67
+        // replace version and mcversion
68
+        expand 'version':project.version, 'mcversion':project.minecraft.version
69
+    }
70
+        
71
+    // copy everything else, thats not the mcmod.info
72
+    from(sourceSets.main.resources.srcDirs) {
73
+        exclude 'mcmod.info'
74
+		exclude 'thumbs.db'
75
+    }
76
+}
77
+
78
+def filteredSourceDir = file("${buildDir}/filtered") 
79
+
80
+sourceSets {
81
+	ahem {
82
+		java {
83
+			srcDirs = [file("${buildDir}/sources/java")]
84
+			//include 'com/kbi/qwertech/**'
85
+			exclude 'com/kbi/qwertech/QwerTech.java'
86
+		}
87
+	}
88
+}
89
+
90
+
91
+sourceSets {
92
+    // This source set will contain all sources that we filter 
93
+    filtered { 
94
+        java { 
95
+            srcDirs = [sourceSets.ahem.java, filteredSourceDir] 
96
+        } 
97
+    } 
98
+} 
99
+
100
+// tell the compileJava task to compile the filtered source 
101
+compileJava.source = sourceSets.filtered.java 
102
+
103
+
104
+// copy the main sources and filter any '$version' occurences. 
105
+task processVersion (type: Copy) { 
106
+    from "build/sources/java/com/kbi/qwertech/QwerTech.java"
107
+    into filteredSourceDir 
108
+    expand 'version':project.version
109
+} 
110
+
111
+compileJava.dependsOn processVersion 
112
+
113
+task deobfJar(type: Jar, dependsOn: 'jar') {
114
+    from "build/classes/main"
115
+	from(sourceSets.main.resources.srcDirs) {
116
+        exclude 'mcmod.info'
117
+		exclude 'thumbs.db'
118
+    }
119
+    classifier "dev"
120
+}
121
+
122
+task sourceJar(type: Jar, dependsOn: 'sourceMainJava') {
123
+    from "build/sources/java/com/kbi/qwertech/api"
124
+    classifier "api"
125
+}
126
+
127
+artifacts {
128
+    archives deobfJar
129
+	archives sourceJar
130
+}
131
+
132
+idea { module { inheritOutputDirs = true } }

+ 15
- 0
src/main/java/com/kbi/qwertech/ClientProxy.java View File

@@ -1,5 +1,6 @@
1 1
 package com.kbi.qwertech;
2 2
 
3
+import com.kbi.qwertech.api.data.FOOD;
3 4
 import com.kbi.qwertech.api.data.QTConfigs;
4 5
 import com.kbi.qwertech.api.data.QTI;
5 6
 import com.kbi.qwertech.api.recipe.CountertopRecipe;
@@ -11,6 +12,7 @@ import com.kbi.qwertech.client.entity.passive.RenderFrog;
11 12
 import com.kbi.qwertech.client.entity.projectile.*;
12 13
 import com.kbi.qwertech.client.models.ModelFrog;
13 14
 import com.kbi.qwertech.client.models.ModelTurkey;
15
+import com.kbi.qwertech.client.tileentity.CountertopRenderer;
14 16
 import com.kbi.qwertech.client.tileentity.CraftingTable3DRenderer;
15 17
 import com.kbi.qwertech.client.tileentity.CraftingTableRenderer;
16 18
 import com.kbi.qwertech.client.tileentity.UpgradeDeskRenderer;
@@ -30,6 +32,7 @@ import gregapi.data.CS;
30 32
 import gregapi.data.LH;
31 33
 import gregapi.data.OP;
32 34
 import net.minecraft.item.ItemStack;
35
+import net.minecraft.nbt.NBTTagCompound;
33 36
 import net.minecraftforge.client.MinecraftForgeClient;
34 37
 import net.minecraftforge.common.MinecraftForge;
35 38
 import net.minecraftforge.event.entity.player.ItemTooltipEvent;
@@ -106,6 +109,8 @@ public final class ClientProxy extends CommonProxy { // NO_UCD (unused code)
106 109
 		ClientRegistry.bindTileEntitySpecialRenderer(CraftingTableT4.class, new CraftingTable3DRenderer());
107 110
 		
108 111
 		ClientRegistry.bindTileEntitySpecialRenderer(UpgradeDesk.class, new UpgradeDeskRenderer());
112
+
113
+		ClientRegistry.bindTileEntitySpecialRenderer(CuttingBoardTileEntity.class, new CountertopRenderer());
109 114
 		
110 115
 		wallRenderID = RenderingRegistry.getNextAvailableRenderId();
111 116
 		RenderingRegistry.registerBlockHandler(wallRenderID, new RenderCorrugated());
@@ -126,6 +131,16 @@ public final class ClientProxy extends CommonProxy { // NO_UCD (unused code)
126 131
 	    		event.toolTip.add(LH.Chat.GOLD + "Can be used to upgrade armor");
127 132
 	    	}
128 133
 
134
+	    	if (event.itemStack.hasTagCompound())
135
+			{
136
+				NBTTagCompound tag = event.itemStack.stackTagCompound;
137
+				if (tag.hasKey("qt.food"))
138
+				{
139
+					event.toolTip.add("Quality: " + FOOD.getQuality(event.itemStack));
140
+					event.toolTip.add("Quantity: " + FOOD.getQuantity(event.itemStack));
141
+				}
142
+			}
143
+
129 144
 	    	if (event.entityPlayer.openContainer instanceof CuttingBoardTileEntity.GUICommonCuttingBoard)
130 145
 			{
131 146
 				CuttingBoardTileEntity.GUICommonCuttingBoard CB = (CuttingBoardTileEntity.GUICommonCuttingBoard)event.entityPlayer.openContainer;

+ 9
- 1
src/main/java/com/kbi/qwertech/QwerTech.java View File

@@ -32,6 +32,7 @@ import cpw.mods.fml.common.registry.GameRegistry;
32 32
 import gregapi.api.Abstract_Mod;
33 33
 import gregapi.api.Abstract_Proxy;
34 34
 import gregapi.block.ItemBlockBase;
35
+import gregapi.block.metatype.BlockStones;
35 36
 import gregapi.block.multitileentity.MultiTileEntityBlock;
36 37
 import gregapi.block.multitileentity.MultiTileEntityRegistry;
37 38
 import gregapi.code.ICondition.And;
@@ -598,9 +599,16 @@ public final class QwerTech extends Abstract_Mod {
598 599
 			OreDictMaterial woodType = WOOD.woodList[q];
599 600
 			if (woodType != null && OreDictionary.getOres("plank" + woodType.mNameInternal).size() > 0)
600 601
 			{
601
-				machines.add(woodType.mNameLocal + " Countertop", "Countertops", 410 + q, 0, CuttingBoardTileEntity.class, 0, 16, wood, UT.NBT.make(null, CS.NBT_MATERIAL, woodType, CS.NBT_INV_SIZE, 16, CS.NBT_TEXTURE, "qwertech:wood", CS.NBT_HARDNESS, 3.0F, CS.NBT_RESISTANCE, 3.0F, CS.NBT_COLOR, UT.Code.getRGBInt(woodType.fRGBaSolid)), "S", "P", 'S', "slabWood", 'P', "plank" + woodType.mNameInternal);
602
+				machines.add(woodType.mNameLocal + " Countertop", "Countertops", 410 + q, 0, CuttingBoardTileEntity.class, 0, 16, wood, UT.NBT.make(null, CS.NBT_MATERIAL, woodType, CS.NBT_INV_SIZE, 8, CS.NBT_TEXTURE, "qwertech:wood", CS.NBT_HARDNESS, 3.0F, CS.NBT_RESISTANCE, 3.0F, CS.NBT_COLOR, UT.Code.getRGBInt(woodType.fRGBaSolid)), "S", "P", 'S', "slabWood", 'P', "plank" + woodType.mNameInternal);
602 603
 			}
603 604
 		}
605
+		for (int q = 0; q < CS.BlocksGT.stones.length; q++)
606
+		{
607
+			BlockStones block = (BlockStones)CS.BlocksGT.stones[q];
608
+			machines.add(block.mMaterial.mNameLocal + " Countertop", "Countertops", 667 + (q * 3), 0, CuttingBoardTileEntity.class, 0, 16, metal, UT.NBT.make(null, CS.NBT_MATERIAL, block.mMaterial, CS.NBT_INV_SIZE, 8, CS.NBT_TEXTURE, q, "qt.metatex", 0, CS.NBT_HARDNESS, 3.0F, CS.NBT_RESISTANCE, 3.0F, CS.NBT_COLOR, UT.Code.getRGBInt(block.mMaterial.fRGBaSolid)), "S", "P", 'S', ST.make(block.mSlabs[CS.SIDE_DOWN], 1, 0), 'P', ST.make(block, 1, 0));
609
+			machines.add("Smooth " + block.mMaterial.mNameLocal + " Countertop", "Countertops", 667 + (q * 3) + 1, 0, CuttingBoardTileEntity.class, 0, 16, metal, UT.NBT.make(null, CS.NBT_MATERIAL, block.mMaterial, CS.NBT_INV_SIZE, 8, CS.NBT_TEXTURE, q, "qt.metatex", 7, CS.NBT_HARDNESS, 3.0F, CS.NBT_RESISTANCE, 3.0F, CS.NBT_COLOR, UT.Code.getRGBInt(block.mMaterial.fRGBaSolid)), "S", "P", 'S', ST.make(block.mSlabs[CS.SIDE_DOWN], 1, 7), 'P', ST.make(block, 1, 7));
610
+			machines.add(block.mMaterial.mNameLocal + " Cobblestone Countertop", "Countertops", 667 + (q * 3) + 2, 0, CuttingBoardTileEntity.class, 0, 16, metal, UT.NBT.make(null, CS.NBT_MATERIAL, block.mMaterial, CS.NBT_INV_SIZE, 8, CS.NBT_TEXTURE, q, "qt.metatex", 1, CS.NBT_HARDNESS, 3.0F, CS.NBT_RESISTANCE, 3.0F, CS.NBT_COLOR, UT.Code.getRGBInt(block.mMaterial.fRGBaSolid)), "S", "P", 'S', ST.make(block.mSlabs[CS.SIDE_DOWN], 1, 1), 'P', ST.make(block, 1, 1));
611
+		}
604 612
 
605 613
 	}
606 614
 

+ 79
- 0
src/main/java/com/kbi/qwertech/client/tileentity/CountertopRenderer.java View File

@@ -0,0 +1,79 @@
1
+package com.kbi.qwertech.client.tileentity;
2
+
3
+import com.kbi.qwertech.tileentities.CuttingBoardTileEntity;
4
+import gregapi.data.CS;
5
+import net.minecraft.client.Minecraft;
6
+import net.minecraft.client.renderer.OpenGlHelper;
7
+import net.minecraft.item.ItemStack;
8
+import net.minecraft.tileentity.TileEntity;
9
+import org.lwjgl.opengl.GL11;
10
+
11
+public class CountertopRenderer extends CraftingTableRenderer {
12
+
13
+    public void renderTileEntityAt(CuttingBoardTileEntity tileEntity, double x, double y, double z, float partialTick) {
14
+        if (mc == null) mc = Minecraft.getMinecraft();
15
+        GL11.glPushMatrix();
16
+        GL11.glTranslated(x, y, z);
17
+        GL11.glPushMatrix();
18
+        //GL11.glDisable(GL11.GL_LIGHTING);
19
+        OpenGlHelper.setLightmapTextureCoords(OpenGlHelper.lightmapTexUnit, 240.0F, 240.0F);
20
+        GL11.glTranslatef(0.5F, 0.5F, 0.5F);
21
+        short dir = tileEntity.getFacing();
22
+        if (dir == CS.SIDE_Y_NEG || dir == CS.SIDE_X_NEG || dir == CS.SIDE_X_POS)
23
+        {
24
+            GL11.glRotatef(90, 0, 1, 0);
25
+        }
26
+
27
+        GL11.glTranslatef(-0.5F, -0.5F, -0.5F);
28
+
29
+        double dist = (Math.abs(x) + Math.abs(y) + Math.abs(z));
30
+        float timeLoop = (tileEntity.getWorld().getWorldTime() % 3600) + partialTick;
31
+        float timeSine = (tileEntity.getWorld().getWorldTime() % 180) + partialTick;
32
+        timeSine = timeSine > 90 ? 180 - timeSine : timeSine;
33
+
34
+        int[] slotsX = new int[]{0, 0, 0, 1, 1, 2, 2, 2};
35
+        int[] slotsY = new int[]{0, 1, 2, 0, 2, 0, 1, 2};
36
+
37
+        if (dist < 16)
38
+        {
39
+            for (int i = 0; i < 8; i++)
40
+            {
41
+                ItemStack display = tileEntity.slot(i);
42
+                if (display != null)
43
+                {
44
+                    if (tileEntity.mFacing == CS.SIDE_Y_NEG || tileEntity.mFacing == CS.SIDE_X_NEG || tileEntity.mFacing == CS.SIDE_Z_NEG)
45
+                    {
46
+                        renderItem(display.copy(), timeLoop/10, 0.5 - (0.33 * (slotsX[i] - 1)), 1.1 + (timeSine/8000), 0.5 - (0.33 * (slotsY[i] - 1)), tileEntity.getWorld(), 1, 1F);
47
+                    } else {
48
+                        renderItem(display.copy(), timeLoop/10, 0.5 + (0.33 * (slotsX[i] - 1)), 1.1 + (timeSine/8000), 0.5 - (0.33 * (slotsY[i] - 1)), tileEntity.getWorld(), 1, 1F);
49
+                    }
50
+                }
51
+            }
52
+        } else if (dist < 32)
53
+        {
54
+            for (int i = 0; i < 8; i++)
55
+            {
56
+                ItemStack display = tileEntity.slot(i);
57
+                if (display != null)
58
+                {
59
+                    GL11.glEnable(GL11.GL_BLEND);
60
+                    GL11.glAlphaFunc(GL11.GL_GREATER, 0.1F);
61
+                    GL11.glDepthFunc(GL11.GL_LESS);
62
+                    OpenGlHelper.glBlendFunc(GL11.GL_ONE, GL11.GL_ONE_MINUS_SRC_ALPHA, GL11.GL_ONE, GL11.GL_ZERO);
63
+                    renderItem(display.copy(), timeLoop/10, 0.5 + (0.33 * (slotsX[i] - 1)), 1.1 + (timeSine/8000), 0.5 - (0.33 * (slotsY[i] - 1)), tileEntity.getWorld(), 1, (float)(1F - ((dist - 16F)/16F)));
64
+                    GL11.glDepthFunc(GL11.GL_LEQUAL);
65
+                    GL11.glAlphaFunc(GL11.GL_GREATER, 0.5F);
66
+                    GL11.glDisable(GL11.GL_BLEND);
67
+                }
68
+            }
69
+        }
70
+        GL11.glEnable(GL11.GL_LIGHTING);
71
+        GL11.glPopMatrix();
72
+        GL11.glPopMatrix();
73
+    }
74
+
75
+    @Override
76
+    public void renderTileEntityAt(TileEntity tileEntity, double x, double y, double z, float partialTick) {
77
+        renderTileEntityAt((CuttingBoardTileEntity)tileEntity, x, y, z, partialTick);
78
+    }
79
+}

+ 111
- 3
src/main/java/com/kbi/qwertech/tileentities/CuttingBoardTileEntity.java View File

@@ -8,10 +8,12 @@ import com.kbi.qwertech.api.tileentities.SlotScroll;
8 8
 import com.kbi.qwertech.network.packets.PacketInventorySync;
9 9
 import cpw.mods.fml.relauncher.Side;
10 10
 import cpw.mods.fml.relauncher.SideOnly;
11
+import gregapi.block.metatype.BlockStones;
11 12
 import gregapi.block.multitileentity.IMultiTileEntity;
12 13
 import gregapi.block.multitileentity.MultiTileEntityBlockInternal;
13 14
 import gregapi.data.CS;
14 15
 import gregapi.data.LH;
16
+import gregapi.data.TD;
15 17
 import gregapi.gui.ContainerClient;
16 18
 import gregapi.gui.ContainerCommon;
17 19
 import gregapi.gui.Slot_Normal;
@@ -21,6 +23,7 @@ import gregapi.render.IIconContainer;
21 23
 import gregapi.render.ITexture;
22 24
 import gregapi.tileentity.base.TileEntityBase09FacingSingle;
23 25
 import gregapi.util.ST;
26
+import gregapi.util.UT;
24 27
 import net.minecraft.block.Block;
25 28
 import net.minecraft.client.gui.FontRenderer;
26 29
 import net.minecraft.creativetab.CreativeTabs;
@@ -31,6 +34,7 @@ import net.minecraft.inventory.InventoryCrafting;
31 34
 import net.minecraft.inventory.Slot;
32 35
 import net.minecraft.item.Item;
33 36
 import net.minecraft.item.ItemStack;
37
+import net.minecraft.nbt.NBTTagCompound;
34 38
 
35 39
 import java.util.*;
36 40
 
@@ -57,6 +61,18 @@ public class CuttingBoardTileEntity extends TileEntityBase09FacingSingle impleme
57 61
         }
58 62
     }
59 63
 
64
+    public int mTexture = -1;
65
+    public int mMetafy = 0;
66
+
67
+    @Override
68
+    public void readFromNBT2(NBTTagCompound aNBT) {
69
+        super.readFromNBT2(aNBT);
70
+        if (aNBT.hasKey(NBT_TEXTURE)) {
71
+            mTexture = aNBT.getInteger(NBT_TEXTURE);
72
+            mMetafy = aNBT.getInteger("qt.metatex");
73
+        }
74
+    }
75
+
60 76
     public void sendDisplays()
61 77
     {
62 78
         for (int q = 0; q < this.invsize(); q++)
@@ -84,7 +100,95 @@ public class CuttingBoardTileEntity extends TileEntityBase09FacingSingle impleme
84 100
 
85 101
     @Override
86 102
     public boolean onBlockActivated3(EntityPlayer aPlayer, byte aSide, float aHitX, float aHitY, float aHitZ) {
87
-        return aSide > 1 && openGUI(aPlayer, 0);
103
+        if (aSide > 1 && openGUI(aPlayer, 0)) return true;
104
+        int aSlot = -1;
105
+        short sided = this.getFacing();
106
+        System.out.println("Facing " + sided);
107
+        switch (sided)
108
+        {
109
+            case CS.SIDE_Z_NEG:
110
+            {
111
+                aHitX = 1 - aHitX;
112
+                break;
113
+            }
114
+            case CS.SIDE_X_POS:
115
+            {
116
+                aHitZ = 1 - aHitZ;
117
+            }
118
+            case CS.SIDE_X_NEG:
119
+            {
120
+                float aTemp = aHitX;
121
+                aHitX = aHitZ;
122
+                aHitZ = aTemp;
123
+                break;
124
+            }
125
+            case CS.SIDE_Z_POS:
126
+            {
127
+                break; //default
128
+            }
129
+        }
130
+        if (aHitX < 0.33)
131
+        {
132
+            if (aHitZ > 0.66)
133
+            {
134
+                aSlot = 0;
135
+            } else if (aHitZ < 0.33)
136
+            {
137
+                aSlot = 2;
138
+            } else {
139
+                aSlot = 1;
140
+            }
141
+        } else if (aHitX > 0.66)
142
+        {
143
+            if (aHitZ > 0.66)
144
+            {
145
+                aSlot = 5;
146
+            } else if (aHitZ < 0.33)
147
+            {
148
+                aSlot = 7;
149
+            } else {
150
+                aSlot = 6;
151
+            }
152
+        } else {
153
+            if (aHitZ > 0.66)
154
+            {
155
+                aSlot = 3;
156
+            } else if (aHitZ < 0.33)
157
+            {
158
+                aSlot = 4;
159
+            }
160
+        }
161
+        if (aSlot > -1)
162
+        {
163
+            ItemStack item = getStackInSlot(aSlot);
164
+            ItemStack held = aPlayer.getHeldItem();
165
+            if (held != null && ST.equal(item, held))
166
+            {
167
+                while (item.stackSize < item.getMaxStackSize() && held.stackSize > 0)
168
+                {
169
+                    item.stackSize = item.stackSize + 1;
170
+                    held.stackSize = held.stackSize - 1;
171
+                }
172
+                if (held.stackSize < 1) {
173
+                    aPlayer.setCurrentItemOrArmor(0, null);
174
+                }
175
+                QTI.NW_API.sendToAllPlayersInRange(new PacketInventorySync(item, this.xCoord, this.yCoord, this.zCoord, aSlot), this.worldObj, this.xCoord, this.zCoord);
176
+                return true;
177
+            } else if (held == null && item != null)
178
+            {
179
+                aPlayer.setCurrentItemOrArmor(0, item);
180
+                setInventorySlotContents(aSlot, null);
181
+                QTI.NW_API.sendToAllPlayersInRange(new PacketInventorySync(null, this.xCoord, this.yCoord, this.zCoord, aSlot), this.worldObj, this.xCoord, this.zCoord);
182
+                return true;
183
+            } else if (held != null && item == null)
184
+            {
185
+                aPlayer.setCurrentItemOrArmor(0, null);
186
+                setInventorySlotContents(aSlot, held);
187
+                QTI.NW_API.sendToAllPlayersInRange(new PacketInventorySync(held, this.xCoord, this.yCoord, this.zCoord, aSlot), this.worldObj, this.xCoord, this.zCoord);
188
+                return true;
189
+            }
190
+        }
191
+        return false;
88 192
     }
89 193
 
90 194
     @Override
@@ -101,8 +205,12 @@ public class CuttingBoardTileEntity extends TileEntityBase09FacingSingle impleme
101 205
 
102 206
     @Override
103 207
     public ITexture getTexture2(Block aBlock, int aRenderPass, byte aSide, boolean[] aShouldSideBeRendered) {
104
-        IIconContainer returnable = aRenderPass == 0 ? icons1[aSide < 2 ? 0 : 1] : icons2[aSide < 2 ? 0 : 1];
105
-        return BlockTextureDefault.get(returnable, mRGBa);
208
+        if (mMaterial.contains(TD.Properties.STONE)) {
209
+            return BlockTextureDefault.get(((BlockStones)BlocksGT.stones[mTexture]).mIcons[mMetafy], UT.Code.getRGBInt(255, 255, 255));
210
+        } else {
211
+            IIconContainer returnable = aRenderPass == 0 ? icons1[aSide < 2 ? 0 : 1] : icons2[aSide < 2 ? 0 : 1];
212
+            return BlockTextureDefault.get(returnable, mRGBa);
213
+        }
106 214
     }
107 215
 
108 216
     // Icons

BIN
src/main/resources/assets/qwertech/textures/blocks/cooking/cutboard.png View File


BIN
src/main/resources/assets/qwertech/textures/blocks/cooking/cutside.png View File


BIN
src/main/resources/assets/qwertech/textures/blocks/cooking/woodbottom.png View File


BIN
src/main/resources/assets/qwertech/textures/blocks/cooking/woodsides.png View File


BIN
src/main/resources/assets/qwertech/textures/gui/countertop.png View File


Loading…
Cancel
Save