Page 1 of 1
Hardcoded-30-4 & 9, Episode Override
Posted: Thu Feb 11, 2021 8:53 am
by ByTheBookGames
Seems like certain hardcoded graphics, namely 30-4 and 9 (even though the "LOADING + [coin]" graphic is inaccessible with local files), are applied to the starting screen before any LunaLua scripts have the chance to change them. However, I've noticed that changing 30-4 in the hardcoded graphics folder will apply the change on startup (or rather, will draw a different custom hardcoded png overtop the old hardcoded start screen). I'm wondering which part of SMBX applies this overlay before the Lua scripts kick in, and if there's a way of adding something to an episode folder (like a base-level lua script or config file) that would apply an episode-specific hardcoded-30-4/9 in time.
Thanks in advance for looking this over and trying to help.
Re: Hardcoded-30-4 & 9, Episode Override
Posted: Thu Feb 11, 2021 9:03 am
by MrDoubleA
So... you just want a custom loadscreen? Then you can just create a file called loadscreen.lua and put some custom code into its onDraw. (Though note that the loadscreen is slightly limited. You only get Graphics, some of Misc, and a few other things here and there.)
Re: Hardcoded-30-4 & 9, Episode Override
Posted: Thu Feb 11, 2021 9:10 am
by ByTheBookGames
MrDoubleA wrote: ↑Thu Feb 11, 2021 9:03 am
So... you just want a custom loadscreen? Then you can just create a file called loadscreen.lua and put some custom code into its onDraw. (Though note that the loadscreen is slightly limited. You only get Graphics, some of Misc, and a few other things here and there.)
Thank you for your response, but no. I understand the mechanics of loadscreen.lua, but that's a separate screen from the first screen that pops up when you load SMBX, which contains the disclaimers about not being affiliated with Nintendo, the Loading text in the bottom right with the coin, etc. This is what I'm referring to, and what the hardcoded graphics I mentioned apply to.
Re: Hardcoded-30-4 & 9, Episode Override
Posted: Thu Feb 11, 2021 9:11 am
by MrDoubleA
ByTheBookGames wrote: ↑Thu Feb 11, 2021 9:10 am
MrDoubleA wrote: ↑Thu Feb 11, 2021 9:03 am
So... you just want a custom loadscreen? Then you can just create a file called loadscreen.lua and put some custom code into its onDraw. (Though note that the loadscreen is slightly limited. You only get Graphics, some of Misc, and a few other things here and there.)
Thank you for your response, but no. I understand the mechanics of loadscreen.lua, but that's a separate screen from the first screen that pops up when you load SMBX, which contains the disclaimers about not being affiliated with Nintendo, the Loading text in the bottom right with the coin, etc. This is what I'm referring to, and what the hardcoded graphics I mentioned apply to.
Pretty sure that's before custom graphics are even loaded.
Re: Hardcoded-30-4 & 9, Episode Override
Posted: Thu Feb 11, 2021 12:06 pm
by ByTheBookGames
MrDoubleA wrote: ↑Thu Feb 11, 2021 9:11 am
ByTheBookGames wrote: ↑Thu Feb 11, 2021 9:10 am
MrDoubleA wrote: ↑Thu Feb 11, 2021 9:03 am
So... you just want a custom loadscreen? Then you can just create a file called loadscreen.lua and put some custom code into its onDraw. (Though note that the loadscreen is slightly limited. You only get Graphics, some of Misc, and a few other things here and there.)
Thank you for your response, but no. I understand the mechanics of loadscreen.lua, but that's a separate screen from the first screen that pops up when you load SMBX, which contains the disclaimers about not being affiliated with Nintendo, the Loading text in the bottom right with the coin, etc. This is what I'm referring to, and what the hardcoded graphics I mentioned apply to.
Pretty sure that's before custom graphics are even loaded.
Yes, it is. I actually already explained that, but I understand it's a complicated subject. Maybe you could re-read the original post before commenting further please?
Re: Hardcoded-30-4 & 9, Episode Override
Posted: Thu Feb 11, 2021 12:32 pm
by Emral
Changing the startup screen is not supported.
Re: Hardcoded-30-4 & 9, Episode Override
Posted: Thu Feb 11, 2021 2:19 pm
by ByTheBookGames
Enjl wrote: ↑Thu Feb 11, 2021 12:32 pm
Changing the startup screen is not supported.
Sure, I get that. And I appreciate your reply. But changing the "hardcoded-30-4.png" file in the "hardcoded" folder of the graphics folder does in fact change the startup screen. So, technically it is supported, just not from within an episode folder currently. If I create a custom "hardcoded-30-4.png" file and replace the previous image in the harcoded graphics folder with that new image, that's what will appear instead when the game starts up. Something outside of the lua scripts and episode folders is telling the base game to do that. I was just curious what part of SMBX is controlling that.
Re: Hardcoded-30-4 & 9, Episode Override
Posted: Thu Feb 11, 2021 2:47 pm
by Emral
It might be that it was changed with one of the earlier ASM patches to read from that folder so that we don't have to recompile lunadll whenever Nintendo releases a new console and we have to change the screen. I recall patching the screen taking quite a while last time.
Re: Hardcoded-30-4 & 9, Episode Override
Posted: Thu Feb 11, 2021 4:12 pm
by ByTheBookGames
Enjl wrote: ↑Thu Feb 11, 2021 2:47 pm
It might be that it was changed with one of the earlier ASM patches to read from that folder so that we don't have to recompile lunadll whenever Nintendo releases a new console and we have to change the screen. I recall patching the screen taking quite a while last time.
Got it, makes sense. Bummer there's not an easy workaround, but I understand the possibilities and limitations much better now. Thanks for your help