Exemple #1
0
    def addTileEntity(self, ref):
        x, y, z = ref.Position
        cx, cz = chunk_pos(x, z)
        chunk = self.getChunk(cx, cz, create=True)
        existing = [old for old in chunk.TileEntities if old.Position == (x, y, z)]
        for e in existing:
            chunk.removeTileEntity(e)

        chunk.addTileEntity(ref.copy())
Exemple #2
0
    def addTileEntity(self, ref):
        x, y, z = ref.Position
        cx, cz = chunk_pos(x, z)
        chunk = self.getChunk(cx, cz, create=True)
        existing = [old for old in chunk.TileEntities
                    if old.Position == (x, y, z)]
        for e in existing:
            chunk.removeTileEntity(e)

        chunk.addTileEntity(ref.copy())
Exemple #3
0
 def addEntity(self, ref):
     x, y, z = ref.Position
     cx, cz = chunk_pos(x, z)
     chunk = self.getChunk(cx, cz, create=True)
     chunk.addEntity(ref.copy())
Exemple #4
0
 def addEntity(self, ref):
     x, y, z = ref.Position
     cx, cz = chunk_pos(x, z)
     chunk = self.getChunk(cx, cz, create=True)
     chunk.addEntity(ref.copy())