Raised This Month: $ Target: $400
 0% 

upload vault content to mysql


  
 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
Bugsy
AMX Mod X Moderator
Join Date: Feb 2005
Location: NJ, USA
Old 02-03-2019 , 11:41   Re: upload vault content to mysql
Reply With Quote #7

PHP Code:
#include <amxmodx>
#include <nvault>

const MaxNumberLength 6;

enum VaultValues
{
    
doswiadczenie
    
poziom
    
inteligencja,
    
zdrowie
    
wytrzymalosc
    
kondycja,
    
bonus,
    
monety
    
ochrona
}

new 
iPlayerDataMAX_PLAYERS ][ VaultValues ];

public 
Testid )
{
    new 
szKey32 ] , szData64 ] , iVault;
    
    new 
iLen nvault_getiVault szKey szData charsmaxszData ) );
    
ParsePlayerDataid szData iLen );
}

public 
ParsePlayerDataid szVaultData[] , iLen 
{
    new 
szNumbersVaultValues ][ MaxNumberLength ] , VaultValues:vvIndex VaultValues:-iPos 0;
    
    
replace_allszVaultData iLen "#" " " );
    
    while ( ( 
iPos > -) && ( ++vvIndex VaultValues:sizeofszNumbers ) ) )
    {
        
iPos argparseszVaultData iPos szNumbersvvIndex ] , charsmaxszNumbers[] ) );
        
        
iPlayerDataid ][ VaultValues:vvIndex ] = str_to_numszNumbersvvIndex ] );
        
        
server_print"Found [%d]" iPlayerDataid ][ VaultValues:vvIndex ] );
    }

__________________
Bugsy 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 07:39.


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