"Always code as if the guy who ends up maintaining your code will be a violent psychopath who knows where you live."
Posts
264
Respect
52Add +1
Forum Rank
Mr. Elemental
Primary Group
Member
Login Issues
Forgot password?Activate Issues
Account activation email not received? Wrong account activation email used?Other Problems?
Contact Support - Help Center Get help on the UGX Discord. Join it now! flag_set("whatever_your_flag_is");
players = get_players();
trig = getEnt("trig_name","targetname");
for(i = 0; i < players.size; i++)
{
if(players[i] isTouching(trig))
{
flag_set("whatever_your_flag_is");
trig delete(); //the trigger has been touched no need to keep it anymore
return; //since someone is touching it no need to continue
}
}

i hope that helps
where would i put these scripts
Double Post Merge: July 10, 2015, 12:44:17 am
would i add this to my mapname.gsc and if so where. or do i make a new .gsc
thread intro_trig();
intro_trig()
{
flag_init("whatever_your_flag_is");
flag_wait("all_players_connected");
trig = getEntArray("trig_name","targetname");
players = get_players();
while(1)
{
for(i = 0; i < players.size; i++)
{
for(k = 0; k < trig.size; k++)
{
if(players[i] isTouching(trig[k]))
{
flag_set("whatever_your_flag_is");
trig delete(); //the trigger has been touched no need to keep it anymore
return; //since someone is touching it no need to continue
}
}
}
}
}