summaryrefslogtreecommitdiff
path: root/NET/worlds/console/BBAppearDroneCommand.java
diff options
context:
space:
mode:
authorFuwn <[email protected]>2021-05-03 16:38:41 -0700
committerFuwn <[email protected]>2021-05-03 16:38:41 -0700
commite1e781bb2135ef78592226f1a3eaba4925702f1f (patch)
tree8a5b590463ed413e1c6eabb719130e701b95ca63 /NET/worlds/console/BBAppearDroneCommand.java
downloadworlds.jar-main.tar.xz
worlds.jar-main.zip
:star:HEADmain
Diffstat (limited to 'NET/worlds/console/BBAppearDroneCommand.java')
-rw-r--r--NET/worlds/console/BBAppearDroneCommand.java77
1 files changed, 77 insertions, 0 deletions
diff --git a/NET/worlds/console/BBAppearDroneCommand.java b/NET/worlds/console/BBAppearDroneCommand.java
new file mode 100644
index 0000000..0e9dc96
--- /dev/null
+++ b/NET/worlds/console/BBAppearDroneCommand.java
@@ -0,0 +1,77 @@
+/* */ package NET.worlds.console;
+/* */
+/* */ import NET.worlds.scape.HoloDrone;
+/* */ import java.io.DataInputStream;
+/* */ import java.io.DataOutputStream;
+/* */ import java.io.IOException;
+/* */
+/* */ public class BBAppearDroneCommand extends BlackBoxCommand
+/* */ {
+/* */ private short x;
+/* */ private short y;
+/* */ private short z;
+/* */ private short dir;
+/* */ private String room;
+/* */ private String name;
+/* */
+/* */ public BBAppearDroneCommand(String roomName, String pName, short px, short py, short pz, short pdir)
+/* */ {
+/* 19 */ this();
+/* 20 */ this.x = px;
+/* 21 */ this.y = py;
+/* 22 */ this.z = pz;
+/* 23 */ this.dir = pdir;
+/* 24 */ this.room = new String(roomName);
+/* 25 */ this.name = new String(pName);
+/* */ }
+/* */
+/* */ public BBAppearDroneCommand() {
+/* 29 */ this.commandType = 5;
+/* */ }
+/* */
+/* */ public boolean execute()
+/* */ {
+/* 34 */ HoloDrone d = new HoloDrone(null, null);
+/* 35 */ d.setName(this.name);
+/* */
+/* 37 */ NET.worlds.scape.Room r = NET.worlds.scape.World.findRoomByName(this.room);
+/* 38 */ if (r != null) {
+/* 39 */ d.appear(r, this.x, this.y, this.z, this.dir);
+/* 40 */ d.makeTag(true);
+/* 41 */ ArmyOfZombies.instance().addZombie(d);
+/* 42 */ doCallback(true);
+/* */ } else {
+/* 44 */ doCallback(false);
+/* */ }
+/* */
+/* 47 */ return true;
+/* */ }
+/* */
+/* */ public void save(DataOutputStream dos) throws IOException
+/* */ {
+/* 52 */ super.save(dos);
+/* 53 */ dos.writeShort(this.x);
+/* 54 */ dos.writeShort(this.y);
+/* 55 */ dos.writeShort(this.z);
+/* 56 */ dos.writeShort(this.dir);
+/* 57 */ dos.writeUTF(this.room);
+/* 58 */ dos.writeUTF(this.name);
+/* */ }
+/* */
+/* */ public void load(DataInputStream dis) throws IOException
+/* */ {
+/* 63 */ super.load(dis);
+/* 64 */ this.x = dis.readShort();
+/* 65 */ this.y = dis.readShort();
+/* 66 */ this.z = dis.readShort();
+/* 67 */ this.dir = dis.readShort();
+/* 68 */ this.room = new String(dis.readUTF());
+/* 69 */ this.name = new String(dis.readUTF());
+/* */ }
+/* */ }
+
+
+/* Location: C:\Program Files (x86)\Worlds Inc\WorldsPlayer - Win7\lib\worlds.jar!\NET\worlds\console\BBAppearDroneCommand.class
+ * Java compiler version: 6 (50.0)
+ * JD-Core Version: 0.7.1
+ */ \ No newline at end of file