Descent_pilot
06-09-2002, 10:59 AM
I'm trying to make the xt battle four remotes. http://forums.massassi.net/html/smile.gif Once the remotes are destroyed, xt will attack me. http://forums.massassi.net/html/eek.gif (Run for your lives!)
The first part is my problem, the remotes just stand still, they won't get close enough for xt to saber them. Otherwise, they hang near me. http://forums.massassi.net/html/confused.gif Here's the cog.
# Jedi Knight Cog Script
#
# xt_rlx.COG
#
# Controls the xt battling remotes
#
# This Cog is Not supported by LucasArts Entertainment Co
symbols
thing xt
thing remote
thing remote1
thing remote2
thing remote3
thing target local
thing player local
int i local
int count=0 local
material tip_mat=saberred0.mat local
material side_mat=saberred1.mat local
template tpl_wall=+ssparks_wall local
template tpl_blood=+ssparks_blood local
template tpl_saber=+ssparks_saber local
message startup
message pulse
message killed
end
# ================================================== ======================================
code
startup:
jkSetSaberInfo(xt, side_mat, tip_mat, 0.003, 0.001, 0.101, tpl_wall, tpl_blood, tpl_saber);
jkSetFlags(xt, 0x5);
count = 0;
SetPulse(0.1);
Return;
# .................................................. ......................................
pulse:
target = FirstThingInView(xt, 170, 12, 0x4);
player = GetLocalPlayerThing();
if(count >= 4) SetPulse(0);
if((target == xt) || (target == player) || (!target))
{
return;
}
AISetFireTarget(xt, target);
AISetMoveThing(xt, GetThingPos(target));
AISetMode(xt, 0x20a);
AIClearMode(xt, 0x1000);
For(i=0; i<=4; i=i+1)
{
AISetFireTarget(remote[i], xt);
AISetMoveThing(remote[i], GetThingPos(xt));
AISetMode(remote[i], 0x20a);
}
Return;
# .................................................. ......................................
killed:
If(GetSenderRef != xt)
{
count = count + 1;
PrintInt(count);
}
SetPulse(0);
jkSetFlags(darkjedi, 0x8);
Return;
end
Any ideas, because I'm stumped. http://forums.massassi.net/html/frown.gif Both xt and the remotes have new/modified AI files. The AI and Templates check out fine.
------------------
The Sniper Missions. Current project, The Sniper Missions
The first part is my problem, the remotes just stand still, they won't get close enough for xt to saber them. Otherwise, they hang near me. http://forums.massassi.net/html/confused.gif Here's the cog.
# Jedi Knight Cog Script
#
# xt_rlx.COG
#
# Controls the xt battling remotes
#
# This Cog is Not supported by LucasArts Entertainment Co
symbols
thing xt
thing remote
thing remote1
thing remote2
thing remote3
thing target local
thing player local
int i local
int count=0 local
material tip_mat=saberred0.mat local
material side_mat=saberred1.mat local
template tpl_wall=+ssparks_wall local
template tpl_blood=+ssparks_blood local
template tpl_saber=+ssparks_saber local
message startup
message pulse
message killed
end
# ================================================== ======================================
code
startup:
jkSetSaberInfo(xt, side_mat, tip_mat, 0.003, 0.001, 0.101, tpl_wall, tpl_blood, tpl_saber);
jkSetFlags(xt, 0x5);
count = 0;
SetPulse(0.1);
Return;
# .................................................. ......................................
pulse:
target = FirstThingInView(xt, 170, 12, 0x4);
player = GetLocalPlayerThing();
if(count >= 4) SetPulse(0);
if((target == xt) || (target == player) || (!target))
{
return;
}
AISetFireTarget(xt, target);
AISetMoveThing(xt, GetThingPos(target));
AISetMode(xt, 0x20a);
AIClearMode(xt, 0x1000);
For(i=0; i<=4; i=i+1)
{
AISetFireTarget(remote[i], xt);
AISetMoveThing(remote[i], GetThingPos(xt));
AISetMode(remote[i], 0x20a);
}
Return;
# .................................................. ......................................
killed:
If(GetSenderRef != xt)
{
count = count + 1;
PrintInt(count);
}
SetPulse(0);
jkSetFlags(darkjedi, 0x8);
Return;
end
Any ideas, because I'm stumped. http://forums.massassi.net/html/frown.gif Both xt and the remotes have new/modified AI files. The AI and Templates check out fine.
------------------
The Sniper Missions. Current project, The Sniper Missions