Code:
# Jedi Knight Cog Script # # BODY.COG # # Leave a gib-able body behind if player gets killed by other means # # [GB] # # no lucasfarts involved, # Lucasarts either. flags=0x240 symbols keyframe dieanim=kyftdeth.key local thing player local thing body local int check=0 local message created message damaged message trigger message setmodel end # ======================================================================================== code created: check = 0; body = GetSenderRef(); SetThingFlags(player, 0x10); PlayKey(body, dieanim, 1, 0x14); Return; # ........................................................................................ damaged: if(GetParam(1)==10) { SetTimer(10); SetThingFlags(body, 0x10); SendTrigger(-1, 1000, body, 0, 0, 0); } Return; # ........................................................................................ trigger: if(GetSourceRef()==1002) { if(check==0) { player=GetParam(0); call setmodel; } } return; # ........................................................................................ setmodel: check=1; SetThingModel(body, GetThingModel(player)); return; # ........................................................................................ timer: destroyThing(body); return; end
when i shoot the dead body(of me, i havnt tried shooting a different player's body) the game immediatly exits.
I'm just an old man with a skooma problem.