Raised This Month: $ Target: $400
 0% 

error 035: argument type mismatch (argument 1)


  
 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
Author Message
supertrio17
Senior Member
Join Date: May 2020
Location: Serbia
Old 06-13-2020 , 11:27   error 035: argument type mismatch (argument 1)
Reply With Quote #1

Hey, so I want to make class plugin, and I want to remember which class member had when they leave the server. I wanted to use nVault, but for some reason it gives me this error.

Here is my code
PHP Code:
public rank_ten_c_one(id//Samurai
{
    
get_user_authidid g_szAuthID[id] , charsmaxg_szAuthID[] ) );

    new 
szClass;
    new 
szKey[40];

    
formatexszKey charsmaxszKey ) , "%sCLASS" g_szAuthID[id] );
    
formatexszClass charsmaxszClass ) , %g_Class );
    
    
nvault_setg_Vault szKey szClass );

    
set_user_health(id110);
    
set_user_gravity(id1.2);

I use g_Vault to set integer for each class, Example: Assasin = 1, Wizard = 2 ....
And on client_authorized, I would read szClass value from nVault like this:

PHP Code:
public client_authorized(id)
{
    new 
szKey[40];
    
formatexszKey charsmaxszKey ) , "%sCLASS" g_szAuthID[id] );
    new 
iClass nvault_getg_Vault szKey );
    if( 
iClass )
    {
        switch(
iClass)
        {
            case 
1:
            {
                
set_user_health(id110);
                
set_user_gravity(id1.2);
            }
            case 
2:
            {
                
set_user_health(id120);
                
set_user_gravity(id1.3);
            }
            case 
3:
            {
                
set_user_health(id130);
                
set_user_gravity(id1.2);
            }
            case 
4:
            {
                
set_user_health(id130);
                
set_user_gravity(id1.2);
                
set_user_maxspeed(id1.5);
            }
            case 
5:
            {
                
set_user_health(id110);
                
set_user_gravity(id1.6);
                
set_user_maxspeed(id1.1);
            }
            case 
6:
            {
                
set_user_health(id190);
                
set_user_gravity(id0.8);
                
set_user_maxspeed(id0.8);
            }
        }
    }

__________________
Contact! || Discord:
Mr_Boopsy_#2066
supertrio17 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 16:58.


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