Mask editor


(TinMan) #1

I decided to re-purpose the deploy mask system to try and improve the drop system in Brace, initially I was hesitant to do that because I thought I’d have to edit the mask tgas by hand, but after poking around I found there was a mask editor. I searched online a bit but didn’t find any noticeable mention of it.

With a disclaimer that I’ve only used it via my mod and not via the sdk/editor.
How to get it working:
Copy def/misc/maskeditor.def from the sdk/base folder to the equivalent in your work/mod folder
Likewise copy def/players/roles_gdf.def
edit roles_gdf.def (the copy in your work folder), in one of the itemPackageDefs (I used class_engineer), add the line:
item “inventory/misc/maskeditor”

Load up the game with mod, spawn as that class,
the editor is a tool in the melee slot (after knife), there’s no weapon image, and a bit of console spam because of it, but it’s of no consequence.

By default it should edit dm_default, which is the deploy mask, you’ll recall the other masks like dm_playzone, dm_mpc etc on the playzone entity. To set what mask is being edited set the g_editmask cvar.

Oh look, it’s the deploy grid

Editing is simple as, just look at the spot you want to edit, you’ll see it highlighted, press fire for green/valid spot, altfire for red/invalid spot.

So how to save? Press your activate key. It saves the mask image to fs_savepath

Other cvars, g_editmaskautosave - saves after each edit, g_editmasksize - size of your edit ‘brush’.

Final note, you’ll have to remember the tool is there and not accidentally package the roles_gdf


(Violator) #2

No way :o What a great find :slight_smile: Wonder what other hidden stuff there is in there…


(.Chris.) #3

What!? This is way cool.


(Susefreak) #4

Woa nice find.

I made a pk4 for people who’d like to test it out.
http://bravehardt.com/TAW/Quake_Wars/Susefreak/idtech4_hacking/zdevelopment.pk4


(Donnovan) #5

Very nice find.

I open mask in one layer of Gimp, command map in another layer (over the first, with “add” merge type), resize the layers so they meet at 1 deploy square = 1x1 or 2x2 pixel. And then add the white dots.

Most time is used to decide where to put the spots, not doing the work itself. It’s also a nice way!


(Scrupus) #6

Awesome TinMan!!! :smiley:

Works like a charm in the SDK too. Even better, you can test the deployment directly after saving the mask! This will be excellent for fine-tuning deploy spots! :smiley:

Thanks a lot for the tutorial!


(light_sh4v0r) #7

Oh great, now someone delete the strogg deploy spot on Salvage last stage facing the outer GDF base exit, it annoys me :tongue:


(.Chris.) #8

You could do that before this tool was released…


(MrLego) #9

Nice Find!


(ballking) #10

Woa nice find.
I really loved this post. You write about this topic very well.