Skip to content
Better HN
Top
Best
Ask
Show
New
Jobs
Search
⌘K
0 points
manwe150
7mo ago
0 comments
Save
Share
Dividing by 5 or 2, respectively, are integers, if the game developers wanted them to be. More so because the actual units of ammo need to be integers if they are to render as full bullets each
0 comments
1 comments · 1 top-level
top
newest
oldest
shultays
7mo ago
Or more generalized "ammo += (maxAmmo * percentageToFill) / 100"
j
/
k
navigate · click thread line to collapse