Raised This Month: $ Target: $400
 0% 

%L


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
Rolnaaba
Veteran Member
Join Date: May 2006
Old 06-28-2007 , 22:47   %L
Reply With Quote #1

can someone explain, the %L used like in client_print(). I am not sure what it is could someone explain what it is, and how to use it, and why to use it ect.
__________________
DO NOT PM me about avp mod.
Rolnaaba is offline
stupok
Veteran Member
Join Date: Feb 2006
Old 06-28-2007 , 22:59   Re: %L
Reply With Quote #2

You must create a txt file in "amxmodx\data\lang" with translations, formatted like this:

Code:
[en]
LOADED_ADMIN = Loaded 1 admin from file

[de]
LOADED_ADMIN = 1 Admin aus der Datei geladen

[sr]
LOADED_ADMIN = Ucitan 1 administrator iz fajla
In plugin_init() do this:

Code:
register_dictionary("your_file.txt")
Then use format() to format the string in the user's or server's language:

Code:
new text[64]
format(text, 63, "%L", LANG_PLAYER, "LOADED_ADMIN")
Code:
#define LANG_SERVER		0
#define LANG_PLAYER		-1
stupok is offline
Rolnaaba
Veteran Member
Join Date: May 2006
Old 06-28-2007 , 23:09   Re: %L
Reply With Quote #3

then you could do, client_print(id, print_chat, text); interesting, are the [en], [de] ect. headers hardcoded? meaning does it have to be [en] or can i say [english]? And if hardcoded can I find a list of all of them?
__________________
DO NOT PM me about avp mod.
Rolnaaba is offline
XxAvalanchexX
Veteran Member
Join Date: Oct 2004
Location: abort73.com
Old 06-28-2007 , 23:10   Re: %L
Reply With Quote #4

http://wiki.amxmodx.org/Advanced_Scr...ingual_Support
__________________
No longer around. Thanks your support, everyone! As always:
THIS ONES FOR YOU
3000 PTS
XxAvalanchexX is offline
Rolnaaba
Veteran Member
Join Date: May 2006
Old 06-28-2007 , 23:11   Re: %L
Reply With Quote #5

thanx
__________________
DO NOT PM me about avp mod.
Rolnaaba is offline
Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


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


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