Renamed QuantumLeap
This commit is contained in:
+14
@@ -0,0 +1,14 @@
|
|||||||
|
package appeng.me.cache.helpers;
|
||||||
|
|
||||||
|
import appeng.api.networking.IGridConnection;
|
||||||
|
|
||||||
|
public class ConnectionWrapper
|
||||||
|
{
|
||||||
|
|
||||||
|
public IGridConnection connection;
|
||||||
|
|
||||||
|
public ConnectionWrapper(IGridConnection gc) {
|
||||||
|
connection = gc;
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
@@ -11,10 +11,10 @@ import appeng.api.AEApi;
|
|||||||
import appeng.api.events.LocatableEventAnnounce;
|
import appeng.api.events.LocatableEventAnnounce;
|
||||||
import appeng.api.events.LocatableEventAnnounce.LocatableEvent;
|
import appeng.api.events.LocatableEventAnnounce.LocatableEvent;
|
||||||
import appeng.api.features.ILocatable;
|
import appeng.api.features.ILocatable;
|
||||||
import appeng.api.networking.IGridConnection;
|
|
||||||
import appeng.api.networking.IGridHost;
|
import appeng.api.networking.IGridHost;
|
||||||
import appeng.api.networking.IGridNode;
|
import appeng.api.networking.IGridNode;
|
||||||
import appeng.api.util.WorldCoord;
|
import appeng.api.util.WorldCoord;
|
||||||
|
import appeng.me.cache.helpers.ConnectionWrapper;
|
||||||
import appeng.me.cluster.IAECluster;
|
import appeng.me.cluster.IAECluster;
|
||||||
import appeng.tile.qnb.TileQuantumBridge;
|
import appeng.tile.qnb.TileQuantumBridge;
|
||||||
import appeng.util.iterators.ChainedIterator;
|
import appeng.util.iterators.ChainedIterator;
|
||||||
@@ -22,13 +22,6 @@ import appeng.util.iterators.ChainedIterator;
|
|||||||
public class QuantumCluster implements ILocatable, IAECluster
|
public class QuantumCluster implements ILocatable, IAECluster
|
||||||
{
|
{
|
||||||
|
|
||||||
class QuantumLeap
|
|
||||||
{
|
|
||||||
|
|
||||||
IGridConnection connection;
|
|
||||||
|
|
||||||
};
|
|
||||||
|
|
||||||
public WorldCoord min;
|
public WorldCoord min;
|
||||||
public WorldCoord max;
|
public WorldCoord max;
|
||||||
public boolean isDestroyed = false;
|
public boolean isDestroyed = false;
|
||||||
@@ -37,7 +30,7 @@ public class QuantumCluster implements ILocatable, IAECluster
|
|||||||
private long thisSide;
|
private long thisSide;
|
||||||
private long otherSide;
|
private long otherSide;
|
||||||
|
|
||||||
QuantumLeap connection;
|
ConnectionWrapper connection;
|
||||||
|
|
||||||
public TileQuantumBridge Ring[];
|
public TileQuantumBridge Ring[];
|
||||||
private TileQuantumBridge center;
|
private TileQuantumBridge center;
|
||||||
@@ -142,8 +135,8 @@ public class QuantumCluster implements ILocatable, IAECluster
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
QuantumLeap ql = sideA.connection = sideB.connection = new QuantumLeap();
|
ConnectionWrapper ql = sideA.connection = sideB.connection = new ConnectionWrapper( AEApi.instance().createGridConnection( sideA.getNode(),
|
||||||
ql.connection = AEApi.instance().createGridConnection( sideA.getNode(), sideB.getNode() );
|
sideB.getNode() ) );
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
shutdown = true;
|
shutdown = true;
|
||||||
@@ -157,7 +150,7 @@ public class QuantumCluster implements ILocatable, IAECluster
|
|||||||
{
|
{
|
||||||
connection.connection.destroy();
|
connection.connection.destroy();
|
||||||
connection.connection = null;
|
connection.connection = null;
|
||||||
connection = new QuantumLeap();
|
connection = new ConnectionWrapper( null );
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user