ROM Hack [WIP] The Fourth Dimension: A Super Mario 3D land level editor

exelix11

Developer
OP
Developer
Joined
Feb 25, 2015
Messages
915
Trophies
1
Location
C:\users\exelix11\
XP
3,062
Country
Italy
Hey exelix
Is it possible to do an edit that makes us able to test custom levels faster :P like an edit combined with citra ?
I already tried, but building the romfs is just too slow, the best thing would be modding citra to load files of a folder instead of the romfs, kinda like cemu loads games in loadiine format, but it's something i can't do
 
  • Like
Reactions: mustafag32g

mustafag32g

Well-Known Member
Member
Joined
Jul 30, 2014
Messages
806
Trophies
0
Age
34
XP
2,331
Country
Argentina
well a button added to the program that could rebuild the files to a cia would be amazing if you could do that... it would be faster than using 3dstocia editor :D
 

exelix11

Developer
OP
Developer
Joined
Feb 25, 2015
Messages
915
Trophies
1
Location
C:\users\exelix11\
XP
3,062
Country
Italy
well a button added to the program that could rebuild the files to a cia would be amazing if you could do that... it would be faster than using 3dstocia editor :D
after a bit of research i realized why i couldn't build working 3ds files
Use this: https://github.com/exelix11/3DS-Builder-citra/releases/tag/citra-build
make a bat file with:
Code:
del game.3ds
"3DS Builder" -romfs "path to romfs" -exefs "path to exefs" -exheader "path to exheader" -out game.3ds
"path to citra\citra-qt" game.3ds
romfs and exefs can be both decompressed to a folder or already built.
every time you open the bat it will build a 3ds of the game and run it in citra, also the build time is considerably faster without encryption.
 
Last edited by exelix11,
  • Like
Reactions: mustafag32g

exelix11

Developer
OP
Developer
Joined
Feb 25, 2015
Messages
915
Trophies
1
Location
C:\users\exelix11\
XP
3,062
Country
Italy
is it normal that I'm getting generating octree and its going on for almost 6 hours now?
The model is too complex or big, you might as well cancel it since it will most likely crash the game.
Collisions generation speed depends on your hardware, but normally should be pretty fast,try removing everything the player can't collide with, simplify the mesh , export only one side of the faces.
If you still have this issue split it in multiple models
 

EmulatorLover

3ds master race
Member
Joined
Apr 26, 2015
Messages
973
Trophies
0
Age
27
Location
Anywhere ;)
XP
523
Country
United States
The model is too complex or big, you might as well cancel it since it will most likely crash the game.
Collisions generation speed depends on your hardware, but normally should be pretty fast,try removing everything the player can't collide with, simplify the mesh , export only one side of the faces.
If you still have this issue split it in multiple models
ok I'll try that
 

ataricore

