serge-web / serge

Serious Gaming, Evolved - web interface
https://sites.google.com/deepbluec.com/serge/
Apache License 2.0
14 stars 4 forks source link

More mapping permissions (per-force) #2950

Open IanMayo opened 2 months ago

IanMayo commented 2 months ago

The mapping permissions model we have designed [#2931 ] allow a game designer to specify that a player can move items for one force (such as their own), but not others.

We have handled whether to display delete/drag/resize buttons, but we have not restricted which shapes (layers) the control acts upon.

I suspect we need to run some logic after a button is selected. This will check the permissions, and filter which layers are active (selectable) on the plot - according to their properties.forceId. My guess is that we'll do this in the MapControls class, see what the current role can do, then loop through the layers and set them non-interactive as necessary.