
single use trigger per user.
Moderator: Core Staff
Well what you could do is make a trigger_once but that would make it so only the first person in the whole server could make it work. I'm sure its possible but I dont know how.
Coding is Poetry. Mapping is Art.
"Cause im the sexiest mapper ever...except for nm, that sexy man" - Soviet
-=[CoDJumper.com Movies]=-
[Ambush] || [Backlot] || [Bloc] || [Bog] || [Broadcast] || [Chinatown] || [Countdown]
[Crash] || [Creek] || [Crossfire] || [District] || [Downpour] || [Killhouse] || [Overgrown]
[Pipeline] || [Shipment & Wetwork] || [Showdown] || [Strike] || [Vacant]
"Cause im the sexiest mapper ever...except for nm, that sexy man" - Soviet
-=[CoDJumper.com Movies]=-
[Ambush] || [Backlot] || [Bloc] || [Bog] || [Broadcast] || [Chinatown] || [Countdown]
[Crash] || [Creek] || [Crossfire] || [District] || [Downpour] || [Killhouse] || [Overgrown]
[Pipeline] || [Shipment & Wetwork] || [Showdown] || [Strike] || [Vacant]
-
- Core Staff
- Posts: 13315
- Joined: April 13th, 2005, 8:22 pm
- Location: UK, London
Ok, this is the way I like to do things. Make a trigger that covers the spawn areas (so, touching the spawns) then make it a trigger_multiple with targetname "start" and then make a trigger_use for the finish button called "finish". Then try this code.
Try that, see if you get any problems (I cannot test for myself atm)
Code: Select all
main()
{
thread start();
}
start()
{
start = getent("start","targetname");
start waittill("trigger",user);
user thread finish_trigger();
}
finish_trigger()
{
finish = getent("finish","targetname");
finish waittill("trigger");
if(!isDefined(self.finishedmap))
{
iprintlnbold(self.name + "^7has completed the map!");
self.finishedmap = true;
}
}

Virgin Media 20Mb Broadband:
"Perfect for families going online at the same time, downloading movies, online gaming and more."
Borked internet since: 22-07-2010
-
- Core Staff
- Posts: 13315
- Joined: April 13th, 2005, 8:22 pm
- Location: UK, London
Good goodKillerSam wrote:drofder.....you amaze me, that works perfectly and credit will given to you on my loading screen, now that i know that code...im sure i can find lots of simliar uses for it......realy greatful

Ejoy


Virgin Media 20Mb Broadband:
"Perfect for families going online at the same time, downloading movies, online gaming and more."
Borked internet since: 22-07-2010
-
- Core Staff
- Posts: 13315
- Joined: April 13th, 2005, 8:22 pm
- Location: UK, London
tbh, the script is VERY basic.KillerSam wrote:drofder.....you amaze me, that works perfectly and credit will given to you on my loading screen, now that i know that code...im sure i can find lots of simliar uses for it......realy greatful
its just people dont think about creating their own vairables (such as "self.finishedmap").

Virgin Media 20Mb Broadband:
"Perfect for families going online at the same time, downloading movies, online gaming and more."
Borked internet since: 22-07-2010
-
- Core Staff
- Posts: 13315
- Joined: April 13th, 2005, 8:22 pm
- Location: UK, London
Well, what im on about is the "self.<variables>"
easily used...
self.boolean = true; // or false;
self.integer = 123; //etc
self.string = "Hello";
you can even double the variables for example...
self.string.one = "Hello";
self.string.two = "Welcome";
You can use anything. You will notice most things that are map specific are...
level.<something> = <something>;
All variables must be defined before you use them... eg
You cannot do
if(self.boolean == false)
iprintln("Blah");
if self.boolean has no value (you will get an error). so you must "declare" them, simply using the method above...
<variable> = <value>;
self.finishedmap = true;
Ja?
easily used...
self.boolean = true; // or false;
self.integer = 123; //etc
self.string = "Hello";
you can even double the variables for example...
self.string.one = "Hello";
self.string.two = "Welcome";
You can use anything. You will notice most things that are map specific are...
level.<something> = <something>;
All variables must be defined before you use them... eg
You cannot do
if(self.boolean == false)
iprintln("Blah");
if self.boolean has no value (you will get an error). so you must "declare" them, simply using the method above...
<variable> = <value>;
self.finishedmap = true;
Ja?

Virgin Media 20Mb Broadband:
"Perfect for families going online at the same time, downloading movies, online gaming and more."
Borked internet since: 22-07-2010
wow drof, I'm amazed at how simple you kept it, good job 

Coding is Poetry. Mapping is Art.
"Cause im the sexiest mapper ever...except for nm, that sexy man" - Soviet
-=[CoDJumper.com Movies]=-
[Ambush] || [Backlot] || [Bloc] || [Bog] || [Broadcast] || [Chinatown] || [Countdown]
[Crash] || [Creek] || [Crossfire] || [District] || [Downpour] || [Killhouse] || [Overgrown]
[Pipeline] || [Shipment & Wetwork] || [Showdown] || [Strike] || [Vacant]
"Cause im the sexiest mapper ever...except for nm, that sexy man" - Soviet
-=[CoDJumper.com Movies]=-
[Ambush] || [Backlot] || [Bloc] || [Bog] || [Broadcast] || [Chinatown] || [Countdown]
[Crash] || [Creek] || [Crossfire] || [District] || [Downpour] || [Killhouse] || [Overgrown]
[Pipeline] || [Shipment & Wetwork] || [Showdown] || [Strike] || [Vacant]
-
- Core Staff
- Posts: 13315
- Joined: April 13th, 2005, 8:22 pm
- Location: UK, London
-
- Core Staff
- Posts: 13315
- Joined: April 13th, 2005, 8:22 pm
- Location: UK, London
Read page 1.creator wrote:...
so how i make it:
it only triggers ones per person
so if i walk thru it it works
if u walk thru it it works
if i walk again thru it it doesnt work
how can i do that wat i need to use?
trig_multiple?
or cant be possible?

Virgin Media 20Mb Broadband:
"Perfect for families going online at the same time, downloading movies, online gaming and more."
Borked internet since: 22-07-2010
Who is online
Users browsing this forum: No registered users and 1 guest