I am useing mbuilder how do I get it to write a log when i d

If you're looking for mapping help or you reckon you're a mapping guru, post your questions / solutions here

Moderator: Moderators

User avatar
small_sumo
Lieutenant General
Posts: 953
Joined: Mon Jul 01, 2002 4:17 pm
Contact:

I am useing mbuilder how do I get it to write a log when i d

Post by small_sumo »

I am useing mbuilder how do I get it to write a log when i do a compile?

Thanks

:)
Image

www.smallsumo.tk

Yeah Truth above Honor Man ;)
Bjarne BZR
Site Admin
Posts: 3298
Joined: Wed Feb 05, 2003 2:04 pm
Location: Sweden
Contact:

Post by Bjarne BZR »

put

Code: Select all

>> C:\compile_logfile.txt
At the end of the compile commands, and you wont get the logs in the DOS window -> it will only write it to the file C:\compile_logfile.txt
Admin .MAP Forums
Image
Head above heels.
User avatar
tltrude
Chuck Norris
Posts: 4774
Joined: Sun Jul 07, 2002 4:03 am
Location: Oklahoma, USA
Contact:

For MBuilder:

Post by tltrude »

You can make seperate logs for all steps, or just the one you need. Click on "change" and put the code after your compile option. The text file can have any name you wish.

-v > c:\WINDOWS\desktop\log_bsp.txt

-v > c:\WINDOWS\desktop\log_vis.txt

-final > c:\WINDOWS\desktop\log_light.txt

I have them going to my desktop, so they can be trashed easily after looking them over. But, your path to the desktop may be different. Also, using these logs, nothing will be printed to the DOS window during the compile.

Looking at Bjarne BZR post, I guess using ">>" will make it add to a text file--instead of overwriting it.
Tom Trude,

Image
User avatar
small_sumo
Lieutenant General
Posts: 953
Joined: Mon Jul 01, 2002 4:17 pm
Contact:

Post by small_sumo »

This is what I wrote in my batch file and it doesnt seam to work, I tried a few other different ways ................ erm would one of you gents mind poating an example of one of your batch files. With this one I just copied my mbuilder one and copied in the lines you showed me.

Thanks



"C:\PROGRA~1\MOHAAT~1\Q3map.exe" -v -gamedir C:\PROGRA~1\EAGAME~1\MOHAA C:\MOHAA\main\maps\obj_hms_hood.map
//newline
>> C:\compile_logfile.txt
//newline
"C:\PROGRA~1\MOHAAT~1\Q3map.exe" -vis -v -gamedir C:\PROGRA~1\EAGAME~1\MOHAA C:\MOHAA\main\maps\obj_hms_hood.map
//newline
>> C:\compile_logfile.txt
//newline
"C:\PROGRA~1\MOHAAT~1\MOHlight.exe" -verbose -final -staticshadows -extragrid -gamedir C:\PROGRA~1\EAGAME~1\MOHAA
C:\MOHAA\main\maps\obj_hms_hood.map
//newline
>> C:\compile_logfile.txt
//newline
pause
Copy "C:\MOHAA\main\maps\obj_hms_hood.bsp" C:\PROGRA~1\EAGAME~1\MOHAA\main\maps
cd C:\PROGRA~1\EAGAME~1\MOHAA
"C:\PROGRA~1\EAGAME~1\MOHAA\MOHAA.exe" +set developer 1 +set thereisnomonkey 1 +set cheats 1 +set ui_console 1 +g_gametype 0 +devmap obj_hms_hood
Image

www.smallsumo.tk

Yeah Truth above Honor Man ;)
Bjarne BZR
Site Admin
Posts: 3298
Joined: Wed Feb 05, 2003 2:04 pm
Location: Sweden
Contact:

Post by Bjarne BZR »

Code: Select all

"C:\PROGRA~1\MOHAAT~1\Q3map.exe" -v -gamedir C:\PROGRA~1\EAGAME~1\MOHAA C:\MOHAA\main\maps\obj_hms_hood.map >> C:\compile_bsp_logfile.txt
//newline
"C:\PROGRA~1\MOHAAT~1\Q3map.exe" -vis -v -gamedir C:\PROGRA~1\EAGAME~1\MOHAA C:\MOHAA\main\maps\obj_hms_hood.map >> C:\compile_vis_logfile.txt 
//newline
"C:\PROGRA~1\MOHAAT~1\MOHlight.exe" -verbose -final -staticshadows -extragrid -gamedir C:\PROGRA~1\EAGAME~1\MOHAA 
C:\MOHAA\main\maps\obj_hms_hood.map >> C:\compile_light_logfile.txt 
//newline
pause
//newline
Copy "C:\MOHAA\main\maps\obj_hms_hood.bsp" C:\PROGRA~1\EAGAME~1\MOHAA\main\maps
//newline
cd C:\PROGRA~1\EAGAME~1\MOHAA
//newline
"C:\PROGRA~1\EAGAME~1\MOHAA\MOHAA.exe" +set developer 1 +set thereisnomonkey 1 +set cheats 1 +set ui_console 1 +g_gametype 0 +devmap obj_hms_hood
And that stuff about the monkey is a lie, I've seen the monkey.... Really... :wink:
Admin .MAP Forums
Image
Head above heels.
User avatar
small_sumo
Lieutenant General
Posts: 953
Joined: Mon Jul 01, 2002 4:17 pm
Contact:

