AlliedModders

AlliedModders (https://forums.alliedmods.net/index.php)
-   Scripting Help (https://forums.alliedmods.net/forumdisplay.php?f=11)
-   -   [Help] Client_print Problem (https://forums.alliedmods.net/showthread.php?t=95956)

Mr.Noobie 06-29-2009 03:19

[Help] Client_print Problem
 
anyone know why i can't add ^n like this:

PHP Code:

#include <amxmodx>
 
#define TIME_DELAY 100.0
#define TEXT_SAY "[AMX] Version 1.8.1, Zombie Plague Version 4.3. ^n Enjoy Your Stay."
 
public plugin_init() 
{
        
register_plugin("Information","1.0","Mr.Noobie")
        
set_task(TIME_DELAY"Information"0__"b")
}
 
public 
Information()
{
        
client_print(0print_chatTEXT_SAY)


In the gameplay the TEXT_SAY show this :

Code:

[AMX] Version 1.8.1, Zombie Plague Version 4.3.  Enjoy Your Stay.
I want it like this :

Code:

[AMX] Version 1.8.1, Zombie Plague Version 4.3.
Enjoy Your Stay.


usabrad86 06-29-2009 03:23

Re: [Help] Client_print Problem
 
try this
PHP Code:


        client_print
(0print_chat,"%s",TEXT_SAY


Mr.Noobie 06-29-2009 03:29

Re: [Help] Client_print Problem
 
Quote:

Originally Posted by usabrad86 (Post 859863)
try this
PHP Code:

 
        client_print
(0print_chat,"%s",TEXT_SAY


I try
PHP Code:

client_print(0print_chat"%s"TEXT_SAY

Didn't work still same.

Arkshine 06-29-2009 03:31

Re: [Help] Client_print Problem
 
Use 2 client_print()

Mr.Noobie 06-29-2009 03:35

Re: [Help] Client_print Problem
 
Quote:

Originally Posted by arkshine (Post 859869)
Use 2 client_print()

what you mean ?

Like this ?

PHP Code:

#include <amxmodx>
 
#define TIME_DELAY 100.0
 
#define TEXT_SAY "[AMX] Version 1.8.1, Zombie Plague Version 4.3." 
#define TEXT_SAY2 "Enjoy Your Stay."
 
public plugin_init() 
{
        
register_plugin("Information","1.0","Mr.noobie")
        
set_task(TIME_DELAY"Information"0__"b")
}
 
public 
Information()
{
        
client_print(0print_chatTEXT_SAY)
        
client_print(0print_chatTEXT_SAY2)


For this it work

Is there any way to prevent for using 2 client_print ?

Arkshine 06-29-2009 03:50

Re: [Help] Client_print Problem
 
You want to put on 2 lines... So I don't see where is the problem. Oo

TitANious 06-29-2009 03:54

Re: [Help] Client_print Problem
 
Don't \n work for that too?

Arkshine 06-29-2009 03:57

Re: [Help] Client_print Problem
 
\ is not the control char by default. It's ^. It can't work in client_print() but for hud message, it does.


All times are GMT -4. The time now is 15:27.

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