acr_death_i

Scripted ALFA systems & related tech discussions (ACR)

Moderators: ALFA Administrators, Staff - Technical

User avatar
ç i p h é r
Retired
Posts: 2904
Joined: Fri Oct 21, 2005 4:12 pm
Location: US Central (GMT - 6)

Post by ç i p h é r »

AcadiusLost wrote:-Added back some SetFirstName() calls on mutilated corpses
I left that commented out because it will break the persistent data references. Object name is used by Set/Get persistence calls to store data so it's important that it remain the player's name until the corpse decays beyond resurrection.
-Added a shape-based handling for redirecting mob attacks on downed PCs, (doesn't work currently, still testing- but they continue to attack dying PCs with ranged weapons even while other alive PCs are in their face pounding on them, so I'd say it is an issue).
Can you graduate this up to the OnDying event handler or put it in the respective AI function so it's not coupled directly with the death code? For the most part, the AI should probably treat a DYING player the same way as it treats a DEAD player, so perhaps some code already exists that you can look at, unless we want to introduce factors like intelligence into the mix.
-Added handling exception for OOC inventory items, so they aren't dropped on corpses (activatable first aid item)
Would it make sense to simply mark these OOC items as undroppable (item property)?
-Trying to work out what needs to be done to script a rez lever for Beta testing.
Maybe just invoke the resurrection function?
The ACR_StabilizePlayer() function informs the player that they are stabilized, but they keep losing health at full pace. If that's supposed to be the external hook used for the Heal skill, it needs to get treated the same as real healing (HP > stored HP) in terms of the decision tree.
Yeah that is the external hook. I think the simplest solution would be to adjust the HP tracker so the system treats it as a healing situation:

SetLocalInt(oPC, ACR_DTH_HITPOINTS, GetLocalInt(oPC, ACR_DTH_HITPOINTS) - 1);
The "Natural partial recovery" case described above is explained to slow down the process, but then schedules the next check at RoundsToSeconds(1) anyway. Should change to HoursToSeconds(1).
That's intentional so the system can detect the changes to the player's death state as soon as possible. I instead keep track of the number of rounds that have passed and perform a modulus operation to determine the passing of hours or days. There's a one time calculation at the top of the script (global variables) which should factor in the local time compression.
Locked