Raised This Month: $ Target: $400
 0% 

Language files


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
MaximusBrood
Veteran Member
Join Date: Sep 2005
Location: The Netherlands
Old 04-14-2006 , 15:15   Language files
Reply With Quote #1

If you are making a plugin which uses a dictionary, and this is your code to display a text:

Code:
client_print(id,  print_chat, "[AMXX] %L", id, "SOME_TEXT", authid)

Which do you have to type the id twice?

client_print(id, print_chat, "[AMXX] %L", id, "SOME_TEXT", authid)
__________________
Released six formerly private plugins. Not active here since ages.
MaximusBrood is offline
BAILOPAN
Join Date: Jan 2004
Old 04-14-2006 , 15:19  
Reply With Quote #2

because you do. %L requires a language target.
__________________
egg
BAILOPAN is offline
Xanimos
Veteran Member
Join Date: Apr 2005
Location: Florida
Old 04-14-2006 , 15:19  
Reply With Quote #3

The second id is when you are sending to one player and that tells the language to set to the clients language.
Xanimos is offline
Send a message via AIM to Xanimos Send a message via MSN to Xanimos
PM
hello, i am pm
Join Date: Jan 2004
Location: Canalization
Old 04-14-2006 , 15:25  
Reply With Quote #4

Or you could use LANG_PLAYER instead of the second id - this makes AMX Mod X auto-choose the language for YOU for YOU for YOU for YOU !!!!
__________________
hello, i am pm
PM is offline
MaximusBrood
Veteran Member
Join Date: Sep 2005
Location: The Netherlands
Old 04-14-2006 , 15:27  
Reply With Quote #5

Ahhh...

But you forgot to tell that you need to specify it because every player has a different language.

Ty
__________________
Released six formerly private plugins. Not active here since ages.
MaximusBrood is offline
PM
hello, i am pm
Join Date: Jan 2004
Location: Canalization
Old 04-14-2006 , 15:35  
Reply With Quote #6

Also, if you are showing something to all players, use client_print with 0 and then LANG_PLAYER.

Of course this won't help you if you are printing to only a subset of the players - you'll have to iterate yourself then.
__________________
hello, i am pm
PM is offline
MaximusBrood
Veteran Member
Join Date: Sep 2005
Location: The Netherlands
Old 04-14-2006 , 16:31  
Reply With Quote #7

Allright, thanks PM
__________________
Released six formerly private plugins. Not active here since ages.
MaximusBrood 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 12:23.


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