ericw-tools icon indicating copy to clipboard operation
ericw-tools copied to clipboard

Feature Request: Support entities in _external_map

Open hemebond opened this issue 3 years ago • 8 comments

The current _external_map implementation is great but it would be great to be able to combine more complex map files.

It would be great if it would just import an external map file in its entirety, not just the Worldspawn, and not do any conversions, merging entities, and brush entities, as-is.

hemebond avatar Sep 01 '22 01:09 hemebond

The new -add feature can merge map files into the current one, but it can't be specified as an entity. I don't know if this feature would make much sense as an entity.. prefabs would be hard to do this way because of name conflicts

Paril avatar Sep 01 '22 12:09 Paril

because of name conflicts

What kind of naming conflicts can you imagine?

hemebond avatar Sep 01 '22 13:09 hemebond

I guess if the external .map uses target/targetname for anything - e.g. if it contains a button targetting a door (all within the same external .map), that will break once several instances of the external .map are inserted into a main map - every button will target every door.

The only workaround for that is to use a better prefab system like TB's that lets you do selective edits to instances.

Despite that, this improvement to the _external_map system could still be useful for things that don't need target/targetname connections, but still need multiple entities (e.g. light fixtures, or prefabs that mix detail/structural), and it should be a quick change

ericwa avatar Sep 01 '22 16:09 ericwa

We could add a "prefix/suffix" option to the _external_map entity, along with a list of keys that need to be prefixed. That would allow that to work, in theory.

Paril avatar Sep 02 '22 04:09 Paril

To be honest I wasn't even imagining something that complex; but rather just importing and transforming map files as-is.

I see more involved prefab support (prefixing entity properties, etc) to be the domain of the editor itself.

hemebond avatar Sep 02 '22 04:09 hemebond

Yeah, I'm just thinking of ways people are going to use this and then complain when all of their doors open when they press a button, lol.

If it's just all simple entities though then yeah it should just work.

Paril avatar Sep 02 '22 04:09 Paril