Homebrew [Release] (A newer) Sonic CD (2011) 3DS Port

legaiaflame

Well-Known Member
Newcomer
Joined
Nov 21, 2008
Messages
86
Trophies
1
XP
1,011
Country
United States
How to compress the Sonic CD video files with ffmpeg:


For New 3DS:
(See bottom of page on how to convert Old 3DS)

For FMV playback, copy the videos/ folder from the original Steam release to sdmc:/3ds/SonicCD/.
To ensure the best playback performance, scale down the OGV files to 400x240 using ffmpeg:

But, you might notice that when you try to open ffmpeg it won't open as a software program but flashes for a second on the screen. This is normal and it's not Windows Defender or your computer blocking the program. This is because ffmpeg is command line program and does not have a graphical UI. But, don't worry there is a very simple process you can set up to convert the videos easily using notepad. Follow these directions as follows:



1. Create a new folder on your desktop.

2. Drop FFMPEG.exe into that folder.

3. Drop the first Sonic CD movie file into the folder you want to compress first.

4. Open Notepad and type CMD

5. Save the file as Open_commandline.bat in the folder.

6. Now, double-clicking that batch file will open a windows command prompt for you.

7. Now, in that command prompt, you can try invoking FFMPEG to do something to the file, such as using a special command line to convert the videos. For instance:


So now we copy and paste the first Sonic CD video file name and replace the input.ogv and output.ovg of the command line below with the first Sonic CD video file name:


For Example, this is the original command line:

ffmpeg -i input.ogv -s 400x240 -c:v libtheora -q:v 7 -c:a libvorbis -q:a 4 output.ogv


So again, put the first video file name (example: Bad_Ending.ogv) into the command line for "input.ovg" and "output.ogv". But for the output.ogv change the name to something like newBad_Ending.ogv. Or the file won't compress.


Example (With the video file name inserted properly):

ffmpeg -i Bad_Ending.ogv -s 400x240 -c:v libtheora -q:v 7 -c:a libvorbis -q:a 4 newBad_Ending.ogv


Then hit enter and it will compress the video. Your new compressed video will be inside the folder. So, then just delete the old video file and take the "new" off of the new compressed video name, to return the file back to its original name. Do this for the rest of the video files and you're all set!

NOTE: It helps to open up a new Notepad screen and paste the command line into there as you make your changes for each video file. Then, once the changes for each video are made to the command line, copy the command line, open up Open_commandline.bat and right click it in and hit enter to compress each video.

For Original 3DS:

Use this code line to convert the videos even further to 200x120 so they play properly on Old 3DS and repeat the steps above:

ffmpeg -i input.ogv -s 200x120 -c:v libtheora -q:v 7 -c:a libvorbis -q:a 4 output.ogv
 
Last edited by legaiaflame,
  • Like
Reactions: raxadian

legaiaflame

Well-Known Member
Newcomer
Joined
Nov 21, 2008
Messages
86
Trophies
1
XP
1,011
Country
United States
Got lyrics back in the videos, using the mod below. But only the Japanese lyrics work. You have to take the videos and convert them again though using the ffmpeg/the tutorial I posted above and then replace the videos in the videos folder again. The U.S. Sonic Boom lyrics do play at the title screen though. Can anyone get both lyrics U.S. and Japanese working? Or is there another mod I don't know about?

https://gamebanana.com/mods/463942
 
Last edited by legaiaflame,

EnergyFocus

New Member
Newbie
Joined
Feb 7, 2025
Messages
2
Trophies
0
XP
5
Country
United States
Thought you may want to know that using the decompiled scripts and setting TxtScripts=true as recommended on the github page will cause your port's unique menu elements to disappear and breaks functionality for the settings menu entirely.

Also, disabling vsync will prevent launching. I would report these as bugs on github, but there's no issues page set up there so I'll share here instead. The binds are a little awkward; B pauses (which is to be expected), but only A and Y jump, X does nothing as far as I can tell, and start doesn't pause. I'm always afraid I will accidentally press select during gameplay and open the dev menu, which boots to the main menu. Maybe this could be moved to L+R like virtual console games?

As far as the newly added mod support goes, so far I have tried both Classic CD Tweaks and CD-Restored (with and without its existing 3ds compatibility version), with no success. I suspect this is in part due to the issues with the decompiled scripts.

I can hardly complain though, it feels like a minor miracle that projects like this exist at all, and this port runs far better than the previous one did :)
 
  • Like
Reactions: raxadian

Voxel

Well-Known Member
OP
Newcomer
Joined
Aug 9, 2015
Messages
55
Trophies
0
Location
E1M1
XP
1,057
Country
Antarctica
It seems like the decompiled scripts causing the settings menu to break also happens on the original decomp as well, so you'll have to take that up with them on their repo.

