UGX-Mods Login

or login with an authentication provider below
Sign In with Google
Sign In with Twitter
Sign In with Discord
Sign In with Steam
Sign In with Facebook
Sign In with Twitch

cod2 gsc problem

broken avatar :(
Created 12 years ago
by hellboy
0 Members and 1 Guest are viewing this topic.
2,005 views
broken avatar :(
×
broken avatar :(
Date Registered: 14 March 2012
Last active: 6 years ago
Posts
44
Respect
Forum Rank
Legless Crawler
Primary Group
Donator ♥
My Groups
More
×
hellboy's Groups
Donator ♥ Benevolent Soul who has our eternal gratitude and exclusive access to betas and the donator section of the forum.
hellboy's Contact & Social Links
hello, im tring to edit this cod2 zombie gsc. when playing the zombie mod if you stand to long in front of the ammo box you get kicked/ temp ban 5 minutes. i tried /* in front an */ end of the function to disable it, but the server doesnt start. any ideas. thanks , ps i dont know why the smiley face shows up. lol

Code Snippet
Plaintext
noblock()
{
self endon("disconnect");
boxes=getentarray("ammobox","targetname");
block=0;
for(;;)
{
f=false;
for(i=0;i<boxes.size;i++)
{
if(distancesquared(getbrushmodelcenter(boxes[i]),self.origin)<5000) {f=true;break;}
}
if(f) block++; else block=0;
if(block==10) {if(!self.lang) clientprint(self,"^5Ne blokkold a Lõszertöltõtt!"); else clientprint(self,"^5Don't block the ammo!"); self suicide();}
wait 1;
}
}
Last Edit: May 07, 2013, 11:28:49 pm by hellboy
broken avatar :(
×
broken avatar :(
[UGX] Founder
Location: usBay Area, California
Date Registered: 24 June 2011
Last active: 2 years ago
Posts
5,551
Respect
6,655Add +1
Forum Rank
Immortal
Primary Group
UGX Administrator
My Groups
More
My Contact & Social Links
More
Signature
If Java had true garbage collection, most programs would delete themselves upon execution.
×
treminaor's Groups
UGX Administrator
UGX Team Member
UGX Site Moderator Has the ability to issue warnings to users, edit and remove posts from the forum and to move topics to other boards. Upholds the rules of the forum. Moderates Chat Rooms.
Remember to put your code in a code block next time. I've fixed your post.

This should work, I've commented the entire inside of the function so essentially it doesn't do anything now:

Code Snippet
Plaintext
noblock()
{ /*
self endon("disconnect");
boxes=getentarray("ammobox","targetname");
block=0;
for(;;)
{
f=false;
for(i=0;i<boxes.size;i++)
{
if(distancesquared(getbrushmodelcenter(boxes[i]),self.origin)<5000) {f=true;break;}
}
if(f) block++; else block=0;
if(block==10) {if(!self.lang) clientprint(self,"^5Ne blokkold a Lõszertöltõtt!"); else clientprint(self,"^5Don't block the ammo!"); self suicide();}
wait 1;
}
*/ }
broken avatar :(
×
broken avatar :(
Date Registered: 14 March 2012
Last active: 6 years ago
Posts
44
Respect
Forum Rank
Legless Crawler
Primary Group
Donator ♥
My Groups
More
×
hellboy's Groups
Donator ♥ Benevolent Soul who has our eternal gratitude and exclusive access to betas and the donator section of the forum.
hellboy's Contact & Social Links
thank you treminaor , it worked great.   :)   :)

 
Loading ...