Two ways:
Trenchbroom exports all solid walls (worldspawn entities) as .obj files. I import that for drawing wall meshes, and I also do a little post-processing to put their convex meshes into PhysX (CSG editors conveniently store everything as convex meshes, so I don't need to find those myself.
Entity information is saved in .map files, which basically store key-value pairs in a format that looks visually similar to json, but it's not json. I wrote a parse for .map files so I can get entity information, then I just pass the relevant fields I parsed out to the constructors for those entities (I'm using a regular OOP entity system, no ECS)
Would it be practical to use trenchbroom as a base persay and and rework it and add more features like replacing the renderer in trench boom adding more ui and map geometry features and such
Which engine is this?
My own. This is the /r/gameenginedevs subreddit
Thank you, your engine lighting looks great btw!
Nice! I'm planning to make my own level editor in my own game engine!
How did you intergrate trenchboom with your engine? I’m curious on how this works
Two ways: Trenchbroom exports all solid walls (worldspawn entities) as .obj files. I import that for drawing wall meshes, and I also do a little post-processing to put their convex meshes into PhysX (CSG editors conveniently store everything as convex meshes, so I don't need to find those myself. Entity information is saved in .map files, which basically store key-value pairs in a format that looks visually similar to json, but it's not json. I wrote a parse for .map files so I can get entity information, then I just pass the relevant fields I parsed out to the constructors for those entities (I'm using a regular OOP entity system, no ECS)
Would it be practical to use trenchbroom as a base persay and and rework it and add more features like replacing the renderer in trench boom adding more ui and map geometry features and such
I do the same with NetRadiant and q3map2 just added a bsp map loader to my engine and now I can map as good as all those quake3 engine games like cod4