OpenJK icon indicating copy to clipboard operation
OpenJK copied to clipboard

[Feature Request] Parenting / Linking Entities to Other Entities (Similar to Soldier of Fortune II)

Open stoofphen opened this issue 1 year ago • 2 comments

Applicable mainly to Singleplayer, although would be useful for Multiplayer nonetheless. Not sure if this will be seen / considered, however it is something I'd appreciate like many other mappers to create a bit more dynamic events, things like ships with multiple parts and effects that all move in unison.

Basically significantly expanding modding capability to be able to parent entities such as FX_Runner, func_doors (virtually any dynamic entity) to 'stick' to another entity; such as a func_train or a moveable func_static. This capability is present in Raven's Soldier of Fortune II, using somewhat a similar engine as Jedi Knight II / Academy.

The set-up is quite simple (in terms of parenting entities in editor) however not sure how easy this would be to implement in the code. Essentially, you assign one entity (the desired parent entity, like a func_train) with the key 'parent' and value '1' and a targetname of course. Then create an additional entity named "func_brushmodel_child" - this entity is then set a key 'brushParent' and value is the targetname of the parent entity. From thereon, you add the key 'brushParent' with value (parent's targetname) to any entity that you want to link to the parent, as well as 'brushChild' with the targetname of the associated "func_brushmodel_child" entity. My understanding is that this "func_brushmodel_child" acts a sort of intermediary, not sure exactly of its true function however.

To complement this feature, being able to enable / disable parenting via an ICARUS script would make sense.

Thanks for reading!

stoofphen avatar May 01 '23 11:05 stoofphen