Sandpit/touchmap/touchmap.py
blank_t, wall_t, door_t, spawn_t, hell_t, tick_t, room_t = range (7) ... rooms_available = [] # any room number which was deleted is placed here next_room = 1 # the next available room number to be used.
Sandpit/touchmap/touchmap.py
def to_room (self, room): self._tile = touchgui.text_tile (black, light_grey, white, mid_grey, room, self._size, self._x, self._y, self._size, self._size, delroom, "room")
Sandpit/touchmap/touchmap.py
def delroom (param, tap): global clicked, cell_array, button_array, double_tapped_cell, rooms_available clicked = True mouse = pygame.mouse.get_pos () x, y = get_cell (mouse) button = button_array.get (x + xoffset, y + yoffset) button.spawn_to_blank () rooms_available += [cell_array.get (x + xoffset, y + yoffset)] cell_array.set_contents (x + xoffset, y + yoffset, " ")
Sandpit/touchmap/touchmap.py
def myroom (name, tap): global next_tile pygame.display.update () if tap == 1: next_tile = room_t
Sandpit/touchmap/touchmap.py
def glyphs (): return [touchgui.text_tile (black, mid_grey, white, light_grey, ’S’, touchgui.unitY (0.05), touchgui.posX (0.5), touchgui.posY (1.0), 100, 100, worldspawn, "worldspawn"), touchgui.text_tile (black, mid_grey, white, light_grey, ’room’, touchgui.unitY (0.05), touchgui.posX (0.45), touchgui.posY (1.0), 100, 100, myroom, "room")]
This document was produced using groff-1.22.