Raised This Month: $ Target: $400
 0% 

Proofreading


  
 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
Hawk552
AMX Mod X Moderator
Join Date: Aug 2005
Old 10-20-2009 , 12:44   Re: Proofreading
Reply With Quote #4

Quote:
Originally Posted by OneMoreLevel View Post
First of thanks alot, It must have tooken quite awhile to do that.

About indenting, when I press Ctrl-I in the compiler, it just brings the code to look like that, and when I indent by myself, it gives me some warnings.
Use tab instead of spaces.

Quote:
Originally Posted by OneMoreLevel View Post
Please do, Im still quite a newb at this.
PHP Code:
enum MODES
{
    
WM 0,
    
JF,
    
SB,
    
ST,
    
AH,
    
RO,
    
SS
}

new 
Float:gSpeeds[_:MODES] =
{
    
300.0,
    
400.0,
    
350.0,
    
250.0,
    
300.0,
    
325.0,
    
275.0
}

new 
gHealths[_:MODES] =
{
    
200,
    
175,
    
175,
    
255,
    
150,
    
175,
    
200
}

new 
gNames[_:MODES][] =
{
    
"War Machine",
    
"Jet Fighter",
    
"Stealth Bomber",
    
"Scorpion Tank",
    
"Apache Helicopter",
    
"Railgun Operator",
    
"Submarine Seeker"
}

// ...

    
client_printidprint_chat"[AMX] You are now a %s. Type /classinfo for information."gNames[item] )
    
set_user_maxspeedidgSpeeds[item] )
    
set_user_healthidgHealths[item] )

// ...
    
    
switch ( item )
    {
        case 
JF :
            
set_user_renderingidkRenderFxGlowShell000kRenderTransAlpha185 )
        case 
SB :
        {
            
set_user_renderingidkRenderFxGlowShell000kRenderTransAlpha65 )
            
cs_set_user_bpammoidCSW_HEGRENADE)
        }
        case 
SS :
            
set_user_renderingidkRenderFxGlowShell000kRenderTransAlpha130 )
    } 
That's a generalized solution to what you were asking.

Quote:
Originally Posted by OneMoreLevel View Post
Im also Quite confused with this one, I know what you mean by creating it in plugin_init, but I dont understand the storing it globally part.
PHP Code:
new gMenu

public plugin_init()
    
gMenu menu_create"whatever""who cares" )

// ...
    
    
menu_displayidgMenu )

// ...

public plugin_end()
    
menu_destroygMenu 
__________________
Hawk552 is offline
Send a message via AIM to Hawk552
 



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 17:40.


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