![]() |
Sphere msgs.scp - Printable Version +- SphereCommunity (https://forum.spherecommunity.net) +-- Forum: Sphere 0.56d (/Forum-Sphere-0-56d) +--- Forum: Script Help (/Forum-Script-Help) +--- Thread: Sphere msgs.scp (/Thread-Sphere-msgs-scp) Pages: 1 2 |
Sphere msgs.scp - Russian - 07-16-2012 02:35 AM Hello. Sphere msgs.scp have a DEFMESSAGEs for one language. How i can set two DEFMESSAGE for various languages? RE: Sphere msgs.scp - Shidhun - 07-16-2012 02:55 AM I think that is not possible just with changing this defmessages within the script. You could change every Defmessage into a Cliloc. But you would have to distribute two different Clilocs to your players . Of course you need to create this cliloc-files first RE: Sphere msgs.scp - Skul - 07-16-2012 05:42 AM @Russian, //comment the defmessage and recode it through it's proper aspect and use account.lang to retrieve the player's language. RE: Sphere msgs.scp - Russian - 07-18-2012 03:45 AM account.lang where is it? RE: Sphere msgs.scp - Wap - 07-18-2012 07:10 AM Russian, what version of client do you use? Account.lang is in the account block: [x] ... LANG=RUS But... I don't know a way to make sysmessages on two languages, using this(excluding overriding internal action-scripts, but it is funny). RE: Sphere msgs.scp - Shaklaban - 07-18-2012 01:37 PM Im using defnames and functions for multi language support, but i never replace hardcoded ones since everyone knows them which plays sphere. Little examples from my shard: PHP Code: [defname language_support] I never think about clilocs since connection which used by sphere in nothing, and its not useful to edit cliloc files with every script change. RE: Sphere msgs.scp - Abuelox - 11-15-2012 06:12 AM How could operate in dialogs and names of objects? I cannot find the way or better said, I have no much idea ... , could help me? Thank you very much! ERROR in console: Code: 23:16:ERROR:(funciones_scripts.scp,5)Can't resolve <account.dtag0.lang> and this is the function: Code: [function lng] RE: Sphere msgs.scp - Shaklaban - 11-16-2012 01:20 PM in dialogs you need to use <src.lng> because default uid can be an item or npc in dialog. also in message function you need to use <src.lng>. RE: Sphere msgs.scp - Skul - 11-16-2012 01:24 PM (11-15-2012 06:12 AM)Abuelox Wrote: How could operate in dialogs and names of objects? I cannot find the way or better said, I have no much idea ... , could help me? Thank you very much! account.lang is stored as a string, so using dtag0 won't resolve if it is set. try this function rather than the function you posted: Code: [function lng] RE: Sphere msgs.scp - xwerswoodx - 06-22-2013 10:43 PM Code: [Function language] In the dialog or sysmessage; SYSMESSAGE <language_too_away_<src.language>> DTEXT - - 0 <language_too_away_<src.language>> |