Massassi Forums Logo

This is the static archive of the Massassi Forums. The forums are closed indefinitely. Thanks for all the memories!

You can also download Super Old Archived Message Boards from when Massassi first started.

"View" counts are as of the day the forums were archived, and will no longer increase.

ForumsCog Forum → Actors damaging actors
Actors damaging actors
2004-09-21, 9:49 AM #1
I have a COG setup so that various things happen in a level when the player damages specific actors. However, I don't want to the game to do these various things should other actors damage these specified actors.

Is there a way to get the COG to differentiate between damage dealt by the player and damage dealt by actors?
the idiot is the person who follows the idiot and your not following me your insulting me your following the path of a idiot so that makes you the idiot - LC Tusken
2004-09-21, 11:14 AM #2
Sure. You can, for example, use code like this in the damaged message of the cogs:
Code:
if(GetThingType(GetThingParent(GetSourceRef())) == 10)
{
   // Player damage: do the nasty stuff
}

AI Actors have a different thing type (8 or something) than players (10).
"Häb Pfrässe, süsch chlepfts!" - The coolest language in the world (besides Cherokee)
2004-09-21, 1:36 PM #3
Actors are type 2, and players are type 10.

PostCount+=1;
May the mass times acceleration be with you.
2004-09-21, 2:15 PM #4
Thank you very much.
the idiot is the person who follows the idiot and your not following me your insulting me your following the path of a idiot so that makes you the idiot - LC Tusken

↑ Up to the top!