Esempio n. 1
0
File: tiles.py Progetto: pvh/thegrid
def add_defender(grid, coord, player):
    # Rename the defending coord
    db.rename(coord.dbid, "def:" + coord.dbid)
    coord['type'] = 8
    coord['health'] = 25
    coord['player'] = player['pid']
    db.zadd(grid.dbid + ":def", str(coord), int(time()))
    UpdateManager.sendCoord(grid, coord)
    return True
Esempio n. 2
0
File: tiles.py Progetto: pvh/thegrid
def add_infector(grid, coord, player):
    db.zadd(grid.dbid + ":inf", str(coord), int(time()))
    return True