com.wallstop-studios.unity-helpers 2.0.0-rc60 → 2.0.0-rc62

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,3 @@
1
+ fileFormatVersion: 2
2
+ guid: 40f1b0a7e1eb4979aa02ef455d77b30a
3
+ timeCreated: 1745450870
@@ -16,7 +16,7 @@
16
16
  for (int i = 0; i < TestIterations; ++i)
17
17
  {
18
18
  float target = PRNG.Instance.NextFloat(-1_000, 1_000);
19
- float delta = PRNG.Instance.NextFloat(0f, 10f);
19
+ float delta = PRNG.Instance.NextFloat(1f, 10f);
20
20
 
21
21
  float insideOffset = delta * PRNG.Instance.NextFloat();
22
22
  if (PRNG.Instance.NextBool())
@@ -737,13 +737,13 @@
737
737
  for (int i = 0; i < SampleCount; ++i)
738
738
  {
739
739
  int index = sample(random);
740
- if (index < 0 || sampleLength <= index)
740
+ if (index < 0 || sampleLength < index)
741
741
  {
742
742
  Assert.Fail("Index {0} out of range", index);
743
743
  }
744
744
  else
745
745
  {
746
- _samples[index]++;
746
+ _samples[Math.Min(sampleLength - 1, index)]++;
747
747
  }
748
748
  }
749
749
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "com.wallstop-studios.unity-helpers",
3
- "version": "2.0.0-rc60",
3
+ "version": "2.0.0-rc62",
4
4
  "displayName": "Unity Helpers",
5
5
  "description": "Various Unity Helper Library",
6
6
  "dependencies": {},