Object effect help.

Post » Fri May 13, 2011 6:31 pm

I'm making an object effect that uses the Turbo effect to slow down time whenever my health gets below 18%, but I also need to add a regen effect that regenerates my health back to 20% of max whenever the Turbo effect activates otherwise the turbo effect stays until I heal manually. I need these two effects to be in one Object effect.

The first part works with the turbo effect, but the health regen doesn't work and even if it did work how would I go about to stopping the regen effect from regenerating indefinitely?

I found three regen effects to choose from which are Regen, Restorehealth and ImplantRegen. None worked....
User avatar
Carlitos Avila
 
Posts: 3438
Joined: Fri Sep 21, 2007 3:05 pm

Post » Fri May 13, 2011 4:59 pm

Do you have a script for the effect somewhere? It is easy to use "getbaseactorvalue health" to find your base health value, and then "setactorvalue health" to set it to 20%. I am not sure the existing effects let you set an absolute percentage.
User avatar
Albert Wesker
 
Posts: 3499
Joined: Fri May 11, 2007 11:17 pm

Post » Fri May 13, 2011 6:24 pm

I'm not using any script. I'm using GetHealthPercentage < 0.1800 on the turbo effect so I assumed the same thing would work with the regen.

I made a picture to show what I have: http://img.photobucket.com/albums/v694/Rafael19/Naamloos.jpg

I have the object effect on an armor whenever my health gets below 18% the turbo effect activates, but the health regen does not.
User avatar
Rob Smith
 
Posts: 3424
Joined: Wed Oct 03, 2007 5:30 pm

Post » Fri May 13, 2011 11:51 am

Perhaps this is obvious, but in the screenshot, the regen effect only triggers if the health *base actor value* is below 0.18, which seems unlikely. (0 means you are dead.) Did you mean to use GetHealthPercentage in both the turbo effect and the regen effect?
User avatar
QuinDINGDONGcey
 
Posts: 3369
Joined: Mon Jul 23, 2007 4:11 pm

Post » Fri May 13, 2011 11:23 am

Yes sorry I mean't to use GetHealthPercentage which I did at first, but that never worked(while turbo did...) and after I saw your first comment I found out that base actor value could also do that so I used 0.18 thinking it was also a percentage :D

Right now I tried it with getbaseactorvalue health at 20.000 and still no change....
User avatar
Jessica Raven
 
Posts: 3409
Joined: Thu Dec 21, 2006 4:33 am

Post » Fri May 13, 2011 10:44 pm

"Getbaseactorvalue health" returns the number of HP you have when fully healed. So it will trigger as soon as you build a character with only 19 HP :-)

I'm not sure why "gethealthpercentage < 20" should fail to trigger regen, maybe somebody else can help.
User avatar
Davorah Katz
 
Posts: 3468
Joined: Fri Dec 22, 2006 12:57 pm

Post » Sat May 14, 2011 2:38 am

I found it! lol the problem lies with Regenerate, it does not seem to regenerate instead I used RestoreHealth and that worked like a charm :)

Thank you davidlallen for the input, it did enlighten me to other things I will want to work on.
User avatar
brian adkins
 
Posts: 3452
Joined: Mon Oct 01, 2007 8:51 am


Return to Fallout: New Vegas