Post by small_sumo »

The monkey would get spanked but it is revered in some countrys, therefore protecting the monkey under the geneva convention.

:wink:
Image

www.smallsumo.tk

Yeah Truth above Honor Man ;)
User avatar
tltrude
Chuck Norris
Posts: 4774
Joined: Sun Jul 07, 2002 4:03 am
Location: Oklahoma, USA
Contact:

Monkey

Post by tltrude »

Is that the monkey that sees no evil pollys?
Tom Trude,

Image
User avatar
small_sumo
Lieutenant General
Posts: 953
Joined: Mon Jul 01, 2002 4:17 pm
Contact:

Post by small_sumo »

And he hears no duplicate planes as well.

:)

:wink:
Image

www.smallsumo.tk

Yeah Truth above Honor Man ;)
Bjarne BZR
Site Admin
Posts: 3298
Joined: Wed Feb 05, 2003 2:04 pm
Location: Sweden
Contact:

Post by Bjarne BZR »

There IS a monkey. As long as we agree on that I'm all good (whatever that silver tounged monkey says).





Oh, and don't taunt happy fun ball.
Admin .MAP Forums
Image
Head above heels.
User avatar
small_sumo
Lieutenant General
Posts: 953
Joined: Mon Jul 01, 2002 4:17 pm
Contact:

Post by small_sumo »

No more monkey comments? I thought JV would have chimed in by now hehe.

:)
Image

www.smallsumo.tk

Yeah Truth above Honor Man ;)
m4rine
Major General
Posts: 714
Joined: Fri Apr 11, 2003 5:28 pm
Location: UK

Post by m4rine »

would there be anyway to use

Code: Select all

>> c:\compile_logs.txt
and have a seperater between each compile log displaying the date of when it was compiled and which map was compiled? I kow i might have to use a date function to get the date, but at least a seperator and any other options which were set. For example:

Code: Select all

************************
date:
map compiled:
command  line:
other options:
************************

first_compile

************************
date:
map compiled:
command  line:
other options:
************************

second_compile
cos I would like my file to be organized - and i'm very forgetful.
"We must become the change we want to see in the world" (Mahatma Gandhi)
Bjarne BZR
Site Admin
Posts: 3298
Joined: Wed Feb 05, 2003 2:04 pm
Location: Sweden
Contact:

Post by Bjarne BZR »

Try something like this in a *.bat file:

Code: Select all

echo. >> c:\test.txt
echo ************************ >> c:\test.txt
echo ** BSP COMPILE START *** >> c:\test.txt
echo ************************ >> c:\test.txt
echo date: >> c:\test.txt
date /T >> c:\test.txt
echo time: >> c:\test.txt
time /T >> c:\test.txt
echo ************************ >> c:\test.txt
echo. >> c:\test.txt
"C:\PROGRA~1\MOHAAT~1\Q3map.exe" -v -gamedir D:\Games\MOHAA C:\DOCUME~1\Bjarne\MYDOCU~1\MOHAA\maps\obj\obj_saving_private_frosty.map >> c:\test.txt
echo. >> c:\test.txt
echo ************************ >> c:\test.txt
echo date: >> c:\test.txt
date /T >> c:\test.txt
echo time: >> c:\test.txt
time /T >> c:\test.txt
echo ************************ >> c:\test.txt
echo *** BSP COMPILE END **** >> c:\test.txt
echo ************************ >> c:\test.txt
echo. >> c:\test.txt
Admin .MAP Forums
Image
Head above heels.
m4rine
Major General
Posts: 714
Joined: Fri Apr 11, 2003 5:28 pm
Location: UK

Post by m4rine »

um .bat?

doo i just do a text and save it as my_map_name.bat and put it in maps?
"We must become the change we want to see in the world" (Mahatma Gandhi)
Bjarne BZR
Site Admin
Posts: 3298
Joined: Wed Feb 05, 2003 2:04 pm
Location: Sweden
Contact:

Post by Bjarne BZR »

You dont add it to the pk3... a bat file is a textfile that is executable in windows (like an exe) and when it is executed : it executes all the commands listed in the file...
Admin .MAP Forums
Image
Head above heels.
m4rine
Major General
Posts: 714
Joined: Fri Apr 11, 2003 5:28 pm
Location: UK

Post by m4rine »

cheers - i did know what a 'MS-Dos Batch File' was, but i didn't know it was .bat. Also it worked but it didn't - it came up with this:
************************
** BSP COMPILE START ***
************************
date:

Invalid date
Enter new date (dd-mm-yy):
I don't know anything about the date functions (i do in PHP, but not in anyhting else) please help! I just copied the code you put, changed all the directory's/mapname to my own.

But it writes to a file, and even if i drop the date that's the important thing for me :wink:

cheers,

m4rine
"We must become the change we want to see in the world" (Mahatma Gandhi)
Post Reply