[TOOL] Level cleaner utility
BeigeAlert
Texas Join Date: 2013-08-08 Member: 186657Members, Super Administrators, Forum Admins, NS2 Developer, NS2 Playtester, Squad Five Blue, Squad Five Silver, NS2 Map Tester, Reinforced - Diamond, Reinforced - Shadow, Subnautica Playtester, Pistachionauts
Hey guys, I've created a quick little utility that searches through .level files, and removes any static_props that have no model files.
Ensure you have Python 3 installed, and simply drag+drop the .level onto the script. The cleaned level will be saved with '_modified' appended to the name.
Already tested it out on refinery, and it works like a charm!
The name "cleaner" is a bit more general than just removing invalid entities... I may later expand this utility to recognize and "clean" more errors. For now, if you've been getting that "couldn't load model "" " error, this should fix it for you.
https://www.dropbox.com/s/uk32uym2h6b1bmq/level_cleaner.py?dl=1
Cheers!
Beige
Changelog:
6-13-15
-Console output is more clear now on when the utility cannot find anything to fix.
6-12-15
-First release
-Detects blank model file paths, and removes these objects from the .level.
Ensure you have Python 3 installed, and simply drag+drop the .level onto the script. The cleaned level will be saved with '_modified' appended to the name.
Already tested it out on refinery, and it works like a charm!
The name "cleaner" is a bit more general than just removing invalid entities... I may later expand this utility to recognize and "clean" more errors. For now, if you've been getting that "couldn't load model "" " error, this should fix it for you.
https://www.dropbox.com/s/uk32uym2h6b1bmq/level_cleaner.py?dl=1
Cheers!
Beige
Changelog:
6-13-15
-Console output is more clear now on when the utility cannot find anything to fix.
6-12-15
-First release
-Detects blank model file paths, and removes these objects from the .level.
Comments
Probably would be even easier to do it there. All this does is check every object for a "model" property, and if it's an empty string, delete the whole object.
I wished it was in the editor in the first place (at NS2 launch).
It would have save a loooooooooot of trouble for everyone including UWE/CDT.
Thank you, Biege bro
rename : BeastAlert
But I like Beige! Do I have a choice in this?
Lies. You told me to remove beige colored props in the past!