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

feat!: use session id instead of plate #129

Merged
merged 5 commits into from
Sep 27, 2024
Merged

feat!: use session id instead of plate #129

merged 5 commits into from
Sep 27, 2024

Conversation

Manason
Copy link
Member

@Manason Manason commented Sep 25, 2024

Dependent on Qbox-project/qbx_core#582

This turned into a more general overhaul as opportunities to delete code rather than convert it arose, although I tried my best to leave future refactoring to another PR.

  • Replacing plate with sessionId. This is a stable identifier so that if plate changes, the player still has access to the same vehicle entity.
  • moved the command code for giving keys entirely to the server. Changed the admin command for giving keys to be the same as the player one, but without the check that the admin already has the keys
  • removed the admin command to remove keys. It doesn't seem super useful, and needed to be redone anyway
  • removed backwards compatibility events for now. It's questionable if we want to support backwards compatibility in vehiclekeys, and these would need to be redone anyway.
  • Removed some exports without a clear use case. It's easy to add to an API later, but once published we can't remove these exports.
  • Exposing RemoveKeys as an export
  • Removed code which pre-loads all of a player's owned vehicles as keys. This no longer makes sense as we can only give keys to physical entities in the world. Removing it shouldn't change behavior as when a player owned vehicle is spawned, the owner should be given keys.

locales/en.json Show resolved Hide resolved
server/functions.lua Outdated Show resolved Hide resolved
server/commands.lua Show resolved Hide resolved
@Manason Manason merged commit 146c7df into main Sep 27, 2024
4 checks passed
@Manason Manason deleted the feat-session-id branch September 27, 2024 07:09
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants