Home | Documentation | Atomic Chat | Github

[Tutorial] Getting levels from Trenchbroom into Atomic Game Engine


Hey everyone,

I was wanting to import a small level made in the awesome trench broom level editor to the Atomic Game Engine. I manged to do this. I have not tried this with a textured level so your mileage may vary on that front.

What you will need.
https://github.com/kduske/TrenchBroom - Trench Broom Level Editor
http://nemesis.thewavelength.net/index.php?p=45 - Crafty Level Viewer
http://Blender.org - Blender
https://www.atomicgameengine.com/ - Atomic Game Engine

  1. Make something in trenchbroom such as a cube,
  2. Save it as a .map file through the file -> Save as. Do not export it.
  3. Open Crafty Level Viewer and open your level.
  4. Export your level as an .OBJ
  5. Open it in blender and resize if Necessary.
  6. Export it as in a format that atomic will accept.
  7. Import it into atomic game engine.

Hope this helps someone out there.

  • HeadClot


I keep trying to get Quake maps into Atomic with varying success. This pic Shamgar in the Atomic Labs is a quake level, but was lacking collision (I just tried to put a rigidbody and mesh collisionshape and that fixed it.). My “toolchain” is somewhat simpler, I have an irrlicht program that loads level.pk3, (so textured) then saves that out as either a level.obj or level.dae, and this works well. Getting the level.obj into atomic is the problem. Theoretically, assimp could load level.obj directly into urho3d/atomic, in practice, the assimp to mdl conversion fails, and you end up with some bad geometry. Trying to debug this failure is difficult, and I still have no testcase to give to assimp. Taking the level.obj into blender and scaling it works, and the path I know works is making it a .blend, and putting that in the Models directory in your project, and magic occurs, after you add collision. Not easy, and many manual steps.


Not to hijack your thread, but I’ve cleaned up and released my [pk3 map converter] (https://github.com/JimMarlowe/GameFarm#utility-pk3-map-converter) program. pk3 to obj|dae|irrmesh|stl|ply, made with Irlicht, cross platform, source code, zlib license.