Well-Known Member
Newcomer
Joined
Sep 21, 2017
Messages
53
Trophies
0
Age
31
XP
161
Country
United Kingdom
I have imported a custom object but the only thing I can't get my head around is adding it to the CreatorClassNameTable. I generate the CCNT patches but then I don't know if I'm doing it right after that. There doesn't seem to be a way to select the object file or anything that I want to use and when I add it to the scene it just appears as the blue box with an arrow (as it said it would if not done correctly. I've followed everything so far well and I'd appreciate any help with this. Thanks
 

exelix11

Developer
OP
Developer
Joined
Feb 25, 2015
Messages
915
Trophies
1
Location
C:\users\exelix11\
XP
3,062
Country
Italy
I have imported a custom object but the only thing I can't get my head around is adding it to the CreatorClassNameTable. I generate the CCNT patches but then I don't know if I'm doing it right after that. There doesn't seem to be a way to select the object file or anything that I want to use and when I add it to the scene it just appears as the blue box with an arrow (as it said it would if not done correctly. I've followed everything so far well and I'd appreciate any help with this. Thanks
You must put your obj file in the models folder with the same name you gave to the game object (eg. your game object name is PeachCastle, you must call the 3d model PeachCastle.obj )
 

ataricore

Well-Known Member
Newcomer
Joined
Sep 21, 2017
Messages
53
Trophies
0
Age
31
XP
161
Country
United Kingdom
You must put your obj file in the models folder with the same name you gave to the game object (eg. your game object name is PeachCastle, you must call the 3d model PeachCastle.obj )
I removed the .obj extension from the obj file and it works now. This program really is amazing, by the way. thanks for making it. One suggestion I have for the future is being able to resize custom objects but it's amazing this program even exists so thanks.
 

Psi-hate

GBATemp's Official Psi-Hater
Member
Joined
Dec 14, 2014
Messages
1,749
Trophies
1
XP
3,380
Country
United States
A friend and I are fiddling around with this program, for the most part I've gathered enough to figure out how to import my custom maps. I have yet to get one working in game, but I'm working on that right now. There really needs to be a proper in-depth tutorial other than the one in the OP. I'm an experienced OoT modder and even so I still had a lot of trial and error trying to get the process of getting the model in-program.

Edit: I've successfully injected the map into FirstStageMap1.szs and when loading that szs, it runs fine in the program, but shoving that onto my 3ds makes the game crash when loading a level. Is there anything I can do to debug this?
 
Last edited by Psi-hate,

exelix11

Developer
OP
Developer
Joined
Feb 25, 2015
Messages
915
Trophies
1
Location
C:\users\exelix11\
XP
3,062
Country
Italy
A friend and I are fiddling around with this program, for the most part I've gathered enough to figure out how to import my custom maps. I have yet to get one working in game, but I'm working on that right now. There really needs to be a proper in-depth tutorial other than the one in the OP. I'm an experienced OoT modder and even so I still had a lot of trial and error trying to get the process of getting the model in-program.

Edit: I've successfully injected the map into FirstStageMap1.szs and when loading that szs, it runs fine in the program, but shoving that onto my 3ds makes the game crash when loading a level. Is there anything I can do to debug this?
Try to reduce as much as you can the textures size, that seems to be the main reason to crash the game.
Also if you're not already doing, make the model with the official tools.
Unluckily i don't know how to debug the game, maybe with luma but i never looked into that.
 

Psi-hate

GBATemp's Official Psi-Hater
Member
Joined
Dec 14, 2014
Messages
1,749
Trophies
1
XP
3,380
Country
United States
Try to reduce as much as you can the textures size, that seems to be the main reason to crash the game.
Also if you're not already doing, make the model with the official tools.
Unluckily i don't know how to debug the game, maybe with luma but i never looked into that.
Ah, okay. I'll import a simpler map in the meantime and if that works, I'll try to remake my previous model to work better in sm3dl.
 

ataricore

Well-Known Member
Newcomer
Joined
Sep 21, 2017
Messages
53
Trophies
0
Age
31
XP
161
Country
United Kingdom
A friend and I are fiddling around with this program, for the most part I've gathered enough to figure out how to import my custom maps. I have yet to get one working in game, but I'm working on that right now. There really needs to be a proper in-depth tutorial other than the one in the OP. I'm an experienced OoT modder and even so I still had a lot of trial and error trying to get the process of getting the model in-program.

Edit: I've successfully injected the map into FirstStageMap1.szs and when loading that szs, it runs fine in the program, but shoving that onto my 3ds makes the game crash when loading a level. Is there anything I can do to debug this?
There are already quite a few tutorials? I came from N64 modding too and I had imported my first custom map on the first day
 

Psi-hate

GBATemp's Official Psi-Hater
Member
Joined
Dec 14, 2014
Messages
1,749
Trophies
1
XP
3,380
Country
United States
There are already quite a few tutorials? I came from N64 modding too and I had imported my first custom map on the first day
Huh, anyway my friend melonspeedruns and I have been trying to get 1 small map in game but it crashes, despite us doing exactly what the tutorial says. The map is only 200 polys and the textures are fine, so I feel like I'm missing something important.

Also to be fair I've been using efe to convert my obj, but I'm downloading Maya and the plugins right now in the meantime. I assumed it'd import and run in game with the efe method, just with the potentiality of being screwy.
 
Last edited by Psi-hate,

ataricore

Well-Known Member
Newcomer
Joined
Sep 21, 2017
Messages
53
Trophies
0
Age
31
XP
161
Country
United Kingdom
Huh, anyway my friend melonspeedruns and I have been trying to get 1 small map in game but it crashes, despite us doing exactly what the tutorial says. The map is only 200 polys and the textures are fine, so I feel like I'm missing something important.

Also to be fair I've been using efe to convert my obj, but I'm downloading Maya and the plugins right now in the meantime. I assumed it'd import and run in game with the efe method, just with the potentiality of being screwy.
I'd suggest using blender or sketchup. I've used both and they worked for me.
 

exelix11

Developer
OP
Developer
Joined
Feb 25, 2015
Messages
915
Trophies
1
Location
C:\users\exelix11\
XP
3,062
Country
Italy
I always had troubles importing with efe, but iirc it wasn't crashing, just not showing or showing with the faces messed up.
Since the video is a bit outdated, this is the way i import models with the latest version of the editor:
1) Make the model, i use sketchup but every program should be fine
2) Put in the same 3d space a model from the game, a stage or mario, so you can scale your model to the game size, then export as obj
2) open it in maya with the leaked tools, i have a VM just for this. Do the hypershade thing and export it how it's described in the video, when you choose the name of the model use a single word just with letters to avoid problems
3) in the editor click on Tools -> Model importer, select your bcmdl (selecting the obj will use efe conversion)
4) now the collisions: if your model is simple click the generate now button, else you must make a simpler version of your model by removing things the player can't touch and things that aren't solid, also you could remove smooth edges and stuff like that, but DON'T change the model position in the 3d space or else the collision won't match the model, export as obj and drag it over collisionsMng.exe, it will generate a KCL and a PA file, open them in the model import window.
5) set a higher clipping radius and click generate SZS, save the SZS with the same name of the model, it should be already written in the save window
6) back to the main editor, click on Tools -> CreatorClassNameTable editor
7) on the panel on the right write the name of your model in the object name field and click add object, then save.
8) copy the obj of the model in the models folder to view it in the editor while editing levels
9) make your level.
10) when copying the custom files to the game you must copy the CreatorClassNameTable.szs you will find in the editor's directory to the SystemData folder and the model szs to the ObjectData folder
11) Profit

