Code Monkey home page Code Monkey logo

cd-2011-decomp's Introduction

A complete decompilation of Retro Engine v3.

SUPPORT THE OFFICIAL RELEASE OF SONIC CD

  • Without assets from the official release, this decompilation will not run.

  • You can get an official release of Sonic CD from:

Even if your platform isn't supported by the official releases, you must buy or officially download it for the assets (you don't need to run the official release, you just need the game assets). Note that only FMV files from the original Steam release of the game are supported; mobile and Origins video files do not work.

Advantages over the PC version of Sonic CD

  • Sharp, pixel-perfect display.
  • Controls are completely remappable via the settings.ini file.
  • The window allows windows shortcuts to be used.
  • Complete support for using mobile/updated scripts, allowing for features the official PC version never got to be played on PC.
  • Native Windows x64 version, as well as an x86 version.

Advantages over the Mobile versions of Sonic CD

  • The rendering backend is based off the PC version by default, so palettes are fully supported (Tidal Tempest water in particular).

Additional Tweaks

  • Added a built in mod loader and API, allowing to easily create and play mods with features such as save file redirection and XML GameConfig data.
  • There is now a settings.ini file that the game uses to load all settings, similar to Sonic Mania.
  • The dev menu can now be accessed from anywhere by pressing the ESC key if enabled in the config.
  • The F12 pause, F11 step over & fast forward debug features from Sonic Mania have all been ported and are enabled if devMenu is enabled in the config.
  • A number of additional dev menu debug features have been added:
    • F1 will load the first scene in the Presentation stage list (usually the title screen).
    • F2 and F3 will load the previous and next scene in the current stage list.
    • F5 will reload the current scene, as well as all assets and scripts.
    • F8 and F9 will visualize touch screen and object hitboxes.
    • F10 will activate a palette overlay that shows the game's 8 internal palettes in real time.
  • If useSteamDir is set in the config (Windows only), the game will try to load savedata from Steam's userdata directory (where the original Steam version saves to).
  • Added the idle screen dimming feature from Sonic Mania Plus, as well as allowing the user to disable it or set how long it takes for the screen to dim.

How to build

Windows

  • Clone the repo, then follow the instructions in the dependencies readme for Windows to setup dependencies, then build via the visual studio solution.
  • Alternatively, you can grab a prebuilt executable from the releases section.

Windows via MSYS2 (64-bit only)

  • Download the newest version of the MSYS2 installer from here and install it.
  • Run the MINGW64 prompt (from the windows Start Menu/MSYS2 64-bit/MSYS2 MinGW 64-bit), when the program starts enter pacman -Syuu in the prompt and hit Enter.
  • Press Y when it asks if you want to update packages. If it asks you to close the prompt, do so, then restart it and run the same command again. This updates the packages to their latest versions.
  • Install the dependencies with the following command: pacman -S pkg-config make git mingw-w64-x86_64-gcc mingw-w64-x86_64-SDL2 mingw-w64-x86_64-libogg mingw-w64-x86_64-libvorbis mingw-w64-x86_64-libtheora mingw-w64-x86_64-glew
  • Clone the repo with the following command: git clone --recursive https://github.com/Rubberduckycooly/Sonic-CD-11-Decompilation.git
  • Go into the repo you just cloned with cd Sonic-CD-11-Decompilation.
  • Run make -f Makefile.msys2 CXXFLAGS=-O2 CXX=x86_64-w64-mingw32-g++ STATIC=1 -j5.
    • The CXXFLAGS option can be removed if you do not want optimizations.
    • -j switch is optional, but will make building faster by running it parallel on multiple cores (8 cores would be -j9).

Windows UWP (Phone, Xbox, etc.)

  • Clone the repo, then follow the instructions in the dependencies readme for Windows and dependencies readme for UWP to setup dependencies.
  • Copy your Data.rsdk file and videos folder into RSDKv3UWP, then build and deploy via RSDKv3.UWP.sln.
  • You may also need to generate visual assets, to do so, open the Package.appxmanifest file in the designer, under the Visual Assets tab, select an image of your choice and click generate.

Mac

Linux

  • To setup your build enviroment and library dependecies, run the following commands:
    • Ubuntu (Mint, Pop!_OS, etc...): sudo apt install build-essential git libsdl2-dev libvorbis-dev libogg-dev libtheora-dev libglew-dev
      • If you're using Debian, add libgbm-dev and libdrm-dev.
    • Fedora Linux: sudo dnf install g++ SDL2-devel libvorbis-devel libogg-devel libtheora-devel glew-devel
    • Arch Linux: sudo pacman -S base-devel git sdl2 libvorbis libogg libtheora glew
  • Clone the repo with the following command: git clone --recursive https://github.com/Rubberduckycooly/Sonic-CD-11-Decompilation.git
  • Go into the repo you just cloned with cd Sonic-CD-11-Decompilation.
  • Run make CXXFLAGS=-O2 -j5.
    • If your distro is using gcc 8.x.x, then add the argument LIBS=-lstdc++fs.
    • The CXXFLAGS option can be removed if you do not want optimizations.
    • -j switch is optional, but will make building faster by running it parallel on multiple cores (8 cores would be -j9).

iOS

Android

  • Clone the repo, then follow the instructions in the dependencies readme for Android.
  • Ensure the symbolic links in android/app/jni are correct. If not, fix them with the following on Windows:
    • mklink /D src ..\..\..
    • mklink /D SDL ..\..\..\dependencies\android\SDL
  • Open android/ in Android Studio, install the NDK and everything else that it asks for, and build.

PlayStation Vita

  • Ensure you have Docker installed and run the script build.sh from RSDKv3.vita. If you are on Windows, WSL2 is recommended.
    • NOTE: You would need to copy Sonic CD game data into ux0:data/RSDKv3 to boot the game.

Unofficial Branches

Follow the installation instructions in the readme of each branch.

Because these branches are unofficial, we can't provide support for them and they may not be up-to-date.

Other Platforms

Currently the only supported platforms are the ones listed above, however the backend uses libogg, libvorbis, libtheora & SDL2 to power it (as well as tinyxml2 for the mod API), so the codebase is very multiplatform. If you're able to, you can clone this repo and port it to a platform not on the list.

FAQ

You can find the FAQ here.

Special Thanks

  • Xeeynamo: for creating the RSDK Animation editor & an early version of the script unpacker, both of which got me into RSDK modding.
  • Sappharad: for making a decompilation of the Windows Phone 7 version of Sonic CD (found here) which gave me the idea & motivation to decompile the PC/iOS/Android versions.
  • SuperSonic16: for creating & adding some stuff to the Sonic CD mod loader that I asked for.
  • The Weigman for creating the header you see up here along with similar assets.
  • Everyone in the Retro Engine Modding Server for being supportive of me and for giving me a place to show off these things that I've found.

Contact:

Join the Retro Engine Modding Discord Server for any extra questions you may need to know about the decompilation or modding it.

cd-2011-decomp's People

Contributors

arclightmat avatar chunkyjackson avatar clownacy avatar consoleskunk avatar deepfriedfilth avatar fjtrujy avatar geffdev avatar idah00 avatar isage avatar kekun avatar leonx254 avatar lethal-guitar avatar luluco250 avatar mapz94 avatar mefiresu avatar megami24 avatar nextvolume avatar rubberduckycooly avatar shoptalky avatar steelt1 avatar stxticovfl avatar tatokis avatar theagamer554 avatar theweigman avatar torutheredfox avatar tunip3 avatar tydevx avatar vanfanel avatar wamwoowam avatar xeeynamo avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.