Raised This Month: $ Target: $400
 0% 

[HELP]How can I save.


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
waza123a
Member
Join Date: Mar 2010
Old 01-09-2014 , 04:46   Re: [HELP]How can I save.
Reply With Quote #1

PHP Code:

// in plugin init
RegisterHamHam_Spawn"player""FwdHamPlayerSpawn");


public 
FwdHamPlayerSpawn( const id ) {
    if(
is_user_alive(id)) {
  
LoadHealth(id);
}
}


    public 
client_putinserverid )
    {
        
set_task(1.0"SaveHealth"6767+id);
    }

public 
client_disconnect(id){
    
remove_task(6767 id);
}


public 
SaveHealth(id)
{
    if(!
is_user_alive(id)) return PLUGIN_HANDLED;

    new 
authid[35];
    
get_user_authid(idauthidsizeof(authid) - 1);
    
    new 
data[16];
    
num_to_str(gXP[id], datasizeof(data) - 1);
    
    
fvault_set_data(g_vault_nameauthiddata);

__________________
Life is good, sometimes...

Last edited by waza123a; 01-09-2014 at 04:55.
waza123a is offline
Reply



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 10:13.


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