Hustensaft
Apprentice
Posts: 24
Likes Given: 0
Likes Received: 0 in 0 posts
Joined: Apr 2013
Reputation: 0
|
Sphere.msgs and Umlaut in general?
Hi,
i edited some of the Messages in Sphere.msgs, but i'm not really happy with them. I'd like to edit the "food_full" Messages to moething like "Your satiation is now at <Src.Food>", to make the Messages a little more precise, because i implemented Food, that stuffes quite fast, and Food you can eat all day without getting really stuffed. But I haven't found the right format, to implement Strings or Tags in this Messages, when i try "Your satiation is now at <Src.Food>", the Message will be shown right in that way, not the current Value of <Src.Food>.
Is there a way to read out Strings in these Messages?
Ah, and i'd love to use Umlaute ( Ä, Ö, Ü ), Players can use them, but the Server doesn't. So i have to work with ae, oe und ue, wich looks a little odd in some words.
|
|
06-05-2013 01:31 AM |
|
|
Shidhun
Journeyman
Posts: 59
Likes Given: 5
Likes Received: 3 in 3 posts
Joined: Jul 2012
Reputation: 1
|
RE: Sphere.msgs and Umlaut in general?
@Hustensaft
Um Umlaute darstellen zu können musst Du eine UTF-8-Formatierung benutzen (Code-Tabellen findest Du dafür per google)
der Syntax wäre dann z.b.
sayua <farbcode>,0,0,deu <text>
sysmessageua <farbcode>,0,0,deu <text>
Quote:Bsp: sayua <tag.name.hue>,0,0,deu Du kannst nichts von einem Händler deines anderen Charakters kaufen
In Dialogen müsstest Du HTMLGUMPS verwenden. Nach der Art hier :
Quote:dhtmlgump 205 245 370 30 0 0 <def.center><def.BFONT>color="#444444"><def.big>Der Händler hat nichts zu verkaufen<def.BFONTE><def.centere>
|
|
06-05-2013 03:20 AM |
|
|
Hustensaft
Apprentice
Posts: 24
Likes Given: 0
Likes Received: 0 in 0 posts
Joined: Apr 2013
Reputation: 0
|
RE: Sphere.msgs and Umlaut in general?
Great, works But the SysMessage always shows the old Value of Food, e.g. if a player has 60 Food and eats a Soup (gives +20 Food), the messages ist, that he ist at 60, not at 80. Strange...
@Shidhun
Danke, das würde zumindest Systemmeldungen etwas weniger schwurbelig machen, aber bei Itemnamen oder im Partychat funzt das nicht, da lasse ich lieber überall die Umschreibungen drin, sonst hat man es mal so, mal so, ist ja auch doof
|
|
06-05-2013 04:48 AM |
|
|
darksun84
Sir Spamalot
Posts: 1,687
Likes Given: 245
Likes Received: 162 in 151 posts
Joined: Mar 2012
Reputation: 35
|
RE: Sphere.msgs and Umlaut in general?
(This post was last modified: 06-05-2013 05:46 AM by darksun84.)
|
|
06-05-2013 05:44 AM |
|
|
darksun84
Sir Spamalot
Posts: 1,687
Likes Given: 245
Likes Received: 162 in 151 posts
Joined: Mar 2012
Reputation: 35
|
RE: Sphere.msgs and Umlaut in general?
Yep i think
But, i looked at it better and :
<food> is the old value of food
<argn1> is the new value of food
So you can do a check like this
PHP Code:
ON=@Hunger if <argn1> > <food> sysmessage Your satiation is now at <Food> endif
In this way, the message should appears only if the player eat something, because if argn1 is less than <food> that means the player food level is decreasing .
|
|
06-05-2013 06:59 AM |
|
|
Hustensaft
Apprentice
Posts: 24
Likes Given: 0
Likes Received: 0 in 0 posts
Joined: Apr 2013
Reputation: 0
|
RE: Sphere.msgs and Umlaut in general?
Ah, that's a good idea. I altered my food to use MoreM and
[TYPEDEF t_food]
ON=@Dclick
src.sysmessage Your satiation is now at <eval <Src.Food> + <morem>>
wich works just as i wanted
Edit: but since there are also t_fruit Items that can be eaten, it might be easier, to use darksuns last idea. Should also work with drinks and maybe potions. Again, thanks darksun, you are really a great help for new and/or untalented scripters like me
(This post was last modified: 06-08-2013 11:21 AM by Hustensaft.)
|
|
06-06-2013 05:32 AM |
|
|