As for vsync, I haven't tried disabling it before because there's no point. There's no way to disable vsync in Citro3D (the graphics API used), thus vsync is always left on by default in the ini file. Are you getting slowdowns? The main game should maintain 60fps, unless there's some resource-heavy mods out there?

I believe the awkward binds are just the original behaviour of the mobile version of the game. The decompiled scripts should remedy this by binding pause back to the START button, and jumping/spindashing back to A/B/Y. You also have the option to rebind controls in the ini file using bit values taken from libctru. Are these not working at all?
 

legaiaflame

Well-Known Member
Newcomer
Joined
Nov 21, 2008
Messages
86
Trophies
1
XP
1,011
Country
United States
It seems like the decompiled scripts causing the settings menu to break also happens on the original decomp as well, so you'll have to take that up with them on their repo.

As for vsync, I haven't tried disabling it before because there's no point. There's no way to disable vsync in Citro3D (the graphics API used), thus vsync is always left on by default in the ini file. Are you getting slowdowns? The main game should maintain 60fps, unless there's some resource-heavy mods out there?

I believe the awkward binds are just the original behaviour of the mobile version of the game. The decompiled scripts should remedy this by binding pause back to the START button, and jumping/spindashing back to A/B/Y. You also have the option to rebind controls in the ini file using bit values taken from libctru. Are these not working at all?

I can confirm using both Old3DS and New3DS, Mobile version of sonic cd data.rsdk, with the unaltered base version of V.1.2.0 and no mods (only video alterations) using the Scripts, START button pauses the game (not B) and jumping/spindashing work with A/B/Y. And I have TxtScripts=true.

But, like Voxel and EnergyFocus said, the only thing I noticed is the "Help and Options" menu doesn't work though. As if you select any of those options it doesn't load anything up. But, I'd assume if you don't use the Scripts like EnergyFocus is doing with not putting TxtScripts=true the controls are going to revert back to B pauses and A and Y jumping.

But with how fantasic the mod already is, I think I can live without the "Help and Options" menu.

 
Last edited by legaiaflame,

EnergyFocus

New Member
Newbie
Joined
Feb 7, 2025
Messages
2
Trophies
0
XP
5
Country
United States
What unique menu elements disappear? And what do you mean by functionality breaking?
Off the top of my head, the intro movie option in the main menu is gone, the help & options menu is broken (as you mentioned) and reverts to its normal options without the option to open the dev menu (which is present without the decompiled scripts), and the in-game pause menu is reverted to its original form (again missing the dev menu option that the base port contains). There may be more that I missed, though.

These are minor issues at worst, the gameplay runs with very little issue in gameplay as far as I can tell. The only thing that may elevate the help & options issue is the inability to switch between genesis and original spindash modes, as this is also tied to the speed cap (crucial for some zones but especially air control in Collision Chaos) and extended camera. Genesis spindash is enabled by default so if someone doesn't change these settings in-game before installing the decompiled scripts they will be locked out of the intended physics behavior of the game.

But, I'd assume if you don't use the Scripts like EnergyFocus is doing with not putting TxtScripts=true the controls are going to revert back to B pauses and A and Y jumping.
Yes, without using the decompiled scripts this is all true. I didn't take note of the rest of the controls until after I had removed the decompiled scripts and set TxtScripts=false, so whatever I'm saying doesn't apply to the port + decompiled scripts. The port runs just fine for me without the decompiled scripts and maintains more functionality so I'm content with that for now.

As for vsync, I haven't tried disabling it before because there's no point. There's no way to disable vsync in Citro3D (the graphics API used), thus vsync is always left on by default in the ini file. Are you getting slowdowns? The main game should maintain 60fps, unless there's some resource-heavy mods out there?
I had no reason for disabling vsync, just did so out of habit. I didn't notice any slowdown, only minor hitching when power-ups begin and end which i didn't find disruptive.

You also have the option to rebind controls in the ini file using bit values taken from libctru. Are these not working at all?
I didn't try to mess with the controls in the ini file since I didn't recognize any of the values. But this is very useful information. I'll give this a try sometime soon and report back.
 

tailssegau

New Member
Newbie
Joined
Feb 12, 2025
Messages
1
Trophies
0
Age
13
XP
2
Country
United States
  • Hi, I need help, I installed this though the qr code and I have a data.rsdk but it's just showing me a glitchy screen, Please help me as I'm dumb (using O3ds)
 
Last edited by tailssegau,

Site & Scene News

Popular threads in this forum

General chit-chat
Help Users
  • No one is chatting at the moment.
    _Ruri_ @ _Ruri_: @Xdqwerty, Thank you 👍 +1