Homebrew [WIP] re3 3ds port

  • Thread starter AJM
  • Start date
  • Views 131,052
  • Replies 156
  • Likes 47

AJM

New Member
OP
Newbie
Joined
Apr 6, 2021
Messages
1
Trophies
0
XP
223
Country
Canada
Intro

This is a WIP port of the re3 project to nintendo 3ds.
Only new 3ds is supported. An old 3ds port might be possible but I'm not going to try.
This release is more suited for developers as I haven't really made anything convenient or easy.

There are four seperate 3dsx files:
re3.3dsx, re3-stereo.3dsx,
re3-txd.3dsx, re3-stereo-txd.3dsx.

bonus files:
miami.3ds miami-stereo.3dsx.

The re3-*-txd builds do texture compression on your 3DS and generate a TXD.IMG / TXD.DIR.
The vanilla builds re3.3dsx, re3-stereo.3dsx assume you have converted the game files to a native format using txdcnv (provided).
The miami.3ds files haven't really been tested in a while and they only do texture conversion on the 3ds (might take literally a day lmao).

There is no CIA version.

GTA3 has reached a certain level of stability that it worth sharing, however consider this an alpha WIP.
Vice City is also working, but has more serious bugs.

Caveats/Bugs (many)
  • Menus and loading screens are blurry (easy fix but its not important).
  • Fonts are fucked due to mip-map generation. This is a recent regression from implementing txdcnv.
  • Material FX environment mapping isn't accurate. Cars are very shiny. Shinier than the mobile port :DDD.
  • Dynamic lighting (directional lights) is broken. I think it has to due with floating point accuracy. This has driven me crazy and I've almost given up as it works with every test program I write.
  • Skinned geometry is jagged / glitchy, I suspect it has to do with floating point accuracy. Looks pretty funny though.
  • There is a black roads glitch, which I presume has to do with blending.
  • MP3 playback slows things down (the audio thread runs on the primary app-core).
  • pager/text messaging is unreadable.
  • bottom screen is not in use... yet.
  • I've only play-tested the first third of the game.
Install:

Prerequisites:
you will need to be able to read instructions.
you will need the PC version of GTA III. (other versions might work).

Procedure:
Texture conversion:
You need to use txdcnv to convert the game files to native formats.
Create a directory for the output files.
I have only built txdcnv for Linux x86-64, sorry about that, you will have to use re3-txd.3dsx or compile from source.

./txdcnv [gta3 root] [output root].

The [output root] will now look like:
.:
models txd

./models:
fonts.txd generic.txd gta3.img menu.txd particle.txd
frontend.txd gta3.DIR hud.txd MISC.TXD

./txd:
LOADSC0.TXD LOADSC15.TXD LOADSC20.TXD LOADSC2.TXD LOADSC8.TXD SPLASH2.TXD
LOADSC10.TXD LOADSC16.TXD LOADSC21.TXD LOADSC3.TXD LOADSC9.TXD SPLASH3.TXD
LOADSC11.TXD LOADSC17.TXD LOADSC22.TXD LOADSC4.TXD mainsc1.txd
LOADSC12.TXD LOADSC18.TXD LOADSC23.TXD LOADSC5.TXD mainsc2.txd
LOADSC13.TXD LOADSC19.TXD LOADSC24.TXD LOADSC6.TXD NEWS.TXD
LOADSC14.TXD LOADSC1.TXD LOADSC25.TXD LOADSC7.TXD SPLASH1.TXD

Mipmaps are actually 100% necessary.
They drastically improve performance and memory management.
Older versions did this on the 3ds but it took too long.

Updating game directory

You will overwrite the files in [Game root] with these modified files.
Copy the files from [Output root] to [Game root].
From (this archive) src/gamefiles copy "data" and "TEXT" to the [Output root].
This will overwrite PARTICLE.CFG and various GXT files.

3ds File system
The game files are stored in a hard-coded directory on your 3ds.
Create the directory 'sdmc:/3ds/re3'. (or sdmc:/3ds/miami for VC)

You can copy the contents of [Game root] to /3ds/re3,
but if your a bit more OCD you only need the following directories:

