Post: Animating Your Menu's!
07-30-2011, 06:03 PM #1
Correy
I'm the Original
(adsbygoogle = window.adsbygoogle || []).push({}); First of all you need these codes, put them anywhere in your GSC
    
elemMoveX(time,Input)
{
self moveOverTime(time);
self.x=Input;
}

    
elemMoveY(time,Input)
{
self moveOverTime(time);
self.y=Input;
}


right, now onto making your menu move.
you need to code your shader from where you want it to start, here's mine from my new menu.
    
self.Shader=self CreateShader("LEFT","LEFT",10,-400,150,700,"white",0.90,0,(0,0,0));


this will start off the screen, like i wanted it too..
now, you need to code where you would like it too move to, using X axis and Y axis.. like this.
    
self.Shader elemMoveY(1,-175);

    
self.Shader elemMoveX(1,10);


you need to add the name of the shader to the coding, do that by using self.SHADERNAME
the X axis is position from the right of the screen, Y is from the top or bottom.. also, you need to put that shader move code onto the menu opening button.

for the 1, at the beginning of the bracket thats the time of how long it takes to get the and then the number after the , is the position on the screen.
note: don't be ripping this from me, i know cause i've never seen a menu which moves like this!

yeah, btw before you ask.. i've made a new menu which you should see Very soon.
(adsbygoogle = window.adsbygoogle || []).push({});

The following 4 users say thank you to Correy for this useful post:

Glittery Penis Skittle, iReset Nigga,
07-30-2011, 06:18 PM #2
iReset Nigga
2Fresshh!!
good shit cant wait to see ur new menu
07-30-2011, 06:20 PM #3
Correy
I'm the Original
Originally posted by iReset View Post
good shit cant wait to see ur new menu


i only need to add my mods to it Winky Winky
07-30-2011, 06:30 PM #4
iReset Nigga
2Fresshh!!
Originally posted by Correy View Post
i only need to add my mods to it Winky Winky


maybe i could use this base for my patch Cool Man (aka Tustin) if u release i will def be taking a look into adding all my mods in the base aswell
07-30-2011, 06:37 PM #5
Originally posted by Correy View Post
i only need to add my mods to it Winky Winky


I used this in MW2 but it's in COD4 as well, it makes your text flash (obviously)

flashThread();

Its in the hud_utility..
07-30-2011, 06:52 PM #6
Correy
I'm the Original
Originally posted by x. View Post
I used this in MW2 but it's in COD4 as well, it makes your text flash (obviously)

flashThread();

Its in the hud_utility..


is that being for the select menu text, or you mean any text and would it be like flashText("blah"); or isn't it coded with an argument?
07-30-2011, 06:57 PM #7
Originally posted by Correy View Post
is that being for the select menu text, or you mean any text and would it be like flashText("blah"); or isn't it coded with an argument?


No, you use it for the text string so if you had

xText = createfontstring(a,b); etc... you then just use
xText flashThread();

Here's the full function from Hud_Util.gsc



flashThread()
{
self endon ( "death" );

if ( !self.hidden )
self.alpha = 1;

while(1)
{
if ( self.frac >= self.flashFrac )
{
if ( !self.hidden )
{
self fadeOverTime(0.3);
self.alpha = .2;
wait(0.35);
self fadeOverTime(0.3);
self.alpha = 1;
}
wait(0.7);
}
else
{
if ( !self.hidden && self.alpha != 1 )
self.alpha = 1;

wait ( 0.05 );
}
}
}

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

Correy, Docko412,
07-30-2011, 11:01 PM #8
Aoehz
Banned
Originally posted by Correy View Post
First of all you need these codes, put them anywhere in your GSC
    
elemMoveX(time,Input)
{
self moveOverTime(time);
self.x=Input;
}

    
elemMoveY(time,Input)
{
self moveOverTime(time);
self.y=Input;
}


right, now onto making your menu move.
you need to code your shader from where you want it to start, here's mine from my new menu.
    
self.Shader=self CreateShader("LEFT","LEFT",10,-400,150,700,"white",0.90,0,(0,0,0));


this will start off the screen, like i wanted it too..
now, you need to code where you would like it too move to, using X axis and Y axis.. like this.
    
self.Shader elemMoveY(1,-175);

    
self.Shader elemMoveX(1,10);


you need to add the name of the shader to the coding, do that by using self.SHADERNAME
the X axis is position from the right of the screen, Y is from the top or bottom.. also, you need to put that shader move code onto the menu opening button.

for the 1, at the beginning of the bracket thats the time of how long it takes to get the and then the number after the , is the position on the screen.
note: don't be ripping this from me, i know cause i've never seen a menu which moves like this!

yeah, btw before you ask.. i've made a new menu which you should see Very soon.


Teach me your ways?
07-30-2011, 11:34 PM #9
Correy
I'm the Original
Originally posted by RelicModz View Post
Teach me your ways?


i have many ways Winky Winky
07-31-2011, 12:20 AM #10
iReset Nigga
2Fresshh!!
Originally posted by x. View Post
No, you use it for the text string so if you had

xText = createfontstring(a,b); etc... you then just use
xText flashThread();

Here's the full function from Hud_Util.gsc



flashThread()
{
self endon ( "death" );

if ( !self.hidden )
self.alpha = 1;

while(1)
{
if ( self.frac >= self.flashFrac )
{
if ( !self.hidden )
{
self fadeOverTime(0.3);
self.alpha = .2;
wait(0.35);
self fadeOverTime(0.3);
self.alpha = 1;
}
wait(0.7);
}
else
{
if ( !self.hidden && self.alpha != 1 )
self.alpha = 1;

wait ( 0.05 );
}
}
}



so could we do this to like menu text??

Copyright © 2026, NextGenUpdate.
All Rights Reserved.

Gray NextGenUpdate Logo