Skip to content

Use Date.getTime() for RNG seed - #778

Open
Infiland wants to merge 1 commit into
YoYoGames:developfrom
Infiland:develop
Open

Use Date.getTime() for RNG seed#778
Infiland wants to merge 1 commit into
YoYoGames:developfrom
Infiland:develop

Conversation

@Infiland

@Infiland Infiland commented Apr 8, 2026

Copy link
Copy Markdown

randomize() now uses d.getTime() instead of d.getMilliseconds() * 1000 to derive the seed. This provides the full millisecond timestamp (higher resolution and wider range) for InitRandomExt(t), improving entropy for the RNG seed while keeping the existing bit-mixing logic.

Fixes: #605

randomize() now uses d.getTime() instead of d.getMilliseconds() * 1000 to derive the seed. This provides the full millisecond timestamp (higher resolution and wider range) for InitRandomExt(t), improving entropy for the RNG seed while keeping the existing bit-mixing logic.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: Triage

Development

Successfully merging this pull request may close these issues.

HTML5: randomize() has a possible pool of 1000 seeds total

2 participants