import ShowBase, helpful sample
This commit is contained in:
parent
e10b203bf2
commit
7f8b3683ee
|
|
@ -1,5 +1,6 @@
|
|||
"""SpecUtil module: contains utility functions for creating and managing level specs"""
|
||||
|
||||
from ShowBaseGlobal import *
|
||||
import LevelSpec
|
||||
import LevelConstants
|
||||
import LevelUtil
|
||||
|
|
@ -14,6 +15,13 @@ def makeNewSpec(filename, modelPath, entTypeModule=EntityTypes):
|
|||
privUpdateSpec(spec, modelPath, entTypeModule)
|
||||
spec.saveToDisk(filename, makeBackup=0)
|
||||
|
||||
"""
|
||||
import SpecUtil
|
||||
import SellbotLegFactorySpec
|
||||
import FactoryEntityTypes
|
||||
SpecUtil.updateSpec(SellbotLegFactorySpec, FactoryEntityTypes, 'phase_9/models/cogHQ/newModel')
|
||||
"""
|
||||
|
||||
def updateSpec(specModule, entTypeModule=EntityTypes, modelPath=None):
|
||||
"""Call this to update an existing levelSpec to work with a new level
|
||||
model. If the level model has a new path, pass it in as 'modelPath'.
|
||||
|
|
|
|||
Loading…
Reference in New Issue