Author Topic: New Error/Bug?  (Read 2062 times)

0 Members and 1 Guest are viewing this topic.

Offline mjn.mixael

  • Cutscene Master
  • 212
  • Chopped liver
    • Steam
    • Twitter
One of BtA's missions has the event "Is "Beta close" true?". As far as I know this was handled gracefully in 3.7.4.

3.8RC1 Errors and closes FSO. If this is an intentional change, sounds good. Might be worth pointing out the reason is probably because of the double quotes in the error and/or disallowing double quotes in event names.

However, it seems like a bug because FRED/FSO only started complaining about this after I used that event in a Departure Cue.

Upon further investigation.. it looks like the problem is more that FRED saved the following event..

Code: [Select]
is-event-true-delay
"is "beta close" true?"
7

as

Code: [Select]
is-event-true-delay
"is "
beta
close"
true?"
7
Cutscene Upgrade Project - Mainhall Remakes - Between the Ashes
Youtube Channel - P3D Model Box
Between the Ashes is looking for committed testers, PM me for details.
Freespace Upgrade Project See what's happening.

 

Offline AdmiralRalwood

  • 211
  • The Cthulhu programmer himself!
    • Skype
    • Steam
    • Twitter
I'm surprised it worked in 3.7.4; I don't recall the parser changing in any significant way since 3.7.4, either. If you edit it with notepad, does FSO read it properly? If so, this could be a mission saving error.
Ph'nglui mglw'nafh Codethulhu GitHub wgah'nagl fhtagn.

schrödinbug (noun) - a bug that manifests itself in running software after a programmer notices that the code should never have worked in the first place.

When you gaze long into BMPMAN, BMPMAN also gazes into you.

"I am one of the best FREDders on Earth" -General Battuta

<Aesaar> literary criticism is vladimir putin

<MageKing17> "There's probably a reason the code is the way it is" is a very dangerous line of thought. :P
<MageKing17> Because the "reason" often turns out to be "nobody noticed it was wrong".
(the very next day)
<MageKing17> this ****ing code did it to me again
<MageKing17> "That doesn't really make sense to me, but I'll assume it was being done for a reason."
<MageKing17> **** ME
<MageKing17> THE REASON IS PEOPLE ARE STUPID
<MageKing17> ESPECIALLY ME

<MageKing17> God damn, I do not understand how this is breaking.
<MageKing17> Everything points to "this should work fine", and yet it's clearly not working.
<MjnMixael> 2 hours later... "God damn, how did this ever work at all?!"
(...)
<MageKing17> so
<MageKing17> more than two hours
<MageKing17> but once again we have reached the inevitable conclusion
<MageKing17> How did this code ever work in the first place!?

<@The_E> Welcome to OpenGL, where standards compliance is optional, and error reporting inconsistent

<MageKing17> It was all working perfectly until I actually tried it on an actual mission.

<IronWorks> I am useful for FSO stuff again. This is a red-letter day!
* z64555 erases "Thursday" and rewrites it in red ink

<MageKing17> TIL the entire homing code is held up by shoestrings and duct tape, basically.

 

Offline mjn.mixael

  • Cutscene Master
  • 212
  • Chopped liver
    • Steam
    • Twitter
Yes, FSO reads it properly. I'm guessing it is, indeed, a saving error.
Cutscene Upgrade Project - Mainhall Remakes - Between the Ashes
Youtube Channel - P3D Model Box
Between the Ashes is looking for committed testers, PM me for details.
Freespace Upgrade Project See what's happening.

 

Offline The E

  • He's Ebeneezer Goode
  • Moderator
  • 213
  • Nothing personal, just tech support.
    • Steam
    • Twitter
Okay, small question, how did you even create an event with that name? Did you use notepad to write that mission?

(Because "Is "Beta close" true?" cannot be entered in the event editor; If you try, FRED will change the event name to "Is $quoteBeta close$quote true?", at least in 3.8 and 3.7.4)

EDIT: Yep, confirmed. If I manually alter the mission file so that the $quote is replaced by ", I get errors.

I'm gonna classify this as working as intended. Double quotes are invalid characters in user-defined text in mission files (since stray ones confuse our parser), and erroring out is the correct response.
« Last Edit: May 06, 2017, 03:26:09 am by The E »
If I'm just aching this can't go on
I came from chasing dreams to feel alone
There must be changes, miss to feel strong
I really need lifе to touch me
--Evergrey, Where August Mourns

 

Offline mjn.mixael

  • Cutscene Master
  • 212
  • Chopped liver
    • Steam
    • Twitter
