AlliedModders

AlliedModders (https://forums.alliedmods.net/index.php)
-   Scripting Help (https://forums.alliedmods.net/forumdisplay.php?f=11)
-   -   emit sound to everyone and print chat (https://forums.alliedmods.net/showthread.php?t=56924)

crazylf2 06-24-2007 08:25

emit sound to everyone and print chat
 
how to emit sound to everyone and use client_print
to print chat by multilingual support ?

i tried a lot and still not work

thx

Deviance 06-24-2007 08:30

Re: emit sound to everyone and print chat
 
Quote:

Originally Posted by crazylf2 (Post 494050)
how to emit sound to everyone

Code:
client_cmd(0, "spk path/to/sound")
or
Code:
emit_sound(0, CHAN_AUTO, "path/to/sound", VOL_NORM, ATTN_NORM, 0, PITCH_NORM)

mateo10 06-24-2007 08:31

Re: emit sound to everyone and print chat
 
Print chat with multilingual support:
Plugin init:
Code:
register_dictionary("file.txt");

Function:
Code:
client_print(0, print_chat, "%L", LANG_PLAYER, "FLAG");

file.txt
Code:

[en]
FLAG = "Hello world"


crazylf2 06-24-2007 08:43

Re: emit sound to everyone and print chat
 
yes ! it worked !

but what is the usage of "%L" ?

mateo10 06-24-2007 08:45

Re: emit sound to everyone and print chat
 
Edit: It searches the language file if there is a flag called FLAG, and takes the information from it and parses it into the client print.


All times are GMT -4. The time now is 21:24.

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