don't click here

Random Hack/Mini Project Thread

Discussion in 'Engineering & Reverse Engineering' started by Malevolence, Jul 4, 2009.

  1. kazblox

    kazblox

    Member
    178
    27
    28
    Diassemblies and decompilations.
    Damnit, someone else has already proved my idea possible! How do infinite looping levels work by the way, does it involve a huge rewrite in the level engine with chunks being overwritten on the fly?
     
  2. AURORA☆FIELDS

    AURORA☆FIELDS

    The cute one here Tech Member
    216
    24
    18
    Finland
    AMPS
    More or less just changing the level position, and moving all the necessary objects (aka those which you could see on screen later on the loop again, and players), and you are usually set. Sometimes you may need to load the tiles in, but to give correct looping effect that should not be necessary.
     
  3. DigitalDuck

    DigitalDuck

    Arriving four years late. Member
    5,456
    504
    93
    Lincs, UK
    TurBoa, S1RL
    Well, in the actual level I am overwriting chunks on the fly. The level's composed of a number of $800x$400 (or 16x8 128px chunks) which are loaded in (eventually a random) order. The game only keeps the previous, current, and next section in memory at any time (although deleting sections isn't working properly and I need to fix that - I'm fairly sure that's the cause for objects failing to load). Object positions are added as necessary to put them in the right place, and then when the camera reaches $3100 I'm subtracting $2000 from the camera, Sonic's position, and all objects. I'm also doing the same thing in reverse when the camera reaches $F00 by adding everything again. (Plus some DLE management.)

    The boss section does it the boring way, though - it's just a layout with teleporting objects, the same way S3K did a few of its bosses.


    If all you want is an infinite looping level, you don't need to do much - the engine is already capable of doing this in the Y direction, after all! It's just teleportation yeah, waaaah zabadoobapbap!
     
  4. RetroKoH

    RetroKoH

    Member
    1,734
    112
    43
    S1Fixed: A successor to ReadySonic
    Having done something similar for a Sketchhog hack a while back, I'd say I personally prefer the Double Jump. I think the Triple Jump is overkill... just my opinion though.
     
  5. DigitalDuck

    DigitalDuck

    Arriving four years late. Member
    5,456
    504
    93
    Lincs, UK
    TurBoa, S1RL
    Yeah, that's what I was thinking.
     
  6. MainMemory

    MainMemory

    Has-Been Modder Tech Member
    4,809
    398
    63
    Myself
    You didn't happen to reverse engineer the data formats while you were doing whatever voodoo magic you use to do all these things did you? But really, that sounds very nice, even nicer if there's something similar for Sonic R. We could finally have all the Windows Sonic games working on Vista+!
     
  7. Korama

    Korama

    Tech Member
    272
    2
    0
    I haven't really looked at the data formats, beyond the PCX/PIC and LBM image files.
    A while ago, I managed to run Sonic R with DXWnd2, but only as a window and in DirectDraw mode. Apart from that, I haven't looked into that game yet.
    But I have Sonic CD 1996 working perfectly again. :v:
     
  8. RetroKoH

    RetroKoH

    Member
    1,734
    112
    43
    S1Fixed: A successor to ReadySonic
    I'd love you to share your secrets if it meant getting SK Collection working
     
  9. MainMemory

    MainMemory

    Has-Been Modder Tech Member
    4,809
    398
    63
    Myself
    Last I checked, Sonic & Knuckles Collection was the only pre-SADX Sonic game that still worked perfectly in modern versions of Windows.
     
  10. Covarr

    Covarr

    Sentient Cash Register Member
    4,233
    3
    18
    Trapped in my own thoughts.
    Two stageplays, a screenplay, and an album
    After you patch it to fix the framerate problems.
     
  11. MainMemory

    MainMemory

    Has-Been Modder Tech Member
    4,809
    398
    63
    Myself
  12. Korama

    Korama

    Tech Member
    272
    2
    0
    It's not a secret or anything you can easily apply to the game yourself. It's just a piece of software. I'm currently working on a GUI for the settings, once that's done I'll release it here.

    Yeah, the programmer(s) made a smart choice. In windowed mode, if the current video mode isn't 8 bit, the game does not use DirectDraw but renders to a DIB section (memory bitmap). That nicely avoids a couple of problems. However, the game also does not use Vsync that way, which results in a somewhat jerky frame rate, at least on my PC.
    I basically wrote a DirectDraw emulator that internally uses DIB sections as well, and I do use Vsync for smooth frame rates (on 60 Hz monitors).

    The wiki is apparently missing one "secret" INI file setting: MIDIFlag (default is "1"). If it's 1, the game will first try to load midiout.dll, and if that fails, it'll try bgm.dll; vice versa for MIDIFlag=0. Makes you wonder if they had planned an alternate music playback method. The game was never shipped with a bgm.dll, as far as I know. Luckily there's smpsout.dll now!
     
  13. MainMemory

    MainMemory

    Has-Been Modder Tech Member
    4,809
    398
    63
    Myself
    The game does still enable DirectDraw for a moment, which is annoying because it forces the display mode to change to 16bpp and back, causing a momentary black screen. I tried poking around the code in the disassembly, but I have no idea what it's actually doing or how to make it not do it.

    I did notice the MIDIFlag setting when I was making SMPSOUT, but it's kind of useless...
     
  14. Selbi

    Selbi

    The Euphonic Mess Tech Member
    1,535
    149
    43
    Northern Germany
    Sonic ERaZor
    Inspired by MegaGWolf's most recent Sonic Hack Showcase of Sonic 1 Painto Edition 2, I present to you:

    Sonic 1 - The Enhanced Special Stage Experience

    [​IMG]

    This was created using Mercury's ReadySonic kit.

    (A little last-minute, I know, but I wanted to get this out.)
     
  15. AURORA☆FIELDS

    AURORA☆FIELDS

    The cute one here Tech Member
    216
    24
    18
    Finland
    AMPS
    This is probably the best hack of 2016!
     
  16. Hitaxas

    Hitaxas

    Retro 80's themed Twitch streamer ( on hiatus) Member
    A hack that is so good it's the best of hack of next year?! =P

    It's fun, I'll give it that great way to blow some time.
     
  17. What's the big deal? It's a version of Sonic 1 where I can actually get all the Emeralds.
     
  18. VAdaPEGA

    VAdaPEGA

    Freelance Digital Artist Member
    80
    23
    8
    Portugal
    Probably something minimalistic
  19. Selbi

    Selbi

    The Euphonic Mess Tech Member
    1,535
    149
    43
    Northern Germany
    Sonic ERaZor
    Not extended, but a completely new hack. I literally didn't know anything about Cinossu's thing before I published my one. They were spawned from the same idea though, so I guess there's that. :v:
     
  20. MarkeyJester

    MarkeyJester

    You smash your heart against the rocks Resident Jester
    2,301
    556
    93
    Japan