Well that could be it.... A very specific case. This mission was created near 4-5 years ago (before that check?). That event has always worked and with all the bug testing over the years the event name never got changed by FRED.

I opened the mission on 3.8 to make it ever so slightly easier and need wings to depart when that event triggers... So perhaps that event name has been grandfathered in for so long and that's how I just now ran into problems?
Cutscene Upgrade Project - Mainhall Remakes - Between the Ashes
Youtube Channel - P3D Model Box
Between the Ashes is looking for committed testers, PM me for details.
Freespace Upgrade Project See what's happening.

 

Offline The E

  • He's Ebeneezer Goode
  • Moderator
  • 213
  • Nothing personal, just tech support.
    • Steam
    • Twitter
Well that could be it.... A very specific case. This mission was created near 4-5 years ago (before that check?). That event has always worked and with all the bug testing over the years the event name never got changed by FRED.

I opened the mission on 3.8 to make it ever so slightly easier and need wings to depart when that event triggers... So perhaps that event name has been grandfathered in for so long and that's how I just now ran into problems?

Could be. I am not entirely sure how this could have worked at any point in time (seriously, the humble double quote is an enormously problematic character), but it's likely that some change we made to make the parser more robust messed this up for you.
If I'm just aching this can't go on
I came from chasing dreams to feel alone
There must be changes, miss to feel strong
I really need lifе to touch me
--Evergrey, Where August Mourns

 

Offline mjn.mixael

  • Cutscene Master
  • 212
  • Chopped liver
    • Steam
    • Twitter
Well I'm all for that. :)

And I'm throwing TBP Slasher under the bus... he's the one who created this particular mission.

I'm innocent, I swear!
Cutscene Upgrade Project - Mainhall Remakes - Between the Ashes
Youtube Channel - P3D Model Box
Between the Ashes is looking for committed testers, PM me for details.
Freespace Upgrade Project See what's happening.

 

Offline AdmiralRalwood

  • 211
  • The Cthulhu programmer himself!
    • Skype
    • Steam
    • Twitter
it's likely that some change we made to make the parser more robust messed this up for you.
...Or it would be, if the parser didn't still handle it; it seems like the mission-saving code that is doing something different.
Ph'nglui mglw'nafh Codethulhu GitHub wgah'nagl fhtagn.

schrödinbug (noun) - a bug that manifests itself in running software after a programmer notices that the code should never have worked in the first place.

When you gaze long into BMPMAN, BMPMAN also gazes into you.

"I am one of the best FREDders on Earth" -General Battuta

<Aesaar> literary criticism is vladimir putin

<MageKing17> "There's probably a reason the code is the way it is" is a very dangerous line of thought. :P
<MageKing17> Because the "reason" often turns out to be "nobody noticed it was wrong".
(the very next day)
<MageKing17> this ****ing code did it to me again
<MageKing17> "That doesn't really make sense to me, but I'll assume it was being done for a reason."
<MageKing17> **** ME
<MageKing17> THE REASON IS PEOPLE ARE STUPID
<MageKing17> ESPECIALLY ME

<MageKing17> God damn, I do not understand how this is breaking.
<MageKing17> Everything points to "this should work fine", and yet it's clearly not working.
<MjnMixael> 2 hours later... "God damn, how did this ever work at all?!"
(...)
<MageKing17> so
<MageKing17> more than two hours
<MageKing17> but once again we have reached the inevitable conclusion
<MageKing17> How did this code ever work in the first place!?

<@The_E> Welcome to OpenGL, where standards compliance is optional, and error reporting inconsistent

<MageKing17> It was all working perfectly until I actually tried it on an actual mission.

<IronWorks> I am useful for FSO stuff again. This is a red-letter day!
* z64555 erases "Thursday" and rewrites it in red ink

<MageKing17> TIL the entire homing code is held up by shoestrings and duct tape, basically.

 

Offline The E

  • He's Ebeneezer Goode
  • Moderator
  • 213
  • Nothing personal, just tech support.
    • Steam
    • Twitter
it's likely that some change we made to make the parser more robust messed this up for you.
...Or it would be, if the parser didn't still handle it; it seems like the mission-saving code that is doing something different.

Then something is weird. The FRED parser straight up refuses to load the mission (since it sees too many arguments for is-event-true-delay), and the same should be true of FSO, shouldn't it?
If I'm just aching this can't go on
I came from chasing dreams to feel alone
There must be changes, miss to feel strong
I really need lifе to touch me
--Evergrey, Where August Mourns