Firefly_Trooper, on 04 February 2019 - 01:05 PM, said:
The first problem that I have not been able to solve for more than a week is how to get a useractor enemy out of the death counter.
I could just do a "notenemy" with cstat 256, but it's for gameplay reasons.
Firefly_Trooper, on 04 February 2019 - 01:30 PM, said:
Okay. Just add in the code of the actor, max_actor_killed and put -1?
I created an EVENT_KILLIT code that could help.
Or getplayer[THISACTOR].max_actors_killed - 1
Firefly_Trooper, on 11 February 2019 - 09:30 AM, said:
Max_actor_killed is not fixed.
Since you're using my GAME.CON fixes, the max_actors_killed variable is depending of the MAXKILLCOUNTFIX variable, to increase each time a enemy actor is appearing but not to decrease (which could happen, for example when a slimer is eating an enemy). I put this in EVENT_GAME:
// Don't allow the maximum number of monsters decrease (exept if manually set)
getplayer[THISACTOR].max_actors_killed TEMPFIX2
ifvarvarl TEMPFIX2 MAXKILLCOUNTFIX
setplayer[THISACTOR].max_actors_killed MAXKILLCOUNTFIX
else ifvarvarg TEMPFIX2 MAXKILLCOUNTFIX
setvarvar MAXKILLCOUNTFIX TEMPFIX2
I think you should try to modify both the variables at the same time like this:
subvar MAXKILLCOUNTFIX 1
getplayer[THISACTOR].max_actors_killed TEMPFIX1
subvar TEMPFIX1 1
setplayer[THISACTOR].max_actors_killed TEMPFIX1