sdmc:/3ds/re3/anim
sdmc:/3ds/re3/audio
sdmc:/3ds/re3/data
sdmc:/3ds/re3/models
sdmc:/3ds/re3/mp3
sdmc:/3ds/re3/skins
sdmc:/3ds/re3/txd

Music files
Copy .wav|.mp3 to sdmc:/3ds/re3/mp3.
Sorry .ogg isn't supported, but would be very easy to enable.

Install 3dsx

Copy re3.3dsx and re3-stereo.3dsx to sdmc:/3ds/ (or anywhere really).
Launch with Homebrew launcher.

To access the Free-Roam script hold [L, R, dpad-up] in the main menu.
To access the Debug script hold [L, R, dpad-down] in the main menu.
To access the debug menu in-game hold [L, R, dpad-down], then use the touch screen.

Building:
You only need devkitpro / devkitARM.
The Makefile has only been tested on linux (devuan beowulf), but it should work on mingw/msys or cygwin.
I've included all the libraries because devkitpro is a rolling release and I can't
assume that future versions of the libraries won't break the build. Its a pain to manually
check-out each specific version of each library. I have enough trouble with my own regressions.

Make sure you environment has DEVKITPRO / DEVKITARM.
$ . /etc/profile.d/devkit-env.sh
$ cd re3/build
$ make

or for stereo set STEREO in your env.

$ STEREO=1 make

make upload sends to hb-menu.
make debug call gdb and connects to 10.0.0.2.

Misc notes:
I'm a bit ashamed by my misuse of git.
I haven't committed anything yet and all the new stuff is untracked.
A good starting point for customization is in src/core/config.h.
If you want to enable online texture compression enable TXD_USE_CDIMAGE.
There are two versions of librw in vendor for mono and stereo rendering respectively.
3ds platform specific code is at src/skel/3ds.
I can't make any promises on updates, I had to force myself to make this release and I'm getting burnt out and need a break.
You should probably build from source, I haven't got the time to test the binaries and I keep making big regressions every time I improve something.

LICENSE? REDISTRIBUTING?
I dunno, the re3 team seems to re3 as public domain(?), but the libraries are GPL.
Feel free to share wherever but I request that if you distribute the source code as well.
At the very least please provide librw's source code, nobody will sue you for that.

DOWNLOAD
3DSX: https://mega.nz/file/bd0gyAJZ#3z92A6nL9ZFrjsBfIC7KRmLgL7F0_eKv50SqPNVmfAg
SOURCE: https://mega.nz/file/bF1UUSoL#S6Eby9ooGC4R6RHCD8zubykULZARnPl0rTyCplrbH-c
 
Last edited by Flame,

MrHuu

Well-Known Member
Member
Joined
Sep 19, 2015
Messages
575
Trophies
1
Age
38
XP
1,663
Country
Netherlands
Nice! Runs pretty well on my end.

Everything is quite blurry, but the framerate is definitely good most of the time.

I do get a lot of missing textures, with their placeholder 'missing'. Only seems to be text related.

Thanks for working on this and sharing. Take your time and don't let these projects burn you out. Great achievement so far!

Edit:
Running 'txdcnv' on the steam version of vice city produces an error? I am supposed to do that right?
 
Last edited by MrHuu,

MrHuu

Well-Known Member
Member
Joined
Sep 19, 2015
Messages
575
Trophies
1
Age
38
XP
1,663
Country
Netherlands
do you need to run txdcnv?

No, its not required. You can do this process on your 3ds itself. (run 're3-txd.3dsx' instead of re3.3dsx)
It will however take hours to complete, while running it on your pc only takes 15~20 minutes.

For Vice City (miami) 'txdcnv' does not work, and the only option is to do this on your 3ds.

Edit:
Here's a re3 icon. Drop it next to 're3.3dsx'.
 

Attachments

  • re3_smdh.7z
    1.3 KB · Views: 908
Last edited by MrHuu,

E1ite007

