Page 2 of 2

Re: Bug #98 - Mob Regen

Posted: Thu Jun 10, 2010 7:30 pm
by Eradani
Eradani wrote:Ring of the Nightblood with Battlement of the Mind (When equipped: increases in-combat power regen per tick of caster by 7.0)
I know for a fact that this ring's Named Effect doesn't stack cause I bought 2 of them. :-(
Rhas wrote:Both formula's (IC_Regen/OOC_Regen) look through all your equipment slots for regen so Food/Drink with IC_Regen will be picked up.
When are you looking through slots? I can't see that eq2 ever just looks through slots. Your regen rate would be modified:
a) basic lvl regen: when you create a toon or lvl
b) effects from items: when the item is un)equipped
c) effects from food, drink, totem and item buffs that wear off: when the item is used / applied

The more I think about this system, the move amazed I am at how much data they must have to store for each toon. They have to store all these effects that persist through login. And there has to be more storage for effects that are applied (through use or equip) so that they persist through death if they're supposed to.

I suppose can see them going through gear when you log in to see what On-Equip effects you have, but you can't do that with food etc, as then you'd be using one up every time you relogged ???

Re: Bug #98 - Mob Regen

Posted: Thu Jun 10, 2010 9:50 pm
by Rhas
Well it appears some regen doesn't stack. I noticed in the emu there are two types of IC regen defined:

Code: Select all

#define ITEM_STAT_COMBATHPREGENPPT 		604
#define ITEM_STAT_COMBATHPREGEN 		661
Perhaps, items within the same type of regen don't stack.
Eradani wrote: When are you looking through slots? I can't see that eq2 ever just looks through slots. Your regen rate would be modified:
a) basic lvl regen: when you create a toon or lvl
b) effects from items: when the item is un)equipped
c) effects from food, drink, totem and item buffs that wear off: when the item is used / applied
I don't store each of these in separate variables. I have two variables on the entity class IC_HP_Regen, OOC_HP_Regen. They get calculated in the situations you described above.

Re: Bug #98 - Mob Regen

Posted: Sat Jun 12, 2010 1:20 am
by Rhas
I've got this mostly working except for food/drink. How are they supposed to be implemented? Is there supposed to be lua scripts for each food item that will cast a OOC regen effect when equipped? Or should food/drink items have normal regen stat buffs in the item_stats table like normal regen items?

Re: Bug #98 - Mob Regen

Posted: Sat Jun 12, 2010 9:01 am
by Eradani
When you equip f/d, it must look to see if you've already got the Homemade Meal/Drink (or w/e) buff as you don't use it unless you need it just by equipping it. However, you do use it if you r-click > Use.

Example Food:

Code: Select all

Frog's Leg Stew  Deer Steak       Magma Fish Infusion
1 hr             45 min           30 min
+5 OOC HP regen  +7 OOC HP regen  +2 OOC HP regen
+3 STR           +5 STR           +50 ability mod
Example:

Assumption: must be equipped to get "use" on context menu (but I forget for sure).
Assumption: auto-consume food ON

you are hungry
equip [frog's leg stew] -> auto-use
-> 60 min timer for +5 OOC HP regen
-> 60 min timer for +3 STR buff

equip [deer steak] -> use
guessing:
-> cancels +5 OOC HP regen
-> 45 min timer for +7 OOC HP regen
-> cancels +3 STR buff
-> 45 min timer for +5 STR buff

equip [frog's leg stew] -> use
-> ?? since both the OOC regen and STR buffs are less than what you've currently got

equip [magma fish infusion] -> use
-> ?? about regen
-> 30 min timer for +50 ability mod (separate from timer for +3 STR buff - and I've done this)

And then there's Totems which work similarily except they don't have to be equipped (just in inventory) for auto-consume ON and they default to auto-consume OFF.