Coding a zombie mod (editing)

Posts 1–4 of 4 · Page 1 of 1
Coding a zombie mod (editing)
Hi, i am editing and improving this Zombie Mod by dozzer. I already done many things like dissabling planting and stuff. But i need help with this one part...

I need to make this action NOT be able to repeat.
I've tried every function like "return false;" or any kind of function but it doesnt seem to work or it gives me a syntax error.

Code:
ghost() {               //the zombie class.
	self endon ( "disconnect" );
	self endon ( "death" );
	
	self notifyOnPlayerCommand("3", "+actionslot 3");      //button for flash ,smoke etc...

	while(1) {
		self waittill("3");
		self maps\mp\perks\_perks::givePerk("specialty_thermal");  //thermal ability...

		self hide();   // ability to be invisible
		self iPrintlnBold("^2Zombie Vision On");   //Printing the mode...
		wait 20;         // i dont know how many seconds....
		self _clearPerks();
		self maps\mp\perks\_perks::givePerk("specialty_marathon");
        self maps\mp\perks\_perks::givePerk("specialty_longersprint");
	self maps\mp\perks\_perks::givePerk("specialty_fastsprintrecovery");
        self maps\mp\perks\_perks::givePerk("specialty_lightweight");
		self maps\mp\perks\_perks::givePerk("specialty_extendedmelee");
		self maps\mp\perks\_perks::givePerk("specialty_automantle");
		self maps\mp\perks\_perks::givePerk("specialty_fastmantle");
		self maps\mp\perks\_perks::givePerk("specialty_quieter");
		self maps\mp\perks\_perks::givePerk("specialty_coldblooded");
		self show();      // to be visible again...
		self iPrintlnBold("^2Zombie Vision Off");
	}
}
I made it so that you can turn on Zombie mode vision on for a few seconds. But when the "few seconds" are done you can repeat the action wich i don't want... if anyone would help me out i would appriciate it, thank you... Apple!
there's several ways you can do this, the easiest is to put a wait at the end:
wait 999999;
Quote Originally Posted by Neekokeen View Post
there's several ways you can do this, the easiest is to put a wait at the end:
wait 999999;
thank you, it worked. One more thing, can you tell me how much seconds are "wait 1;"
wait 1; is 1 second
Posts 1–4 of 4 · Page 1 of 1
This thread is closed for replies.

Similar Threads

Talk with us