@@ -41,7 +41,7 @@ public void validate() {
41
41
if (Computers .isMultiplayerClient ()) {
42
42
PacketComputers packet = new PacketComputers ();
43
43
packet .packetType = 5 ;
44
- packet .dataInt = new int []{this .xCoord , this .yCoord , this .zCoord };
44
+ packet .dataInt = new int []{this .x , this .y , this .z };
45
45
Computers .sendToServer (packet );
46
46
}
47
47
}
@@ -66,13 +66,13 @@ public boolean isDestroyed() {
66
66
/*
67
67
// WARNING - Removed try catching itself - possible behaviour change.
68
68
*/
69
- public void updateEntity () {
69
+ public void tick () {
70
70
double dt = 0.05 ;
71
71
if (!Computers .isMultiplayerClient ()) {
72
72
PacketComputers packet ;
73
73
this .m_computer .advance (dt );
74
74
if (this .m_computer .pollChanged ()) {
75
- Computers .notifyBlockChange (this .worldObj , this .xCoord , this .yCoord , this .zCoord , Computers .computer .id );
75
+ Computers .notifyBlockChange (this .worldObj , this .x , this .y , this .z , Computers .computer .id );
76
76
if (Computers .isMultiplayerServer ()) {
77
77
packet = this .createOutputChangedPacket ();
78
78
Computers .sendToAllPlayers (packet );
@@ -126,7 +126,7 @@ public void keyTyped(char ch, int key) {
126
126
} else {
127
127
PacketComputers packet = new PacketComputers ();
128
128
packet .packetType = 2 ;
129
- packet .dataInt = new int []{this .xCoord , this .yCoord , this .zCoord , key };
129
+ packet .dataInt = new int []{this .x , this .y , this .z , key };
130
130
packet .dataString = new String []{"" + ch };
131
131
Computers .sendToServer (packet );
132
132
}
@@ -138,7 +138,7 @@ public void terminate() {
138
138
} else {
139
139
PacketComputers packet = new PacketComputers ();
140
140
packet .packetType = 6 ;
141
- packet .dataInt = new int []{this .xCoord , this .yCoord , this .zCoord };
141
+ packet .dataInt = new int []{this .x , this .y , this .z };
142
142
Computers .sendToServer (packet );
143
143
}
144
144
}
@@ -149,7 +149,7 @@ public void reboot() {
149
149
} else {
150
150
PacketComputers packet = new PacketComputers ();
151
151
packet .packetType = 9 ;
152
- packet .dataInt = new int []{this .xCoord , this .yCoord , this .zCoord };
152
+ packet .dataInt = new int []{this .x , this .y , this .z };
153
153
Computers .sendToServer (packet );
154
154
}
155
155
}
@@ -160,7 +160,7 @@ public void shutdown() {
160
160
} else {
161
161
PacketComputers packet = new PacketComputers ();
162
162
packet .packetType = 12 ;
163
- packet .dataInt = new int []{this .xCoord , this .yCoord , this .zCoord };
163
+ packet .dataInt = new int []{this .x , this .y , this .z };
164
164
Computers .sendToServer (packet );
165
165
}
166
166
}
@@ -233,13 +233,13 @@ public void playRecord(String record) {
233
233
if (Computers .isMultiplayerServer ()) {
234
234
PacketComputers packet = new PacketComputers ();
235
235
packet .packetType = 7 ;
236
- packet .dataInt = new int []{this .xCoord , this .yCoord , this .zCoord };
236
+ packet .dataInt = new int []{this .x , this .y , this .z };
237
237
if (record != null ) {
238
238
packet .dataString = new String []{record };
239
239
}
240
240
Computers .sendToAllPlayers (packet );
241
241
} else {
242
- this .worldObj .playRecord (record , this .xCoord , this .yCoord , this .zCoord );
242
+ this .worldObj .playRecord (record , this .x , this .y , this .z );
243
243
}
244
244
}
245
245
@@ -252,9 +252,9 @@ private void tryEjectDisk(int targetSide, int testSide, int i, int j, int k) {
252
252
253
253
public void ejectDisk (int side ) {
254
254
if (!Computers .isMultiplayerClient ()) {
255
- int i = this .xCoord ;
256
- int j = this .yCoord ;
257
- int k = this .zCoord ;
255
+ int i = this .x ;
256
+ int j = this .y ;
257
+ int k = this .z ;
258
258
int m = this .worldObj .getBlockMetadata (i , j , k );
259
259
this .tryEjectDisk (side , BlockComputer .getLocalSide (0 , m ), i , j + 1 , k );
260
260
this .tryEjectDisk (side , BlockComputer .getLocalSide (1 , m ), i , j - 1 , k );
@@ -281,7 +281,7 @@ private PacketComputers createTerminalChangedPacket(boolean _includeAllText) {
281
281
}
282
282
PacketComputers packet = new PacketComputers ();
283
283
packet .packetType = 3 ;
284
- packet .dataInt = new int []{this .xCoord , this .yCoord , this .zCoord , this .m_terminal .getCursorX (), this .m_terminal .getCursorY (), lineChangeMask };
284
+ packet .dataInt = new int []{this .x , this .y , this .z , this .m_terminal .getCursorX (), this .m_terminal .getCursorY (), lineChangeMask };
285
285
packet .dataString = new String [lineChangeCount ];
286
286
int n = 0 ;
287
287
for (int y = 0 ; y < this .m_terminal .getHeight (); ++y ) {
@@ -306,7 +306,7 @@ private PacketComputers createOutputChangedPacket() {
306
306
if (!this .m_computer .getOutput (i )) continue ;
307
307
flags += 1 << i + 2 ;
308
308
}
309
- packet .dataInt = new int []{this .xCoord , this .yCoord , this .zCoord , flags , this .m_computer .getBundledOutput (0 ), this .m_computer .getBundledOutput (1 ), this .m_computer .getBundledOutput (2 ), this .m_computer .getBundledOutput (3 ), this .m_computer .getBundledOutput (3 ), this .m_computer .getBundledOutput (5 )};
309
+ packet .dataInt = new int []{this .x , this .y , this .z , flags , this .m_computer .getBundledOutput (0 ), this .m_computer .getBundledOutput (1 ), this .m_computer .getBundledOutput (2 ), this .m_computer .getBundledOutput (3 ), this .m_computer .getBundledOutput (3 ), this .m_computer .getBundledOutput (5 )};
310
310
return packet ;
311
311
}
312
312
@@ -375,7 +375,7 @@ public void handlePacket(PacketComputers packet, EntityPlayer player) {
375
375
this .m_clientData .output [i ] = (flags & 1 << i + 2 ) > 0 ;
376
376
this .m_clientData .bundledOutput [i ] = packet .dataInt [4 + i ];
377
377
}
378
- Computers .notifyBlockChange (this .worldObj , this .xCoord , this .yCoord , this .zCoord , Computers .computer .id );
378
+ Computers .notifyBlockChange (this .worldObj , this .x , this .y , this .z , Computers .computer .id );
379
379
break ;
380
380
}
381
381
case 7 : {
0 commit comments