Skip to content

[Bug]: NativePCGRandom has code rot #282

Description

Description

NativePCGRandom has not kept up with correctness/performance changes in the AbstractRandom base and has problems such as NextBool bias, and NextFloat/NextDouble potentially returning 1.0 exactly, among others. We should bring it up to the latest and greatest speed.

Steps to Reproduce

Look at NativePCGRandom code and compare to PCGRandom

Expected Behavior

Equivalent, except for NativePCGRandom being a value type

Actual Behavior

Different behavior

Severity

Major (feature broken, no workaround)

Unity Version

Other

Package Version

3.5.0

Platform

  • Editor
  • Windows
  • macOS
  • Linux
  • iOS
  • Android
  • WebGL
  • Other

Regression

  • Yes, this is a regression (worked in a previous version)

Additional Context

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't workingtriage

    Type

    No type

    Fields

    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions