Other > General Game Discussion
Treasure Hunter is bogus (Proof!)
Marko:
TH works fine. Without it, you find fewer caps in those footlockers*. With TH, the bottom limit of the caps range is still 1, but the upper limit is much higher than without it.
*Unless the number of caps you find is 1, in which case you don't find any less. ;)
the underground:
--- Quote from: Mayck on May 24, 2013, 04:03:06 pm ---
--- Code: ---if(cr.Perk[PE_TREASURE_HUNTER]>0)
{
array<Item@> items;
for(uint i=0,j=chest.GetItems(0,items);i<j;i++)
{
if(items[i].IsStackable()) items[i].SetCount((items[i].GetCount()*23)/20);
else if(Random(1,100)<=15) chest.AddItem(items[i].GetProtoId(),1,0);
}
}
--- End code ---
--- End quote ---
Sorry, this is Latin to me. Could you translate it?
Edik:
--- Code: ---if(items[i].IsStackable()) items[i].SetCount((items[i].GetCount()*23)/20);
--- End code ---
you multiply by 23 and divide by 20, so when you do that with 1$, you still get 1$ :D
on the other hand, in c++ 7/9*9 is 0 so :P
racoon:
--- Code: ---if(cr.Perk[PE_TREASURE_HUNTER]>0)
{
array<Item@> items;
for(uint i=0,j=chest.GetItems(0,items);i<j;i++)
{
if(items[i].IsStackable()) items[i].SetCount((items[i].GetCount()*2);
else if(Random(100,300)<=15) chest.AddItem(items[i].GetProtoId(),1,0);
}
}
--- End code ---
repaired it
Mayck:
--- Quote from: Edik on May 24, 2013, 10:49:49 pm ---on the other hand, in c++ 7/9*9 is 0 so :P
--- End quote ---
Yep, and that's why we multiply before division.
Navigation
[0] Message Index
[#] Next page
[*] Previous page
Go to full version