Difference between revisions of "Sonic R/Technical information/Windows PC"
From Sonic Retro
GerbilSoft (talk | contribs) (→Fixing Startup Crash: Second value is supposed to be 0x01, not 0x31.) |
(Additional info) |
||
Line 143: | Line 143: | ||
| 0 | | 0 | ||
| Byte | | Byte | ||
− | | Difficulty | + | | Difficulty |
+ | * 00 - Easy | ||
+ | * 01 - Normal | ||
+ | * 02 - Hard | ||
|- | |- | ||
| 4 | | 4 | ||
| Byte | | Byte | ||
| Ghost Toggle | | Ghost Toggle | ||
+ | * 00 - Off | ||
+ | * 01 - On | ||
|- | |- | ||
| 8 | | 8 | ||
| Byte | | Byte | ||
| Weather | | Weather | ||
− | * | + | * 00 - Random |
− | * | + | * 01 - Clear |
− | * | + | * 02 - Rain |
− | * | + | * 03 - Snow |
|- | |- | ||
| C | | C | ||
| Byte | | Byte | ||
| Catch Up Toggle | | Catch Up Toggle | ||
+ | * 00 - Off | ||
+ | * 01 - On | ||
|- | |- | ||
| 10 | | 10 | ||
| Byte | | Byte | ||
| Guide Toggle | | Guide Toggle | ||
+ | * 00 - Off | ||
+ | * 01 - On | ||
|- | |- | ||
| 14 | | 14 | ||
| Byte | | Byte | ||
| Map Toggle | | Map Toggle | ||
+ | * 00 - Off | ||
+ | * 01 - On | ||
+ | |- | ||
+ | | 28 | ||
+ | | Byte | ||
+ | | Color | ||
+ | * 08 - 8-bit | ||
+ | * 10 - 16-bit | ||
|- | |- | ||
| 18 | | 18 | ||
| Byte | | Byte | ||
| 2P Split | | 2P Split | ||
− | * | + | * 00 - Horizontal |
− | * | + | * 01 - Vertical |
+ | |- | ||
+ | | 2C | ||
+ | | Byte | ||
+ | | Alpha Blending | ||
+ | * 00 - Off | ||
+ | * 01 - On | ||
+ | |- | ||
+ | | 34 | ||
+ | | Byte | ||
+ | | Interlace | ||
+ | * 00 - Off | ||
+ | * 01 - On | ||
|- | |- | ||
| 3C | | 3C | ||
| Byte | | Byte | ||
− | | Draw Distance | + | | Draw Distance |
+ | * 00 - Very Near | ||
+ | * 01 - Near | ||
+ | * 02 - Medium | ||
+ | * 03 - Far | ||
+ | * 04 - Very Far | ||
+ | * 10 - Max. Draw Distance | ||
|- | |- | ||
| 40 | | 40 | ||
| Byte | | Byte | ||
− | | Screen Size | + | | Screen Size |
+ | * 00 - Very Small | ||
+ | * 01 - Small | ||
+ | * 02 - Medium | ||
+ | * 03 - Large | ||
+ | * 04 - Full Screen | ||
+ | |- | ||
+ | | 44 | ||
+ | | Byte | ||
+ | | Track Shading | ||
+ | * 00 - Off | ||
+ | * 01 - On | ||
|- | |- | ||
| 50 | | 50 | ||
| Byte | | Byte | ||
| Stereo Toggle | | Stereo Toggle | ||
+ | * 00 - Off | ||
+ | * 01 - On | ||
|- | |- | ||
| 54 | | 54 | ||
| Byte | | Byte | ||
| Vocals Toggle | | Vocals Toggle | ||
+ | * 00 - Off | ||
+ | * 01 - On | ||
|- | |- | ||
| 58 | | 58 | ||
| Byte | | Byte | ||
− | | SFX Volume ( | + | | SFX Volume (00-08) |
|- | |- | ||
| 5C | | 5C | ||
| Byte | | Byte | ||
| Music Toggle | | Music Toggle | ||
+ | * 00 - Off | ||
+ | * 01 - On | ||
|} | |} | ||
{{SCHGuides}} | {{SCHGuides}} | ||
[[Category:Sonic Community Hacking Guide]] | [[Category:Sonic Community Hacking Guide]] |
Revision as of 17:26, 11 July 2013
This short article is in need of work. You can help Sonic Retro by adding to it. |
This is the Sonic Community Hacking Guide for the PC Version of Sonic R.
Fixing Startup Crash
Sonic R's startup code attempts to divide a value by the time elapsed for a given function. On reasonably fast computers (basically anything with a CPU newer than Pentium 4), this results in a division by zero. This can be fixed with a simple binary edit. [source](Note: This hack assumes you're using the original executable without network support. The network version doesn't seem to work on NT-based Windows systems to begin with.)
In a hex editor, go to offset 0x70584. Replace these bytes:
00070584: 2e ff 15 8c 05 95 00 call cs:[0x95058c]
with these bytes:
00070584: b8 31 00 00 00 mov eax, 0x31
00070589: 90 nop
0007058A: 90 nop
Next, go to offset 0x705A0. Replace these bytes:
000705A0: 2e ff 15 8c 05 95 00 call cs:[0x95058c]
with these bytes:
000705A0: b8 01 00 00 00 mov eax, 0x01
000705A5: 90 nop
000705A6: 90 nop
What this does is it disables the function calls to get the system time and replaces them with known values that are guaranteed to work on modern systems.
Save Files
These files can be found in the .\save directory with filenames in the format r##.sav
This is an incomplete listing of the locations inside these files:
Offset | Type | Description |
---|---|---|
4 | Byte | Resort Island Unlocked (def. 1)
|
8 | Byte | Radical City Unlocked (def. 1) |
C | Byte | Reactive Factory Unlocked (def. 1) |
10 | Byte | Regal Ruin Unlocked (def. 1) |
14 | Byte | Radiant Emerald Unlocked (def. 0) |
18 | Byte | Sonic Unlocked (def. 2)
|
1C | Byte | Tails Unlocked (def. 2) |
20 | Byte | Knuckles Unlocked (def. 2) |
24 | Byte | Amy Unlocked (def. 2) |
28 | Byte | Robotnik Unlocked (def. 1) |
2C | Byte | Metal Sonic Unlocked (def. 0) |
30 | Byte | Tails Doll Unlocked (def. 0) |
34 | Byte | Metal Knuckles Unlocked (def. 0) |
38 | Byte | Eggrobo Unlocked (def. 0) |
3C | Byte | Super Sonic Unlocked (def. 0) |
40 | Byte | Blue Emerald Collected
|
44 | Byte | Green Emerald Collected |
48 | Byte | Purple Emerald Collected |
4C | Byte | Yellow Emerald Collected |
50 | Byte | Orange Emerald Collected |
54 | Byte | Red Emerald Collected |
58 | Byte | White Emerald Collected |
sonicr.inf
This file, located in the main folder, stores various settings. Note that despite the extension inf, it is not an actual inf file, and should NOT be opened with Notepad.
Offset | Type | Description |
---|---|---|
0 | Byte | Difficulty
|
4 | Byte | Ghost Toggle
|
8 | Byte | Weather
|
C | Byte | Catch Up Toggle
|
10 | Byte | Guide Toggle
|
14 | Byte | Map Toggle
|
28 | Byte | Color
|
18 | Byte | 2P Split
|
2C | Byte | Alpha Blending
|
34 | Byte | Interlace
|
3C | Byte | Draw Distance
|
40 | Byte | Screen Size
|
44 | Byte | Track Shading
|
50 | Byte | Stereo Toggle
|
54 | Byte | Vocals Toggle
|
58 | Byte | SFX Volume (00-08) |
5C | Byte | Music Toggle
|