Config
Log for #openttd.dev on 8th June 2014:
Times are UTC Toggle Colours
09:25:32  *** frosch123 has joined #openttd.dev
09:25:32  *** ChanServ sets mode: +v frosch123
09:58:22  *** Alberth has joined #openttd.dev
09:58:22  *** ChanServ sets mode: +v Alberth
11:33:09  *** Supercheese has quit IRC
11:33:43  *** Supercheese has joined #openttd.dev
11:33:43  *** ChanServ sets mode: +v Supercheese
12:12:03  *** Godde has quit IRC
12:46:47  <frosch123> meh
12:47:02  <frosch123> turns out game scripts have wide spread incorrect usage of STRING command
12:47:09  <frosch123> break them all?
12:47:42  <Alberth> is some sort of grace period possible?
12:47:49  <frosch123> otherwise i beleive they can just randomly crash like fs#6037 for random languages
12:48:20  <frosch123> problem is that the STRING command is supposed to mean STRING0, i.e. with no sub parameter
12:48:37  <frosch123> but in many cases it is uses at the end of the string as "take any amount of parameters"
12:48:51  <Alberth> joy :)
12:49:00  <frosch123> which works because for some reasno the range check is commented out in ottd for 8 years in that place or something
12:50:02  <Alberth> the script crashes, or openttd?
12:50:09  <frosch123> ottd :)
12:50:18  <frosch123> like fs#6037
12:50:52  <frosch123> currently scripts do not support genders or cases, so it may be hard to construct an actual case
12:51:02  <frosch123> but the fundamental problem persists
12:52:59  <Alberth> This morning I looked at the eints docs for scripts as linked from http://www.tt-forums.net/viewtopic.php?p=1122370#p1122370
12:53:09  <frosch123> alternatively we could define the STRING command as "take any amount" if at the end of a string :p
12:54:28  <Alberth> you really need to dig to get the commands for scripts. Even then, http://bundles.openttdcoop.org/eints/nightlies/LATEST/docs/string_commands.html#pos-gamescript-string-commands  isn't exactly clear what commands actually do
12:55:22  <frosch123> we can also add a new command {STRING0} :)
12:55:47  <frosch123> and allow {STRING} only at the end or something
12:56:17  <Alberth> give a deprecated warning, and remove at 1.5 ?
12:57:27  <frosch123> somehow we did the same mistake with script lang files as ttdp did with newgrf :p
12:57:49  <frosch123> expose internals and then get screwed with stuff being abused and having to keep compatibilty
12:58:27  <Alberth> the main question is perhaps mostly when to drop support
12:59:19  <Alberth> at least, "whether to drop support" seems best to get a "yes" answer, in the long run
13:01:25  <Alberth> there is a simple solution around {STRING}  in the form of {STRINGx}, that would need to be communicated to script devs
13:01:56  * Alberth cares very little about backward compability
13:03:16  <Alberth> it would be nice if we could have some sort of grace period to make script devs aware of the problem
13:04:14  <Alberth> in software would be ideal, or by post in the forum
13:04:50  <Alberth> then after some time, just break old things, imho
13:18:02  <frosch123> well, we have an api version, so it would actually be possible to convert the lang files on load
13:18:59  <frosch123> i am just not sure about what should be the final lang format
13:19:12  <frosch123> remove STRING, add STRING0 and maybe STRINGx
13:19:13  <frosch123> ?
13:19:34  <frosch123> where STRINGx is only allowed at the end of strings
13:19:47  <frosch123> and may be used for weird things like STR_JUST_STRING or STR_BLACK_STRING
13:20:24  <frosch123> in my working copy i added STR_JUST_STRING2 and STR_BLACK_STRING2 and stuff :p
13:23:24  <frosch123> it would also mean that STRING0..STRING7,STRINGx,RAW_STRING are only valid in base language
13:23:31  <frosch123> and STRING would only be valid in translations
13:23:44  <frosch123> that would remove some ambigouty about STRING
13:24:01  <Alberth> sounds useful
13:25:05  <frosch123> well, rb's translation backport script will love it :p
13:26:15  <frosch123> hmm, actually, it would only affect 138 strings
13:26:33  <Alberth> at least one happy user :p
13:26:36  <frosch123> 3%
13:26:54  <frosch123> Alberth: i rather fear him shooting at me :p
13:27:09  <frosch123> having to back-covert strings and such :)
13:27:17  <Alberth> you downloaded all bananas scipts?
13:27:32  <frosch123> no, i mean ottd's lang files
13:27:45  <frosch123> 138 ottd string use {STRING}
13:27:59  <frosch123> which would change in english.txt to STRING0 or STRINGx
13:33:33  <Alberth> hmm, somewhere we switched from scripts to native ottd strings :)
13:36:04  <frosch123> the same issue applies to ottd :)
13:36:15  <frosch123> i fixed those by fixing all string, but then notices that gs have the same issue
13:36:28  <Alberth> ah, ok :)
13:36:31  <frosch123> and keeping them in sync is my preference anyway
13:36:59  <Alberth> yeah, that's useful to prevent us from getting crazy
13:37:30  <frosch123> http://paste.openttdcoop.org/show/3414/ <- i just cannot do that on-the-fly for all gs :p
13:40:19  <frosch123> STR_JUST_STRINGN is used for the caption of the query window btw.
13:40:29  <frosch123> it is passed an unspecified amount of parameters
13:40:56  <frosch123> so, there is in fact some need for STRINGx in some case
15:49:55  *** DorpsGek changes topic to "OpenTTD Dev Channel || Latest SVN: r26634 || Logs: http://webster.openttdcoop.org/?channel=openttd.dev || Voice (talk-right) upon request via #openttd; make sure you are registered to NickServ before asking"
17:45:10  *** DorpsGek changes topic to "OpenTTD Dev Channel || Latest SVN: r26635 || Logs: http://webster.openttdcoop.org/?channel=openttd.dev || Voice (talk-right) upon request via #openttd; make sure you are registered to NickServ before asking"
20:38:01  *** frosch123 has quit IRC
21:03:48  *** Alberth has left #openttd.dev

Powered by YARRSTE version: svn-trunk