WHDLoad MantisBT - WHDLoad
View Issue Details
0005171WHDLoad[All Projects] Generalpublic2021-05-02 13:162022-01-15 23:15
ReporterPaul Head 
Assigned ToWepl 
PlatformOSOS Version
Product Version18.6 
Target Version18.7Fixed in Version18.7 
ChipMem2 MB
FastMem8 MB
WorkbenchOS 3.0
KickROM39 - Kick 3.0
Summary0005171: Return Code when user aborts loading with the 'Esc' key on splash window
DescriptionAs far as I can tell, there is no way via AmigaDOS that I can reliably detect whether a 'user abort' was issued or not during loading a game. This 'user abort' happens when pressing the escape key whilst the splash screen is active. (introduced in 17.0?) Currently it returns $RC 10 with no error message. An actual error due to incorrect tooltypes (for example) also returns $RC 10 but with a message 'wrong number of arguments'.

Is it always the case that if $RC 10 is returned and with no error message, then the user did actually abort the loading with the Esc key? I can't find anything in the docs regarding this. Another error might mimic this behaviour of the $RC 10 with no error message for all I know...so I can't be sure. "preload aborted by user" or similar message could be displayed I suppose so then I'd be clear on what happened. Or, shuffle the error codes around a bit and give them unique return codes. I don't know what the others are in this 10-20 range. Maybe it needs a 5 code instead (like a break). Thanks.
TagsNo tags attached.
Attached Files

Paul Head   
2021-05-02 13:21   
I don't actually know what the correct return code should be from an AmigaDOS perspective. I just tried some commands and aborted them and they abort with 20. Others abort with 5, and I read somewhere an 8 too...so I don't know. :-D
2021-05-03 01:33   
Currently WHDLoad will always return 10 if the Slave didn't got called because of any problems.
I could maybe return 5 if preload has been cancelled.
For what do you want this to know?
Paul Head   
2021-05-04 13:38   
I use custom scripts to manage WHDLoad (non WB environment), and I need to know whether preload was Escaped/cancelled (no actual error as such) or whether there was a real error due to incorrect tooltypes for example. The 5 (WARN) sounds perfect to me and it seems quite correct in the Amiga scheme of things I believe. With a 5 (WARN) I would know that Escape had been pressed, and tooltypes or anything else wouldn't need to be checked.

So yes, please make it return 5 if at all possible for when Preload is cancelled via the Escape key. This is a useful feature all round, games launcher programs would benefit too if they know about it. It's useful for them too to know whether a game has failed in launching as opposed to just a cancelled preload.
2021-05-16 17:12   
WHDLoad now returns a return code = 5 if the preload process has been canceled pressing the Esc key in the splash window.
Paul Head   
2021-05-17 13:04   
Thank you very much, it's working brill :-)

Issue History
2021-05-02 13:16Paul HeadNew Issue
2021-05-02 13:21Paul HeadNote Added: 0010155
2021-05-03 01:23WeplAssigned To => Wepl
2021-05-03 01:23WeplStatusnew => assigned
2021-05-03 01:33WeplNote Added: 0010166
2021-05-04 13:38Paul HeadNote Added: 0010183
2021-05-16 17:12WeplNote Added: 0010276
2021-05-16 17:13WeplFixed in Version => 18.7beta
2021-05-16 17:13WeplTarget Version => 18.7
2021-05-16 17:13WeplStatusassigned => resolved
2021-05-16 17:13WeplResolutionopen => fixed
2021-05-17 13:04Paul HeadNote Added: 0010290
2022-01-15 23:15WeplStatusresolved => closed
2022-01-15 23:15WeplFixed in Version18.7beta => 18.7