Sonic and Sega Retro Message Board: Disabling HUD in Sonic 1/2/3/Knuckles - Sonic and Sega Retro Message Board

Jump to content

Hey there, Guest!  (Log In · Register) Help
Page 1 of 1
    Locked
    Locked Forum

Disabling HUD in Sonic 1/2/3/Knuckles

#1 User is offline abckookooman 

Posted 29 December 2012 - 09:23 PM

  • Posts: 4
  • Joined: 01-January 12
  • Gender:Male
  • Location:Fremont, CA
Please excuse my ignorance and naïveté as this is my first post and I am still in the process learning the ropes of ROM hacking learning what ROM hacking is.

How I can disable the HUD (Heads Up Display) or somehow remove it so it won't show up?

This video roughly shows the desired effect - the time, rings, score, and life counters to "go invisible", and everything else remains unchanged.

If this can be done without complex hacking or if there is an easy way to do it with a PAR or game genie code/ etc. please do mention it.
This post has been edited by abckookooman: 29 December 2012 - 09:41 PM

#2 User is offline Neo 

Posted 30 December 2012 - 01:31 AM

  • Bitter Old Coot
  • Posts: 1062
  • Joined: 10-December 04
  • Gender:Male
  • Location:Portugal
  • Project:Sonic 3 Complete
  • Wiki edits:1
Sonic 1 at the very least should have a mode for this somewhere, somehow -- the demos during the credits show up HUDless, after all.

You could always do a bit of RAM watching to try and figure out what this mode is and whether or not it's possible to make a simple PAR code to activate it, or you could also look for where the thing is loaded in the disassembly and just nop those lines away...

EDIT: There's also the 21st century solution of don't touch anything in the code (it might blow up!) and just blank all the relevant art files
This post has been edited by Neo: 30 December 2012 - 01:35 AM

#3 User is offline TheInvisibleSun 

Posted 30 December 2012 - 02:01 AM

  • OVER THE TOP TECHNO-BLAST
  • Posts: 1228
  • Joined: 09-December 09
  • Gender:Male
  • Location:Buffalo, NY, USA
  • Project:Sonic 1 Color Contrast

View Postabckookooman, on 29 December 2012 - 09:23 PM, said:

Please excuse my ignorance and naïveté as this is my first post and I am still in the process learning the ropes of ROM hacking learning what ROM hacking is.

How I can disable the HUD (Heads Up Display) or somehow remove it so it won't show up?

This video roughly shows the desired effect - the time, rings, score, and life counters to "go invisible", and everything else remains unchanged.

If this can be done without complex hacking or if there is an easy way to do it with a PAR or game genie code/ etc. please do mention it.


You might want to do a bit of minor ASM hacking for this.

If you have a Split-Disassembly for Sonic 1 set up already, then you want to go to your disassembly/hack folder, and open the file called sonic.asm, in WordPad.

Use Ctrl+F to find this phrase "Level_SkipTtlCard". Under this you will find this code:

Level_SkipTtlCard:
		moveq	#palid_Sonic,d0
		bsr.w	PalLoad1	; load Sonic's palette
		bsr.w	LevelSizeLoad
		bsr.w	DeformLayers
		bset	#2,(v_bgscroll1).w
		bsr.w	LevelDataLoad ; load block mappings and palettes
		bsr.w	LoadTilesFromStart
		jsr	FloorLog_Unk
		bsr.w	ColIndexLoad
		bsr.w	LZWaterFeatures
		move.b	#id_SonicPlayer,(v_objspace).w ; load Sonic object
		tst.w	(f_demo).w
		bmi.s	Level_ChkDebug
		move.b	#id_HUD,(v_objspace+$40).w ; load HUD object


Comment out the last 3 lines, like this by putting semicolons before them, so that the game reads them as comments:

;tst.w	(f_demo).w
;bmi.s	Level_ChkDebug
;move.b	#id_HUD,(v_objspace+$40).w ; load HUD object


The end result should look like this:

Level_SkipTtlCard:
		moveq	#palid_Sonic,d0
		bsr.w	PalLoad1	; load Sonic's palette
		bsr.w	LevelSizeLoad
		bsr.w	DeformLayers
		bset	#2,(v_bgscroll1).w
		bsr.w	LevelDataLoad ; load block mappings and palettes
		bsr.w	LoadTilesFromStart
		jsr	FloorLog_Unk
		bsr.w	ColIndexLoad
		bsr.w	LZWaterFeatures
		move.b	#id_SonicPlayer,(v_objspace).w ; load Sonic object
		;tst.w	(f_demo).w
		;bmi.s	Level_ChkDebug
		;move.b	#id_HUD,(v_objspace+$40).w ; load HUD object


And now the HUD shouldn't show up in your ROM of Sonic 1.

