Added notes to right click of PartMech and fixed a client side debug turning on
This commit is contained in:
parent
8e889773fd
commit
6c3436d36d
1 changed files with 28 additions and 23 deletions
|
@ -69,11 +69,13 @@ public abstract class PartMechanical extends JCuboidPart implements JNormalOcclu
|
||||||
if (ResonantEngine.runningAsDev)
|
if (ResonantEngine.runningAsDev)
|
||||||
{
|
{
|
||||||
if (itemStack != null)
|
if (itemStack != null)
|
||||||
{
|
|
||||||
if (itemStack.getItem().itemID == Item.stick.itemID)
|
|
||||||
{
|
{
|
||||||
if (!world().isRemote)
|
if (!world().isRemote)
|
||||||
{
|
{
|
||||||
|
if (itemStack.getItem().itemID == Item.stick.itemID)
|
||||||
|
{
|
||||||
|
|
||||||
|
//Set the nodes debug mode
|
||||||
if (!ControlKeyModifer.isControlDown(player))
|
if (!ControlKeyModifer.isControlDown(player))
|
||||||
{
|
{
|
||||||
this.node.doDebug = !this.node.doDebug;
|
this.node.doDebug = !this.node.doDebug;
|
||||||
|
@ -81,23 +83,25 @@ public abstract class PartMechanical extends JCuboidPart implements JNormalOcclu
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
|
//Opens a debug GUI
|
||||||
if (frame == null)
|
if (frame == null)
|
||||||
{
|
{
|
||||||
frame = new GearDebugFrame(this);
|
frame = new GearDebugFrame(this);
|
||||||
frame.showDebugFrame();
|
frame.showDebugFrame();
|
||||||
}
|
} //Closes the debug GUI
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
frame.closeDebugFrame();
|
frame.closeDebugFrame();
|
||||||
frame = null;
|
frame = null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
|
||||||
}
|
}//Changes the debug cue of the node
|
||||||
else if (itemStack.getItem().itemID == Item.blazeRod.itemID)
|
else if (itemStack.getItem().itemID == Item.blazeRod.itemID)
|
||||||
{
|
{
|
||||||
if (this.node.doDebug)
|
if (this.node.doDebug)
|
||||||
{
|
{
|
||||||
|
//Increases the cue count
|
||||||
if (!ControlKeyModifer.isControlDown(player))
|
if (!ControlKeyModifer.isControlDown(player))
|
||||||
{
|
{
|
||||||
if (this.node.debugCue + 1 <= this.node.maxDebugCue)
|
if (this.node.debugCue + 1 <= this.node.maxDebugCue)
|
||||||
|
@ -107,7 +111,7 @@ public abstract class PartMechanical extends JCuboidPart implements JNormalOcclu
|
||||||
player.addChatMessage("[Debug] PartMechanical is at max debug cue");
|
player.addChatMessage("[Debug] PartMechanical is at max debug cue");
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}//Decreases the cue count
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
if (this.node.debugCue - 1 >= this.node.minDebugCue)
|
if (this.node.debugCue - 1 >= this.node.minDebugCue)
|
||||||
|
@ -123,6 +127,7 @@ public abstract class PartMechanical extends JCuboidPart implements JNormalOcclu
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
}
|
||||||
return super.activate(player, hit, itemStack);
|
return super.activate(player, hit, itemStack);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue