Skip to content

Apply #2507 bounds checks to RandomGenerator():random() and :irandom()#2863

Open
oznogon wants to merge 2 commits intodaid:masterfrom
oznogon:fix-randomgenerator-bounds
Open

Apply #2507 bounds checks to RandomGenerator():random() and :irandom()#2863
oznogon wants to merge 2 commits intodaid:masterfrom
oznogon:fix-randomgenerator-bounds

Conversation

@oznogon
Copy link
Copy Markdown
Contributor

@oznogon oznogon commented Apr 16, 2026

PR #2507 added standalone random() and irandom() Lua global functions with bounds checks, but didn't add bounds checks to RandomGenerator():random() and RandomGenerator():irandom().

Align RandomGenerator() behavior to the standalone functions'.

Not sure if there was a reason for this omission, cc @GinjaNinja32

@GinjaNinja32
Copy link
Copy Markdown
Contributor

the reason: I forgot RandomGenerator got added and the scenarios I was checking either didn't use it or used it correctly 😆

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