i wrote this quickly there may be some inaccuracies, but it should work.
If you still have problems i'll make a new video when i have some free time.
 
  • Like
Reactions: Psi-hate

Psi-hate

GBATemp's Official Psi-Hater
Member
Joined
Dec 14, 2014
Messages
1,749
Trophies
1
XP
3,380
Country
United States
I always had troubles importing with efe, but iirc it wasn't crashing, just not showing or showing with the faces messed up.
Since the video is a bit outdated, this is the way i import models with the latest version of the editor:
1) Make the model, i use sketchup but every program should be fine
2) Put in the same 3d space a model from the game, a stage or mario, so you can scale your model to the game size, then export as obj
2) open it in maya with the leaked tools, i have a VM just for this. Do the hypershade thing and export it how it's described in the video, when you choose the name of the model use a single word just with letters to avoid problems
3) in the editor click on Tools -> Model importer, select your bcmdl (selecting the obj will use efe conversion)
4) now the collisions: if your model is simple click the generate now button, else you must make a simpler version of your model by removing things the player can't touch and things that aren't solid, also you could remove smooth edges and stuff like that, but DON'T change the model position in the 3d space or else the collision won't match the model, export as obj and drag it over collisionsMng.exe, it will generate a KCL and a PA file, open them in the model import window.
5) set a higher clipping radius and click generate SZS, save the SZS with the same name of the model, it should be already written in the save window
6) back to the main editor, click on Tools -> CreatorClassNameTable editor
7) on the panel on the right write the name of your model in the object name field and click add object, then save.
8) copy the obj of the model in the models folder to view it in the editor while editing levels
9) make your level.
10) when copying the custom files to the game you must copy the CreatorClassNameTable.szs you will find in the editor's directory to the SystemData folder and the model szs to the ObjectData folder
11) Profit

i wrote this quickly there may be some inaccuracies, but it should work.
If you still have problems i'll make a new video when i have some free time.
Thank you so much! I'll get to it as soon as I'm home.
 

Psi-hate

GBATemp's Official Psi-Hater
Member
Joined
Dec 14, 2014
Messages
1,749
Trophies
1
XP
3,380
Country
United States
Here are the steps that I did:

1) Exported the model made in sketchup into an obj
2) Used NW4C tools to export the obj into cmdl
3) Used CreativeStudio to export the cmdl into bcmdl
4) made collision from bcmdl
5) imported the collision and bcmdl into "FirstStepASideView.szs"
6) Added the object to "CreatorClassNameTable.szs"
7) Made the level
8) Imported the byml into "FirstStageMap1.szs"
9) Moved "CreatorClassNameTable.szs" to /SystemData
10) Moved "3dltest.szs" to /ObjectData

It worked! Textures for my walls were black, but that's whatever. I found out what my fatal flaw was when trying this previously: I didn't put "3dltest.szs" to /ObjectData, instead I simply put the byml from "3dltest.szs" into "FirstStageMap1.szs". The video tutorial didn't exactly clarify, but maybe that was just me overlooking it. Honestly, the setup was harder than it should have been, but fortunately enough I got it working and I plan on making an in-depth tutorial once I get the hang of it where I make the model from scratch up to showing it off in game.

20171005_233357.jpg
 
Last edited by Psi-hate,
  • Like
Reactions: exelix11

exelix11

Developer
OP
Developer
Joined
Feb 25, 2015
Messages
915
Trophies
1
Location
C:\users\exelix11\
XP
3,062
Country
Italy
Here are the steps that I did:

