Script to end game once a trigger is, "triggered"
Posted: October 5th, 2007, 9:02 am
How would you do that? also once its triggered the allies, and only allies team can score, they get 1000 kills extra on there team.
CoDJumper.com - For all your CoDJumping needs!
https://codjumper.com/forums/
Code: Select all
trigger waittill("trigger",user);
user.score=1000;
Code: Select all
trigger waittill("trigger",user);
endMap();
Code: Select all
main()
{
maps\mp\_load::main();
getent("kingofhill_trigger","targetname") thread kingofhill_trigger();
}
kingofhill_trigger()
{
while(1)
{
self waittill("trigger", other);
while(other isTouching(self))
{
self.score++;
wait 1;
}
wait 0.05;
}
}
Code: Select all
main()
{
maps\mp\_load::main();
level.pointNum = 0;
getent("kingofhill_trigger_axis","targetname") thread kingofhill_trigger_axis();
getent("kingofhill_trigger_allies","targetname") thread kingofhill_trigger_allies();
}
kingofhill_trigger_axis()
{
while(1)
{
self waittill("trigger", other);
while(other isTouching(self))
{
if(self.pers["team"] == "allies")
{
self.score++;
wait 1;
}
else
self iprintln("This is your base.");
}
wait 0.05;
}
}
kingofhill_trigger_allies()
{
while(1)
{
self waittill("trigger", other);
while(other isTouching(self))
{
if(self.pers["team"] == "axis")
{
self.score++;
wait 1;
}
else
self iprintln("This is your base.");
}
wait 0.05;
}
}