C++ Titanfall BSP Reader/editor banner

C++ Titanfall BSP Reader/editor

10 devlogs
34h 44m 56s

The whole goal of this is to create a C++ app for Titanfall BSP editing (BSP is the Titanfall 2 map file), as of now it currently works only as a viewer. Unlike normal Source games no Titanfall modding tools were ever released by the devs of the g…

The whole goal of this is to create a C++ app for Titanfall BSP editing (BSP is the Titanfall 2 map file), as of now it currently works only as a viewer. Unlike normal Source games no Titanfall modding tools were ever released by the devs of the game. The goal of this is to create better community tools for the game :3

This project uses AI

I suck at c++ so I used it for a lot of bug fixing

Demo Repository

Loading README...

Mr Milky Way

Shipped this project!

Hours: 34.75
Cookies: 🍪 868
Multiplier: 20.8 cookies/hr

The whole goal of this is to create a C++ app for Titanfall BSP editing, as of now it currently works only as a viewer. Unlike normal Source games no Titanfall modding tools were ever released by the devs of the game. The goal of this is to create better community tools for the game :3

Currently it uses OpenGL to view the maps but before I can continue I need to swap to DX11 (that’s what Titanfall uses).

Since I made this, I figured that I might as well just release it as a BSP viewer before I swap to DX11. There is currently a very basic texture system that doesn’t work all the time. You can use it if you own the game and have unpacked all the starpaks with the game textures. Just set the textures folder to exported_files\texture

Recommendations:
Turn off renderUnlit and renderLitFlat in Settings

Controls:

  • WASD to move the camera
  • Q for camera down
  • E for camera up
  • Scroll wheel for camera movement speed
Mr Milky Way

As a prep before I ship, I decided to make the textures folder optional. If you don’t select a textures folder it falls back to a different color for different materials. I added a little option for that

It also now pulls the missing texture image from a local path now. I did a small bugfix for the settings too, it used to not save now it does.

I also removed the shaders from last devlog bc it made more things buggy and reduced the overall experience.

Demos

  • New Folder Option Thingy
  • Map without textures loaded
  • Map with textures loaded (note not all of them load)

Changelog

Attachment
Attachment
Attachment
2

Comments

Shuflentity
Shuflentity 6 days ago

oh hey the only other titanfall 2 player ever

Mr Milky Way
Mr Milky Way 6 days ago

lmao

Mr Milky Way

I created better texture stuff but I’m going to have to remove it for DX11, it was great insight into how the games textures work tho. I also learned how to write OpenGL shaders (only a little bit)

Attachment
0
Mr Milky Way

So I added textures (kinda) turns out I have to recode the whole things to use DX11 and not OpenGL. It also needs shaders and so thats all next.

But this is a 12h 11m devlog, and thats because I decided to add my Titanfall testing folders into the projects. Here is a rundown:

Titanfall 2 Modding: this is the folder that has all of the unpacked VPK’s so I can load the maps or anything from a certain map (is missing textures those are in the rpaks)

Titanfall2: Game Dir

source-sdk-2013: For taking a look at old source engine logic (Titanfall is based off of source after all)

milkyway.restore - Copy: for testing BSP stuff in game

NewMapTester: Also for testing BSP stuff in game

Attachment
0
Mr Milky Way

This one is a bit odd, I deiced to make it load textures now, but because I’m using this as a way to learn OpenGL I had no idea how to to that. I deiced that I didn’t want to add all of the texture loading right away bc that seemed kinda hard, SO I i just made it load the missing texture file. Then I saw that there was some bugs with the code for vertex stuff. It wouldn’t put stuff in the right spot so I tried to rework the whole system. That didn’t work so well. I also made it so when you scroll it speeds up/slows down the camera movement speed.

I went back and added anti-aliasing tho is it looks nicer now :)

Next I need to fix the vertex stuff for real and add the ability to use the vtf textures

Attachment
Attachment
Attachment
Attachment
Attachment
Attachment
0
Mr Milky Way

I fixed the settings menu and added better camera movement
You can no disable different vertex types and move the camera in 3d, pretty short and sweet BUT I started making the camera in Y up and not in Z up but I fixed it :)


Change log

  • Create a working viewer (e15a42c)
  • added camera controls and fixed settings (53cec8e)
0
Mr Milky Way

I spent some time making the UI look better, and added a OpenGL Viewer to it so it can now load the vertex/faces of the maps. It was really hard to get working, and the settings page is still not working lol.

Demos

  • Image of window (loading file)
  • Image of loaded file

Changelog

Attachment
Attachment
0
Mr Milky Way

I added the rest of the 127 lumps (128 if counting 0) and also added a read function each for of them. Next up is editing, GUI, and then a render for the 3d bits.

Attachment
Attachment
0
Mr Milky Way

I went back thru and implemented checks for every struct size, I also added up to lump 94 now (no read on them tho). I also got Entity_Partitions reading right :)

Attachment
Attachment
0
Mr Milky Way

I moved the structs into their own header file, I also added a read function for each of the 73 current lumps I have added. While I was at it I improved the logging. More time consuming work than hard work. Didn’t feel like 3 hours tho 💀

Attachment
Attachment
Attachment
0
Mr Milky Way

To start this off I added 73 of the 127 need lump structs and made it read off the PLANES lump.
Not much other stuff, A lot of configuring cmake and other stuff like that.

Attachment
0