Okay...I'm redoing Cliff Hanger for MotS and the Army TC. I want to use player actions to determine strafing, jumping, crouching, turning, moving, etc. But the problem is, they don't seem to work in mid-air. And the whole point of this is so you can touch a ledge surface in mid air, freeze/grab it, then shimmmy, fall down, or pull up. I just need to get this to work.
Here's my COG:
# Jedi Knight COG Script
#
# script.cog
#
# Created by Emon. E-Mail: emon@coruscant.net - Zone: EJM_Emon - ICQ: 35960628
# Feel free to use this COG as long as credit is given in the readme file.
#
# Description
#
#
# This COG is not supported by LucasArts Entertainment Co.
flags=0x240
symbols
thing Player local
keyframe HangAnim=cliffhang.key
keyframe ClimbAnim=cliffclimb.key
sound GrabSound=kylerun01.wav
sound GrabVoice=kyljpa.wav
surface Ledge1
int HangTrack local
int CurWeap local
message startup
message touched
message playeraction
end
# ========================================================================================
code
startup:
Player = GetLocalPlayerThing();
Return;
touched:
CurWeap = GetCurWeap(Player); // Gets current weapon. For some crap that's not completed.
SetThingVel(Player, 0, 0, 0); // Stop current velocity.
SetActorFlags(Player, 0x40000); // Make sure the player stop even if they hold down a movement key.
Sleep(.001); // ""
ClearActorFlags(Player, 0x40000); // ""
HangTrack = PlayKey(Player, HangAnim, 1, 0x0);
SetActionCog(GetSelfCog(), 0x7fffffff);
ClearPhysicsFlags(Player, 0x1);
Return;
playeraction:
If(GetParam(0) == 5 || GetParam(0) == 6 || GetParam(0) == 3)
{
SetThingVel(Player, 0, 0, 0);
Print("No shooting, moving or turning!");
ReturnEx(0);
}
else
{
ReturnEx(1);
}
Return;
end
Any help would REALLY be appreciated...
Btw, I DID read
both Player Action
tutorials at massassi.
Here's my COG:
# Jedi Knight COG Script
#
# script.cog
#
# Created by Emon. E-Mail: emon@coruscant.net - Zone: EJM_Emon - ICQ: 35960628
# Feel free to use this COG as long as credit is given in the readme file.
#
# Description
#
#
# This COG is not supported by LucasArts Entertainment Co.
flags=0x240
symbols
thing Player local
keyframe HangAnim=cliffhang.key
keyframe ClimbAnim=cliffclimb.key
sound GrabSound=kylerun01.wav
sound GrabVoice=kyljpa.wav
surface Ledge1
int HangTrack local
int CurWeap local
message startup
message touched
message playeraction
end
# ========================================================================================
code
startup:
Player = GetLocalPlayerThing();
Return;
touched:
CurWeap = GetCurWeap(Player); // Gets current weapon. For some crap that's not completed.
SetThingVel(Player, 0, 0, 0); // Stop current velocity.
SetActorFlags(Player, 0x40000); // Make sure the player stop even if they hold down a movement key.
Sleep(.001); // ""
ClearActorFlags(Player, 0x40000); // ""
HangTrack = PlayKey(Player, HangAnim, 1, 0x0);
SetActionCog(GetSelfCog(), 0x7fffffff);
ClearPhysicsFlags(Player, 0x1);
Return;
playeraction:
If(GetParam(0) == 5 || GetParam(0) == 6 || GetParam(0) == 3)
{
SetThingVel(Player, 0, 0, 0);
Print("No shooting, moving or turning!");
ReturnEx(0);
}
else
{
ReturnEx(1);
}
Return;
end
Any help would REALLY be appreciated...
Btw, I DID read
both Player Action
tutorials at massassi.
Bassoon, n. A brazen instrument into which a fool blows out his brains.