crash with FSM._init__

  File "toontown/distributed/ToontownClientRepository.py", line 336, in handleAvatarResponseMsg
    localAvatar = LocalToon.LocalToon(self)
  File "toontown/toon/LocalToon.py", line 84, in __init__
    DistributedToon.DistributedToon.__init__(self, cr)
  File "toontown/toon/DistributedToon.py", line 83, in __init__
    DistributedPlayer.DistributedPlayer.__init__(self, cr)
  File "otp/avatar/DistributedPlayer.py", line 35, in __init__
    DistributedAvatar.DistributedAvatar.__init__(self, cr)
  File "otp/avatar/DistributedAvatar.py", line 26, in __init__
    Avatar.__init__(self)
  File "otp/avatar/Avatar.py", line 49, in __init__
    self.nametag = NametagGroup()
  File "toontown/nametag/NametagGroup.py", line 55, in __init__
    self.nametag2d = Nametag2d()
  File "toontown/nametag/Nametag2d.py", line 26, in __init__
    Clickable2d.__init__(self, 'Nametag2d')
  File "toontown/toontowngui/Clickable.py", line 8, in __init__
    FSM.__init__(self, name)
  File "/Developer/Panda3D/direct/fsm/FSM.py", line 158, in __init__
    self.state = 'Off'
TypeError: C++ object is not yet constructed, or already destructed.
   def __init__(self, name):
        FSM.__init__(self, name)
        PandaNode.__init__(self, name)
        DirectObject.__init__(self)

Your class inherits from PandaNode, but PandaNode already provides a property called ‘state’ that conflicts with the one in FSM.

To fix this, I suppose we could rename the ‘state’ variable to something else in FSM.py. But in this case you could also wonder whether inheriting from both PandaNode and FSM is the right thing to do, or whether instead you should use composition (ie. storing the node as a member of the class instead).