Thanks travus! That’s really good to know.
Now, I have some other problem with this, and it’s REALLY weird. I don’t have a clue as to what’s going on. Like I said in my previous post, I went and “solved” this situation by doing it the way I did before, with a custom script spawning each and every creature. Every creature has a different tag but…well, they are called l_dogwolf1, l_dogwolf2 and so on…So I used the function I had used successfully before, but now when not all of them are dead, the game thinks all of them are dead. So, I went back to a previous discussion and used your, slightly different script for this, and tried it, and it the game STILL does things it should do when only all are dead, instead when almost each and everyone of them dies. The function looks like this:
int CheckIfCreaturesWithTagAreAllDead(object oPC, string EnemyTag)
int n = 1;
object oNPC = GetNearestObjectByTag(EnemyTag + IntToString(n), oPC);
if(!GetIsDead(oNPC)) return FALSE;
oNPC = GetNearestObjectByTag(EnemyTag + IntToString(n), oPC);
What I did, that maybe somehow interfers with this is: I copied the first blueprint that had l_dogwolf1 on Tag, Resource and Resref and gave the new blueprint l_dogwolf2 on Tag, Resource and Resref but…I mean, the script checks for the tags so…I don’t know what to do right now! This is so frustrating!
Ok, I’m not making myself clear I think:
What I want: When all die, something should happen.
What happens in game: When 2 wolves (instead of all of them, they are 6) die the “something” that should happen, happens.
So why does the game run the script before all are dead?