Jump to content

End mission button not working


BuzzLine
Go to solution Solved by BuzzLine,

Recommended Posts

For some reason the old End Mission thread was locked but the code is *still* brittle and unsatisfactory. So the previously reported "End Mission" bugs may still occurr. 🙄

 

If that's the case, here's my additional fix rebased on top of latest open beta 2.7.4.9632 of July 21st (attached).

 

The original discussion can be found here

Hope this helps and may your missions always find an end.
Buzz

me_logbook.lua

  • Thanks 1
Link to comment
Share on other sites

Hey BuzzLine. A fix was published some weeks ago, but I assume it didn't work for you. Can you please give me an example of short missions triggering this bug? I need to reproduce it in order to report it.

Does it only happen in a campaign?

Don't accept indie game testing requests from friends in Discord. Ever.

Link to comment
Share on other sites

On 7/23/2021 at 12:29 AM, Flappie said:

Hey BuzzLine. A fix was published some weeks ago, but I assume it didn't work for you. Can you please give me an example of short missions triggering this bug? I need to reproduce it in order to report it.

Does it only happen in a campaign?

Hi Flappie, thanks for the quick answer.

I only play with my additional bug protection so I don't know if the original issue is present. And I'm not super keen on flying 1h or 2h campaign mission just to check it.

Also, maybe someone has fixed the issue (an undefined id  for statics, I guess) but based on ED's track record, there is *no* guarantee of this issue not reappearing. 

Finally: the current ED code that I touched makes no sense. The "if" I move is either always true or is never reached because it will have crashed three lines earlier. It's like an airbag with a 5s deployment delay ! By the time it triggers, you have already crashed. 

So I moved that "if" three lines earlier and now it provides additional defense-in-depth should there ever be a target with Nil id. If the ED fix is good and persists in time, good. If not, I have my safety net and I won't stupidly lose two hours of my time and not progress in a campaign.

 

TLDR : my patch is here, feel free to use it. I hope it's never useful (like an airbag) but anyone who wants it feel free to use it.  I do recommend having a dev actually look at the code, do a facepalm and chuckle and move that "if" three lines above. Or remove it altogether. It's really silly where it stands:

 

 

 

  • Like 2
Link to comment
Share on other sites

  • 4 weeks later...

I'm playing with the latest Open Beta. 'End Mission' button doesn't work. I can only leave to game's main menu, without any progress for the campaign. This has happened 3 times in a row in the same mission. Restarting DCS didn't help. Repairing installation didn't help too.


Edited by Nipil
Link to comment
Share on other sites

  • 4 weeks later...

Hey everyone ! Buzz here, from (apparently) ED's pro bono dev team.  

 

Attached below is the now usual rebase of my fix on latest openbeta (2.7.6.12852). The same change, as always, around line 1122.

Same rationale as before : no idea if the source bug is fixed but the code looks just as brittle as ever so better use my defensive code instead of flying a campaign mission for an hour or two and seeing the End Mission button fail.

 

Enjoy,

Buzz

 

 

me_logbook.lua

  • Like 3
Link to comment
Share on other sites

  • 3 months later...
20 minutes ago, Flappie said:

Thanks, I was wondering. Can you please tell me how to reproduce the bug? Because so far, I cannot.

@BuzzLine Do you have any idea how to properly reproduce the bug?

 

Nope. It happens when a unit is destroyed by the player but is missing a targetMissionId field. Maybe some scenery object ? 🤷‍♂️ For fairly obvious reasons, I fly campaigns with my fix. 🙂

Still, as I said before, it is quite visible that the code is fragile. I don't think we users need to spend hours to produce a track for the devs to fix this bug. Or at least workaround it. Heck, I even provide the fix, free of charge. Just merge the thing.

 

For reference this was my original report with has more detailed logs:

And this is where I explain why the code is silly:

 

 

  • Like 1
Link to comment
Share on other sites

  • ED Team

the fix was applied some weeks ago, if you are still having problems please provide the way to reproduce it. 

your replies are not helpful 

merged threads

smallCATPILOT.PNG.04bbece1b27ff1b2c193b174ec410fc0.PNG

Forum rules - DCS Crashing? Try this first - Cleanup and Repair - Discord BIGNEWY#8703 - Youtube - Patch Status

