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

hardcode lua array size #929

Merged
merged 1 commit into from
Jan 4, 2025
Merged

Conversation

barbeque-squared
Copy link
Member

the array size for the lua functions has no relation whatsoever with IMaxPlayerCount, they currently just happen to be the same value

this is a similar change to what was done in #554, specifically #554 (comment)
I don't think it's wrong to use a hardcoded number here: it's a static array, it seems to be how Pascal works, it's done hundreds of other times throughout the code -- see for example UIni.pas.

And maybe there is an even better way, but at the very least, I think this PR objectively improves the code.

…IMaxPlayerCount, they currently just happen to be the same value
@barbeque-squared barbeque-squared force-pushed the hardcode-lua-array-size branch from 689882b to ef3003a Compare January 4, 2025 12:51
@barbeque-squared barbeque-squared merged commit 8434099 into master Jan 4, 2025
5 checks passed
@barbeque-squared barbeque-squared deleted the hardcode-lua-array-size branch January 4, 2025 19:15
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.

1 participant