World Storage System

LizardLad_1
New member
 
Posts: 3
Joined: Wed Oct 26, 2016 20:20
IRC: LizardLad_1
In-game: LizardLad_1 Ollie

World Storage System

by LizardLad_1 » Fri Oct 28, 2016 10:53

Hello I've been trying to figure out how the minetest storage system works I've had a look at the maps.cpp and maps.h or map.cpp so on and so on but I am not able to understand the code I would like to know how this works as I would like to write a python program to convert it to a .Fbx file for use in blender and UE4.or any other 3D file that blender can open.
 

kahrl
Member
 
Posts: 236
Joined: Fri Sep 02, 2011 07:51

Re: World Storage System

by kahrl » Fri Oct 28, 2016 12:33

See here: doc/world_format.txt

You might be able to reuse some code from util/minetestmapper.py.
 

twoelk
Member
 
Posts: 1092
Joined: Fri Apr 19, 2013 16:19

Re: World Storage System

by twoelk » Fri Oct 28, 2016 13:02

you might be interested in this old thread:
3D printing for kids: modelling objects with Minetest
or this:
Minetest 3D Print
or this:
mt2obj
 

LizardLad_1
New member
 
Posts: 3
Joined: Wed Oct 26, 2016 20:20
IRC: LizardLad_1
In-game: LizardLad_1 Ollie

Re: World Storage System

by LizardLad_1 » Fri Oct 28, 2016 20:45

Thank you, world edit can make development of 3D games sooo much easier. using this it will make things a lot quicker now I will try to implement a world type that is 20x20x1 blocks based of the old world type that used to only have a Nyan cat in it I don't remember what that release was but it was fun anyway thanks will let you know when an obj2fbx script is complete.
 

LizardLad_1
New member
 
Posts: 3
Joined: Wed Oct 26, 2016 20:20
IRC: LizardLad_1
In-game: LizardLad_1 Ollie

Re: World Storage System

by LizardLad_1 » Fri Oct 28, 2016 21:42

Ok done obj2fbx but it relies on the Autodesk FBX SDK it is free but not open source I will paste the source of my program here but you have to get the SDK yourself. Remember you take the .pyd files and place them in the same directory as the script also use the correct architecture and correct version of the file for your version of python

Your phone or window isn't wide enough to display the code box. If it's a phone, try rotating it to landscape mode.
Code: Select all
import fbx
# Create an SDK manager                                                                                           
manager = fbx.FbxManager.Create()
# Create a scene
scene = fbx.FbxScene.Create(manager, "")
# Create an importer object                                                                                                 
importer = fbx.FbxImporter.Create(manager, "")
# Path to the .obj file
Input = "Input.obj"
# Specify the path and name of the file to be imported                                                                           
importstat = importer.Initialize(Input, -1)
importstat = importer.Import(scene)
# Create an exporter object                                                                                                 
exporter = fbx.FbxExporter.Create(manager, "")
save_path = "Output.fbx"
# Specify the path and name of the file to be imported                                                                           
exportstat = exporter.Initialize(save_path, -1)
exportstat = exporter.Export(scene)
 


Return to Minetest-Related

Who is online

Users browsing this forum: No registered users and 4 guests

cron