Implement a permission system
A permission system should be implemented to allow for more open lobbies while preventing people from trolling.
Permission should be broken down into groups, with two by default. The 'Admin' group has all permissions, and the 'Default' group has limited permissions.
The admin group should not be able to be modified or deleted. The default group can be modified but cannot be deleted. Other groups can be added, modified, and deleted at will.
The UI for selecting what group a player is in would look something like the following.
| Players | Group |
|---|---|
| Insprill | [x] Admin [ ] Default [ ] MyCustomGroup |
| ChaoticWagon | [ ] Admin [x] Default [ ] MyCustomGroup |
| Wiz | [x] Admin [ ] Default [x] MyCustomGroup |
The UI for creating and deleting groups would look something like the following.
| Groups |
|---|
| Admin |
| [x] Manual Switches |
| [x] Remote Switches |
| [x] Delete Cars |
| [x] Rerail Cars |
| Default |
| [x] Manual Switches |
| [ ] Remote Switches |
| [ ] Delete Cars |
| [x] Rerail Cars |
| + Create Group |
Permissions would exist for the following.
- Manual Switches: The ability to throw switches by clicking on them. The server would validate this with a simple distance-based sanity check.
- Remote Switches: The ability to throw switches with the comms remote.
- Delete Cars
- Rerail Cars
- Take Jobs
- Use Turntables
- Service Cars
- Fast Travel
- Purchase Licenses
I might suggesting including an API that other mods can use to add additional permissions, ex: Rolling Stock Ownership adding a Purchase Cars permission.