Better HN
topnewbestaskshowjobs
Log inSign up

dimi777

2 karma · joined Jun 19, 2022 (4y ago) · 1 submissions

Submissions

comment 4y ago · link · parent

Hi, I’m the guy behind this code. First we roll the type of the gem: 1-star, 2-star or a ?/5-star and then if the rolled gem is ?/5-star, we determine the amount of stars that it will have using the probability array at the bottom of the code snippet, that you attached.