The International Simutrans Forum

Development => Scripting Scenarios and AI => Topic started by: Andarix on September 17, 2019, 08:24:51 PM

Title: function object.href
Post by: Andarix on September 17, 2019, 08:24:51 PM
I think the function to create links has an error. Despite the same code, the link is displayed differently.

I assume that it is > before the link. Then a space is inserted before and after the link.


...
switch (this.step) {
case 1:
text.t1 = coordb.href("("+coordb.tostring()+")")
text.t2 = coorda.href("("+coorda.tostring()+")")
text.t3 = coordc.href("("+coordc.tostring()+")")
break
case 2:
text.pos = coordb.href("("+coordb.tostring()+")")
break
....


(https://forum.simutrans.com/index.php?action=dlattach;topic=19246.0;attach=28191)

(https://forum.simutrans.com/index.php?action=dlattach;topic=19246.0;attach=28193)
Title: Re: function object.href
Post by: Andarix on September 18, 2019, 11:13:00 AM
Meanwhile, it works better, though nothing has changed.
Title: Re: function object.href
Post by: Dwachs on September 18, 2019, 05:25:15 PM
This refers to the tutorial scenario?
Title: Re: function object.href
Post by: Andarix on September 18, 2019, 06:06:31 PM
yes

r8803 + latest Scriptfiles from Simutrans-SVN
Title: Re: function object.href
Post by: Andarix on September 18, 2019, 11:23:28 PM
the string [<--] (for Backspace) is not displayed correctly

everything after < until next > is not displayed

red text is not show, the line break not works
QuoteBackspace [<--] Taste.<br/> text
Title: Re: function object.href
Post by: Yona-TYT on September 19, 2019, 03:23:50 AM
Speaking of the "href" function, I found a small mistake long ago.

When used with "coord3d", the coordinates shown are incorect if the map is rotated.