SA-MP Forums Archive
#define and SendClientMessage - Printable Version

+- SA-MP Forums Archive (https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (https://sampforum.blast.hk/forumdisplay.php?fid=12)
+--- Thread: #define and SendClientMessage (/showthread.php?tid=615239)



#define and SendClientMessage - 28days - 19.08.2016

Hello. There is one problem, such as a constant

#define ERROR_TEXT "You need to check your mail"

and if you use so it will not be replaced

PHP Code:
SendClientMessage(playerid,-1,"Problem:ERROR_TEXT"); 
result
Quote:

Problem: ERROR_TEXT

How to use a constant in order to function SendClientMessage correctly displays the value?


Re: #define and SendClientMessage - SyS - 19.08.2016

PHP Code:
SendClientMessage(playerid,-1,"Problem: "ERROR_TEXT); 



Re: #define and SendClientMessage - AndySedeyn - 19.08.2016

PHP Code:
SendClientMessage(playerid,-1,"Problem: "ERROR_TEXT); 



Re: #define and SendClientMessage - 28days - 19.08.2016

Thank you all, work.