1) Exported the model made in sketchup into an obj
2) Used NW4C tools to export the obj into cmdl
3) Used CreativeStudio to export the cmdl into bcmdl
4) made collision from bcmdl
5) imported the collision and bcmdl into "FirstStepASideView.szs"
6) Added the object to "CreatorClassNameTable.szs"
7) Made the level
8) Imported the byml into "FirstStageMap1.szs"
9) Moved "CreatorClassNameTable.szs" to /SystemData
10) Moved "3dltest.szs" to /ObjectData

It worked! Textures for my walls were black, but that's whatever. I found out what my fatal flaw was when trying this previously: I didn't put "3dltest.szs" to /ObjectData, instead I simply put the byml from "3dltest.szs" into "FirstStageMap1.szs". The video tutorial didn't exactly clarify, but maybe that was just me overlooking it. Honestly, the setup was harder than it should have been, but fortunately enough I got it working and I plan on making an in-depth tutorial once I get the hang of it where I make the model from scratch up to showing it off in game.

View attachment 101757
The textures are black probably because you didn't do the fragment lighting thing.
Anyway, you injected your bcmdl in another model, using the model importer from the editor it will create a new szs so you can add models without breaking other levels.
Also you might be using an older version of the editor because from a while it can edit szs levels directly so you don't have manually inject the byml every time.

EDIT: i checked the video, it clearly shows copying the szs to the objects folder.
If you are saving the level as byml because the video says that you don't have to, if you open a szs level then it will save as szs
 
Last edited by exelix11,
  • Like
Reactions: Psi-hate

Psi-hate

GBATemp's Official Psi-Hater
Member
Joined
Dec 14, 2014
Messages
1,749
Trophies
1
XP
3,380
Country
United States
The textures are black probably because you didn't do the fragment lighting thing.
Anyway, you injected your bcmdl in another model, using the model importer from the editor it will create a new szs so you can add models without breaking other levels.
Also you might be using an older version of the editor because from a while it can edit szs levels directly so you don't have manually inject the byml every time.

EDIT: i checked the video, it clearly shows copying the szs to the objects folder.
If you are saving the level as byml because the video says that you don't have to, if you open a szs level then it will save as szs
The video did show it, but I don't believe I noticed since there was no text explaining it, but don't worry I blame myself for not seeing it. Anyway I tried the shading in Maya but no matter what the model appeared pitch black despite doing the exact same thing in the video. Anyway, is fragmentation lighting done via Maya?
 

Site & Scene News

Popular threads in this forum

General chit-chat
Help Users
  • K3Nv2 @ K3Nv2:
    Sonics fast I would've been home in 10 mins
  • BigOnYa @ BigOnYa:
    Meet and greet with AncientBoi then?
  • K3Nv2 @ K3Nv2:
    That would've gone slow he's old
    +1
  • ZeroT21 @ ZeroT21:
    sadly the person in question feels too young for his own good
  • K3Nv2 @ K3Nv2:
    We don't question people
  • ZeroT21 @ ZeroT21:
    me neither, i just bash them
  • K3Nv2 @ K3Nv2:
    We just question @AncientBoi
  • ZeroT21 @ ZeroT21:
    it wasn't a question, it was fact
  • BigOnYa @ BigOnYa:
    He said he had 3 different doctors apt this week, so he prob there. Something about gerbal extraction, I don't know.
    +1
  • ZeroT21 @ ZeroT21:
    bored, guess i'll spread more democracy
  • LeoTCK @ LeoTCK:
    @K3Nv2 one more time you say such bs to @BakerMan and I'll smack you across the whole planet
  • K3Nv2 @ K3Nv2:
    Make sure you smack my booty daddy
    +1
  • LeoTCK @ LeoTCK:
    telling him that my partner is luke...does he look like someone with such big ne
    eds?
  • LeoTCK @ LeoTCK:
    do you really think I could stand living with someone like luke?
  • LeoTCK @ LeoTCK:
    I suppose luke has "special needs" but he's not my partner, did you just say that to piss me off again?
  • LeoTCK @ LeoTCK:
    besides I had bigger worries today
  • LeoTCK @ LeoTCK:
    but what do you know about that, you won't believe me anyways
  • K3Nv2 @ K3Nv2:
    @BigOnYa can answer that
  • BigOnYa @ BigOnYa:
    BigOnYa already left the chat
  • K3Nv2 @ K3Nv2:
    Biginya
  • BigOnYa @ BigOnYa:
    Auto correct got me, I'm on my tablet, i need to turn that shit off
  • K3Nv2 @ K3Nv2:
    With other tabs open you perv
  • BigOnYa @ BigOnYa:
    I'm actually in my shed, bout to cut 2-3 acres of grass, my back yard.
  • K3Nv2 @ K3Nv2:
    I use to have a guy for that thanks richard
    K3Nv2 @ K3Nv2: I use to have a guy for that thanks richard