(Protip: Questions like these should ordinarily be asked in the designated Basic Question's and Answers Thread)

This post has been edited by TheInvisibleSun: 30 December 2012 - 02:06 AM

#4 User is offline Truner 

Posted 30 December 2012 - 07:37 AM

  • Posts: 104
  • Joined: 01-May 08
  • Gender:Male
  • Location:Hungary
Allow me, to butt in. I'm no hacking master, but what about redrawing all the sprites (letters, numbers) with no color? Sonic 1-3 doesn't even have a dialogue (especially not with the letters and numbers used on the HUD), so it wouldn't be a problem anywhere in the game, no?

#5 User is offline vladikcomper 

Posted 30 December 2012 - 10:21 AM

  • Posts: 170
  • Joined: 13-June 09
  • Gender:Not Telling
  • Location:Russia
  • Project:Sonic Winter Adventures
  • Wiki edits:1
In Sonic 1 and 2 HUD is presented by object, so disabling shouldn't be a problem at all - just follow what TheInvisibleSun said.

In Sonic 3/Sonic Knuckles however, HUD is hardcoded into sprites rendering routine. I once did a hack that removes HUD in S3K by someone's request. It took me a while to figure out HUD displaying code, since nearly nothing was annotated in disassembly back then. If you want the hack, here you go: https://dl.dropbox.c...7401/skbuilt.7z (I don't remember if this hack has anything else besides HUD being removed though)

#6 User is offline abckookooman 

Posted 30 December 2012 - 04:03 PM

  • Posts: 4
  • Joined: 01-January 12
  • Gender:Male
  • Location:Fremont, CA
OMG thank you very much for that hack; that ROM was a godsend.

View PostTruner, on 30 December 2012 - 07:37 AM, said:

what about redrawing all the sprites (letters, numbers) with no color?


How can this be done without messing with the asm code? Or, is it possible to take out the whole HUD with a hex editor in a compiled ROM?

==EDIT==
The VDP's memory range is between $C00000 and $DFFFFF, and the HUD is rendered on the high sprite layer, so it's a matter of finding the right par code to mess with it. Does anyone have any ideas?
This post has been edited by abckookooman: 30 December 2012 - 04:26 PM

#7 User is offline vladikcomper 

Posted 30 December 2012 - 06:23 PM

  • Posts: 170
  • Joined: 13-June 09
  • Gender:Not Telling
  • Location:Russia
  • Project:Sonic Winter Adventures
  • Wiki edits:1

Quote

The VDP's memory range is between $C00000 and $DFFFFF, and the HUD is rendered on the high sprite layer, so it's a matter of finding the right par code to mess with it. Does anyone have any ideas?

There's no $C00000--$DFFFFF range in VDP memory, perhaps you're meaning $C000-$DFFF range in VDP's VRAM? In Sonic games this range is used to store Plane A nametable (I.e. levels' foreground), it has nothing to do with sprites. Sprites attribute tables is starts from offset $F800 of VRAM. While in S3/SK HUD sprites can possibly have fixed positions in this table, as they are hardcoded, in Sonic 1/2 their position can be variable since HUD is being rendered among other objects, you cannot predict it, it depends on how many pieces in sprites were rendered before.

I also doubt PAR codes can access VDP's memory. If by $C00000--$DFFFFF range you are referring to M68K address space, then this area is actually VDP control area, but you cannot access VDP's memory directly in SMD, which makes using this area totally useless for PAR codes. Bytes $C00000--$C00007 are VDP ports, they act as bridge between VDP and SMD's main processor, the rest are few ports to control PSG (sound generator, built-in in VDP) and a huge area of this range is mirrors (meaning sequence of repeated offsets referring to the same physical location as the offsets described above). In a nutshell, you can't see the whole VDP memory, you have to send specified commands to these ports to write a specified byte/word at specified VRAM offset.

You'd better disable HUD in S1/S2 by taking out few instructions as TheInvisibleSun has pointer out. You can do it via PAR codes of course. Just know out the offsets of the instructions and replace them with nop instructions (opcode 4E71). But using a disassembly would work better.

#8 User is offline abckookooman 

Posted 31 December 2012 - 08:43 PM

  • Posts: 4
  • Joined: 01-January 12
  • Gender:Male
  • Location:Fremont, CA
Great, I got sonic 1 to compile, and made it HUDless! That was easier than I thought. I really appreciate the help, and I learned some more about ROM hacking.

But I'm only 3/4 done, I need to hack Sonic 2; more specifically, I need to get Sonic 2 Long version HUDless. Is there a way to remove Sonic 2 Long version's HUD through a hex editor? If so, does anyone happen to know the offset or what I need to look for?

Thanks again for all the help.

==EDIT==

I found this PAR code: FFF711:?? for sonic 2 - set ?? to 00 to turn it off
This post has been edited by abckookooman: 01 January 2013 - 07:05 PM

#9 User is offline TheInvisibleSun 

Posted 02 January 2013 - 04:24 PM

  • OVER THE TOP TECHNO-BLAST
  • Posts: 1228
  • Joined: 09-December 09
  • Gender:Male
  • Location:Buffalo, NY, USA
  • Project:Sonic 1 Color Contrast
No problem! :)
This post has been edited by TheInvisibleSun: 02 January 2013 - 04:25 PM

Page 1 of 1
    Locked
    Locked Forum

1 User(s) are reading this topic
0 members, 1 guests, 0 anonymous users