Raised This Month: $ Target: $400
 0% 

Dont have to hold the key pressed


  
 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
Author Message
CS-A-Roland
Member
Join Date: Jul 2009
Old 07-14-2012 , 16:27   Dont have to hold the key pressed
Reply With Quote #1

Hey by the way i tink about another part of another script....

Here it is and also NOT MINE i try to fix it...:
Code:
            static iButton;
            iButton = get_user_button( id );
            
            if( iButton & IN_USE )
            {
                static Float:fOrigin[ 3 ];
                pev( id, pev_origin, fOrigin );
                
                if( get_distance_f( fOrigin, g_flWallOrigin[ id ] ) > 10.0 )
                    return;
                
                if( pev( id, pev_flags ) & FL_ONGROUND )
                    return;
                
                if( iButton & IN_FORWARD )
                {
                    static Float:fVelocity[ 3 ];
                    velocity_by_aim( id, 240, fVelocity );
                    
                    set_pev( id, pev_velocity, fVelocity );
                }
                
                else if( iButton & IN_BACK )
                {
                    static Float:fVelocity[ 3 ];
                    velocity_by_aim( id, -240, fVelocity );
                    
                    set_pev( id, pev_velocity, fVelocity );
                }
            }
When i dont want to hold the key pressed but want more to stay or run to the wall ive been at this moment, did i must delede the "iButton &" code in front of the IN_FORWARD IN_BACK ?!
The idea iss to Jump to the wall, press the key and then the function to climb is on and if i jump from the wall or press the key again i lost the climb function...

Thanks for understanding it! And thanks for anyone who help!
__________________
oOOOoooh it's www.Cs-Attack.de
New World of Warcraft Mod Beta 0.5(based on WC3FT 3.5)
Counterstrike 1.6 SERVER:
Server IP: 193.192.58.154:27200

CONDITION ZERO SERVER:
Server IP: 193.192.58.154:27016
CS-A-Roland is offline
 



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 15:24.


Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.
Theme made by Freecode