Windows 11, NVIDIA MSI RTX 3090, Intel® i9-10900K 3.70GHz, 5.30GHz Turbo, Corsair Hydro Series H150i Pro, 64GB DDR @3200, ASUS ROG Strix Z490-F Gaming, HP Reverb G2

Link to comment
Share on other sites

34 minutes ago, BIGNEWY said:

the fix was applied some weeks ago, if you are still having problems please provide the way to reproduce it. 

your replies are not helpful 

merged threads

My fix is not in 2.7.9.18080 so I'm not sure what you are referring to. I suggest asking @JeffreyC for details of his recent issue since he's the one who ran into it. I fly with my fix, that I rebase regularly when the file changes, so I'm immune to the issue. I suggest ED merge my one-liner fix to protect users from the issue until it is fully resolved. 

I guess that the root cause is similar to this : 

 

And you may have better luck asking the MOOSE devs as they apparently know (and had to workaround) issues that also look like they may have a similar cause:

https://github.com/FlightControl-Master/MOOSE/issues/1334

https://github.com/FlightControl-Master/MOOSE/issues/1337

 

  • Like 1
Link to comment
Share on other sites

11 hours ago, BIGNEWY said:

the fix was applied some weeks ago, if you are still having problems please provide the way to reproduce it. 

your replies are not helpful 

merged threads

2.7.9 still has the same problem with not ending missions. The fix on here from BuzzLine is still the only fix for the problem. Had the problem until putting this fix back in and have not had the issue again since. When it shows up is hit and miss usually, but this issue occurs every time with the USAF Weapons School campaign.  Reproducing is simply flying the mission, ending, and clicking End Mission with nothing happening in the results screen as always.

 

  • Like 1
Link to comment
Share on other sites

Glad to hear that, Jeff. Happy to help.

If anyone encounters the issue on a non-payware campaign, let them post the debriefing.log file *and* the .miz file so that we can try to reproduce and pare it down to a simple test case. I've been blasting static buildings for months trying to get a replicable failure but to no avail. (Payware campaigns are encrypted so we can't pop the hood and reduce missions to a simple test case).

Also interesting to see it happens also on NTTR, I had it on Caucasus. So it's not only on one map.

Finally : does the issue happen only on air-to-ground missions or also in pure air-to-air ?

Link to comment
Share on other sites

BTW, since some people are still encountering the issue, here's my fixed file for use with current DCS versions (2.7.9.18080, both stable and openbeta at the moment). It may be the same as the one I uploaded above, I don't remember if there was a recent change to the file.

As usual, drop in DCSWorld\MissionEditor\modules and replace the original file. Fix is on line 1126, the usual stuff.

 

me_logbook.lua

  • Thanks 1
Link to comment
Share on other sites

  • 3 weeks later...
  • 1 month later...
  • 8 months later...
  • 2 weeks later...

I haven’t checked if they updated the file recently. If so then the fix will have been overwritten. Or it can be a new cause. I’ll look at that tonight when I’m home. 

The fix is trivial indeed, just move a null check up two lines. 

If you have encountered the issue despite having this fix then by all means post your dcs.log and debrief.log files here and I’ll try to understand where the new cause is from. 

Link to comment
Share on other sites

  • 2 weeks later...

Let's see... I'm not home so I don't have my DCS installation at hand but just looking at the logs and the line where the nullref occurs (1128), it does look like my old friend.
Grab my fix, it should solve your issue.

2023-01-14 20:32:22.131 ALERT   LUACOMMON (Main): Error: GUI Error: [string "./MissionEditor/modules/me_logbook.lua"]:1128: attempt to index local 'unitTarget' (a nil value)
GUI debug.traceback: stack traceback:
	[C]: ?
	[string "./MissionEditor/modules/me_logbook.lua"]:1128: in function 'updateUserStatistics'
	[string "./MissionEditor/modules/me_debriefing.lua"]:361: in function 'updateStatistic'
	[string "./MissionEditor/modules/me_debriefing.lua"]:385: in function 'endMission'
	[string "./MissionEditor/modules/me_debriefing.lua"]:351: in function 'onChange'
  • Thanks 1
Link to comment
Share on other sites

Guest
This topic is now closed to further replies.
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...