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

refactor(Player Class): Typing Code & Perf #1217

Merged
merged 5 commits into from
Oct 2, 2023

Conversation

Walker974
Copy link
Contributor

268528063-d3191c7e-b258-4423-b73b-1204f47c2d1c

@Thekuca Thekuca changed the base branch from main to dev September 18, 2023 13:47
Copy link
Contributor

@Thekuca Thekuca left a comment

Choose a reason for hiding this comment

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

I don't see the reason for parentheses IMO the code is cleaner without them. Other then that it's all good.

@Thekuca Thekuca assigned Thekuca and unassigned Thekuca Sep 18, 2023
@Thekuca Thekuca requested a review from Gellipapa September 18, 2023 13:54
@Walker974
Copy link
Contributor Author

Hey, yeah i agree with you.
Thank you
Have a good day

@benzon
Copy link

benzon commented Sep 21, 2023

Wondering why you are using
local _GetPlayerPed = GetPlayerPed;
Instead of just local GetPlayerPed = GetPlayerPed

And why ; is added in the end, looks messy.

@Walker974
Copy link
Contributor Author

Yes you can just use local GetPlayerPed = GetPlayerPed
For ; in the end, it is just because I am familiar with C

@Gellipapa
Copy link
Contributor

Hi! @Walker974 Please remove ; and () in code. Keep the lua simple.

@Walker974
Copy link
Contributor Author

Hello @Gellipapa !
Good !

@Kenshiin13
Copy link
Contributor

Hi! @Walker974 Please remove ; and () in code. Keep the lua simple.

I can get behind not using semicolons, but I must say I find code less readable without '()'. Obviously, that is subjective.

@benzon
Copy link

benzon commented Sep 25, 2023

Hi! @Walker974 Please remove ; and () in code. Keep the lua simple.

I can get behind not using semicolons, but I must say I find code less readable without '()'. Obviously, that is subjective.

Think it comes down to coding preferences and styles in the end, but it needs to be consistent throughout a project, and not end up having different coding styles, and formatting.

@benzon
Copy link

benzon commented Sep 25, 2023

Yes you can just use local GetPlayerPed = GetPlayerPed For ; in the end, it is just because I am familiar with C

Personally, I would prefer that natives are not redeclared (loaded) and then set to a new variable.

local GetPlayerPed = GetPlayerPed over local _GetPlayerPed = GetPlayerPed

@Kenshiin13
Copy link
Contributor

Think it comes down to coding preferences and styles in the end, but it needs to be consistent throughout a project, and not end up having different coding styles, and formatting.

Of course, I am not suggesting a change, everyone should stick to the style guidelines of the project.

Copy link
Contributor

@Thekuca Thekuca left a comment

Choose a reason for hiding this comment

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

Looks good

@Thekuca Thekuca merged commit 50f7dce into esx-framework:dev Oct 2, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Archived in project
Development

Successfully merging this pull request may close these issues.

5 participants