Browse Source

Dont know why I didnt just check isDead instead of doing getBlock

Gregorius Techneticies 3 months ago
parent
commit
555aebe8e2
Signed by: Gregorius Techneticies <gregoriustech@gmail.com> GPG Key ID: 1B693EA14F2FD70F

+ 26
- 4
src/main/java/gregapi/tileentity/base/TileEntityBase04MultiTileEntities.java View File

@@ -176,27 +176,49 @@ public abstract class TileEntityBase04MultiTileEntities extends TileEntityBase03
176 176
 		if (tRegistry != null) rList.add(tRegistry.getItem(mMTEID, writeItemNBT(UT.NBT.make())));
177 177
 		return rList;
178 178
 	}
179
+	
179 180
 	public void popOff() {
180
-		if (getBlockOffset(0,0,0) == NB) return;
181
+		if (isDead()) return;
181 182
 		for (ItemStack tStack : getDrops(0, F)) ST.drop(worldObj, xCoord, yCoord, zCoord, tStack);
182 183
 		setToAir();
183 184
 	}
184 185
 	public void popOff(Entity aEntity) {
185
-		if (getBlockOffset(0,0,0) == NB) return;
186
+		if (isDead()) return;
186 187
 		for (ItemStack tStack : getDrops(0, F)) ST.drop(aEntity.worldObj, aEntity.posX, aEntity.posY, aEntity.posZ, tStack);
187 188
 		setToAir();
188 189
 	}
189 190
 	public void popOff(World aWorld, double aX, double aY, double aZ) {
190
-		if (getBlockOffset(0,0,0) == NB) return;
191
+		if (isDead()) return;
191 192
 		for (ItemStack tStack : getDrops(0, F)) ST.drop(aWorld, aX, aY, aZ, tStack);
192 193
 		setToAir();
193 194
 	}
194 195
 	public void popOff(World aWorld, ChunkCoordinates aCoords) {
195
-		if (getBlockOffset(0,0,0) == NB) return;
196
+		if (isDead()) return;
196 197
 		for (ItemStack tStack : getDrops(0, F)) ST.drop(aWorld, aCoords, tStack);
197 198
 		setToAir();
198 199
 	}
199 200
 	
201
+	public void burnOff() {
202
+		if (isDead()) return;
203
+		for (ItemStack tStack : getDrops(0, F)) ST.drop(worldObj, xCoord, yCoord, zCoord, tStack);
204
+		setToFire();
205
+	}
206
+	public void burnOff(Entity aEntity) {
207
+		if (isDead()) return;
208
+		for (ItemStack tStack : getDrops(0, F)) ST.drop(aEntity.worldObj, aEntity.posX, aEntity.posY, aEntity.posZ, tStack);
209
+		setToFire();
210
+	}
211
+	public void burnOff(World aWorld, double aX, double aY, double aZ) {
212
+		if (isDead()) return;
213
+		for (ItemStack tStack : getDrops(0, F)) ST.drop(aWorld, aX, aY, aZ, tStack);
214
+		setToFire();
215
+	}
216
+	public void burnOff(World aWorld, ChunkCoordinates aCoords) {
217
+		if (isDead()) return;
218
+		for (ItemStack tStack : getDrops(0, F)) ST.drop(aWorld, aCoords, tStack);
219
+		setToFire();
220
+	}
221
+	
200 222
 	public ItemStack toStack() {
201 223
 		MultiTileEntityRegistry tRegistry = MultiTileEntityRegistry.getRegistry(mMTERegistry);
202 224
 		if (tRegistry != null) return tRegistry.getItem(mMTEID, writeItemNBT(UT.NBT.make()));

Loading…
Cancel
Save