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

fix: Resolve an error when giving keys without ID #158

Merged
merged 2 commits into from
Dec 19, 2024

Conversation

zozomanx
Copy link
Contributor

@zozomanx zozomanx commented Dec 6, 2024

Description

When attempting to hand keys to someone standing next to you without using an ID an error would be generated:
image

The error was from a nil value. I added a config setting, got rid of the nil value error, and added in user notifications.

Before: https://medal.tv/games/gta-v/clips/je2GVr3kBS0OLfjWB?invite=cr-MSxsZ3csMTk1NzEzNDc0LA
After: https://medal.tv/games/gta-v/clips/je2JXUH9ehD7sHQ5P?invite=cr-MSxPYUMsMTk1NzEzNDc0LA

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.

When attempting to give keys to another player without an ID an error was given.

It had to do with closestDistance being nil.
Added a new config option "distanceToHandKeys = 3" so players can adjust the range at which to hand keys over.
@mafewtm mafewtm merged commit 02666e9 into Qbox-project:main Dec 19, 2024
1 of 2 checks passed
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.

3 participants