Jump to content

Home

Setting minimal health?


GeorgNihilus

Recommended Posts

Hi :) now I'm trying to use this in TSL to reduce the PC current health to only 7 hitpoints, but he's dying ... even firing that a_min_one_hp in-game script before in the dialog ... here's the script:

 

void main() {

object oVictim = GetFirstPC();

int nDamage = GetCurrentHitPoints(GetFirstPC());

int nRests = 7;

int nAplidam = nDamage-nRests;

effect eOuch = EffectDamage(nAplidam);

ApplyEffectToObject(DURATION_TYPE_INSTANT, eOuch, oVictim);

}

 

what's wrong?? :confused:

 

oh by the way, PC is alone in party for this script

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...