Archive 17/01/2023.

URHO3D_OBJECT base type

sabotage3d

Hi guys I switched to 1.5 from 1.4 and I have a question for the new URHO3D_OBJECT. In 1.4 we just defined OBJECT(typeName) and we had seperate macro for the BASEOBJECT wich wasn’t mandatory if I am not mistaken. Now we have URHO3D_OBJECT(typeName, baseTypeName), where we always have to specify the base type. For the base type do we have to specify a base class from Urho3d or it can be any other base class for example:

class State: public LogicComponent { ... } class JumpState: public State { ... }
Do we need URHO3D_OBJECT(JumpState, State) or URHO3D_OBJECT(JumpState, LogicComponent)?

ghidra

This would be correct:

for state

 URHO3D_OBJECT(State, LogicComponent)

for jumpsate

 URHO3D_OBJECT(JumpState, State)
sabotage3d

Thanks It makes sense now.