Modding:General Best Practices: Difference between revisions

Jump to navigation Jump to search
imported>Koboldunderlord
No edit summary
imported>Koboldunderlord
Line 26: Line 26:
</syntaxhighlight>
</syntaxhighlight>


==Random Functions==
=Random Functions=
{{Main|Modding:Random Functions}}
{{Main|Modding:Random Functions}}
To avoid conflicts and to keep consistency between seeds, Stat.Random() and Stat.Rnd() should not be called. The ideal is to use [[Modding:Random_Functions#GetSeededRandomGenerator.28string_Seed.29|GetSeededRandomGenerator()]] for your mod's randomness. The next best is calling RandomCosmetic() or Rnd2().
To avoid conflicts and to keep consistency between seeds, Stat.Random() and Stat.Rnd() should not be called. The ideal is to use [[Modding:Random_Functions#GetSeededRandomGenerator.28string_Seed.29|GetSeededRandomGenerator()]] for your mod's randomness. The next best is calling RandomCosmetic() or Rnd2().

Navigation menu