Restricted visibility option for simple-entity-with-* types
Posted: Wed Jan 17, 2018 7:35 pm
As far as I'm aware, there's currently no way of doing things that are user-interface related but within the game world space.
It would be extremely useful to be able to create things within the world that are only visible to specific players, or a specific force.
It seems like a convenient way to do this, is if the simple-entity-with-owner and simple-entity-with-force prototypes had an option for "only_visible_to_owner".
If true, it would simply mean that the entity would only render for the owning player/force. For non owners it would not render but otherwise be unaffected.
The default value for only_visible_to_owner would be false, and if false the entities would act exactly as they do now.
Use-cases:
Any time you need to make a UI-style in-game indicator that has relevance to only 1 player, such as the Even Distribution mod.
In the AAI Programmable Vehicles mod you can order vehicles around. I'm in the process of adding additional overlays that show where a vehicle is going. This information is only relevant to the player selecting the vehicles, other people don't need the extra screen clutter. Also in a PVP mode this would be visible to the enemy so they'd see attack vectors that they shouldn't.
Various other PVP applications.
It would be extremely useful to be able to create things within the world that are only visible to specific players, or a specific force.
It seems like a convenient way to do this, is if the simple-entity-with-owner and simple-entity-with-force prototypes had an option for "only_visible_to_owner".
If true, it would simply mean that the entity would only render for the owning player/force. For non owners it would not render but otherwise be unaffected.
The default value for only_visible_to_owner would be false, and if false the entities would act exactly as they do now.
Use-cases:
Any time you need to make a UI-style in-game indicator that has relevance to only 1 player, such as the Even Distribution mod.
In the AAI Programmable Vehicles mod you can order vehicles around. I'm in the process of adding additional overlays that show where a vehicle is going. This information is only relevant to the player selecting the vehicles, other people don't need the extra screen clutter. Also in a PVP mode this would be visible to the enemy so they'd see attack vectors that they shouldn't.
Various other PVP applications.