vassalengine / vassal

VASSAL, the open-source boardgame engine
https://vassalengine.org
GNU Lesser General Public License v2.1
424 stars 101 forks source link

Special player role for scenario designers #12326

Open riverwanderer opened 1 year ago

riverwanderer commented 1 year ago

This is an idea for a change to support one of the use-cases for Scenario Options, where that feature is used to set up game scenario settings not altered by players. The idea has more general application to help modules distinguish between a game that is in "scenario setup" mode and the more normal "play" mode.

Simply; a new player role "Scenario Designer" or just, "<designer>". This role would be a special player side with, similar to <observer> but subject to an additional control to prevent accidental use.

The <designer> role would have the following features:

Always available to be connected to, subject to a new setting on the Preferences Personal panel (see below). Able to amend the "Scenario Options" panel regardless of lock status. Tab update info will still be applied by Scenario Options. Excluded from auto default selection feature in the side-switcher. Only the <designer> role will be able to edit the contents of the "Scenario Notes" tab of the Notes Window.

The feature should be supported by a new Preferences checkbox on the Personal tab, along the lines: "Design [module name] scenarios:" If the checkbox is clear, the <designer> side will not be offered by the side switcher.

riverwanderer commented 1 year ago

Alternative idea for controlling <designer> role, in place of the idea above:

  1. <designer> is auto-ejected from a game prior to a game being saved.
  2. '' role cannot start or open a logfile.
  3. <designer> role is not offered by side-switcher when any other player role (not <observer>) is already taken.
  4. The side-joiner/switcher auto-joins any other player as <observer> if the role is connected
  5. OR (alternative to 3/4, if possible) an online game cannot be be started or joined by the <designer> role.

The features of the <designer> role will still cover: Amend "Scenario Options" panel regardless of lock status. Tab update info will still be applied by Scenario Options. Only the <designer> role will be able to edit the contents of the "Scenario Notes" tab of the Notes Window.

Related info:

Because some player roles may be reserved as part of scenario configuration, this new feature as specified would work best in conjunction with an alternative method for closing out other player roles in a Pre-defined Setup, such as suggested in #12545.

If the designer role is able to connect to an online game (i.e. 5 above not possible), then checks 3-4 will be vulnerable to issue #12542.