 |
|
Senior Member
Join Date: Nov 2013
Location: Vilnius, Lithuania
|

05-18-2016
, 00:18
Re: Plugin compile error (old plugin)
|
#11
|
Quote:
Originally Posted by wickedd
PHP Code:
#include <amxmodx>
#define PLUGIN "HUD MSG for VIP,Admin,Player"
#define VERSION "1.0"
#define AUTHOR "4iTGAME & Dim4ik"
new const joining[] = "myproject/mysound.wav"
public plugin_init(){
register_plugin(PLUGIN, VERSION, AUTHOR)
}
public plugin_precache()
{
precache_sound( joining )
}
public client_putinserver(id)set_task(5.0,"flappybuird",id)
public flappybuird(id)
{
new szName[32]
get_user_name(id, szName, charsmax(szName))
if(get_user_flags(id) & ADMIN_LEVEL_B)
{
set_dhudmessage(0, 255, 0, 0.28, 0.16, 0, 6.0, 12.0)
show_dhudmessage(id, "Glad to see the Administrator %s! Enjoy the game.", szName)
client_cmd( id, "spk ^"sound/%s^"", joining ) // copy and paste this line where you want the sound to play
}
else if(get_user_flags(id) & ADMIN_LEVEL_H)
{
set_dhudmessage(0, 255, 0, 0.28, 0.16, 0, 6.0, 12.0)
show_dhudmessage(id, "Glad to see you VIP %s! Enjoy the game.", szName)
}
else
{
set_dhudmessage(0, 255, 0, 0.28, 0.16, 0, 6.0, 12.0)
show_dhudmessage(id, "Glad to see you %s ! Enjoy the game.", szName)
}
}
/* AMXX-Studio Notes - DO NOT MODIFY BELOW HERE
*{\\ rtf1\\ ansi\\ deff0{\\ fonttbl{\\ f0\\ fnil Tahoma;}}\n\\ viewkind4\\ uc1\\ pard\\ lang1049\\ f0\\ fs16 \n\\ par }
*/
|
Why the "\n" didn't work?
PHP Code:
Glad to see the Administrator %s! [B]\n[/B]Enjoy the game.
|
|
|
|