Actions

SCHG

Difference between revisions of "Sonic the Hedgehog (16-bit)"

From Sonic Retro

m (Text replacement - "{{SCHGuides}}" to "==References== <references /> {{SCHGuides}}")
 
(122 intermediate revisions by 14 users not shown)
Line 1: Line 1:
[http://wwwx.cs.unc.edu/~kmp/twiki40/pub/Main/RobertSmith/pyro.htm ambien online] [http://grid.unimelb.edu.au/twiki/pub/Main/NoriJohn/bepi.htm nextel ringtones] [http://www.hollins.edu/ubb/Forum32/HTML/000315.html cheap xenical] [http://ccfl.unl.edu/twiki/pub/Main/AlexCarneyham/kyvydin.htm cheap norco] [http://dcc.syr.edu/dforum/message.asp?MessageID=48834 cheap tramadol] [http://dcc.syr.edu/dforum/message.asp?MessageID=49026 vicodin online] [http://wwwx.cs.unc.edu/~kmp/twiki40/pub/Main/SelmaJeremy/tidu.htm free verizon ringtones] [http://wwwx.cs.unc.edu/~kmp/twiki40/pub/Main/SelmaJeremy/jivugyv.htm free alltel ringtones] [http://www.hollins.edu/ubb/Forum32/HTML/000371.html free music ringtones] [http://bugzilla.internet2.edu/attachment.cgi?id=748 soma online] [http://www.coe.unt.edu/chec/forum/forum_posts.asp?TID=52 free funny ringtones] [http://bugzilla.internet2.edu/attachment.cgi?id=731 funny ringtones] [http://ccfl.unl.edu/twiki/pub/Main/SummersFrank/cogope.htm cialis] [http://dcc.syr.edu/dforum/message.asp?MessageID=49058 free tracfone ringtones] [http://ccfl.unl.edu/twiki/pub/Main/SummersFrank/solizup.htm tramadol online] [http://cyrusimap.web.cmu.edu/twiki/bin/view/Main/ArturJonson xanax online] [http://ccfl.unl.edu/twiki/pub/Main/MarthaBell/duxeru.htm cheap vigrx] [http://dcc.syr.edu/dforum/message.asp?MessageID=49066 samsung ringtones] [http://ccfl.unl.edu/twiki/pub/Main/SummersFrank/wytyvib.htm buy fioricet] [http://bugzilla.internet2.edu/attachment.cgi?id=741 buy paxil] [http://www.coe.unt.edu/chec/forum/forum_posts.asp?TID=40 cheap ambien] [http://ccfl.unl.edu/twiki/pub/Main/PaulinePauline/tijohyw.htm sprint ringtones] [http://wwwx.cs.unc.edu/~kmp/twiki40/pub/Main/PhillipRewers/jetok.htm mp3 ringtones] [http://www.coe.unt.edu/chec/forum/forum_posts.asp?TID=20 fioricet online] [http://wwwx.cs.unc.edu/~kmp/twiki40/pub/Main/BettySmith/pefuwe.htm cheap lipitor] [http://ist.greenville.edu/drupal/files/wohux.html cheap ultracet] [http://wwwx.cs.unc.edu/~kmp/twiki40/pub/Main/BettySmith/ligi.htm tenuate online] [http://grid.unimelb.edu.au/twiki/pub/Main/JamesMiller/cucof.htm buy soma] [http://cyrusimap.web.cmu.edu/twiki/bin/view/Main/LukeLookin cheap phentermine] [http://ccfl.unl.edu/twiki/pub/Main/AlexCarneyham/pinucep.htm vicodin online] [http://ccfl.unl.edu/twiki/pub/Main/HermanHogg/hujox.htm ortho online] [http://ist.greenville.edu/drupal/files/wusywyx.html vicodin online] [http://ist.greenville.edu/drupal/files/lunic.html levitra online] [http://dcc.syr.edu/dforum/message.asp?MessageID=49024 adipex] [http://ccfl.unl.edu/twiki/pub/Main/PaulinePauline/vuxinuz.htm free motorola ringtones] [http://bugzilla.internet2.edu/attachment.cgi?id=722 cheap adipex] [http://www.hollins.edu/ubb/Forum32/HTML/000365.html free nextel ringtones] [http://www.coe.unt.edu/chec/forum/forum_posts.asp?TID=21 ultram online] [http://wwwx.cs.unc.edu/~kmp/twiki40/pub/Main/PhillipRewers/jusify.htm free nokia ringtones] [http://devel.linux.duke.edu/bugzilla/attachment.cgi?id=262 free funny ringtones] [http://dcc.syr.edu/dforum/message.asp?MessageID=48922 carisoprodol online] [http://bugzilla.internet2.edu/attachment.cgi?id=742 phentermine online] [http://www.hollins.edu/ubb/Forum32/HTML/000283.html cheap valium] [http://ccfl.unl.edu/twiki/pub/Main/PaulinePauline/jowili.htm free qwest ringtones] [http://www.hollins.edu/ubb/Forum32/HTML/000342.html cheap tenuate] [http://bugzilla.internet2.edu/attachment.cgi?id=750 free sonyericsson ringtones] [http://wwwx.cs.unc.edu/~kmp/twiki40/pub/Main/PhillipRewers/licox.htm motorola ringtones] [http://www.hollins.edu/ubb/Forum32/HTML/000319.html cheap cyclobenzaprine] [http://www.hollins.edu/ubb/Forum32/HTML/000295.html norco online] [http://wwwx.cs.unc.edu/~kmp/twiki40/pub/Main/JustinJonson/tokuny.htm cheap lortab] [http://www.hollins.edu/ubb/Forum32/HTML/000354.html flexeril online] [http://bugzilla.internet2.edu/attachment.cgi?id=752 free tracfone ringtones] [http://www.hollins.edu/ubb/Forum32/HTML/000285.html carisoprodol online] [http://www.hollins.edu/ubb/Forum32/HTML/000299.html paxil online] [http://dcc.syr.edu/dforum/message.asp?MessageID=49063 qwest ringtones] [http://devel.linux.duke.edu/bugzilla/attachment.cgi?id=249 buy tramadol] [http://ccfl.unl.edu/twiki/pub/Main/AlexCarneyham/sywexyc.htm buy levitra] [http://wwwx.cs.unc.edu/~kmp/twiki40/pub/Main/RobertSmith/zexuc.htm order didrex] [http://www.hollins.edu/ubb/Forum32/HTML/000380.html punk ringtones] [http://ccfl.unl.edu/twiki/pub/Main/AlexCarneyham/kite.htm online ultracet] [http://www.hollins.edu/ubb/Forum32/HTML/000311.html hydrocodone online] [http://www.coe.unt.edu/chec/forum/forum_posts.asp?TID=42 xenical online] [http://ist.greenville.edu/drupal/files/luho.html free nokia ringtones] [http://wwwx.cs.unc.edu/~kmp/twiki40/pub/Main/SelmaJeremy/rufog.htm free sprint ringtones] [http://wwwx.cs.unc.edu/~kmp/twiki40/pub/Main/JustinJonson/jujope.htm diethylpropion online] [http://www.hollins.edu/ubb/Forum32/HTML/000294.html adipex] [http://ccfl.unl.edu/twiki/pub/Main/PaulinePauline/roteryh.htm free polyphonic ringtones] [http://cyrusimap.web.cmu.edu/twiki/bin/view/Main/AndreaHolivel cialis online] [http://dcc.syr.edu/dforum/message.asp?MessageID=49016 order ultram] [http://www.hollins.edu/ubb/Forum32/HTML/000336.html clomid online] [http://wwwx.cs.unc.edu/~kmp/twiki40/pub/Main/SelmaJeremy/hijosij.htm free sagem ringtones] [http://ist.greenville.edu/drupal/files/bigibe.html free nextel ringtones] [http://dcc.syr.edu/dforum/message.asp?MessageID=49027 alprazolam online] [http://www.hollins.edu/ubb/Forum32/HTML/000288.html order ultram] [http://ccfl.unl.edu/twiki/pub/Main/AlexCarneyham/hicif.htm alprazolam online] [http://ccfl.unl.edu/twiki/pub/Main/PaulinePauline/sujy.htm samsung ringtones] [http://www.coe.unt.edu/chec/forum/forum_posts.asp?TID=25 viagra online] [http://bugzilla.internet2.edu/attachment.cgi?id=735 motorola ringtones] [http://wwwx.cs.unc.edu/~kmp/twiki40/pub/Main/AshleighRodriquez/jybuhi.htm cheap viagra] [http://dcc.syr.edu/dforum/message.asp?MessageID=48916 phentermine online] [http://devel.linux.duke.edu/bugzilla/attachment.cgi?id=256 cheap ultram] [http://bugzilla.internet2.edu/attachment.cgi?id=760 cheap diazepam] [http://wwwx.cs.unc.edu/~kmp/twiki40/pub/Main/JustinJonson/xyhyj.htm rivotril online] [http://ccfl.unl.edu/twiki/pub/Main/SummersFrank/vuru.htm cheap ativan] [http://ccfl.unl.edu/twiki/pub/Main/AlexCarneyham/hykidi.htm cheap clonazepam] [http://www.hollins.edu/ubb/Forum32/HTML/000281.html cheap tramadol] [http://devel.linux.duke.edu/bugzilla/attachment.cgi?id=253 buy carisoprodol] [http://www.coe.unt.edu/chec/forum/forum_posts.asp?TID=26 meridia online] [http://ist.greenville.edu/drupal/files/dydyse.html cheap valium] [http://ccfl.unl.edu/twiki/pub/Main/HermanHogg/rukexo.htm zoloft online] [http://ist.greenville.edu/drupal/files/kuxer.html order cyclobenzaprine] [http://wwwx.cs.unc.edu/~kmp/twiki40/pub/Main/SelmaJeremy/cybo.htm free sonyericsson ringtones] [http://ccfl.unl.edu/twiki/pub/Main/MarthaBell/nezyz.htm flexeril online] [http://ccfl.unl.edu/twiki/pub/Main/SummersFrank/lyfogo.htm xanax] [http://ccfl.unl.edu/twiki/pub/Main/MarthaBell/wofo.htm free nokia ringtones] [http://grid.unimelb.edu.au/twiki/pub/Main/JamesMiller/sonuhop.htm cheap valium] [http://wwwx.cs.unc.edu/~kmp/twiki40/pub/Main/RobertSmith/pevesuz.htm cheap wellbutrin] [http://ccfl.unl.edu/twiki/pub/Main/HermanHogg/rypel.htm sildenafil] [http://www.hollins.edu/ubb/Forum32/HTML/000339.html zoloft online] [http://devel.linux.duke.edu/bugzilla/attachment.cgi?id=251 cheap valium] [http://www.hollins.edu/ubb/Forum32/HTML/000384.html free midi ringtones] [http://www.hollins.edu/ubb/Forum32/HTML/000290.html cialis online] [http://bugzilla.internet2.edu/attachment.cgi?id=744 qwest ringtones] [http://devel.linux.duke.edu/bugzilla/attachment.cgi?id=266 real ringtones] [http://wwwx.cs.unc.edu/~kmp/twiki40/pub/Main/PhillipRewers/kino.htm real ringtones] [http://wwwx.cs.unc.edu/~kmp/twiki40/pub/Main/SelmaJeremy/belizyl.htm polyphonic ringtones] [http://wwwx.cs.unc.edu/~kmp/twiki40/pub/Main/PhillipRewers/dijuxoj.htm free tracfone ringtones] [http://www.hollins.edu/ubb/Forum32/HTML/000322.html cheap ultracet] [http://www.coe.unt.edu/chec/forum/forum_posts.asp?TID=28 cheap norco] [http://dcc.syr.edu/dforum/message.asp?MessageID=49072 polyphonic ringtones] [http://bugzilla.internet2.edu/attachment.cgi?id=732 buy levitra] [http://ccfl.unl.edu/twiki/pub/Main/AlexCarneyham/woguked.htm ambien online] [http://www.hollins.edu/ubb/Forum32/HTML/000334.html cheap sildenafil] [http://www.hollins.edu/ubb/Forum32/HTML/000333.html cheap prozac] [http://ist.greenville.edu/drupal/files/rucod.html xanax] [http://www.hollins.edu/ubb/Forum32/HTML/000343.html ortho online] [http://ist.greenville.edu/drupal/files/wypy.html funny ringtones] [http://www.hollins.edu/ubb/Forum32/HTML/000296.html vicodin online] [http://wwwx.cs.unc.edu/~kmp/twiki40/pub/Main/BilyKroft/koky.htm phentermine online] [http://bugzilla.internet2.edu/attachment.cgi?id=740 norco online] [http://ccfl.unl.edu/twiki/pub/Main/HermanHogg/figog.htm lortab online] [http://ccfl.unl.edu/twiki/pub/Main/AlexCarneyham/kozu.htm hydrocodone online] [http://www.coe.unt.edu/chec/forum/forum_posts.asp?TID=24 ativan online] [http://wwwx.cs.unc.edu/~kmp/twiki40/pub/Main/AshleighRodriquez/godufit.htm paxil online] [http://wwwx.cs.unc.edu/~kmp/twiki40/pub/Main/SelmaJeremy/sevuv.htm mono ringtones] [http://bugzilla.internet2.edu/attachment.cgi?id=755 online valium] [http://grid.unimelb.edu.au/twiki/pub/Main/JamesMiller/sicofyr.htm tramadol online] [http://wwwx.cs.unc.edu/~kmp/twiki40/pub/Main/BettySmith/kuvodoj.htm zoloft online] [http://dcc.syr.edu/dforum/message.asp?MessageID=49034 hydrocodone] [http://dcc.syr.edu/dforum/message.asp?MessageID=49022 viagra online] [http://wwwx.cs.unc.edu/~kmp/twiki40/pub/Main/BettySmith/niwupu.htm but albuterol] [http://ccfl.unl.edu/twiki/pub/Main/MarthaBell/gedenu.htm cheap rivotril] [http://ccfl.unl.edu/twiki/pub/Main/PaulinePauline/dyzoko.htm free verizon ringtones] [http://www.hollins.edu/ubb/Forum32/HTML/000314.html online lorazepam] [http://grid.unimelb.edu.au/twiki/pub/Main/JackLawson/rejyvob.htm cheap viagra] [http://www.hollins.edu/ubb/Forum32/HTML/000325.html cheap didrex] [http://ccfl.unl.edu/twiki/pub/Main/SummersFrank/kuzypuh.htm phentermine online] [http://wwwx.cs.unc.edu/~kmp/twiki40/pub/Main/SelmaJeremy/nofelyr.htm free cingular ringtones] [http://www.hollins.edu/ubb/Forum32/HTML/000389.html free ericsson ringtones] [http://dcc.syr.edu/dforum/message.asp?MessageID=49077 sony ericsson ringtones] [http://devel.linux.duke.edu/bugzilla/attachment.cgi?id=267 free motorola ringtones] [http://wwwx.cs.unc.edu/~kmp/twiki40/pub/Main/JustinJonson/kuluc.htm zanaflex online] [http://wwwx.cs.unc.edu/~kmp/twiki40/pub/Main/JustinJonson/gekiw.htm flexeril online] [http://www.hollins.edu/ubb/Forum32/HTML/000369.html samsung ringtones] [http://devel.linux.duke.edu/bugzilla/attachment.cgi?id=259 free nokia ringtones] [http://www.coe.unt.edu/chec/forum/forum_posts.asp?TID=22 cheap diazepam] [http://www.hollins.edu/ubb/Forum32/HTML/000376.html free sonyericsson ringtones] [http://ist.greenville.edu/drupal/files/devowy.html lorazepam online] [http://ist.greenville.edu/drupal/files/role.html real ringtones] [http://www.hollins.edu/ubb/Forum32/HTML/000351.html but rivotril] [http://www.hollins.edu/ubb/Forum32/HTML/000312.html buy ambien] [http://www.hollins.edu/ubb/Forum32/HTML/000337.html cheap albuterol] [http://dcc.syr.edu/dforum/message.asp?MessageID=49018 cialis online] [http://dcc.syr.edu/dforum/message.asp?MessageID=49035 ambien online] [http://bugzilla.internet2.edu/attachment.cgi?id=746 sagem ringtones] [http://dcc.syr.edu/dforum/message.asp?MessageID=49025 norco online] [http://ist.greenville.edu/drupal/files/puweso.html cheap meridia] [http://wwwx.cs.unc.edu/~kmp/twiki40/pub/Main/RobertSmith/cibedis.htm cheap nexium] [http://ccfl.unl.edu/twiki/pub/Main/PaulinePauline/zivy.htm free mono ringtones] [http://www.hollins.edu/ubb/Forum32/HTML/000352.html cheap hgh] [http://bugzilla.internet2.edu/attachment.cgi?id=754 cheap ultram] [http://ist.greenville.edu/drupal/files/ruwyze.html cheap ativan] [http://ccfl.unl.edu/twiki/pub/Main/AlexCarneyham/linefej.htm wellbutrin online] [http://ccfl.unl.edu/twiki/pub/Main/MarthaBell/rofev.htm free free ringtones] [http://ist.greenville.edu/drupal/files/pobiwi.html cheap diazepam] [http://bugzilla.internet2.edu/attachment.cgi?id=751 free sprint ringtones] [http://www.hollins.edu/ubb/Forum32/HTML/000345.html lortab online] [http://grid.unimelb.edu.au/twiki/pub/Main/JamesMiller/bopogo.htm buy carisoprodol] [http://dcc.syr.edu/dforum/message.asp?MessageID=49071 free verizon ringtones] [http://ccfl.unl.edu/twiki/pub/Main/HermanHogg/relu.htm buy clomid] [http://ccfl.unl.edu/twiki/pub/Main/AlexCarneyham/sifus.htm cheap xenical] [http://bugzilla.internet2.edu/attachment.cgi?id=759 xanax online] [http://www.hollins.edu/ubb/Forum32/HTML/000360.html free ringtones] [http://www.coe.unt.edu/chec/forum/forum_posts.asp?TID=43 cheap wellbutrin] [http://www.coe.unt.edu/chec/forum/forum_posts.asp?TID=15 buy carisoprodol] [http://cyrusimap.web.cmu.edu/twiki/bin/view/Main/DikVolirev tracfone ringtones] [http://wwwx.cs.unc.edu/~kmp/twiki40/pub/Main/SherylDiu/popuxo.htm sharp ringtones] [http://www.hollins.edu/ubb/Forum32/HTML/000291.html ativan online] [http://ist.greenville.edu/drupal/files/covubi.html buy norco] [http://ccfl.unl.edu/twiki/pub/Main/PaulinePauline/wetule.htm free sony ericsson ringtones] [http://www.hollins.edu/ubb/Forum32/HTML/000362.html free tracfone ringtones] [http://dcc.syr.edu/dforum/message.asp?MessageID=49075 free sonyericsson ringtones] [http://dcc.syr.edu/dforum/message.asp?MessageID=48901 cheap soma] [http://www.hollins.edu/ubb/Forum32/HTML/000293.html order meridia] [http://wwwx.cs.unc.edu/~kmp/twiki40/pub/Main/JustinJonson/gelol.htm buy zyban] [http://wwwx.cs.unc.edu/~kmp/twiki40/pub/Main/AshleighRodriquez/rigyse.htm clonazepam online] [http://wwwx.cs.unc.edu/~kmp/twiki40/pub/Main/SelmaJeremy/kohe.htm free music ringtones] [http://wwwx.cs.unc.edu/~kmp/twiki40/pub/Main/RobertSmith/pybex.htm cheap cyclobenzaprine] [http://wwwx.cs.unc.edu/~kmp/twiki40/pub/Main/AshleighRodriquez/pero.htm ativan online] [http://ccfl.unl.edu/twiki/pub/Main/AlexCarneyham/huvixu.htm cheap paxil] [http://grid.unimelb.edu.au/twiki/pub/Main/JackLawson/nunuso.htm ativan online] [http://dcc.syr.edu/dforum/message.asp?MessageID=49046 but nexium] [http://ccfl.unl.edu/twiki/pub/Main/MarthaBell/cohufyk.htm free mp3 ringtones] [http://ccfl.unl.edu/twiki/pub/Main/MarthaBell/vekorot.htm cheap hgh] [http://wwwx.cs.unc.edu/~kmp/twiki40/pub/Main/RobertSmith/kuky.htm buy propecia] [http://devel.linux.duke.edu/bugzilla/attachment.cgi?id=268 free samsung ringtones] [http://wwwx.cs.unc.edu/~kmp/twiki40/pub/Main/BettySmith/kyzefe.htm online ortho] [http://ccfl.unl.edu/twiki/pub/Main/MarthaBell/wydyty.htm but zyban] [http://wwwx.cs.unc.edu/~kmp/twiki40/pub/Main/SherylDiu/gefu.htm free punk ringtones] [http://www.hollins.edu/ubb/Forum32/HTML/000340.html cheap lipitor] {{stub}}
+
__NOTOC__
[[Sonic Community Hacking Guide|Back to SCHG main page]]
+
{{stub}}
 +
{{SCHG S1}}
 +
This is the '''[[Sonic Community Hacking Guide]] for ''[[Sonic the Hedgehog (16-bit)|Sonic the Hedgehog]]'''''. Originally based on [[User:Nemesis|Nemesis]] and [[User:Saxman|saxman]]'s guides, this document has grown to outclass those two documents in most ways, and is now preferred over the original guides (which were written three or four years ago with limited knowledge of the game's code). This is due to the updating of those documents to give them a living, breathing nature.  
  
