MCPcopy Create free account
hub / github.com/diasurgical/devilution / RndHealerItem

Function RndHealerItem

Source/items.cpp:3696–3710  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

3694}
3695
3696int RndHealerItem(int lvl)
3697{
3698 int i, ri;
3699 int ril[512];
3700
3701 ri = 0;
3702 for (i = 1; AllItemsList[i].iLoc != ILOC_INVALID; i++) {
3703 if (AllItemsList[i].iRnd && HealerItemOk(i) && lvl >= AllItemsList[i].iMinMLvl) {
3704 ril[ri] = i;
3705 ri++;
3706 }
3707 }
3708
3709 return ril[random_(50, ri)] + 1;
3710}
3711
3712void SortHealer()
3713{

Callers 2

SpawnHealerFunction · 0.85
RecreateHealerItemFunction · 0.85

Calls 2

HealerItemOkFunction · 0.85
random_Function · 0.85

Tested by

no test coverage detected