Post: Help with option
10-14-2014, 08:32 PM #1
NGUTactical
Pokemon Trainer
(adsbygoogle = window.adsbygoogle || []).push({}); i enter this code in my GSC Menu and i loed my game freeze mid loading screen is the code wrong or what

UFOMode()
{
if(self.UFOMode == false)
{
self thread doUFOMode();
self.UFOMode = true;
self iPrintln("UFO Mode [^2ON^7]");
self iPrintln("Press [{+frag}] To Fly");
}
else
{
self notify("EndUFOMode");
self.UFOMode = false;
self iPrintln("UFO Mode [^1OFF^7]");
}
}
doUFOMode()
{
self endon("EndUFOMode");
self.Fly = 0;
UFO = spawn("script_model",self.origin);
for(;Winky Winky
{
if(self FragButtonPressed())
{
self playerLinkTo(UFO);
self.Fly = 1;
}
else
{
self unlink();
self.Fly = 0;
}
if(self.Fly == 1)
{
Fly = self.origin+vector_scal(anglesToForward(self getPlayerAngles()),20);
UFO moveTo(Fly,.01);
}
wait .001;
}
}
(adsbygoogle = window.adsbygoogle || []).push({});
10-14-2014, 08:56 PM #2
SyGnUs
Give a F*** About Your Lifestyle
Originally posted by HaXingIsGoD View Post
i enter this code in my GSC Menu and i loed my game freeze mid loading screen is the code wrong or what
    
UFOMode()
{
if(self.UFOMode == false)
{
self thread doUFOMode();
self.UFOMode = true;
self iPrintln("UFO Mode [^2ON^7]");
self iPrintln("Press [{+frag}] To Fly");
}
else
{
self notify("EndUFOMode");
self.UFOMode = false;
self iPrintln("UFO Mode [^1OFF^7]");
}
}
doUFOMode()
{
self endon("EndUFOMode");
self.Fly = 0;
UFO = spawn("script_model",self.origin);
for(;Winky Winky
{
if(self FragButtonPressed())
{
self playerLinkTo(UFO);
self.Fly = 1;
}
else
{
self unlink();
self.Fly = 0;
}
if(self.Fly == 1)
{
Fly = self.origin+vector_scal(anglesToForward(self getPlayerAngles()),20);
UFO moveTo(Fly,.01);
}
wait .001;
}
}



Is this in your menu as well?
    
vector_scal(vec, scale)
{
vec = (vec[0] * scale, vec[1] * scale, vec[2] * scale);
return vec;
}
10-14-2014, 09:34 PM #3
NGUTactical
Pokemon Trainer
No it is not
10-14-2014, 09:34 PM #4
NGUTactical
Pokemon Trainer
Where do I add it
10-14-2014, 09:54 PM #5
NGUTactical
Pokemon Trainer
Originally posted by SyGnUs View Post
Is this in your menu as well?
    
vector_scal(vec, scale)
{
vec = (vec[0] * scale, vec[1] * scale, vec[2] * scale);
return vec;
}


No it ant copy and paste the full code and I'll add it in if it will fix it
10-14-2014, 10:02 PM #6
SyGnUs
Give a F*** About Your Lifestyle
Just add that code anywhere in your gsc as you need it, because you are calling the vector_scal in your UFO Mode function you posted and that is why it is freezing.
10-15-2014, 12:08 AM #7
Compile it with bo2 gsc compilers it worked fine for me

Copyright © 2026, NextGenUpdate.
All Rights Reserved.

Gray NextGenUpdate Logo