root/src/buildables.py @ 285

Revision 285, 403 bytes (checked in by mmorton, 2 years ago)

build menus working in full, build button broken

Line 
1from building import Building, loadBuilding
2from globals import *
3import os
4
5buildingLUT = {}
6
7def loadAllBuildings():
8    buildingFiles = os.listdir(buildingDir)
9    for f in buildingFiles:
10        fileName, fileExt = os.path.splitext(f)
11        if fileExt == buildExt:
12            building = loadBuilding(f)
13            if building is not False:
14                buildingLUT[building.name] = building
15
Note: See TracBrowser for help on using the browser.