-
Notifications
You must be signed in to change notification settings - Fork 5
Testing for partial drop flags
The topic is related to this ticket: https://github.com/igroglaz/srvmgr/issues/4
Summary: There is a setting in the A2 server configuration that handles how inventory drop happens when player dies on a map.
It looks like the following:
[Settings]
InventoryDropPropapility = 0.39
WearDropPropapility = 0.72
In this example when user dies his unit will drop 39% of items from inventory and 72% of worn items: cloth, weapon, shield, jewelry. The algorithm does not guarantee that exactly 39% and 72% will drop. Instead, every item from inventory has 39% chance of being dropped. Worn items work same.
So there is still a chance that all items will drop or none. But the chance is very small. For those who interested, the distribution is close to Gaussian.
Now, how to test.
There are several events that are affected by the change:
- Player dies.
- Player kills a mob.
- Player picks up a sack from the ground.
- Inventory operations.
Every situation has multiple circumstances. For instance. Player may be a mage or warrior, may have or have not items in the inventory, etc. For every of this situations I am going to describe a case, so when the testing is complete we'll know what cases are tested and proved to be safe.
Categories: Player is: mage, warrior. Sex does not make any difference. Death reason: by monster, by another player, by himself. Inventory: empty, has items, has some extreme number of items(let's say 10k or 100k of potions or scrolls or anything else). Worn items: wears smth, naked.
Categories: Player is: mage, warrior. Sex does not make any difference. Weapon: by melee weapon, by ranged weapon, by magic staff, by magic spell, by magic scroll Mob: small without reward, small with fixed reward and money like goblin, mod with random reward like trolls, mobs with predefined reward like quest mobs(not obviously should be 5lvl, just need to have a reward in it's inventory), flying mobs, big 2x2 3x3 mobs. Mob location: ground, unaccessible tiles(water or rocks or forest) this is for flying mobs.
Categories: Sack origin: from mob random reward, from mob predefined reward, from another player, random sack.
Categories: Buy/Sell in shop Get items in Inn Drop items from the inventory