[Ohrrpgce] SVN: teeemcee/9931 Fix two bugs involving textbox 'after' links, one quite nasty.

James Paige Bob at hamsterrepublic.com
Mon Jan 1 21:17:50 PST 2018


I guess I never ran into this bug because I always use the text box
connection browser to add all my new instead/after conditions.

Adding a tool to check for "never" after chains and running it once on
upgrade sounds like a good idea.

On Monday, January 1, 2018, Ralph Versteegen <teeemcee at gmail.com> wrote:

>
>
> On 2 January 2018 at 17:19, Ralph Versteegen <teeemcee at gmail.com> wrote:
>
>>
>>
>> On 2 January 2018 at 03:55, <subversion at hamsterrepublic.com> wrote:
>>
>>> teeemcee
>>> 2018-01-01 06:55:47 -0800 (Mon, 01 Jan 2018)
>>> 953
>>> Fix two bugs involving textbox 'after' links, one quite nasty.
>>>
>>> In the textbox editor, pressing Ctrl+Left/Right to link to another box
>>> appeared
>>> to work but actually the "After" tag condition didn't get set to
>>> "Always",
>>> although it claimed it was. It didn't actually get set to "Always" until
>>> you
>>> entered a submenu. The textbox editor doesn't save when you exit
>>> (instead, its
>>> meant to save when data is edited), so it's possible that what appears
>>> to be the
>>> state of the textbox never makes it to disk.
>>> Reported by Taoki.
>>>
>>> The in-game F1 textbox debug screen also showed "ALWAYS" instead of
>>> "NEVER"
>>> (this only affected the After box/script option; tags aren't shown for
>>> other
>>> conditionals), which made this bug even more confusing.
>>>
>>> The bug was that these lines of code were in the wrong order:
>>>        SaveTextBox box, st.id
>>>        update_textbox_editor_main_menu box, menu()
>>> but to make this less confusing I instead split out
>>> "textbox_set_after_textbox"
>>> ---
>>> U   wip/game.bas
>>> U   wip/textboxedit.bas
>>> U   wip/whatsnew.txt
>>>
>>
>> Note that this bug is a lot like a data corruption bug: what you see in
>> the textbox editor isn't what actually happens in-game, so unless you
>> actually tested your textbox chains, you wouldn't know whether they're
>> broken. Entering any submenu fixed the problem. They're still broken, but
>> at least now you can see it. You would have to look through all your
>> textboxs to be certain you're not affected.
>>
>> So it might be a good idea to scan the game for After chains with a Never
>> condition and warn people about them. This only has to happen once, so
>> could be done in upgrade() and controlled by a fixbit.
>> But, that's a lot of trouble, and it's unlikely to be affected by it...
>>
> *people are unlikely to be affected
>
>>
>> Also, there was another bug I didn't mention: if you intentionally set an
>> After chain with a Never condition, it would get turned into an Always
>> condition when you exited the conditional editor (and actually saved that
>> way).
>>
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.motherhamster.org/pipermail/ohrrpgce-motherhamster.org/attachments/20180101/68657417/attachment.html>


More information about the Ohrrpgce mailing list