Page 1 of 1

MoH Precacher

Posted: Tue Jul 11, 2006 10:39 am
by Rookie One.pl
I built a little tool for building precache scripts for MoHAA. :) It's a commandline program that reads a .map file and the script and uses the data it finds to create a precache script for you. :) Due to a parsing deficiency (I'm trying to fix it), reading BSP files is not supported yet.
http://iqstudios.quakedev.com/precacher wrote:MoH Precacher is a simple command line tool to build precache scripts for Medal of Honor Allied Assault maps. Let's take a look at the program's help message:

Code: Select all

MoH Precacher v0.1 - a MoHAA precache script builder
Copyright (C) 2006, Leszek Godlewski

Usage: precacher.exe [OPTIONS] <MAPFILE>

Options:

  -a, --all       Precaches all found models no matter if they're included in
                  dmprecache.scr or not (i.e. for single player maps).
  -b, --bsponly   Parses the map file only (skips script parsing).
  -s, --single    Precaches some common single player map items (forces
                  --all to be on).
  -c, --nocommon  Switches off adding some common precached items.
  -p, --noprefix  Switches off adding the models/ prefix to paths that don't
                  contain it.
  -h, --help      Displays this help message.
By default a precache script for a multiplayer map is created. The options are pretty self explanatory. The program takes a filename of a .map file and loads it into memory, then it parses out all the .tik files from it and adds them to the cached item list. After that, it tries to open a script by the same name (but with .scr extension) and parses all the models out of it as well. When all this is done, the final result is written into foobar_precache.scr (for mapfile called foobar.map). There you go! :)
You can grab the program here. It's released under GPL, which means the source is available as well. :)

Enjoy!

Posted: Tue Jul 11, 2006 2:42 pm
by Tod001
Excellent piece of work, thank you. :wink:

Posted: Fri Dec 15, 2006 3:04 pm
by Devil_Dog
This is the best idea ever...would help new mappers alot I think (like me), we could use it, then open the script to see it applied to things we did.

edit: Just tried the link above, I got a 404 error, maybe you want to up-date it to the IneQuation site.

Posted: Fri Dec 15, 2006 7:34 pm
by jv_map
Cool! 8-) We have a time saver here :)

Posted: Fri Dec 15, 2006 8:31 pm
by Rookie One.pl
Ah, yeah, I updated the links, the site's still a work-in-progress. But if you went to the main page (http://iqstudios.quakedev.com/) and then to downloads, you would find it. ;)

Posted: Sat Dec 16, 2006 3:12 am
by Devil_Dog
Ya I found it, just figured you'd want to know about the link. This helped alot. I was able to see where I made a few mistakes. Very cool. Thanks.