Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/OpenStarbound/OpenStarbound
/ randInt
Method
randInt
source/core/StarRandom.cpp:86–88 ·
view source on GitHub ↗
Source
from the content-addressed store, hash-verified
84
}
85
86
int64_t RandomSource::randInt(int64_t max) {
87
return randUInt(max);
88
}
89
90
uint64_t RandomSource::randUInt(uint64_t max) {
91
uint64_t denom = (uint64_t)(-1) / ((uint64_t)max + 1);
Callers
14
processRule
Method · 0.80
findRandomWorld
Method · 0.80
Plant
Method · 0.80
worldHorizonImages
Method · 0.80
chooseSkills
Method · 0.80
BiomeItemDistribution
Method · 0.80
buildLayer
Method · 0.80
init
Method · 0.80
main
Function · 0.80
init
Method · 0.80
generate
Method · 0.80
randInt
Function · 0.80
Calls
3
randUInt
Function · 0.85
StarException
Class · 0.85
randInt
Function · 0.85
Tested by
1
TEST
Function · 0.64