Boost a mobs "power"

Posted by Zeno on Sun 02 Jan 2005 05:43 AM — 5 posts, 17,819 views.

USA #0
After placing a shard on a mob, I want to boost the mobs "power" (its strength or whatever) by 2x. This is what I have done:
       vch->hitroll *= 2;
       vch->hitroll *= 2;


vch is the mob. But it doesn't seeem to change the hitroll or damroll. Is something being done wrong? What else could be changed to make it stronger?

Example, this mob has a shard, so it should have 2x hr/dr.
Hitroll : 10
Damroll : 28 


So I minvoke a normal mob of the same vnum, that has no shard.
Hitroll : 10
Damroll : 28  


That's what I mean by it not working.
Amended on Sun 02 Jan 2005 05:53 PM by Zeno
Canada #1
I beleive that hitroll and damroll are also calculated above their base through the GET_HITROLL macro, might want to look at that.
USA #2
Ah, that is why, I forgot about that. I could add an affect... but I haven't figured out how those work yet, in the code. Like if I wanted to add 2 affects, one doubling hr, another doubling dr, lasting until death, how would that be done? (For the double var, I just would grab the curr hr/dr and have the affect add that var)

[EDIT] If just did perm_con, perm_str, and perm_dex 2x, would that be fine? As in, it wouldn't modify the original index mobs stats? Not using ->pindexdata
Amended on Sun 02 Jan 2005 06:42 PM by Zeno
USA #3
That'd work, except that you won't always get an increase by two times. The stats are capped, unless of course you removed that.

For adding an effect, I suggest looking at how some races are given permanent effects such as detect magic or infravision. You'd do something rather similar, and attach something like that onto your mob.
USA #4
Stat cap is basically removed. (its at 1000).

I've looked over some examples a while ago, but I really don't get some of it. I'll post a new topic if I can't figure it out.