PenUltima Online Forum Index Official Core: 096.7
Official Core: 097 2008-02-26
Donate towards the POL web hosting bill!
 POL Home   FAQ   Search    Memberlist   Usergroups    Register    Profile   Log in to check your private messages   Log in
MAXHP for npcs

 
Post new topic   This topic is locked: you cannot edit posts or make replies.    PenUltima Online Forum Index -> Feature Suggestions
Display posts from previous:   

Author Message
OldnGrey



Joined: 04 Feb 2006
Posts: 520

PostPosted: Wed May 31, 2006 9:45 am    Post subject: MAXHP for npcs Reply with quote

Is there any way we can change the maxhp for an npc? I don't mean editing and reloading the npcdesc file. I am looking for a way to set a maxhp_mod on an npc the same way as an item.

Author Message
Austin
POL Developer


Joined: 30 Jan 2006
Posts: 354
Location: San Diego, California

PostPosted: Wed May 31, 2006 10:55 am    Post subject: Reply with quote

Already exists.
1. Look at your vitals.cfg
-This will tell you where your vital hook is and what function it uses.
2. Look at the function that returns something for the hit point vital.
This is what sets the hitpoints.
It probably points to the strength attribute?
You can change it to look for something else, a cprop maybe for an npc?
Use RecalcVitals() im uo.em to update the vitals and their regen rates.
It causes the hook to be re-run on the mobile.

Author Message
OldnGrey



Joined: 04 Feb 2006
Posts: 520

PostPosted: Fri Jun 02, 2006 3:43 am    Post subject: Reply with quote

The cprop idea works just fine.
Thanks Austin.

Pol still ain't the best thing to figure out stuff.
The POL Object Class Reference really lead me astray here.

Post new topic   This topic is locked: you cannot edit posts or make replies.    PenUltima Online Forum Index -> Feature Suggestions All times are GMT - 4 Hours
Page 1 of 1

 




Powered by phpBB © 2001, 2005 phpBB Group :: Theme & Graphics by GHS & Scott E. Royalty