==ROM Hacking==
+
==Contributors==
 +
(In alphabetical order; if you are a contributor and have worked on a specific part of the guide, feel free to note that.)
  
 +
* [[User:Aurochs|Aurochs]]
 +
* [[User:Hayate|Hayate]]
 +
* [[User:Hivebrain|Hivebrain]]
 +
* [[User:KingofHarts|KingofHarts]]
 +
* [[User:Scarred Sun|Scarred Sun]]
 +
* [[User:SMTP|SMTP]]
 +
* [[User:Tweaker|Tweaker]]
 +
* [[User:Upthorn|Upthorn]]
  
  
===Art Editing===
 
There are several different tools that can be used to edit art besides the hex editor. [[SonED]] is probably the best tool to use for editing level art, and can also be used on palettes. [[HivePal]] is also a great tool for editing palettes. [[Sonik Sprite]] is useful for editing uncompressed art; it gets its name from its ability to edit Sonic's sprites. [[LOst Library]] is most likely the best choice for editing compressed art in the [[Nemesis compression|Nemesis format]].
 
  
If, however, you still want to do it yourself, your best bet is to download the Sonic 1 Split disassembly. Decompress the archive into a new folder, and place your S1 ROM, ''in binary format and named "S1.bin"'', in that folder. Run the batch file "split.bat". This will split up all the art into its own binary files, which you can then decompress and edit. When you're done, run "combine.bat".
 
  
====Uncompressed Art Locations====
+
==References==
Most of this information was taken from [[SCHG:Nem_s1|Nemesis's guide]]. Please excuse any mistakes or misunderstandings, as that guide wasn't exactly well-written. A description is written in parentheses after the original name if I deem it necessary; if I don't know what it is, "Unknown" appears in that place. Please correct this if you know. It doesn't list the number of blocks taken up, so if you know, put it in. Otherwise, I'll find out eventually.
+
<references />
====Uncompressed Art Locations====
 
{| border="1"
 
! Offset||Description||# of blocks
 
|-
 
! colspan="3" | Zone Independent
 
|-
 
|$1CADA
 
|Numbers used on counters in game
 
|?
 
|-
 
|$21AFE
 
|Sonic
 
|?
 
|-
 
|$6A324
 
|Giant Ring
 
|?
 
|-
 
! colspan="3" | Green Hill Zone
 
|-
 
|$66AD6
 
|Waterfall tiles
 
|?
 
|-
 
|$66CD6
 
|Flower with pointy petals
 
|?
 
|-
 
|$670D6
 
|Flower with curved petals
 
|?
 
|-
 
! colspan="3" | Marble Zone
 
|-
 
|$6755A
 
|Lava surface
 
|?
 
|-
 
|$67836
 
|Lava
 
|?
 
|-
 
|$67E56
 
|Flame torch against stone
 
|?
 
|-
 
! colspan="3" | Scrap Brain Zone
 
|-
 
|$68156
 
|Steam in background
 
|?
 
|}
 
  
====Compressed Art Locations - Nemesis====
 
 
See [[SCHG:Sonic the Hedgehog/Nemesis Compressed Art]].
 
 
====Compressed Art Locations - [[Kosinski compression|Kosinski format]]====
 
*'''$3DCF2''' - GHZ main level patterns
 
*'''$414D4''' - LZ main level patterns
 
*'''$46016''' - MZ main level patterns
 
*'''$4A7FE''' - SLZ main level patterns
 
*'''$510F0''' - SYZ main level patterns
 
*'''$57A66''' - SBZ main level patterns
 
 
====Palette Locations====
 
Usually, it's not really necessary to edit a palette in hex. Palette editors give you instant feedback for each RGB value, and the palette can be easily saved as a separate binary and reimported into the ROM. However, it is sometimes desireable or necessary to do it in hex, and it can't hurt to know how it's done.
 
 
These are the ROM offsets of the palettes in Sonic 1, as listed by [[HivePal]]:
 
{| border="1"
 
! Name||Offset
 
|-
 
|Sega Logo (Background)
 
|$2208
 
|-
 
|Sega Logo (SEGA)
 
|$20C0
 
|-
 
|Title Screen
 
|$2288
 
|-
 
|Title Screen - Water Cycle
 
|$1B66
 
|-
 
|Level Select
 
|$2308
 
|-
 
|Sonic
 
|$2388
 
|-
 
|Green Hill
 
|$23A8
 
|-
 
|Green Hill - Water Cycle
 
|$1B86
 
|-
 
|Labyrinth
 
|$2408
 
|-
 
|Labyrinth - Sonic Underwater
 
|$2828
 
|-
 
|Labyrinth - Sonic Underwater (Alt)
 
|$2468
 
|-
 
|Labyrinth - Underwater
 
|$2488
 
|-
 
|Labyrinth - Water Cycle
 
|$1BA6
 
|-
 
|Labyrinth - Conveyor Cycle
 
|$1BC6
 
|-
 
|Labyrinth - Conveyor Cycle Underwater
 
|$1BD8
 
|-
 
|Marble
 
|$24E8
 
|-
 
|Star Light
 
|$2548
 
|-
 
|Star Light lights
 
|$1C52
 
|-
 
|Spring Yard
 
|$25A8
 
|-
 
|Spring Yard - Cycle 1
 
|$1C76
 
|-
 
|Spring Yard - Cycle 2
 
|$1C96
 
|-
 
|Scrap Brain Act 1
 
|$2608
 
|-
 
|Scrap Brain Act 2/Final
 
|$2668
 
|-
 
|Scrap Brain Act 3
 
|$2748
 
|-
 
|Scrap Brain Act 3 - Sonic Underwater
 
|$2848
 
|-
 
|Scrap Brain Act 3 - Sonic Underwater (Alt)
 
|$27A8
 
|-
 
|Scrap Brain Act 3 - Underwater
 
|$27C8
 
|-
 
|Scrap Brain Act 1/Act 2 - Cycle 1
 
|$1D0A
 
|-
 
|Scrap Brain Act 1/Act 2 - Cycle 2
 
|$1D1A
 
|-
 
|Scrap Brain Act 1/Act 2 - Cycle 3
 
|$1D2A
 
|-
 
|Scrap Brain Act 1/Act 2 - Cycle 4
 
|$1D3A
 
|-
 
|Scrap Brain Act 1/Act 2 - Cycle 5
 
|$1D46
 
|-
 
|Scrap Brain Act 1/Act 2 - Cycle 6
 
|$1D56
 
|-
 
|Scrap Brain Act 1/Act 2 - Cycle 7
 
|$1D66
 
|-
 
|Scrap Brain Act 1/Act 2 - Cycle 8
 
|$1D86
 
|-
 
|Scrap Brain Act 2 - Cycle 1
 
|$1D90
 
|-
 
|Scrap Brain Act 2 - Cycle 2
 
|$1DA0
 
|-
 
|Scrap Brain Act 3 - Water Cycle
 
|$1BEA
 
|-
 
|Special Stage - Sonic
 
|$26C8
 
|-
 
|Special Stage No. 1
 
|$26E8
 
|-
 
|Special Stage No. 2
 
|$2708
 
|-
 
|Special Stage No. 3
 
|$2728
 
|-
 
|Special Stage Title Card
 
|$2868
 
|-
 
|Special Stage Cycle 1
 
|$4ACA
 
|-
 
|Special Stage Cycle 2
 
|$4B12
 
|-
 
|Special Stage Cycle 3
 
|$4B92
 
|-
 
|Continue - Sonic
 
|$28E8
 
|-
 
|Continue
 
|$2908
 
|-
 
|Ending - Sonic
 
|$2928
 
|-
 
|Ending
 
|$2948
 
|}
 
 
===Object Editing===
 
 
====Object Pointer List====
 
 
====Mappings Editing====
 
 
====Object Placement====
 
 
==RAM Hacking==
 
 
====Main System Memory Locations====
 
 
==== Sprite Status Table ====
 
The Sprite Status Table is located at RAM address $D000. Each entry is $40 bytes long. Here is a list of all the values for one entry in the SST:
 
 
{|border="1"
 
!Offset||Size||Description
 
|-
 
| $00 || byte || Object type
 
|-
 
| $01 || byte|| Action flags. The bitfield looks like this:
 
*Bit 0 is the horizontal mirror flag. If set, the object will be flipped on its horizontal axis.
 
*Bit 1 is the vertical mirror flag.
 
*Bit 2 is the coordinate system flag. If clear, the object will be positioned by absolute screen coordinates. This is used for things like the HUD and menu options. If set, the object will be positioned by the playfield coordinates, i.e. where it is in a level. Sonic uses both positioning systems.
 
*Bits 3, 4, and 5 are either unused, or their purpose is unknown.
 
*Bit 6 is not used in this game.
 
*Bit 7 is the draw object flag. It will be set if the object was onscreen when it came time to draw things. Otherwise, it is clear. There should be no reason to edit this flag, but it's good to know what it does.
 
|-
 
| $02 || word || Starting art block.
 
*First nybble: Palette line the sprite will use.
 
*Latter 3 nybbles: Starting art block in VRAM for which the object reads from. Multiply by $20 to get VRAM address; divide VRAM address by $20 to get this value.
 
|-
 
| $04 || long || Mappings offset
 
|-
 
| $08 || word || If the object is Sonic, this is the X playfield coordinate. Otherwise:
 
*If in playfield positioning mode, it is the X playfield coordinate.
 
*If in screen positioning mode, it is the X screen coordinate.
 
|-
 
| $0A || word || If the object is Sonic, this is the X screen coordinate. Otherwise:
 
*If in playfield positioning mode, it is unused.
 
*If in screen positioning mode, it's the Y screen coordinate.
 
|-
 
| $0C || word || If the object is Sonic, this is the Y playfield coordinate. Otherwise:
 
*If in playfield positioning mode, it is the Y playfield coordinate.
 
*If in screen positioning mode, it is unused.
 
|-
 
| $0E || word || If the object is Sonic, this is the Y screen coordinate. Otherwise:
 
*It's unused.
 
|-
 
| $10 || word || Horizontal (X) speed
 
|-
 
| $12 || word || Vertical (Y) speed
 
|-
 
|$14 || byte ||Potential speed (inertia).
 
|-
 
|$16 || byte ||Height/2
 
|-
 
|$17 || byte ||Width/2
 
|-
 
|$18 || byte ||Sprite priority (00 = front).
 
|-
 
|$19 || byte ||Width of the object, in pixels
 
|-
 
|$1A || byte ||Current animation frame to display. i.e, the frame currently being displayed on-screen, according to the animation script (currently parsed mappings frame, in other words).
 
|-
 
|$1B || byte ||Current frame in animation script. i.e, the frame entry IN the animation script being currently processed.
 
|-
 
|$1C || byte ||Animation number. When an animation ID is moved here, it's processed and displayed.
 
|-
 
|$1D || byte ||Restart animation flag (when $1D is not equal to $1C, animation restarts)
 
|-
 
|$1E || byte ||Animation frame duration (time until next frame).
 
|-
 
|$20 || byte ||Collision response bitfield. Tells what the object will do if hit by the character. The bitfield is in the format TTSS SSSS. TT is the type of collision - 00 is enemy, 01 increments the routine counter, 10 is harm, and 11 seems to be a special thing for the starpole. SSSSSS is the size, lifted from a lookup table in the collision response routine.
 
|-
 
|$21 || byte ||Custom collision property, for special interaction with Sonic. This is used by bosses, badniks, bumpers and other objects. The way in which this byte is used is different for each object. Bosses use this byte as a hit counter.
 
|-
 
|$22 || byte
 
|Object's orientation. $00 is normal, $01 is X flipped, $02 is Y flipped, and $03 is X-Y flipped. These values repeat until $FF. Note that this byte has a different meaning for Sonic (see below).
 
|-
 
|$23 || byte ||Respawn index reference number, used by badniks, rings and monitors. Each destroyable object is assigned an index number (01, 02, 03 etc.) which refers to a list at $FC00 in the RAM.
 
|-
 
|$24 || byte ||Routine counter.
 
|-
 
|$25 || byte ||Second routine counter. This is used for some of the more complicated objects.
 
|-
 
|$26 || word ||Angle.
 
|-
 
|$28 || byte ||Object subtype. For example, the current monitor selected. See the Object List above for values. Has a different meaning for Sonic.
 
|-
 
| $29-$3F || || Object's scratch RAM
 
|-
 
!colspan="3" | Object-specific variables
 
|-
 
!Offset||Size||Description
 
|-
 
|$22 || byte ||'''Sonic''': Special bitfield. Counting from the least significant bit:
 
{|border='1'
 
!Bit||Hex||Description
 
|-
 
|0||$01||Orientation. Clear is left and set is right.
 
|-
 
|1||$02||Set if Sonic is in the air (jump counts).
 
|-
 
|2||$04||Set if jumping or rolling.
 
|-
 
|3||$08||Set if Sonic isn't on the ground but shouldn't fall. (Usually when he is on a object that should stop him falling, like a platform or a bridge.)
 
|-
 
|4||$10||Set if jumping after rolling.
 
|-
 
|5||$20||Set if pushing something.
 
|-
 
|6||$40||Set if underwater.
 
|-
 
|7||$80||Unused.
 
|}
 
You can add the hex values together to use multiple settings at once. Also notice that the first 3 bits (0-2) are used in the character object as a second routine counter.
 
|-
 
| $28 || byte
 
| '''Sonic''': Seconds of air left. Usually $1E; it decrements every second while the player is underwater. Beeps on $18, $13, and $0E. Countdown starts on $0B.
 
|-
 
|$2B || byte
 
|'''Sonic''': Unused
 
|-
 
| $30-$31 || word
 
| '''Sonic''': Remaining invunerability time. Starts at $0078 after Sonic is hit, and seems to decrement every frame until it reaches $0000.
 
|-
 
|$32-$33 || word ||'''Sonic''': Remaining time of invincibility.
 
|-
 
|$34-$35 || word ||'''Sonic''': Remaining time of Speed Shoes.
 
|-
 
|$36 || byte ||'''Sonic''': Seems to be related with the collision block boundaries (this isn't a flag)
 
|-
 
|$37 || byte ||'''Sonic''': Seems to be related with the collision block boundaries (the opposite side of $36) (this isn't a flag)
 
|-
 
|$39 || byte ||'''Sonic''': Unused.
 
|-
 
|$3A-$3B || word
 
|'''Sonic''': Unused.
 
|-
 
|$3C || byte ||'''Sonic''': Set if jumping.
 
|-
 
!colspan="3" | Boss Variables
 
|-
 
!Offset||Size||Description
 
|-
 
| $21 || byte || Hit counter. Number of hits it takes to defeat a boss.
 
|-
 
| $30 || word || X position
 
|-
 
| $38 || word || Y position
 
|-
 
| $3E || byte || Number of times to flash when hit
 
|}
 
 
{{SCHGuides}}
 
{{SCHGuides}}
[[Category:Sonic_Community_Hacking_Guide]]
+
[[Category:Sonic Community Hacking Guide]]

Latest revision as of 15:52, 24 March 2020


Sonicretro-round.svg This short article is in need of work. You can help Sonic Retro by adding to it.


SCHG: Sonic the Hedgehog

This is the Sonic Community Hacking Guide for Sonic the Hedgehog. Originally based on Nemesis and saxman's guides, this document has grown to outclass those two documents in most ways, and is now preferred over the original guides (which were written three or four years ago with limited knowledge of the game's code). This is due to the updating of those documents to give them a living, breathing nature.

Contributors

(In alphabetical order; if you are a contributor and have worked on a specific part of the guide, feel free to note that.)



References


Sonic Community Hacking Guide
General
SonED2 Manual | Subroutine Equivalency List
Game-Specific
Sonic the Hedgehog (16-bit) | Sonic the Hedgehog (8-bit) | Sonic CD (prototype 510) | Sonic CD | Sonic CD (PC) | Sonic CD (2011) | Sonic 2 (Simon Wai prototype) | Sonic 2 (16-bit) | Sonic 2 (Master System) | Sonic 3 | Sonic 3 & Knuckles | Chaotix | Sonic Jam | Sonic Jam 6 | Sonic Adventure | Sonic Adventure DX: Director's Cut | Sonic Adventure DX: PC | Sonic Adventure (2010) | Sonic Adventure 2 | Sonic Adventure 2: Battle | Sonic Adventure 2 (PC) | Sonic Heroes | Sonic Riders | Sonic the Hedgehog (2006) | Sonic & Sega All-Stars Racing | Sonic Unleashed (Xbox 360/PS3) | Sonic Colours | Sonic Generations | Sonic Forces
Technical information
Sonic Eraser | Sonic 2 (Nick Arcade prototype) | Sonic CD (prototype; 1992-12-04) | Dr. Robotnik's Mean Bean Machine | Sonic Triple Trouble | Tails Adventures | Sonic Crackers | Sonic 3D: Flickies' Island | Sonic & Knuckles Collection | Sonic R | Sonic Shuffle | Sonic Advance | Sonic Advance 3 | Sonic Battle | Shadow the Hedgehog | Sonic Rush | Sonic Classic Collection | Sonic Free Riders | Sonic Lost World
Legacy Guides
The Nemesis Hacking Guides The Esrael Hacking Guides
ROM: Sonic 1 | Sonic 2 | Sonic 2 Beta | Sonic 3

Savestate: Sonic 1 | Sonic 2 Beta/Final | Sonic 3

Sonic 1 (English / Portuguese) | Sonic 2 Beta (English / Portuguese) | Sonic 2 and Knuckles (English / Portuguese)
Move to Sega Retro
Number Systems (or scrap) | Assembly Hacking Guide | 68000 Instruction Set | 68000 ASM-to-Hex Code Reference | SMPS Music Hacking Guide | Mega Drive technical information