wierd avatar guy
Member
Joined
Nov 19, 2016
Messages
1,051
Trophies
1
Location
Itchy & Scratchy Land
XP
3,023
Country
Mexico
It looks neat tbh.
Here is a picture of how it looks on an XL model:

vMizOTH.jpg

If anyone is wondering, you can convert the txdcnv textures with Windows 10 Ubuntu's subsystem and works flawless.

EDIT: Here's a video of how it runs:

 
Last edited by E1ite007,

Moon164

Well-Known Member
Member
Joined
Nov 21, 2015
Messages
868
Trophies
0
Age
26
XP
3,084
Country
Brazil
It's a shame that it doesn't work on the Old 3DS, but I think it was expected, it's still pretty impressive to see a game of that scale on the 3DS.
 

danielglzt88

Member
Newcomer
Joined
Jan 19, 2021
Messages
20
Trophies
0
Age
36
XP
249
Country
Cuba
fantastic, although there are other priorities, it would be wonderful if you could add the 3d stereoscopic. but it is excellent work, I was a little envious to see gta ports on other platforms and not in the excellent new 3ds.
 

DodgyJudge

A man of weird taste it seems!
Member
Joined
Jun 12, 2018
Messages
172
Trophies
0
Age
37
XP
2,084
Country
Trinidad and Tobago
Well i don't want to be an ass but it is not working link for me and i used 2 decrypt64 site and why is it encrypted just post the damn link? I mean there is no need to do that and please open a github page so we can post bug related stuff there so it get more widespread to people.
 

Site & Scene News

Popular threads in this forum

General chit-chat
Help Users
  • BigOnYa @ BigOnYa:
    No I am not. You are part of our community now. We tease sometimes, you and everybody, but that only means we love you. :wub:
    +2
  • SylverReZ @ SylverReZ:
    BigOnYa's right y'know.
    +2
  • SylverReZ @ SylverReZ:
    I understand you not getting the feeling of not understanding sarcasm or jokes at times.
    +1
  • SylverReZ @ SylverReZ:
    Just have a laugh and everyone is happy, like me. :D
    +2
  • Xdqwerty @ Xdqwerty:
    @SylverReZ, I do laugh sometimes but Im still depressed
  • SylverReZ @ SylverReZ:
    @Xdqwerty, A lot of teens do feel depressed at that age, when you grow older you'll start to get out of that stage.
  • SylverReZ @ SylverReZ:
    Just make sure you try to balance yourself, find ways to go without the internet and do other things.
  • Xdqwerty @ Xdqwerty:
    @SylverReZ, I don't think i'll ever get proper help ever
  • SylverReZ @ SylverReZ:
    That's up to you or your parents to make that decision, not mine.
  • Xdqwerty @ Xdqwerty:
    @SylverReZ, I never said it was yours
  • K3Nv2 @ K3Nv2:
    It's more so about taking the internet too seriously you gotta balance personal details off of it more often could do more harm than good
    +3
  • SylverReZ @ SylverReZ:
    I agree.
  • Xdqwerty @ Xdqwerty:
    Ok I have to sleep, it's too late
  • Xdqwerty @ Xdqwerty:
    Good night
    +1
  • SylverReZ @ SylverReZ:
    The internet is different to what it is in real life.
    +1
  • SylverReZ @ SylverReZ:
    You just got to be extremely careful with what you give out.
    +1
  • Xdqwerty @ Xdqwerty:
    I should stop going to sleep this late when being at my dad's house...
  • K3Nv2 @ K3Nv2:
    It's true you can get laid on the internet but don't be like psi and let every transit know your home address
    +1
  • BigOnYa @ BigOnYa:
    Does he happen to have a cable tv box with a key slot on the back of it?
  • K3Nv2 @ K3Nv2:
    Got some of these today yah good good Deutsche Kche Doppel Keks https://www.instacart.com/products/19763204
    +1
  • SylverReZ @ SylverReZ:
    @K3Nv2, I've ordered Maryland Triple Choc cookies, they're actually very good.
  • K3Nv2 @ K3Nv2:
    One thing Hitler got right?
    K3Nv2 @ K3Nv2: One thing Hitler got right?