Cash loot distribution
Database::AddLootTableToNPC() in the loottables.cpp file seems to be doing strange things when distributing cash.
Can whoever wrote, or understands the concept explain to me what the avgcoin variable does? In some instances it produces negatives (very high integers in uint). I'm trying to understand the way it works, or was intended to work. Thanks |
I didnt write it, but I've noticed odd problems with our rand's at times. We had a long running bug in loot determination because the rand was coming out with a REALLY screwed up range, I'm guessing that might be what you're seeing. I doubt you'd ever want to see a negative value. Usually when that happens, it turns out to be a casting problem, a unit32 just won't fit correctly into an int8.
|
I've seen some issues with the items distribution. At first glance, what's there seems to work with what I had in mind.
Cash is another story. Ok, I'll try it out when I get home tonight. Right now, if I use a mincash 0, maxcash 25 and avgcoin 5 it looks pretty nasty. hehe, will see how the client spews the cash over. Should be fairly screwed up in many occasions, unless there is some other code i've not gone through that filters it when passed to the client. P.S. Big "Way to Go" to anyone who is re-populating a zone. It's a hell of a job! |
All times are GMT -4. The time now is 11:17 PM. |
Powered by vBulletin®, Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.