datumhue.random.new
functiondatumhue.random.new(seed: integer, stream?: string) -> RngCreate an independent random stream from a seed. Equal seeds give equal sequences, on every platform, in every session. A stream name selects a named substream of the seed: the same seed under different names yields unrelated sequences, and the name-to-stream mapping is itself a stable contract -- one seed can feed a family of parallel streams without any hand-rolled hashing.
-- Equal seeds give equal sequences.
local a = datumhue.random.new(42)
local b = datumhue.random.new(42)
print(a:int(1, 100), b:int(1, 100)) --> 45 45
-- Each named stream of a seed is a sequence of its own.
local loot = datumhue.random.new(42, "loot")
local weather = datumhue.random.new(42, "weather")
print(loot:int(1, 100), weather:int(1, 100)) --> 88 62In the guide: Query and chart data