dna: Add DNAAnimProp.
This commit is contained in:
parent
174b61cb62
commit
a12c1a9221
4 changed files with 19 additions and 5 deletions
14
toontown/dna/DNAAnimProp.py
Normal file
14
toontown/dna/DNAAnimProp.py
Normal file
|
@ -0,0 +1,14 @@
|
|||
from DNAProp import DNAProp
|
||||
from DNAParser import *
|
||||
from panda3d.core import *
|
||||
|
||||
class DNAAnimProp(DNAProp):
|
||||
TAG = 'anim_prop'
|
||||
|
||||
def __init__(self, name, code, anim):
|
||||
DNAProp.__init__(self, name, code)
|
||||
|
||||
self.anim = anim
|
||||
|
||||
|
||||
registerElement(DNAAnimProp)
|
|
@ -1,14 +1,13 @@
|
|||
from DNAProp import DNAProp
|
||||
from DNAAnimProp import DNAAnimProp
|
||||
from DNAParser import *
|
||||
from panda3d.core import *
|
||||
|
||||
class DNAInteractiveProp(DNAProp):
|
||||
class DNAInteractiveProp(DNAAnimProp):
|
||||
TAG = 'interactive_prop'
|
||||
|
||||
def __init__(self, name, code, anim, cell_id='0'):
|
||||
DNAProp.__init__(self, name, code)
|
||||
DNAAnimProp.__init__(self, name, code, anim)
|
||||
|
||||
self.anim = anim
|
||||
self.cell_id = int(cell_id)
|
||||
|
||||
|
||||
|
|
|
@ -3,7 +3,7 @@ from DNAParser import *
|
|||
from panda3d.core import *
|
||||
|
||||
class DNAPropertyElement(DNASceneElement):
|
||||
PARENTS = ['prop', 'interactive_prop', 'node', 'flat_building',
|
||||
PARENTS = ['prop', 'anim_prop', 'interactive_prop', 'node', 'flat_building',
|
||||
'landmark_building', 'door', 'flat_door', 'wall', 'windows',
|
||||
'cornice', 'sign', 'baseline', 'street']
|
||||
|
||||
|
|
|
@ -16,6 +16,7 @@ import DNANode
|
|||
import DNAVisGroup
|
||||
|
||||
import DNAProp
|
||||
import DNAAnimProp
|
||||
import DNAInteractiveProp
|
||||
import DNAFlatBuilding
|
||||
import DNALandmarkBuilding
|
||||
|
|
Loading…
Reference in a new issue