Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Expand permissions system #1267

Merged

Conversation

joaoburatto
Copy link
Contributor

@joaoburatto joaoburatto commented Sep 26, 2023

Summary

Expands and cleans up the permissions systems to facilitate changes, adds the missing change permission and save permissions functionality.

Creates a permission settings file to define if a server/host should get the owner permission whenever they join the game.

Adds the functionality to change a user's permission, and the functionality to save the permissions back to the permissions file, this can be used if the permissions are changed runtime, ex. when an admin gives a non admin the admin permission.

PR checklist

  • The game builds properly without errors.
  • No unrelated changes are present.
  • No "trash" files are committed.
  • Relevant code is documented.
  • Update the related GitBook document, or create a new one if needed.

Testing

This can be tested by running the game as the host, with the AddServerOwnerPermissionToServerHost setting ticked under "ProjectSettings/SS3D/Server/PermissionSettings", this should change the host permission to "Server Owner" whenever the server is started. There should be logs for this.

Networking checklist

  • Works from host in host mode.
  • Works from server in server mode.
  • Works on server in client mode.
  • Works and is syncronized across different clients.
  • Is persistent.

Changes

Many changes are related to import settings, the permissions system was moved to a separate assembly as it is very independent and that makes things more modular.

@joaoburatto joaoburatto force-pushed the feature/expand-permissions-system branch 2 times, most recently from 8572de7 to 92645ed Compare September 30, 2023 22:07
Copy link
Contributor

@stilnat stilnat left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just a bit of doc to add, and explain a bit more how this works from the user perspective in the PR description. Do I choose to register permission ? Is is automatic ? Can you do it on build or only in editor ?

Copy link
Contributor

@stilnat stilnat left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please add a detailed description of the PR

@joaoburatto joaoburatto force-pushed the feature/expand-permissions-system branch from 0143b68 to 613eede Compare October 17, 2023 02:23
@joaoburatto joaoburatto self-assigned this Oct 17, 2023
@joaoburatto joaoburatto added the General Management Clean up or other management tasks. label Oct 17, 2023
@joaoburatto
Copy link
Contributor Author

@stilnat added docs and description

Copy link
Contributor

@stilnat stilnat left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

fix build error

Copy link
Contributor

@stilnat stilnat left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

works as expected, good job

@stilnat stilnat merged commit 88903c2 into RE-SS3D:develop Oct 29, 2023
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
General Management Clean up or other management tasks.
Projects
No open projects
Status: Done
Development

Successfully merging this pull request may close these issues.

2 participants