# LevelStyleManager

from direct.leveleditor.LevelStyleManager import LevelStyleManager

Class which reads in style files and manages class variables

## Inheritance:

LevelStyleManager:

## Methods of LevelStyleManager:

__init__
createBaselineStyleAttributes
createBaselineStyleDictionary
createBaselineStyleMenu
createBaselineStyleSample
createBuildingStyleAttributes
createBuildingStyleDictionary
createBuildingStyleMenu
createBuildingStyleSample
createColorAttributes
createColorDictionary
createColorMenu
createColorMenus
createDNAAttributes
createDNAPieMenu
createMiscAttribute
createMiscAttributes
createScrollMenu
createTextPieMenu
createWallStyleAttributes
createWallStyleDictionary
createWallStyleMenu
createWallStyleSample
extractBaselineStyle
extractWallStyle
getAttribute
getCatalogCode
getCatalogCodes
getCatalogCodesSuffix
getColorDictionary
getEditMode
getStyleFileData
hasAttribute
initializeBaselineStyleDictionary
initializeBuildingStyleDictionary
initializeWallStyleDictionary
printFlatBuildingStyle
printWallStyle
setDNAFlatBuildingStyle
setDNAWallStyle
setEditMode

__init__ def __init__(self, NEIGHBORHOODS=[], NEIGHBORHOOD_CODES={}) Undocumented function.

createBaselineStyleAttributes def createBaselineStyleAttributes(self) Create a baselineStyle entry in the attribute dictionary This will be a dictionary of style attributes, one per neighborhood

createBaselineStyleDictionary def createBaselineStyleDictionary(self, neighborhood) Create a dictionary of baseline styles for a neighborhood

createBaselineStyleMenu def createBaselineStyleMenu(self, neighborhood, dictionary) Create a baseline style pie menu

createBaselineStyleSample def createBaselineStyleSample(self, baselineStyle) Create a style sample using the DNA info in the style

createBuildingStyleAttributes def createBuildingStyleAttributes(self) Create a buildingStyle entry in the attribute dictionary This will be a dictionary of style attributes, one per neighborhood This information is sorted and stored by num walls, building height, and building type (e.g. 10_20, or 10_10_10).

createBuildingStyleDictionary def createBuildingStyleDictionary(self, neighborhood) Create a dictionary of wall styles for a neighborhood

createBuildingStyleMenu def createBuildingStyleMenu(self, neighborhood, dictionary) Create a wall style pie menu

createBuildingStyleSample def createBuildingStyleSample(self, bldgStyle) Create a style sample using the DNA info in the style

createColorAttributes def createColorAttributes(self) Undocumented function.

createColorDictionary def createColorDictionary(self, neighborhood) Undocumented function.

createColorMenu def createColorMenu(self, menuName, colorList, radius=0.7, sf=2.0) Undocumented function.

createColorMenus def createColorMenus(self, neighborhood, dictionary) Undocumented function.

createDNAAttributes def createDNAAttributes(self) Undocumented function.

createDNAPieMenu def createDNAPieMenu(self, dnaType, dnaList, radius=0.7, sf=1.0) Undocumented function.

createMiscAttribute def createMiscAttribute(self, miscType, miscList, sf=3.0) Undocumented function.

createMiscAttributes def createMiscAttributes(self) Undocumented function.

createScrollMenu def createScrollMenu(self, dnaType, textList) Undocumented function.

createTextPieMenu def createTextPieMenu(self, dnaType, textList, radius=0.7, sf=1.0) Undocumented function.

createWallStyleAttributes def createWallStyleAttributes(self) Create a wallStyle entry in the attribute dictionary This will be a dictionary of style attributes, one per neighborhood

createWallStyleDictionary def createWallStyleDictionary(self, neighborhood) Create a dictionary of wall styles for a neighborhood

createWallStyleMenu def createWallStyleMenu(self, neighborhood, dictionary) Create a wall style pie menu

createWallStyleSample def createWallStyleSample(self, wallStyle) Create a style sample using the DNA info in the style

extractBaselineStyle def extractBaselineStyle(self, styleData) Pull out one style from a list of style data. Will keep processing data until endBaselineStyle of end of data is reached. Returns a baseline style and remaining styleData.

extractWallStyle def extractWallStyle(self, styleData) Pull out one style from a list of style data. Will keep processing data until endWallStyle of end of data is reached. Returns a wall style and remaining styleData.

getAttribute def getAttribute(self, attribute) Return specified attribute for current neighborhood

getCatalogCode def getCatalogCode(self, category, i) Undocumented function.

getCatalogCodes def getCatalogCodes(self, category) Undocumented function.

getCatalogCodesSuffix def getCatalogCodesSuffix(self, category, suffix) Undocumented function.

getColorDictionary def getColorDictionary(self, colorData) Undocumented function.

getEditMode def getEditMode(self) Get current neighborhood editing mode

getStyleFileData def getStyleFileData(self, filename) Open the specified file and strip out unwanted whitespace and empty lines. Return file as list, one file line per element.

hasAttribute def hasAttribute(self, attribute) Return specified attribute for current neighborhood

initializeBaselineStyleDictionary def initializeBaselineStyleDictionary(self, styleData, neighborhood) Fill in the baseline style dictionary with data from the style file

initializeBuildingStyleDictionary def initializeBuildingStyleDictionary(self, styleData, neighborhood) Fill in the building style dictionary with data from the style file

initializeWallStyleDictionary def initializeWallStyleDictionary(self, styleData, neighborhood) Fill in the wall style dictionary with data from the style file

printFlatBuildingStyle def printFlatBuildingStyle(self, building) Undocumented function.

printWallStyle def printWallStyle(self, wall) Undocumented function.

setDNAFlatBuildingStyle def setDNAFlatBuildingStyle(self, fb, bldgStyle, width=10.0, heightList=None, name='building') Set DNAFlatBuilding style.

setDNAWallStyle def setDNAWallStyle(self, wall, style, height=10.0, width=None) Set DNAWall to input style.

setEditMode def setEditMode(self, mode) Set current neighborhood editing mode