Post: [SCRIPT] UFO Mode | 10x Shorter Script | Converted From MW2
12-01-2011, 08:16 PM #1
IVI40A3Fusionz
Former Gaming Squad Member
(adsbygoogle = window.adsbygoogle || []).push({}); I see alot of people were still using the old, boring and long script for the UFO Mode mod in their menus, so i thought i would make a better code that was shorter and more easy to understand. This is basically a recreation of how it was done on MW2 just I've changed a few things and taken some things out so it's compatible with CoD4.

Thread doUFO to your menu ( you probably want to make this a toggle for your menu but you can do that yourself Winky Winky ).

    doUFO()
{
self endon ( "disconnect" );
self endon ( "death" );
self thread MonitorButtons();
for(;Winky Winky
{
self waittill("Pressed_Square");
if ( self GetStance() == "crouch")
{
self.sessionstate = "spectator";
self allowSpectateTeam( "freelook", true );
}
self waittill("Pressed_Square");
self.sessionstate = "playing";
self allowSpectateTeam( "freelook", false );
}
}

MonitorButtons()
{
self endon("death");
self endon("disconnect");
for(;Winky Winky
{
if(self UseButtonPressed())
{
self notify("Pressed_Square");
wait .3;
}
wait .05;
}
}


Correy's Version:
    On_Ufo( yesorno )
{
self.sessionstate = "playing";
self allowSpectateTeam( "freelook", false );
if( yesorno == "yes" )
{
while( self GetStance() == "crouch" )
{
if( self UseButtonPressed() )
{
self allowSpectateTeam( "freelook", true );
self.sessionstate = "spectating";
}
}
}
}

go in crouch and press sqaure.. use input to toggle !

- Toggle On
    self OnUfo( "yes" );

change the yes to anything to turn off


How To Use:
After you've selected the option from your menu, crouch and press Square (On the PS3) or X (On the XBOX 360) and it will activate the mod.
When you want to exit UFO Mode press Square (On the PS3) or X (On the XBOX 360) and it will end the mod.

Credits:
Correy - For the spectate function
Who ever created this for MW2


EDIT: This can be made shorter however i'm stupid and don't know the self waitill(""); for when you press square so if anyone knows it please tell me Smile.
(adsbygoogle = window.adsbygoogle || []).push({});

The following 3 users say thank you to IVI40A3Fusionz for this useful post:

BlazingDope, Correy, JamesSwagger
12-01-2011, 11:28 PM #11
Correy
I'm the Original
Originally posted by reScript View Post
No?
The lier that said that to me says that! :carling:


um, what :p?
you said while only works with '1'
12-01-2011, 11:35 PM #12
Woof
...hmm
Originally posted by Correy View Post
um, what :p?
you said while only works with '1'

No I didn't I knew it was a fake statement someone made to me.
This is what I said "Apparently the "while" statement in GSC does not allow anything other than "1", is this true or is someone telling me porky-pies?".
Read what I write properly >.<
12-01-2011, 11:43 PM #13
Correy
I'm the Original
Originally posted by reScript View Post
No I didn't I knew it was a fake statement someone made to me.
This is what I said "Apparently the "while" statement in GSC does not allow anything other than "1", is this true or is someone telling me porky-pies?".
Read what I write properly >.<


i dont get it ha, so someone told you that you can only use 1?
12-02-2011, 05:43 AM #14
Blackstorm
Veni. Vidi. Vici.
Originally posted by reScript View Post
Apparently the "while" statement in GSC does not allow anything other than "1", is this true or is someone telling me porky-pies?
:rolleyes:


No lol it works the same as any other languages.. :b

The following user thanked Blackstorm for this useful post:

Woof

Copyright © 2026, NextGenUpdate.
All Rights Reserved.

Gray NextGenUpdate Logo