Skip to content

Commit

Permalink
Fix missing PipeClosed trigger texture
Browse files Browse the repository at this point in the history
  • Loading branch information
multiplemonomials committed Jun 21, 2016
1 parent c10cd85 commit 112f5d5
Showing 1 changed file with 8 additions and 4 deletions.
12 changes: 8 additions & 4 deletions src/main/java/buildcraft/additionalpipes/gates/APTrigger.java
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,6 @@
import net.minecraftforge.fml.relauncher.Side;
import net.minecraftforge.fml.relauncher.SideOnly;
import buildcraft.additionalpipes.AdditionalPipes;
import buildcraft.additionalpipes.utils.Log;
import buildcraft.api.statements.IStatement;
import buildcraft.api.statements.StatementManager;

Expand All @@ -32,17 +31,22 @@ public APTrigger(String idWithoutPrefix)

this.id = "additionalpipes:" + descriptionKey;
StatementManager.statements.put(this.id, this);
texture = new ResourceLocation(AdditionalPipes.MODID, "textures/items/triggers/" + idWithoutPrefix);
texture = new ResourceLocation(AdditionalPipes.MODID, "items/triggers/" + idWithoutPrefix);

MinecraftForge.EVENT_BUS.register(this);
MinecraftForge.EVENT_BUS.register(this);

}

@SubscribeEvent
@SideOnly(Side.CLIENT)
public void stitchTextures(TextureStitchEvent.Pre event) {
sprite = event.map.getTextureExtry(texture.toString());

Log.debug("resource location: " + texture.toString());
if (sprite == null)
{
sprite = event.map.registerSprite(texture);
}

}

@Override
Expand Down

0 comments on commit 112f5d5

Please sign in to comment.