effect command
This commit is contained in:
parent
6c0bd5481f
commit
66421e806e
16 changed files with 393 additions and 16 deletions
|
@ -17,6 +17,8 @@ import game.util.ExtMath;
|
|||
import game.vars.BoolVar;
|
||||
import game.vars.CVar;
|
||||
import game.window.Keysym;
|
||||
import game.world.BlockPos;
|
||||
import game.world.HitPosition;
|
||||
|
||||
public class GuiConsole extends Gui implements Textbox.Callback {
|
||||
public static final GuiConsole INSTANCE = new GuiConsole();
|
||||
|
@ -238,22 +240,22 @@ public class GuiConsole extends Gui implements Textbox.Callback {
|
|||
{
|
||||
if (currentText.length() >= 1)
|
||||
{
|
||||
// BlockPos blockpos = null;
|
||||
// int eid = -1;
|
||||
//
|
||||
// if (this.gm.pointed != null && this.gm.pointed.type == HitPosition.ObjectType.BLOCK)
|
||||
// {
|
||||
// blockpos = this.gm.pointed.block;
|
||||
// }
|
||||
// else if (this.gm.pointed != null && this.gm.pointed.type == HitPosition.ObjectType.ENTITY)
|
||||
// {
|
||||
// eid = this.gm.pointed.entity.getId();
|
||||
// }
|
||||
BlockPos blockpos = null;
|
||||
int eid = -1;
|
||||
if (this.gm.pointed != null && this.gm.pointed.type == HitPosition.ObjectType.BLOCK)
|
||||
{
|
||||
blockpos = this.gm.pointed.block;
|
||||
}
|
||||
else if (this.gm.pointed != null && this.gm.pointed.type == HitPosition.ObjectType.ENTITY)
|
||||
{
|
||||
eid = this.gm.pointed.entity.getId();
|
||||
blockpos = new BlockPos(this.gm.pointed.entity);
|
||||
}
|
||||
if(currentText.startsWith("/")) {
|
||||
if(this.gm.thePlayer != null) {
|
||||
currentText = currentText.substring(1);
|
||||
this.prefixFirst = currentText.split(" ", -1).length == 1 ? "/" : null;
|
||||
this.gm.thePlayer.sendQueue.addToSendQueue(new CPacketComplete(currentText));
|
||||
this.gm.thePlayer.sendQueue.addToSendQueue(new CPacketComplete(currentText, eid, blockpos));
|
||||
this.waitingOnAutocomplete = true;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -24,7 +24,7 @@ public class GuiInfo extends Gui {
|
|||
"Albert Pham - WorldEdit (Snippets)",
|
||||
"Joonas Vali - NameGenerator",
|
||||
"LWJGL 2.9.4-nightly-20150209 - Project, Vector*, Matrix*",
|
||||
"Guava 17.0 - collect + future + Predicates",
|
||||
"Guava 17.0 - collect, future, Predicates",
|
||||
"JOrbis 20101023 (JCraft) - jogg, jorbis, CodecJOrbis",
|
||||
"MC 1.8.9"
|
||||
};
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue