hi. ok so my ShowHud function is not updating properly. it says Level: 0 XP: 0 SkillPoints: 0
but when i type /xp which runs the showhud function it goes to Level : 0 XP: 40 SkillPoints: 0
really fast. then goes back to 0 for all.
any help would be apreciated. :) I'm new to this so yea. ^-^
YamiKaitou
06-23-2012 00:37
Re: Hud Not Updating Properly? o.0
id is 0 in ShowHud, pass the correct id in set_task.
Moved to Scripting Help
Bombe_
06-23-2012 00:46
Re: Hud Not Updating Properly? o.0
thanks for moving, i didn't realize I posted it here. Anyway, i'm not sure what you mean by the correct id in set task. how would i know? :o
Also anther question:
when my xp goes over the required to level: ex. you need 100 xp and its at 105. it wont level up. from 0 to lvl 1? o.o so frustrating.
switch( get_cvar_num ( "amx_show_activity" ) ) { case 1: client_print( 0, print_chat, "ADMIN: gave %i EXP to %s.", expnum, player_name ); case 2: client_print( 0, print_chat, "ADMIN %s: gave %i EXP to %s.", admin_name, expnum, player_name ); }
client_print( player, print_chat, "[AMXX] You received %i EXP. (Total: %d)", expnum, PlayerXP[player] );
SaveData( id )
return PLUGIN_CONTINUE; }
YamiKaitou
06-23-2012 01:18
Re: Hud Not Updating Properly? o.0
Are you wanting to show the hud message to every user?
Also, in client_connect, the user does not have an authid yet.
Bombe_
06-23-2012 10:04
Re: Hud Not Updating Properly? o.0
Well, every user has its own hud. so yeah.
+
edit;
ok so I added
Code:
new authID[32];
get_user_authid(id,authID,32);
in client_connect to get their id.
edit;
Also I believe I fixed the
Quote:
Originally Posted by Bombe_
(Post 1734277)
Also anther question:
when my xp goes over the required to level: ex. you need 100 xp and its at 105. it wont level up. from 0 to lvl 1? o.o so frustrating.
thing.
now I just need the hud message to update properly. cause when I type /xp it shows the actual level and xp. but when it sets task it just shows 0 for all.
ConnorMcLeod
06-23-2012 11:21
Re: Hud Not Updating Properly? o.0
This is not your personal forum, don't delete your posts once you got your answer.
Next time you do this i request a ban, i hope you understand.