Config
Log for #openttd.dev on 16th November 2013:
Times are UTC Toggle Colours
01:18:50  *** LordAro has quit IRC
02:09:58  *** zydeco has quit IRC
05:50:21  *** adf88 has joined #openttd.dev
05:50:21  *** ChanServ sets mode: +v adf88
08:37:52  <Rubidium> http://rbijker.net/openttd/fs5804.diff & http://rbijker.net/openttd/fs5804-extra.diff (try to prevent some other crashes with data from game scripts)
08:54:04  *** LordAro has joined #openttd.dev
08:54:04  *** ChanServ sets mode: +v LordAro
09:15:32  *** adf88 has quit IRC
09:17:04  *** Alberth has joined #openttd.dev
09:17:04  *** ChanServ sets mode: +v Alberth
09:29:14  *** adf88 has joined #openttd.dev
09:29:14  *** ChanServ sets mode: +v adf88
09:49:15  *** DorpsGek changes topic to "OpenTTD Dev Channel || Latest SVN: r26006 || Logs: http://webster.openttdcoop.org/?channel=openttd.dev || Voice (talk-right) upon request via #openttd; make sure you are registered to NickServ before asking"
09:54:23  *** DorpsGek changes topic to "OpenTTD Dev Channel || Latest SVN: r26007 || Logs: http://webster.openttdcoop.org/?channel=openttd.dev || Voice (talk-right) upon request via #openttd; make sure you are registered to NickServ before asking"
10:04:11  *** DorpsGek changes topic to "OpenTTD Dev Channel || Latest SVN: r26008 || Logs: http://webster.openttdcoop.org/?channel=openttd.dev || Voice (talk-right) upon request via #openttd; make sure you are registered to NickServ before asking"
10:05:58  *** DorpsGek changes topic to "OpenTTD Dev Channel || Latest SVN: r26009 || Logs: http://webster.openttdcoop.org/?channel=openttd.dev || Voice (talk-right) upon request via #openttd; make sure you are registered to NickServ before asking"
10:25:14  *** adf88 has quit IRC
10:42:20  *** Zuu has joined #openttd.dev
10:42:20  *** ChanServ sets mode: +v Zuu
11:21:18  *** JGR_ has left #openttd.dev
11:21:51  *** JGR has joined #openttd.dev
12:03:50  *** zydeco has joined #openttd.dev
12:24:31  *** zydeco has quit IRC
12:32:15  *** Supercheese has quit IRC
12:32:47  *** Supercheese has joined #openttd.dev
12:33:46  *** DorpsGek changes topic to "OpenTTD Dev Channel || Latest SVN: r26010 || Logs: http://webster.openttdcoop.org/?channel=openttd.dev || Voice (talk-right) upon request via #openttd; make sure you are registered to NickServ before asking"
12:58:17  <Zuu> This patch adds a new goal type: GT_STORY_PAGE. When you click on a such goal, a referenced story page will be opened: https://bugs.openttd.org/task/5761/getfile/9469/5761.patch
12:58:22  <Zuu> FS task: https://bugs.openttd.org/task/5761
12:59:38  *** frosch123 has joined #openttd.dev
12:59:38  *** ChanServ sets mode: +v frosch123
13:16:39  *** DorpsGek changes topic to "OpenTTD Dev Channel || Latest SVN: r26011 || Logs: http://webster.openttdcoop.org/?channel=openttd.dev || Voice (talk-right) upon request via #openttd; make sure you are registered to NickServ before asking"
14:20:42  <Alberth> why do you add parentheses around an equality condition?
14:21:07  <frosch123> +			(type == GT_STORY_PAGE && story_page != NULL && story_page->company == INVALID_COMPANY ? c == INVALID_COMPANY : (c == INVALID_COMPANY || c == story_page->company))); <- the ? : has lowest precendence
14:21:40  <frosch123> so you need ( ) around the story_page->company == INVALID_COMPANY ? ... : ...
14:22:25  <Alberth> oh there are && hidden in them
14:22:37  <frosch123> but the precondition is somewhat confusing to me
14:22:50  <Alberth> make it a switch?
14:24:05  <frosch123> the check in the command handler and gui in understand
14:24:21  <frosch123> but i do not get what EnforcePrecondition and the @pre try to say
14:24:50  <Alberth> not sure you should call it a goal. It looks more like a hyperlink
15:05:21  <Zuu> Alberth: Many GS authors abuse thet goal window to display lines of text instead of making each line correspond to a goal.
15:05:54  <Zuu> If you would use GT_STORY_BOOK, I guess the goal text would need some text indicatding that you can click on it for more info.
15:06:16  <Alberth> I am fine with the idea itself
15:06:35  <Alberth> it's just not a "goal", something that you can achieve, imho
15:06:50  <Alberth> unless "click at it" counts as an achievement :p
15:07:10  <Zuu> Oh, and the check goal_gui.cpp needs updating too to use the same condition as in the precondition.
15:07:54  <Alberth> so if you name it "link" instead of "goal" it may reduce confusion of what it is
15:09:24  <Zuu> Where is it named "goal"?
15:09:48  <Alberth>  Zuu: This patch adds a new goal type: GT_STORY_PAGE.  <-- there?  :)
15:10:17  <Zuu> Yes, as each line in the goal window is a goal type.
15:11:03  <Zuu> Or do you suggest that the type GT_STORY_PAGE is not exposed via the API and we use a specialized API to create this link which internally is a GT_STORY_PAGE, but in the API use eg GSGoal::NewLink?
15:11:27  <Alberth> nah, sounds too complicated
15:11:39  <Zuu> (and add complexity such that a link can not have a progress / be completed ... )
15:12:08  <Zuu> I agree that it become too complicated. So I then wonder how to make the link not a goal?
15:12:34  <frosch123> referenceing a story page like you reference a town or tile sounds fine to me
15:12:36  <Alberth> technically it can be a goal, it's just naming things
15:13:00  <frosch123> Zuu: what is the idea of the precondition?
15:13:05  <frosch123> i did not understand it
15:13:22  <Zuu> frosch123: To ensure that when type is GT_TOWN, the referenced town is valid etc.
15:13:34  <frosch123> goals referencing pages of same company makes sense
15:13:44  <frosch123> global goals referening global pages makes sense
15:14:00  <Zuu> and company goals refering to global pages
15:14:05  <frosch123> but you seem to have added some ogther combinations
15:14:19  <Zuu> Yep, that is commented in the FS task
15:14:28  <frosch123> i think the @pre are wordeed to complicated (and inconsisten "==" vs "is")
15:15:27  <frosch123> so, it is "company pages can be referenced by company goals", "global pages can be referenced by either company or global goals"
15:15:30  <Zuu> The problem I had on hand is that this pre condition cannot be expressed with API calls. Because there is no API to get the owner of a story page.
15:15:47  <Zuu> So I had to fall back to a pre condition using english wordings instead.
15:16:39  <frosch123> i would put it in a single @pre, can make it complete english
15:16:47  <frosch123> s/can/and/
15:16:53  <Zuu> frosch123: Yes like that (and if both are for a company, they have to be for the same company)
15:17:02  <frosch123> maybe a \li with the 3 options
15:18:53  <Zuu> While you could in theory allow referencing story pages of other companies and open the story book of that company if that goal is clicked, I think we can block these cross references.
15:19:56  <Zuu> Though, if those cross references are allowed, the @pre will become simplier.
15:21:48  <frosch123> nah, not allowing them is fine
15:21:54  <frosch123> it just needs rewording
15:24:09  <frosch123> http://paste.openttdcoop.org/show/2808/ <- something like that?
15:25:15  <Alberth> s/or/and/ at the last line, I think
15:25:34  *** adf88 has joined #openttd.dev
15:25:35  *** ChanServ sets mode: +v adf88
15:25:41  <frosch123> and no "," maybe :)
15:26:25  <Alberth> no idea :)
15:43:49  *** adf88 has quit IRC
16:00:09  <Zuu> http://devs.openttd.org/~zuu/5761.patch <--- updated patch (updated @pre doc and updated checks in goal_gui.cpp and goal.cpp to apply thet same owner rules and in the API pre condition check.
16:03:05  <frosch123> the first @pre looks redundant to the second
16:04:42  <frosch123> the EnforcePrecondition switches page and goal companies, doesn'T it?
16:05:04  <Zuu> indeed forgot to remove the old @pre
16:05:45  <Alberth> if (company == INVALID_COMPANY ? story_company != INVALID_COMPANY : company != INVALID_COMPANY && company != story_company) return CMD_ERROR;   <-- please add some parentheses, ?: and && at the same level is confusing
16:05:55  <frosch123> it allows global goals to reference company pages, and not the other way around
16:07:07  <frosch123> the command check, uses company instead of story_company in the : part
16:07:51  <Alberth> if (story_company == INVALID_COMPANY || (company != INVALID_COMPANY && company == story_company) break \n return CMD_ERROR;   like this ?
16:08:00  <frosch123> +				uint8 goal_company = this->window_number; <- use CompanyId instead of uint8? and also use it to pass it to ShowStoryBook?
16:08:06  <Zuu> yes, the goal <-> story has been mixed up :-s
16:11:14  <Zuu> I've updated the patch now so that it checks if the goal is global and then checks the story company.
16:11:24  <Zuu> (and not the other way around)
16:12:56  <frosch123> +				ShowStoryBook(goal_company, s->dst); <- story_company ?
16:13:30  <frosch123> hmm, no
16:13:47  <frosch123> maybw the window_number was better :p
16:15:55  <Zuu> hmm actually, using goal_company = this->window_number is wrong
16:16:03  <Zuu> It will fail on global goals
16:17:01  <Zuu> and using this->window_number is probably best. As there is no goal window corresponidng to INVALID_COMPANY
16:17:51  <frosch123> spectactors cannot see any goals unless there is a company?
16:20:50  <Zuu> That does seems to be correct.
16:21:29  <Zuu> In 1.3 and older it was available for spectators.
16:21:55  <frosch123> well, fine enough :)
16:22:50  <Zuu> I'm not sure why I made it like that, but think there has been some discussion/conclusion/reason for that.
16:23:22  <Zuu> (assuming I am the one to blame)
16:24:59  <Zuu> But it is a bit silly that now spectators cannot see any informaiton from the GS.
16:25:16  <Zuu> (if there is no company)
16:25:51  <frosch123> one could add a dummy entry "global gaols" which is only displayed for obsevers if there is no company
16:25:58  <frosch123> or something like that
16:26:18  <frosch123> similiar how the "company" menu has entries for "join specatators" or "new company"
16:35:27  <Zuu> I've updated the patch with respect to where to use window_number. I've now also complemented my test to do a full test where all 4 combinations of global+company owner which gives the predicted results.
16:39:23  <frosch123> looks nice :)
17:41:58  *** DorpsGek changes topic to "OpenTTD Dev Channel || Latest SVN: r26012 || 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:52:02  *** DorpsGek changes topic to "OpenTTD Dev Channel || Latest SVN: r26013 || Logs: http://webster.openttdcoop.org/?channel=openttd.dev || Voice (talk-right) upon request via #openttd; make sure you are registered to NickServ before asking"
18:28:47  *** Zuu_ has joined #openttd.dev
18:35:32  *** Zuu has quit IRC
18:45:44  *** DorpsGek changes topic to "OpenTTD Dev Channel || Latest SVN: r26014 || Logs: http://webster.openttdcoop.org/?channel=openttd.dev || Voice (talk-right) upon request via #openttd; make sure you are registered to NickServ before asking"
19:04:02  *** Zuu_ has quit IRC
19:04:39  *** Zuu has joined #openttd.dev
19:04:39  *** ChanServ sets mode: +v Zuu
19:46:51  <Zuu> <frosch123> spectactors cannot see any goals unless there is a company? <--- Actually, I was wrong. As long as there exist at least one global goal, spectators can view the global goal window.
19:47:09  <frosch123> ok :)
19:47:10  <Zuu> Same goes for the global story book.
19:47:45  <Zuu> Actually it is enough that there exsist a non-global goal/story page, but those cannot exist without a company so that implies that they are global if they exist. :-)
19:48:26  <Zuu> In my earlier test, I just was using a GS that (at that time) did not create any global goals/pages.
19:59:08  *** DorpsGek changes topic to "OpenTTD Dev Channel || Latest SVN: r26015 || 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:05:12  <planetmaker> is my quick scanning of the backlog right? This allows goals to reference story book pages?
20:15:48  <frosch123> yes
20:16:53  <planetmaker> sounds nice :-)
20:32:56  *** DorpsGek changes topic to "OpenTTD Dev Channel || Latest SVN: r26016 || 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:34:18  <Zuu> yes
20:36:12  <Zuu> I was shortly thinking about making a quick "read more" button for the town window that could refer to a story page. However, I'm not sure this is the right solution.
20:37:32  <Zuu> For the case when all towns may refer to the same story page, that make sense. But perhaps not for those who want to display more than 20 parameters in the town window.
20:38:08  <frosch123> some time ago i looked again into the hyperlinks
20:38:16  <Zuu> Eg. having one story page for each town in the story page window may not be desirable. Thus those pages should perhaps to be hidden there and only visible from a button in the town window.
20:38:26  <frosch123> i think with the new layouter and visualrun stuff, hyperlinks are easier to do than before
20:38:41  <Zuu> aka click-on-string?
20:38:53  <frosch123> yeah
20:39:22  <frosch123> basically you can split the text at arbitary points into visual runs, and later get the bounds for them
20:40:04  <Zuu> Even if the visual bound get split over a soft line break?
20:40:20  <frosch123> you get multiple visual runs then
20:40:33  <Zuu> ok
20:40:41  <frosch123> a visual run is separated by linebreaks, colour/font changes, and ltr/rtl changes
20:40:45  <Zuu> That should works fine
20:41:03  <frosch123> hyperlinks are basically a different font, which looks the same
20:41:09  <Zuu> You could just iterate over them all and check against cursor location.
20:57:55  *** DorpsGek changes topic to "OpenTTD Dev Channel || Latest SVN: r26017 || Logs: http://webster.openttdcoop.org/?channel=openttd.dev || Voice (talk-right) upon request via #openttd; make sure you are registered to NickServ before asking"
21:05:27  *** DorpsGek changes topic to "OpenTTD Dev Channel || Latest SVN: r26018 || Logs: http://webster.openttdcoop.org/?channel=openttd.dev || Voice (talk-right) upon request via #openttd; make sure you are registered to NickServ before asking"
21:49:30  *** Alberth has left #openttd.dev
22:06:49  *** zydeco has joined #openttd.dev
22:17:04  *** DorpsGek changes topic to "OpenTTD Dev Channel || Latest SVN: r26019 || Logs: http://webster.openttdcoop.org/?channel=openttd.dev || Voice (talk-right) upon request via #openttd; make sure you are registered to NickServ before asking"
23:15:30  *** zydeco has quit IRC
23:24:23  *** planetmaker has quit IRC
23:24:23  *** Terkhen has quit IRC
23:24:23  *** Hirundo has quit IRC
23:24:23  *** TheIJ has quit IRC
23:24:23  *** orudge has quit IRC
23:24:23  *** Zuu has quit IRC
23:24:23  *** frosch123 has quit IRC
23:24:23  *** JGR has quit IRC
23:24:23  *** Rubidium has quit IRC
23:24:23  *** juzza1 has quit IRC
23:24:23  *** michi_cc has quit IRC
23:24:23  *** dihedral has quit IRC
23:24:23  *** DorpsGek has quit IRC
23:24:23  *** Yexo has quit IRC
23:24:23  *** peter1138 has quit IRC
23:32:24  *** Zuu has joined #openttd.dev
23:32:24  *** frosch123 has joined #openttd.dev
23:32:24  *** JGR has joined #openttd.dev
23:32:24  *** peter1138 has joined #openttd.dev
23:32:24  *** planetmaker has joined #openttd.dev
23:32:24  *** reticulum.oftc.net sets mode: +vvvv Zuu frosch123 peter1138 planetmaker
23:32:24  *** Yexo has joined #openttd.dev
23:32:24  *** Terkhen has joined #openttd.dev
23:32:24  *** Hirundo has joined #openttd.dev
23:32:24  *** dihedral has joined #openttd.dev
23:32:24  *** michi_cc has joined #openttd.dev
23:32:24  *** juzza1 has joined #openttd.dev
23:32:24  *** Rubidium has joined #openttd.dev
23:32:24  *** DorpsGek has joined #openttd.dev
23:32:24  *** reticulum.oftc.net sets mode: +vvvo Terkhen michi_cc Rubidium DorpsGek
23:32:24  *** orudge has joined #openttd.dev
23:32:24  *** TheIJ has joined #openttd.dev
23:32:24  *** reticulum.oftc.net sets mode: +vv DorpsGek orudge
23:32:26  *** TheIJ has quit IRC
23:32:26  *** Hirundo has quit IRC
23:32:26  *** orudge has quit IRC
23:32:26  *** Terkhen has quit IRC
23:32:26  *** planetmaker has quit IRC
23:32:26  *** Rubidium has quit IRC
23:32:26  *** juzza1 has quit IRC
23:32:26  *** michi_cc has quit IRC
23:32:26  *** JGR has quit IRC
23:32:26  *** frosch123 has quit IRC
23:32:26  *** dihedral has quit IRC
23:32:26  *** DorpsGek has quit IRC
23:32:26  *** Zuu has quit IRC
23:32:26  *** peter1138 has quit IRC
23:32:26  *** Yexo has quit IRC
23:32:26  *** Supercheese has quit IRC
23:32:26  *** tycoondemon has quit IRC
23:32:26  *** fonsinchen has quit IRC
23:32:26  *** Belugas has quit IRC
23:33:25  *** TheIJ has joined #openttd.dev
23:33:25  *** orudge has joined #openttd.dev
23:33:25  *** DorpsGek has joined #openttd.dev
23:33:25  *** Rubidium has joined #openttd.dev
23:33:25  *** resistance.oftc.net sets mode: +vovv orudge DorpsGek DorpsGek Rubidium
23:33:25  *** juzza1 has joined #openttd.dev
23:33:25  *** michi_cc has joined #openttd.dev
23:33:25  *** dihedral has joined #openttd.dev
23:33:25  *** Hirundo has joined #openttd.dev
23:33:25  *** Terkhen has joined #openttd.dev
23:33:25  *** Yexo has joined #openttd.dev
23:33:25  *** planetmaker has joined #openttd.dev
23:33:25  *** peter1138 has joined #openttd.dev
23:33:25  *** resistance.oftc.net sets mode: +vvvv michi_cc Terkhen planetmaker peter1138
23:33:25  *** JGR has joined #openttd.dev
23:33:25  *** frosch123 has joined #openttd.dev
23:33:25  *** Zuu has joined #openttd.dev
23:33:25  *** Supercheese has joined #openttd.dev
23:33:25  *** tycoondemon has joined #openttd.dev
23:33:25  *** Belugas has joined #openttd.dev
23:33:25  *** fonsinchen has joined #openttd.dev
23:33:25  *** resistance.oftc.net sets mode: +vvvv frosch123 Zuu Belugas fonsinchen

Powered by YARRSTE version: svn-trunk