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: HasGroup export #497

Merged
merged 2 commits into from
Jun 24, 2024
Merged

feat: HasGroup export #497

merged 2 commits into from
Jun 24, 2024

Conversation

solareon
Copy link
Member

Description

This adds a utility export that allows for a string/table of job/gang/citizenId to be passed against a function and quickly return if the condition matches. Utilizes ox_target code for group/citizenId matching.

Checklist

  • I have personally loaded this code into an updated Qbox project and checked all of its functionality.
  • My pull request fits the contribution guidelines & code conventions.

This adds a utility export that allows for a string/table of job/gang/citizenId to be passed against a function and quickly return if the condition matches. Utilizes ox_target code for group/citizenId matching.
Copy link
Member

@Manason Manason left a comment

Choose a reason for hiding this comment

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

Could we extract shared code to a shared function? Nice idea moving this to core to be generally available. Also, maybe we should rename to make it clear that we're only considering the primary group? Maybe HasPrimaryGroup?

Creates new functions.lua and adds to fxmanifest to allow for shared portable functions between client and server.
@solareon solareon requested a review from mafewtm June 24, 2024 16:31
@mafewtm mafewtm merged commit 1f6d538 into main Jun 24, 2024
4 checks passed
@mafewtm mafewtm deleted the feat-hasgotgroup branch June 24, 2024 16:39
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.

None yet

3 participants