blob: 01df71451ac63a2e452e2a668cc01e3e8fd67bdc (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
|
/* */ package NET.worlds.network;
/* */
/* */ import NET.worlds.scape.Drone;
/* */ import java.io.IOException;
/* */ import java.io.PrintStream;
/* */
/* */
/* */
/* */
/* */
/* */
/* */
/* */
/* */
/* */
/* */
/* */
/* */
/* */
/* */
/* */
/* */
/* */
/* */
/* */
/* */
/* */
/* */
/* */
/* */
/* */
/* */
/* */
/* */
/* */
/* */
/* */
/* */
/* */ public class longLocCmd
/* */ extends receivedNetPacket
/* */ {
/* */ public static final byte LONGLOCCMD = 1;
/* */ protected short _x;
/* */ protected short _y;
/* */ protected short _z;
/* */ protected short _dir;
/* */
/* */ public longLocCmd()
/* */ {
/* 50 */ this._commandType = 1;
/* */ }
/* */
/* */ public longLocCmd(short x, short y, short z, short dir) {
/* 54 */ super(null, 1);
/* */
/* 56 */ this._x = x;
/* 57 */ this._y = y;
/* 58 */ this._z = z;
/* 59 */ this._dir = dir;
/* */ }
/* */
/* */ void parseNetData(ServerInputStream data) throws IOException
/* */ {
/* 64 */ this._x = data.readShort();
/* 65 */ this._y = data.readShort();
/* 66 */ this._z = data.readShort();
/* 67 */ this._dir = data.readShort();
/* */ }
/* */
/* */ int packetSize()
/* */ {
/* 72 */ return 8 + super.packetSize();
/* */ }
/* */
/* */ void send(ServerOutputStream o) throws IOException
/* */ {
/* 77 */ super.send(o);
/* 78 */ o.writeShort(this._x);
/* 79 */ o.writeShort(this._y);
/* 80 */ o.writeShort(this._z);
/* 81 */ o.writeShort(this._dir);
/* */ }
/* */
/* */ void process(WorldServer _serv) throws Exception
/* */ {
/* 86 */ NetworkObject o = _serv.getObject(this._objID);
/* 87 */ if ((o instanceof Drone)) {
/* 88 */ this._dir = ((short)(90 - this._dir));
/* 89 */ this._dir = ((short)(360 - this._dir));
/* */
/* */
/* */
/* */
/* */
/* 95 */ ((Drone)o).longLoc(this._x, this._y, this._z, this._dir);
/* */ }
/* */
/* 98 */ if (o == null) {
/* 99 */ System.out.println("error in message: " + toString(_serv));
/* */ }
/* */ }
/* */
/* */
/* */
/* */ public String toString(WorldServer serv)
/* */ {
/* 107 */ return
/* 108 */ "LONGLOC " + this._objID.toString(serv) + " @ " + this._x + "," + this._y + "," + this._z + "," + this._dir;
/* */ }
/* */ }
/* Location: C:\Program Files (x86)\Worlds Inc\WorldsPlayer - Win7\lib\worlds.jar!\NET\worlds\network\longLocCmd.class
* Java compiler version: 6 (50.0)
* JD-Core Version: 0.7.1
*/
|