mirror of
https://github.com/KAMKEEL/CustomNPC-Plus.git
synced 2026-11-12 16:37:45 +00:00
Dialog packet needs NPC
This commit is contained in:
1 parent
ea1f5b259d
commit
54a07ffb48
1 file changed
+5
-3
@@ -25,6 +25,11 @@ public class DialogSelectPacket extends AbstractPacket {
|
||||
this.optionID = optionID;
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean needsNPC() {
|
||||
return true;
|
||||
}
|
||||
|
||||
@Override
|
||||
public Enum getType() {
|
||||
return EnumPlayerPacket.DialogSelect;
|
||||
@@ -46,9 +51,6 @@ public class DialogSelectPacket extends AbstractPacket {
|
||||
if (!(player instanceof EntityPlayerMP))
|
||||
return;
|
||||
EntityPlayerMP playerMP = (EntityPlayerMP) player;
|
||||
EntityNPCInterface npc = NoppesUtilServer.getEditingNpc(playerMP);
|
||||
if(npc == null)
|
||||
return;
|
||||
NoppesUtilPlayer.dialogSelected(in.readInt(), in.readInt(), playerMP, npc);
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user