Authorized Repost "Some parameter, weapon and ammo chan

Magnus
Posts: 529
Joined: Wed Feb 16, 2005 6:38 pm

Post by Magnus »

Still reading and learning.

Hey BTW, check your e-mail.

:icon25:
Uh, well....good luck with that. :shrug:

[img]http://i57.photobucket.com/albums/g228/Magnus3204/forumheader.jpg[/img]
Silicone_Milk
Posts: 2237
Joined: Sat Mar 12, 2005 10:49 pm

Post by Silicone_Milk »

alright got the email a while ago hehe =)

How's progress?
Magnus
Posts: 529
Joined: Wed Feb 16, 2005 6:38 pm

Post by Magnus »

Well I consulted a few friends that are very good coders and everything we went through could not pinpoint the reason I keep getting compile errors.
So for now (though I hated to do it) I am going back and starting all over. This time I am giong to try useing the tutorials and info from the Q3Devel site.

Hopefully I will see where I went wrong the first time. I have a feeling I may have either made changes that I shoulden't have or or I possibly left discrepancies between the include files.

Anyway the changes I made aren't that big so this will be a nice exercize in what I have learned about modding. :icon25:

Thanks.

BTW, any advice or warnings anyone wants to give about making changes to Weapon and Ammo velocity, spread, damage, splash damage and RoF are welcome.

Later.
Uh, well....good luck with that. :shrug:

[img]http://i57.photobucket.com/albums/g228/Magnus3204/forumheader.jpg[/img]
^misantropia^
Posts: 4022
Joined: Sat Mar 12, 2005 6:24 pm

Post by ^misantropia^ »

You should've posted those compile errors, damnit! Me or someone else would probably have been able to point you in the right direction.
Silicone_Milk
Posts: 2237
Joined: Sat Mar 12, 2005 10:49 pm

Post by Silicone_Milk »

lol Misantropia
I was wondering why it took so long for you to make a post ;)

This is Caldiar's alt account btw. How's things on Planetquake?
^misantropia^
Posts: 4022
Joined: Sat Mar 12, 2005 6:24 pm

Post by ^misantropia^ »

Hiya Caldiar. PQ is same tranquil haven it always is. Come to think of it, I don't think I have seen you there in quite a while.
Magnus
Posts: 529
Joined: Wed Feb 16, 2005 6:38 pm

Post by Magnus »

Oops! :dork:

Well the problem is I keep getting an error durring compilation that tells me 'lcc' is not recognized as an internal or external command, operable program or batch file.

I went into my cgame.q3ase, game.q3ase, that actuall batch files in my game and cgame folders and made sure that the first line pointed to the proper location.
I went into my source/bin file had all in the proper .exe files and I made sure the lcc.exe is in the lcc\bin folder as well. I discussed this with corncobman and showed him all of the files he said were important to this kind of issue and he couldn't see a problem.
He did have me go into system properties\advanced\environment variables and add lcc to the list, but the error keeps happening.

The only other thing I could come up with was that I might have some variables that I changed to a value that the compiling just doesn't agree with or something like that.

Anyway that is the current problem.

That is why I decided to try to go back to the begining and start over with the Q3Devel debuged source and follow the instructions in the tutorials on the Q3Devel web site.

If there is anything I should check to look for the problem it would be a big help.

Thanks guys!
Uh, well....good luck with that. :shrug:

[img]http://i57.photobucket.com/albums/g228/Magnus3204/forumheader.jpg[/img]
^misantropia^
Posts: 4022
Joined: Sat Mar 12, 2005 6:24 pm

Post by ^misantropia^ »

In the .bat files, there's a line to the extent of:

set cc=lcc -DQ3_VM -S -Wf-target=bytecode -Wf-g -I..\..\cgame -I..\..\game -I..\..\ui %1

Just change the 'lcc' part to the absolute path to LCC (e.g. 'c:\quake3\code\bin\lcc') and you should be well.
Silicone_Milk
Posts: 2237
Joined: Sat Mar 12, 2005 10:49 pm

Post by Silicone_Milk »

I didn't realize that was what you were talking about Magnus. I could have told you earlier lol. Sorry man =(

I worked around that problem and Im currently having a problem with the q3asm files not being found for anything. Damn >.>

And yea, Misantropia, I haven't been on PQ for a while.
^misantropia^
Posts: 4022
Joined: Sat Mar 12, 2005 6:24 pm

Post by ^misantropia^ »

Silicone_Milk wrote:I worked around that problem and Im currently having a problem with the q3asm files not being found for anything.
What do your (for example) game.bat and game.q3asm look like?
Magnus
Posts: 529
Joined: Wed Feb 16, 2005 6:38 pm

Post by Magnus »

^misantropia^ wrote:In the .bat files, there's a line to the extent of:

set cc=lcc -DQ3_VM -S -Wf-target=bytecode -Wf-g -I..\..\cgame -I..\..\game -I..\..\ui %1

Just change the 'lcc' part to the absolute path to LCC (e.g. 'c:\quake3\code\bin\lcc') and you should be well.
Thanks misantropia. I think we are getting somewhere with your advice.

I set the path like you suggested and instead of the 'lcc' is not recognised error I am getting a cannot find g_main.c error now.

I can see what it is talking about because in the .bat files the first %cc% line commnands if g_main.c is not found then quit.

So if I set it to

set cc=lcc-DQ3_VM -S -Wf-target=bytecode -Wf-g -I..\..\cgame -I..\..\game -I..\..\ui %1

I get

'lcc' is not recognized as an internal or external command, operable program or batch file.

If I set it to

set cc=C:\quake3\source\code\game -DQ3_VM -S -Wf-target=bytecode -Wf-g -I..\..\cgame -I..\..\game -I..\..\ui %1

I get

'C:\quake3\source\code\game' is not recognized as an internal or external command, operable program or batch file.

And if I set it to

set cc=C:\quake3\source\bin\lcc-DQ3_VM -S -Wf-target=bytecode -Wf-g -I..\..\cgame -I..\..\game -I..\..\ui %1

I get

C:\quake3\source\bin\lcc: can't find `../g_main.c'

So do these errors tell you anything about what to do next or what the problem might be?
^misantropia^ wrote:What do your (for example) game.bat and game.q3asm look like?
Good question. I'm curious as well. Particularly what the game.bat file looks like Calidar. Not that I could help...:icon16:...heh, but I would like to see what you have as your first line and the third from last (q3asm -f game) I think it is in your game.bat.

Anyway thanks again.
Uh, well....good luck with that. :shrug:

[img]http://i57.photobucket.com/albums/g228/Magnus3204/forumheader.jpg[/img]
Silicone_Milk
Posts: 2237
Joined: Sat Mar 12, 2005 10:49 pm

Post by Silicone_Milk »

whoohoo! Here's my Cgame.bat file.... I'm not so sure about the -I on each line >.>

rem make sure we have a safe environement
set LIBRARY=
set INCLUDE=

mkdir vm
cd vm
set cc="C:\quake3\source\bin\lcc" -DQ3_VM -DCGAME -S -Wf-target=bytecode -Wf-g -I "C:\quake3\source\code\cgame" -I "C:\quake3\source\code\game" -I "C:\quake3\source\code\ui" %1

%cc% -I"C:\quake3\source\code\game\bg_misc.c"
@if errorlevel 1 goto quit
%cc% -I"C:/quake3/source/code/game/bg_pmove.c"
@if errorlevel 1 goto quit
%cc% -I"C:/quake3/source/code/game/bg_slidemove.c"
@if errorlevel 1 goto quit
%cc% -I"C:/quake3/source/code/game/bg_lib.c"
@if errorlevel 1 goto quit
%cc% -I"C:/quake3/source/code/game/q_math.c"
@if errorlevel 1 goto quit
%cc% -I"C:/quake3/source/code/game/q_shared.c"
@if errorlevel 1 goto quit
%cc% -I"C:/quake3/source/code/cgame/cg_consolecmds.c"
@if errorlevel 1 goto quit
%cc% -I"C:/quake3/source/code/cgame/cg_draw.c"
@if errorlevel 1 goto quit
%cc% -I"C:/quake3/source/code/cgame/cg_drawtools.c"
@if errorlevel 1 goto quit
%cc% -I"C:/quake3/source/code/cgame/cg_effects.c"
@if errorlevel 1 goto quit
%cc% -I"C:/quake3/source/code/cgame/cg_ents.c"
@if errorlevel 1 goto quit
%cc% -I"C:/quake3/source/code/cgame/cg_event.c"
@if errorlevel 1 goto quit
%cc% -I"C:/quake3/source/code/cgame/cg_info.c"
@if errorlevel 1 goto quit
%cc% -I"C:/quake3/source/code/cgame/cg_localents.c"
@if errorlevel 1 goto quit
%cc% -I"C:/quake3/source/code/cgame/cg_main.c"
@if errorlevel 1 goto quit
%cc% -I"C:/quake3/source/code/cgame/cg_marks.c"
@if errorlevel 1 goto quit
%cc% -I"C:/quake3/source/code/cgame/cg_players.c"
@if errorlevel 1 goto quit
%cc% -I"C:/quake3/source/code/cgame/cg_playerstate.c"
@if errorlevel 1 goto quit
%cc% -I"C:/quake3/source/code/cgame/cg_predict.c"
@if errorlevel 1 goto quit
%cc% -I"C:/quake3/source/code/cgame/cg_scoreboard.c"
@if errorlevel 1 goto quit
%cc% -I"C:/quake3/source/code/cgame/cg_servercmds.c"
@if errorlevel 1 goto quit
%cc% -I"C:/quake3/source/code/cgame/cg_snapshot.c"
@if errorlevel 1 goto quit
%cc% -I"C:/quake3/source/code/cgame/cg_view.c"
@if errorlevel 1 goto quit
%cc% -I"C:/quake3/source/code/cgame/cg_weapons.c"
@if errorlevel 1 goto quit




"C:\quake3\source\bin\q3asm" -f "C:/quake3/source/code/cgame/cgame.q3asm"
:quit
cd ..
Silicone_Milk
Posts: 2237
Joined: Sat Mar 12, 2005 10:49 pm

Post by Silicone_Milk »

*poke* *poke*
Awfully quiet all of a sudden :paranoid:
^misantropia^
Posts: 4022
Joined: Sat Mar 12, 2005 6:24 pm

Post by ^misantropia^ »

You might want to remove the -I switch in the `%cc% -I"C:\quake3\source\code\game\some_file.c" ` statements. It means to include, which is nice for header files, but not source files.
Silicone_Milk
Posts: 2237
Joined: Sat Mar 12, 2005 10:49 pm

Post by Silicone_Milk »

well here's the thing, if i remove them, then they aren't found at all >.>
Silicone_Milk
Posts: 2237
Joined: Sat Mar 12, 2005 10:49 pm

Post by Silicone_Milk »

Do you realize ^misantropia^ that we both joined Q3W on the same exact date yet you have 1000+ posts and I have around 70?

Whoa.
^misantropia^
Posts: 4022
Joined: Sat Mar 12, 2005 6:24 pm

Post by ^misantropia^ »

Silicone_Milk wrote:well here's the thing, if i remove them, then they aren't found at all >.>
FWIW, here are my old cgame.bat and cgame.q3asm. Can't vouch for their useability since I haven't used Windows in over a year. Note that I do set PATH=%PATH%; c:\quake3\code\bin before actually executing it.

cgame.bat
rem make sure we have a safe environement
set LIBRARY=
set INCLUDE=

mkdir vm
cd vm
set cc=lcc -DQ3_VM -DCGAME -S -Wf-target=bytecode -Wf-g -I..\..\cgame -I..\..\game -I..\..\ui %1

%cc% ../../game/bg_misc.c
@if errorlevel 1 goto quit
%cc% ../../game/bg_pmove.c
@if errorlevel 1 goto quit
%cc% ../../game/bg_slidemove.c
@if errorlevel 1 goto quit
%cc% ../../game/bg_lib.c
@if errorlevel 1 goto quit
%cc% ../../game/q_math.c
@if errorlevel 1 goto quit
%cc% ../../game/q_shared.c
@if errorlevel 1 goto quit
%cc% ../cg_consolecmds.c
@if errorlevel 1 goto quit
%cc% ../cg_draw.c
@if errorlevel 1 goto quit
%cc% ../cg_drawtools.c
@if errorlevel 1 goto quit
%cc% ../cg_effects.c
@if errorlevel 1 goto quit
%cc% ../cg_ents.c
@if errorlevel 1 goto quit
%cc% ../cg_event.c
@if errorlevel 1 goto quit
%cc% ../cg_info.c
@if errorlevel 1 goto quit
%cc% ../cg_localents.c
@if errorlevel 1 goto quit
%cc% ../cg_main.c
@if errorlevel 1 goto quit
%cc% ../cg_marks.c
@if errorlevel 1 goto quit
%cc% ../cg_players.c
@if errorlevel 1 goto quit
%cc% ../cg_playerstate.c
@if errorlevel 1 goto quit
%cc% ../cg_predict.c
@if errorlevel 1 goto quit
%cc% ../cg_scoreboard.c
@if errorlevel 1 goto quit
%cc% ../cg_servercmds.c
@if errorlevel 1 goto quit
%cc% ../cg_snapshot.c
@if errorlevel 1 goto quit
%cc% ../cg_view.c
@if errorlevel 1 goto quit
%cc% ../cg_weapons.c
@if errorlevel 1 goto quit

q3asm -f ../cgame
:quit
cd ..
cgame.q3asm
-o "\quake3\code\vm\cgame"
cg_main
..\cg_syscalls
cg_consolecmds
cg_draw
cg_drawtools
cg_effects
cg_ents
cg_event
cg_info
cg_localents
cg_marks
cg_players
cg_playerstate
cg_predict
cg_scoreboard
cg_servercmds
cg_snapshot
cg_view
cg_weapons
bg_slidemove
bg_pmove
bg_lib
bg_misc
q_math
q_shared
^misantropia^
Posts: 4022
Joined: Sat Mar 12, 2005 6:24 pm

Post by ^misantropia^ »

Silicone_Milk wrote:Do you realize ^misantropia^ that we both joined Q3W on the same exact date yet you have 1000+ posts and I have around 70?
It's not as bad as it seems, though; I post, on average, 3.5 times a day and mostly in help topics. Even though the answer usually consists of only one or two lines, it's still postcount++ for me.
Silicone_Milk
Posts: 2237
Joined: Sat Mar 12, 2005 10:49 pm

Post by Silicone_Milk »

yea... thanks but the bat files still dont work. Im just going to give up on it for now as I don\'t really have any serious plans about making modifications to the source. I\'ve been mapping a lot more than coding lately.

though sometime in the future I do hope to do some weapon adjustments and tweak the rendering code a bit.
Magnus
Posts: 529
Joined: Wed Feb 16, 2005 6:38 pm

Post by Magnus »

^misantropia^ wrote: It's not as bad as it seems, though; I post, on average, 3.5 times a day and mostly in help topics. Even though the answer usually consists of only one or two lines, it's still postcount++ for me.
More proof that misantropia is a "Dedicated Server" Heh....jk.

Sorry I got silent guys.
I moved on the 31st. of last month and just got Charter to get here to hook up my service two days ago. :icon8:
It was supposed to be hooked up almost two weeks ago, but they failed to show up for 5 appointments! :icon22:

Oh well.
Uh, well....good luck with that. :shrug:

[img]http://i57.photobucket.com/albums/g228/Magnus3204/forumheader.jpg[/img]
Silicone_Milk
Posts: 2237
Joined: Sat Mar 12, 2005 10:49 pm

Post by Silicone_Milk »

hehe no worries man. I heard about your move. Hope all went well.

I've been doing lots of work in C++ so I've been learning A LOT. Now I might be able to make something out of the Quake 3 source code lol =)
I didn't understand the whole
weapon->bullet->does_this
but then I learned about it and fell in love with linked lists =P I use it for my projectile system in a side project I've been working on
Silicone_Milk
Posts: 2237
Joined: Sat Mar 12, 2005 10:49 pm

Post by Silicone_Milk »

Magnus, I decided to take another whack at the code and got cgame.qvm to compile after about 3 tweaks =)

Ill be making a compile bat for game and the ui after I take a shower.
Ill test them out to see if they are indeed compiling fine and not just saying so.

If you want the bats just let me know and Ill send them your way if you haven't got the code to compile yet.
sick2012
Posts: 1
Joined: Fri Mar 17, 2006 6:56 pm

Post by sick2012 »

so i got the same problem of magnus and i tried everything that ppl say here, and i got this

C:\quake3\source\game\vm>C:\quake3\source\game\lcc -DQ3_VM -S -Wf-target=bytecod
e -Wf-g -I..\..\cgame -I..\..\game -I..\..\ui ../g_main.c
C:\quake3\source\game\lcc: q3cpp: No such file or directory

i got lcc q3asm q3cpp q3rcc in the folder game.

Hey sillicone_milk can u post the bats that worked for you? thx =)
Silicone_Milk
Posts: 2237
Joined: Sat Mar 12, 2005 10:49 pm

Post by Silicone_Milk »

alright here's what I did. Make a copy of the exes in the bin folder (lcc.exe etc...)
throw a copy of these files in Cgame, Game, q3_ui

Now for cgame compile I have the following batch file:

Code: Select all

@echo off
echo compiling cgame\cg_main.c
lcc -DQ3_VM -DCGAME -S -Wf-target=bytecode -Wf-g  -I"C:\Quake3\hello\code\cgame" -I"C:\Quake3\hello\code\game" -I"C:\Quake3\hello\code\q3_ui" "C:\Quake3\hello\code\cgame\cg_main.c"
@if errorlevel 1 goto quit
echo compiling game\bg_slidemove.c
lcc -DQ3_VM -DCGAME -S -Wf-target=bytecode -Wf-g  -I"C:\Quake3\hello\code\cgame" -I"C:\Quake3\hello\code\game" -I"C:\Quake3\hello\code\q3_ui" "C:\Quake3\hello\code\game\bg_slidemove.c"
@if errorlevel 1 goto quit
echo compiling game\bg_pmove.c
lcc -DQ3_VM -DCGAME -S -Wf-target=bytecode -Wf-g  -I"C:\Quake3\hello\code\cgame" -I"C:\Quake3\hello\code\game" -I"C:\Quake3\hello\code\q3_ui" "C:\Quake3\hello\code\game\bg_pmove.c"
@if errorlevel 1 goto quit
echo compiling game\bg_lib.c
lcc -DQ3_VM -DCGAME -S -Wf-target=bytecode -Wf-g  -I"C:\Quake3\hello\code\cgame" -I"C:\Quake3\hello\code\game"  -I"C:\Quake3\hello\code\q3_ui" "C:\Quake3\hello\code\game\bg_lib.c"
@if errorlevel 1 goto quit
echo compiling game\bg_misc.c
lcc -DQ3_VM -DCGAME -S -Wf-target=bytecode -Wf-g  -I"C:\Quake3\hello\code\cgame" -I"C:\Quake3\hello\code\game" -I"C:\Quake3\hello\code\q3_ui" "C:\Quake3\hello\code\game\bg_misc.c"
@if errorlevel 1 goto quit
echo compiling game\q_math.c
lcc -DQ3_VM -DCGAME -S -Wf-target=bytecode -Wf-g  -I"C:\Quake3\hello\code\cgame" -I"C:\Quake3\hello\code\game" -I"C:\Quake3\hello\code\q3_ui" "C:\Quake3\hello\code\game\q_math.c"
@if errorlevel 1 goto quit
echo compiling game\q_shared.c
lcc -DQ3_VM -DCGAME -S -Wf-target=bytecode -Wf-g  -I"C:\Quake3\hello\code\cgame" -I"C:\Quake3\hello\code\game" -I"C:\Quake3\hello\code\q3_ui" "C:\Quake3\hello\code\game\q_shared.c"
@if errorlevel 1 goto quit
echo compiling cgame\cg_consolecmds.c
lcc -DQ3_VM -DCGAME -S -Wf-target=bytecode -Wf-g  -I"C:\Quake3\hello\code\cgame" -I"C:\Quake3\hello\code\game" -I"C:\Quake3\hello\code\q3_ui" "C:\Quake3\hello\code\cgame\cg_consolecmds.c"
@if errorlevel 1 goto quit
echo compiling cgame\cg_draw.c
lcc -DQ3_VM -DCGAME -S -Wf-target=bytecode -Wf-g  -I"C:\Quake3\hello\code\cgame" -I"C:\Quake3\hello\code\game" -I"C:\Quake3\hello\code\q3_ui" "C:\Quake3\hello\code\cgame\cg_draw.c"
@if errorlevel 1 goto quit
echo compiling cgame\cg_drawtools.c
lcc -DQ3_VM -DCGAME -S -Wf-target=bytecode -Wf-g  -I"C:\Quake3\hello\code\cgame" -I"C:\Quake3\hello\code\game" -I"C:\Quake3\hello\code\q3_ui" "C:\Quake3\hello\code\cgame\cg_drawtools.c"
@if errorlevel 1 goto quit
echo compiling cgame\cg_effects.c
lcc -DQ3_VM -DCGAME -S -Wf-target=bytecode -Wf-g  -I"C:\Quake3\hello\code\cgame" -I"C:\Quake3\hello\code\game" -I"C:\Quake3\hello\code\q3_ui" "C:\Quake3\hello\code\cgame\cg_effects.c"
@if errorlevel 1 goto quit
echo compiling cgame\cg_ents.c
lcc -DQ3_VM -DCGAME -S -Wf-target=bytecode -Wf-g  -I"C:\Quake3\hello\code\cgame" -I"C:\Quake3\hello\code\game" -I"C:\Quake3\hello\code\q3_ui" "C:\Quake3\hello\code\cgame\cg_ents.c"
@if errorlevel 1 goto quit
echo compiling cgame\cg_event.c
lcc -DQ3_VM -DCGAME -S -Wf-target=bytecode -Wf-g  -I"C:\Quake3\hello\code\cgame" -I"C:\Quake3\hello\code\game" -I"C:\Quake3\hello\code\q3_ui" "C:\Quake3\hello\code\cgame\cg_event.c"
@if errorlevel 1 goto quit
echo compiling cgame\cg_info.c
lcc -DQ3_VM -DCGAME -S -Wf-target=bytecode -Wf-g  -I"C:\Quake3\hello\code\cgame" -I"C:\Quake3\hello\code\game" -I"C:\Quake3\hello\code\q3_ui" "C:\Quake3\hello\code\cgame\cg_info.c"
@if errorlevel 1 goto quit
echo compiling cgame\cg_localents.c
lcc -DQ3_VM -DCGAME -S -Wf-target=bytecode -Wf-g  -I"C:\Quake3\hello\code\cgame" -I"C:\Quake3\hello\code\game" -I"C:\Quake3\hello\code\q3_ui" "C:\Quake3\hello\code\cgame\cg_localents.c"
@if errorlevel 1 goto quit
echo compiling cgame\cg_marks.c
lcc -DQ3_VM -DCGAME -S -Wf-target=bytecode -Wf-g  -I"C:\Quake3\hello\code\cgame" -I"C:\Quake3\hello\code\game"  -I"C:\Quake3\hello\code\q3_ui" "C:\Quake3\hello\code\cgame\cg_marks.c"
@if errorlevel 1 goto quit
echo compiling cgame\cg_players.c
lcc -DQ3_VM -DCGAME -S -Wf-target=bytecode -Wf-g  -I"C:\Quake3\hello\code\cgame" -I"C:\Quake3\hello\code\game" -I"C:\Quake3\hello\code\q3_ui" "C:\Quake3\hello\code\cgame\cg_players.c"
@if errorlevel 1 goto quit
echo compiling cgame\cg_playerstate.c
lcc -DQ3_VM -DCGAME -S -Wf-target=bytecode -Wf-g  -I"C:\Quake3\hello\code\cgame" -I"C:\Quake3\hello\code\game"  -I"C:\Quake3\hello\code\q3_ui" "C:\Quake3\hello\code\cgame\cg_playerstate.c"
@if errorlevel 1 goto quit
echo compiling cgame\cg_predict.c
lcc -DQ3_VM -DCGAME -S -Wf-target=bytecode -Wf-g  -I"C:\Quake3\hello\code\cgame" -I"C:\Quake3\hello\code\game"  -I"C:\Quake3\hello\code\q3_ui" "C:\Quake3\hello\code\cgame\cg_predict.c"
@if errorlevel 1 goto quit
echo compiling cgame\cg_scoreboard.c
lcc -DQ3_VM -DCGAME -S -Wf-target=bytecode -Wf-g  -I"C:\Quake3\hello\code\cgame" -I"C:\Quake3\hello\code\game" -I"C:\Quake3\hello\code\q3_ui" "C:\Quake3\hello\code\cgame\cg_scoreboard.c"
@if errorlevel 1 goto quit
echo compiling cgame\cg_servercmds.c
lcc -DQ3_VM -DCGAME -S -Wf-target=bytecode -Wf-g  -I"C:\Quake3\hello\code\cgame" -I"C:\Quake3\hello\code\game" -I"C:\Quake3\hello\code\q3_ui" "C:\Quake3\hello\code\cgame\cg_servercmds.c"
@if errorlevel 1 goto quit
echo compiling cgame\cg_snapshot.c
lcc -DQ3_VM -DCGAME -S -Wf-target=bytecode -Wf-g  -I"C:\Quake3\hello\code\cgame" -I"C:\Quake3\hello\code\game"  -I"C:\Quake3\hello\code\q3_ui" "C:\Quake3\hello\code\cgame\cg_snapshot.c"
@if errorlevel 1 goto quit
echo compiling cgame\cg_view.c
lcc -DQ3_VM -DCGAME -S -Wf-target=bytecode -Wf-g  -I"C:\Quake3\hello\code\cgame" -I"C:\Quake3\hello\code\game" -I"C:\Quake3\hello\code\q3_ui" "C:\Quake3\hello\code\cgame\cg_view.c"
@if errorlevel 1 goto quit
echo compiling cgame\cg_weapons.c
lcc -DQ3_VM -DCGAME -S -Wf-target=bytecode -Wf-g  -I"C:\Quake3\hello\code\cgame" -I"C:\Quake3\hello\code\game" -I"C:\Quake3\hello\code\q3_ui" "C:\Quake3\hello\code\cgame\cg_weapons.c"
@if errorlevel 1 goto quit

q3asm -o "C:\Quake3\hello\vm\cgame"  cg_main cg_syscalls bg_slidemove bg_pmove bg_lib bg_misc q_math q_shared cg_consolecmds cg_draw cg_drawtools cg_effects cg_ents cg_event cg_info cg_localents cg_marks cg_players cg_playerstate cg_predict cg_scoreboard cg_servercmds cg_snapshot cg_view cg_weapons
:quit
*note that you'll have to edit the file paths to fit your own directory. Or you can just set up your source directory exactly like mine since that'd be easier.

for Game folder I have this batch:

Code: Select all

@echo off

echo compiling game\g_main.c
lcc -DQ3_VM -DCGAME -S -Wf-target=bytecode -Wf-g  -I"C:\Quake3\hello\code\cgame" -I"C:\Quake3\hello\code\game" -I"C:\Quake3\hello\code\q3_ui" "C:\Quake3\hello\code\game\g_main.c"
@if errorlevel 1 goto quit

echo compiling cgame\ai_chat.c
lcc -DQ3_VM -DCGAME -S -Wf-target=bytecode -Wf-g  -I"C:\Quake3\hello\code\cgame" -I"C:\Quake3\hello\code\game" -I"C:\Quake3\hello\code\q3_ui" "C:\Quake3\hello\code\game\ai_chat.c"
@if errorlevel 1 goto quit

echo compiling game\ai_cmd.c
lcc -DQ3_VM -DCGAME -S -Wf-target=bytecode -Wf-g  -I"C:\Quake3\hello\code\cgame" -I"C:\Quake3\hello\code\game" -I"C:\Quake3\hello\code\q3_ui" "C:\Quake3\hello\code\game\ai_cmd.c"
@if errorlevel 1 goto quit

echo compiling game\bg_lib.c
lcc -DQ3_VM -DCGAME -S -Wf-target=bytecode -Wf-g  -I"C:\Quake3\hello\code\cgame" -I"C:\Quake3\hello\code\game" -I"C:\Quake3\hello\code\q3_ui" "C:\Quake3\hello\code\game\bg_lib.c"
@if errorlevel 1 goto quit

echo compiling game\ai_dmnet.c
lcc -DQ3_VM -DCGAME -S -Wf-target=bytecode -Wf-g  -I"C:\Quake3\hello\code\cgame" -I"C:\Quake3\hello\code\game" -I"C:\Quake3\hello\code\q3_ui" "C:\Quake3\hello\code\game\ai_dmnet.c"
@if errorlevel 1 goto quit

echo compiling game\ai_dmq3.c
lcc -DQ3_VM -DCGAME -S -Wf-target=bytecode -Wf-g  -I"C:\Quake3\hello\code\cgame" -I"C:\Quake3\hello\code\game" -I"C:\Quake3\hello\code\q3_ui" "C:\Quake3\hello\code\game\ai_dmq3.c"
@if errorlevel 1 goto quit

echo compiling game\ai_main.c
lcc -DQ3_VM -DCGAME -S -Wf-target=bytecode -Wf-g  -I"C:\Quake3\hello\code\cgame" -I"C:\Quake3\hello\code\game" -I"C:\Quake3\hello\code\q3_ui" "C:\Quake3\hello\code\game\ai_main.c"
@if errorlevel 1 goto quit

echo compiling game\ai_team.c
lcc -DQ3_VM -DCGAME -S -Wf-target=bytecode -Wf-g  -I"C:\Quake3\hello\code\cgame" -I"C:\Quake3\hello\code\game" -I"C:\Quake3\hello\code\q3_ui" "C:\Quake3\hello\code\game\ai_team.c"
@if errorlevel 1 goto quit

echo compiling game\ai_vcmd.c
lcc -DQ3_VM -DCGAME -S -Wf-target=bytecode -Wf-g  -I"C:\Quake3\hello\code\cgame" -I"C:\Quake3\hello\code\game" -I"C:\Quake3\hello\code\q3_ui" "C:\Quake3\hello\code\game\ai_vcmd.c"
@if errorlevel 1 goto quit

echo compiling game\bg_misc.c
lcc -DQ3_VM -DCGAME -S -Wf-target=bytecode -Wf-g  -I"C:\Quake3\hello\code\cgame" -I"C:\Quake3\hello\code\game" -I"C:\Quake3\hello\code\q3_ui" "C:\Quake3\hello\code\game\bg_misc.c"
@if errorlevel 1 goto quit

echo compiling game\bg_pmove.c
lcc -DQ3_VM -DCGAME -S -Wf-target=bytecode -Wf-g  -I"C:\Quake3\hello\code\cgame" -I"C:\Quake3\hello\code\game" -I"C:\Quake3\hello\code\q3_ui" "C:\Quake3\hello\code\game\bg_pmove.c"
@if errorlevel 1 goto quit

echo compiling game\bg_slidemove.c
lcc -DQ3_VM -DCGAME -S -Wf-target=bytecode -Wf-g  -I"C:\Quake3\hello\code\cgame" -I"C:\Quake3\hello\code\game" -I"C:\Quake3\hello\code\q3_ui" "C:\Quake3\hello\code\game\bg_slidemove.c"
@if errorlevel 1 goto quit

echo compiling game\g_active.c
lcc -DQ3_VM -DCGAME -S -Wf-target=bytecode -Wf-g  -I"C:\Quake3\hello\code\cgame" -I"C:\Quake3\hello\code\game" -I"C:\Quake3\hello\code\q3_ui" "C:\Quake3\hello\code\game\g_active.c"
@if errorlevel 1 goto quit

echo compiling game\g_arenas.c
lcc -DQ3_VM -DCGAME -S -Wf-target=bytecode -Wf-g  -I"C:\Quake3\hello\code\cgame" -I"C:\Quake3\hello\code\game" -I"C:\Quake3\hello\code\q3_ui" "C:\Quake3\hello\code\game\g_arenas.c"
@if errorlevel 1 goto quit

echo compiling game\g_bot.c
lcc -DQ3_VM -DCGAME -S -Wf-target=bytecode -Wf-g  -I"C:\Quake3\hello\code\cgame" -I"C:\Quake3\hello\code\game" -I"C:\Quake3\hello\code\q3_ui" "C:\Quake3\hello\code\game\g_bot.c"
@if errorlevel 1 goto quit

echo compiling game\g_client.c
lcc -DQ3_VM -DCGAME -S -Wf-target=bytecode -Wf-g  -I"C:\Quake3\hello\code\cgame" -I"C:\Quake3\hello\code\game" -I"C:\Quake3\hello\code\q3_ui" "C:\Quake3\hello\code\game\g_client.c"
@if errorlevel 1 goto quit

echo compiling game\g_cmds.c
lcc -DQ3_VM -DCGAME -S -Wf-target=bytecode -Wf-g  -I"C:\Quake3\hello\code\cgame" -I"C:\Quake3\hello\code\game" -I"C:\Quake3\hello\code\q3_ui" "C:\Quake3\hello\code\game\g_cmds.c"
@if errorlevel 1 goto quit

echo compiling game\g_combat.c
lcc -DQ3_VM -DCGAME -S -Wf-target=bytecode -Wf-g  -I"C:\Quake3\hello\code\cgame" -I"C:\Quake3\hello\code\game" -I"C:\Quake3\hello\code\q3_ui" "C:\Quake3\hello\code\game\g_combat.c"
@if errorlevel 1 goto quit

echo compiling game\g_items.c
lcc -DQ3_VM -DCGAME -S -Wf-target=bytecode -Wf-g  -I"C:\Quake3\hello\code\cgame" -I"C:\Quake3\hello\code\game" -I"C:\Quake3\hello\code\q3_ui" "C:\Quake3\hello\code\game\g_items.c"
@if errorlevel 1 goto quit

echo compiling game\g_mem.c
lcc -DQ3_VM -DCGAME -S -Wf-target=bytecode -Wf-g  -I"C:\Quake3\hello\code\cgame" -I"C:\Quake3\hello\code\game" -I"C:\Quake3\hello\code\q3_ui" "C:\Quake3\hello\code\game\g_mem.c"
@if errorlevel 1 goto quit

echo compiling game\g_misc.c
lcc -DQ3_VM -DCGAME -S -Wf-target=bytecode -Wf-g  -I"C:\Quake3\hello\code\cgame" -I"C:\Quake3\hello\code\game" -I"C:\Quake3\hello\code\q3_ui" "C:\Quake3\hello\code\game\g_misc.c"
@if errorlevel 1 goto quit

echo compiling game\g_missile.c
lcc -DQ3_VM -DCGAME -S -Wf-target=bytecode -Wf-g  -I"C:\Quake3\hello\code\cgame" -I"C:\Quake3\hello\code\game" -I"C:\Quake3\hello\code\q3_ui" "C:\Quake3\hello\code\game\g_missile.c"
@if errorlevel 1 goto quit

echo compiling game\g_mover.c
lcc -DQ3_VM -DCGAME -S -Wf-target=bytecode -Wf-g  -I"C:\Quake3\hello\code\cgame" -I"C:\Quake3\hello\code\game" -I"C:\Quake3\hello\code\q3_ui" "C:\Quake3\hello\code\game\g_mover.c"
@if errorlevel 1 goto quit


echo compiling game\g_session.c
lcc -DQ3_VM -DCGAME -S -Wf-target=bytecode -Wf-g  -I"C:\Quake3\hello\code\cgame" -I"C:\Quake3\hello\code\game" -I"C:\Quake3\hello\code\q3_ui" "C:\Quake3\hello\code\game\g_session.c"
@if errorlevel 1 goto quit

echo compiling game\g_spawn.c
lcc -DQ3_VM -DCGAME -S -Wf-target=bytecode -Wf-g  -I"C:\Quake3\hello\code\cgame" -I"C:\Quake3\hello\code\game" -I"C:\Quake3\hello\code\q3_ui" "C:\Quake3\hello\code\game\g_spawn.c"
@if errorlevel 1 goto quit

echo compiling game\g_svcmds.c
lcc -DQ3_VM -DCGAME -S -Wf-target=bytecode -Wf-g  -I"C:\Quake3\hello\code\cgame" -I"C:\Quake3\hello\code\game" -I"C:\Quake3\hello\code\q3_ui" "C:\Quake3\hello\code\game\g_svcmds.c"
@if errorlevel 1 goto quit


echo compiling game\g_target.c
lcc -DQ3_VM -DCGAME -S -Wf-target=bytecode -Wf-g  -I"C:\Quake3\hello\code\cgame" -I"C:\Quake3\hello\code\game" -I"C:\Quake3\hello\code\q3_ui" "C:\Quake3\hello\code\game\g_target.c"
@if errorlevel 1 goto quit

echo compiling game\g_team.c
lcc -DQ3_VM -DCGAME -S -Wf-target=bytecode -Wf-g  -I"C:\Quake3\hello\code\cgame" -I"C:\Quake3\hello\code\game" -I"C:\Quake3\hello\code\q3_ui" "C:\Quake3\hello\code\game\g_team.c"
@if errorlevel 1 goto quit

echo compiling game\g_trigger.c
lcc -DQ3_VM -DCGAME -S -Wf-target=bytecode -Wf-g  -I"C:\Quake3\hello\code\cgame" -I"C:\Quake3\hello\code\game" -I"C:\Quake3\hello\code\q3_ui" "C:\Quake3\hello\code\game\g_trigger.c"
@if errorlevel 1 goto quit

echo compiling game\g_utils.c
lcc -DQ3_VM -DCGAME -S -Wf-target=bytecode -Wf-g  -I"C:\Quake3\hello\code\cgame" -I"C:\Quake3\hello\code\game" -I"C:\Quake3\hello\code\q3_ui" "C:\Quake3\hello\code\game\g_utils.c"
@if errorlevel 1 goto quit

echo compiling game\g_weapon.c
lcc -DQ3_VM -DCGAME -S -Wf-target=bytecode -Wf-g  -I"C:\Quake3\hello\code\cgame" -I"C:\Quake3\hello\code\game" -I"C:\Quake3\hello\code\q3_ui" "C:\Quake3\hello\code\game\g_weapon.c"
@if errorlevel 1 goto quit

echo compiling game\q_math.c
lcc -DQ3_VM -DCGAME -S -Wf-target=bytecode -Wf-g  -I"C:\Quake3\hello\code\cgame" -I"C:\Quake3\hello\code\game" -I"C:\Quake3\hello\code\q3_ui" "C:\Quake3\hello\code\game\q_math.c"
@if errorlevel 1 goto quit

echo compiling game\q_shared.c
lcc -DQ3_VM -DCGAME -S -Wf-target=bytecode -Wf-g  -I"C:\Quake3\hello\code\cgame" -I"C:\Quake3\hello\code\game" -I"C:\Quake3\hello\code\q3_ui" "C:\Quake3\hello\code\game\q_shared.c"
@if errorlevel 1 goto quit

q3asm -o "C:\Quake3\hello\vm\game"  g_main ai_chat ai_cmd ai_dmnet ai_dmq3 ai_main ai_team ai_vcmd bg_misc bg_pmove bg_slidemove g_active g_arenas g_bot g_client g_cmds g_combat g_items g_mem g_misc g_missile g_mover g_syscalls g_session g_spawn g_svcmds g_target g_team g_trigger g_utils g_weapon q_math q_shared bg_lib
:quit
Finally, q3_ui gave me the most trouble. Two parts to this one. I have a batch file and a q3asm file written:
Compile.bat:

Code: Select all

@echo off
echo compiling cgame\ui_atoms.c
lcc -DQ3_VM -DCGAME -S -Wf-target=bytecode -Wf-g  -I"C:\Quake3\hello\code\cgame" -I"C:\Quake3\hello\code\game" -I"C:\Quake3\hello\code\q3_ui" "C:\Quake3\hello\code\q3_ui\ui_atoms.c"
@if errorlevel 1 goto quit

echo compiling cgame\ui_gameinfo.c
lcc -DQ3_VM -DCGAME -S -Wf-target=bytecode -Wf-g  -I"C:\Quake3\hello\code\cgame" -I"C:\Quake3\hello\code\game" -I"C:\Quake3\hello\code\q3_ui" "C:\Quake3\hello\code\q3_ui\ui_gameinfo.c"
@if errorlevel 1 goto quit

echo compiling cgame\ui_main.c
lcc -DQ3_VM -DCGAME -S -Wf-target=bytecode -Wf-g  -I"C:\Quake3\hello\code\cgame" -I"C:\Quake3\hello\code\game" -I"C:\Quake3\hello\code\q3_ui" "C:\Quake3\hello\code\q3_ui\ui_main.c"
@if errorlevel 1 goto quit

echo compiling cgame\ui_players.c
lcc -DQ3_VM -DCGAME -S -Wf-target=bytecode -Wf-g  -I"C:\Quake3\hello\code\cgame" -I"C:\Quake3\hello\code\game" -I"C:\Quake3\hello\code\q3_ui" "C:\Quake3\hello\code\q3_ui\ui_players.c"
@if errorlevel 1 goto quit

echo compiling cgame\ui_addbots.c
lcc -DQ3_VM -DCGAME -S -Wf-target=bytecode -Wf-g  -I"C:\Quake3\hello\code\cgame" -I"C:\Quake3\hello\code\game" -I"C:\Quake3\hello\code\q3_ui" "C:\Quake3\hello\code\q3_ui\ui_addbots.c"
@if errorlevel 1 goto quit


echo compiling cgame\ui_cdkey.c
lcc -DQ3_VM -DCGAME -S -Wf-target=bytecode -Wf-g  -I"C:\Quake3\hello\code\cgame" -I"C:\Quake3\hello\code\game" -I"C:\Quake3\hello\code\q3_ui" "C:\Quake3\hello\code\q3_ui\ui_cdkey.c"
@if errorlevel 1 goto quit


echo compiling cgame\ui_cinematics.c
lcc -DQ3_VM -DCGAME -S -Wf-target=bytecode -Wf-g  -I"C:\Quake3\hello\code\cgame" -I"C:\Quake3\hello\code\game" -I"C:\Quake3\hello\code\q3_ui" "C:\Quake3\hello\code\q3_ui\ui_cinematics.c"
@if errorlevel 1 goto quit


echo compiling cgame\ui_confirm.c
lcc -DQ3_VM -DCGAME -S -Wf-target=bytecode -Wf-g  -I"C:\Quake3\hello\code\cgame" -I"C:\Quake3\hello\code\game" -I"C:\Quake3\hello\code\q3_ui" "C:\Quake3\hello\code\q3_ui\ui_confirm.c"
@if errorlevel 1 goto quit


echo compiling cgame\ui_connect.c
lcc -DQ3_VM -DCGAME -S -Wf-target=bytecode -Wf-g  -I"C:\Quake3\hello\code\cgame" -I"C:\Quake3\hello\code\game" -I"C:\Quake3\hello\code\q3_ui" "C:\Quake3\hello\code\q3_ui\ui_connect.c"
@if errorlevel 1 goto quit


echo compiling cgame\ui_controls2.c
lcc -DQ3_VM -DCGAME -S -Wf-target=bytecode -Wf-g  -I"C:\Quake3\hello\code\cgame" -I"C:\Quake3\hello\code\game" -I"C:\Quake3\hello\code\q3_ui" "C:\Quake3\hello\code\q3_ui\ui_controls2.c"
@if errorlevel 1 goto quit


echo compiling cgame\ui_credits.c
lcc -DQ3_VM -DCGAME -S -Wf-target=bytecode -Wf-g  -I"C:\Quake3\hello\code\cgame" -I"C:\Quake3\hello\code\game" -I"C:\Quake3\hello\code\q3_ui" "C:\Quake3\hello\code\q3_ui\ui_credits.c"
@if errorlevel 1 goto quit


echo compiling cgame\ui_demo2.c
lcc -DQ3_VM -DCGAME -S -Wf-target=bytecode -Wf-g  -I"C:\Quake3\hello\code\cgame" -I"C:\Quake3\hello\code\game" -I"C:\Quake3\hello\code\q3_ui" "C:\Quake3\hello\code\q3_ui\ui_demo2.c"
@if errorlevel 1 goto quit

echo compiling cgame\ui_display.c
lcc -DQ3_VM -DCGAME -S -Wf-target=bytecode -Wf-g  -I"C:\Quake3\hello\code\cgame" -I"C:\Quake3\hello\code\game" -I"C:\Quake3\hello\code\q3_ui" "C:\Quake3\hello\code\q3_ui\ui_display.c"
@if errorlevel 1 goto quit

echo compiling cgame\ui_ingame.c
lcc -DQ3_VM -DCGAME -S -Wf-target=bytecode -Wf-g  -I"C:\Quake3\hello\code\cgame" -I"C:\Quake3\hello\code\game" -I"C:\Quake3\hello\code\q3_ui" "C:\Quake3\hello\code\q3_ui\ui_ingame.c"
@if errorlevel 1 goto quit


echo compiling cgame\ui_loadconfig.c
lcc -DQ3_VM -DCGAME -S -Wf-target=bytecode -Wf-g  -I"C:\Quake3\hello\code\cgame" -I"C:\Quake3\hello\code\game" -I"C:\Quake3\hello\code\q3_ui" "C:\Quake3\hello\code\q3_ui\ui_loadconfig.c"
@if errorlevel 1 goto quit


echo compiling cgame\ui_login.c
lcc -DQ3_VM -DCGAME -S -Wf-target=bytecode -Wf-g  -I"C:\Quake3\hello\code\cgame" -I"C:\Quake3\hello\code\game" -I"C:\Quake3\hello\code\q3_ui" "C:\Quake3\hello\code\q3_ui\ui_login.c"
@if errorlevel 1 goto quit

echo compiling cgame\ui_menu.c
lcc -DQ3_VM -DCGAME -S -Wf-target=bytecode -Wf-g  -I"C:\Quake3\hello\code\cgame" -I"C:\Quake3\hello\code\game" -I"C:\Quake3\hello\code\q3_ui" "C:\Quake3\hello\code\q3_ui\ui_menu.c"
@if errorlevel 1 goto quit

echo compiling cgame\ui_mfield.c
lcc -DQ3_VM -DCGAME -S -Wf-target=bytecode -Wf-g  -I"C:\Quake3\hello\code\cgame" -I"C:\Quake3\hello\code\game" -I"C:\Quake3\hello\code\q3_ui" "C:\Quake3\hello\code\q3_ui\ui_mfield.c"
@if errorlevel 1 goto quit

echo compiling cgame\ui_mods.c
lcc -DQ3_VM -DCGAME -S -Wf-target=bytecode -Wf-g  -I"C:\Quake3\hello\code\cgame" -I"C:\Quake3\hello\code\game" -I"C:\Quake3\hello\code\q3_ui" "C:\Quake3\hello\code\q3_ui\ui_mods.c"
@if errorlevel 1 goto quit


echo compiling cgame\ui_network.c
lcc -DQ3_VM -DCGAME -S -Wf-target=bytecode -Wf-g  -I"C:\Quake3\hello\code\cgame" -I"C:\Quake3\hello\code\game" -I"C:\Quake3\hello\code\q3_ui" "C:\Quake3\hello\code\q3_ui\ui_network.c"
@if errorlevel 1 goto quit

echo compiling cgame\ui_options.c
lcc -DQ3_VM -DCGAME -S -Wf-target=bytecode -Wf-g  -I"C:\Quake3\hello\code\cgame" -I"C:\Quake3\hello\code\game" -I"C:\Quake3\hello\code\q3_ui" "C:\Quake3\hello\code\q3_ui\ui_options.c"
@if errorlevel 1 goto quit

echo compiling cgame\ui_playermodel.c
lcc -DQ3_VM -DCGAME -S -Wf-target=bytecode -Wf-g  -I"C:\Quake3\hello\code\cgame" -I"C:\Quake3\hello\code\game" -I"C:\Quake3\hello\code\q3_ui" "C:\Quake3\hello\code\q3_ui\ui_playermodel.c"
@if errorlevel 1 goto quit

echo compiling cgame\ui_playersettings.c
lcc -DQ3_VM -DCGAME -S -Wf-target=bytecode -Wf-g  -I"C:\Quake3\hello\code\cgame" -I"C:\Quake3\hello\code\game" -I"C:\Quake3\hello\code\q3_ui" "C:\Quake3\hello\code\q3_ui\ui_playersettings.c"
@if errorlevel 1 goto quit

echo compiling cgame\ui_preferences.c
lcc -DQ3_VM -DCGAME -S -Wf-target=bytecode -Wf-g  -I"C:\Quake3\hello\code\cgame" -I"C:\Quake3\hello\code\game" -I"C:\Quake3\hello\code\q3_ui" "C:\Quake3\hello\code\q3_ui\ui_preferences.c"
@if errorlevel 1 goto quit

echo compiling cgame\ui_qmenu.c
lcc -DQ3_VM -DCGAME -S -Wf-target=bytecode -Wf-g  -I"C:\Quake3\hello\code\cgame" -I"C:\Quake3\hello\code\game" -I"C:\Quake3\hello\code\q3_ui" "C:\Quake3\hello\code\q3_ui\ui_qmenu.c"
@if errorlevel 1 goto quit

echo compiling cgame\ui_removebots.c
lcc -DQ3_VM -DCGAME -S -Wf-target=bytecode -Wf-g  -I"C:\Quake3\hello\code\cgame" -I"C:\Quake3\hello\code\game" -I"C:\Quake3\hello\code\q3_ui" "C:\Quake3\hello\code\q3_ui\ui_removebots.c"
@if errorlevel 1 goto quit

echo compiling cgame\ui_saveconfig.c
lcc -DQ3_VM -DCGAME -S -Wf-target=bytecode -Wf-g  -I"C:\Quake3\hello\code\cgame" -I"C:\Quake3\hello\code\game" -I"C:\Quake3\hello\code\q3_ui" "C:\Quake3\hello\code\q3_ui\ui_saveconfig.c"
@if errorlevel 1 goto quit


echo compiling cgame\ui_serverinfo.c
lcc -DQ3_VM -DCGAME -S -Wf-target=bytecode -Wf-g  -I"C:\Quake3\hello\code\cgame" -I"C:\Quake3\hello\code\game" -I"C:\Quake3\hello\code\q3_ui" "C:\Quake3\hello\code\q3_ui\ui_serverinfo.c"
@if errorlevel 1 goto quit

echo compiling cgame\ui_servers2.c
lcc -DQ3_VM -DCGAME -S -Wf-target=bytecode -Wf-g  -I"C:\Quake3\hello\code\cgame" -I"C:\Quake3\hello\code\game" -I"C:\Quake3\hello\code\q3_ui" "C:\Quake3\hello\code\q3_ui\ui_servers2.c"
@if errorlevel 1 goto quit

echo compiling cgame\ui_setup.c
lcc -DQ3_VM -DCGAME -S -Wf-target=bytecode -Wf-g  -I"C:\Quake3\hello\code\cgame" -I"C:\Quake3\hello\code\game" -I"C:\Quake3\hello\code\q3_ui" "C:\Quake3\hello\code\q3_ui\ui_setup.c"
@if errorlevel 1 goto quit

echo compiling cgame\ui_sound.c
lcc -DQ3_VM -DCGAME -S -Wf-target=bytecode -Wf-g  -I"C:\Quake3\hello\code\cgame" -I"C:\Quake3\hello\code\game" -I"C:\Quake3\hello\code\q3_ui" "C:\Quake3\hello\code\q3_ui\ui_sound.c"
@if errorlevel 1 goto quit

echo compiling cgame\ui_sparena.c
lcc -DQ3_VM -DCGAME -S -Wf-target=bytecode -Wf-g  -I"C:\Quake3\hello\code\cgame" -I"C:\Quake3\hello\code\game" -I"C:\Quake3\hello\code\q3_ui" "C:\Quake3\hello\code\q3_ui\ui_sparena.c"
@if errorlevel 1 goto quit

echo compiling cgame\ui_specifyleague.c
lcc -DQ3_VM -DCGAME -S -Wf-target=bytecode -Wf-g  -I"C:\Quake3\hello\code\cgame" -I"C:\Quake3\hello\code\game" -I"C:\Quake3\hello\code\q3_ui" "C:\Quake3\hello\code\q3_ui\ui_specifyleague.c"
@if errorlevel 1 goto quit

echo compiling cgame\ui_specifyserver.c
lcc -DQ3_VM -DCGAME -S -Wf-target=bytecode -Wf-g  -I"C:\Quake3\hello\code\cgame" -I"C:\Quake3\hello\code\game" -I"C:\Quake3\hello\code\q3_ui" "C:\Quake3\hello\code\q3_ui\ui_specifyserver.c"
@if errorlevel 1 goto quit

echo compiling cgame\ui_splevel.c
lcc -DQ3_VM -DCGAME -S -Wf-target=bytecode -Wf-g  -I"C:\Quake3\hello\code\cgame" -I"C:\Quake3\hello\code\game" -I"C:\Quake3\hello\code\q3_ui" "C:\Quake3\hello\code\q3_ui\ui_splevel.c"
@if errorlevel 1 goto quit

echo compiling cgame\ui_sppostgame.c
lcc -DQ3_VM -DCGAME -S -Wf-target=bytecode -Wf-g  -I"C:\Quake3\hello\code\cgame" -I"C:\Quake3\hello\code\game" -I"C:\Quake3\hello\code\q3_ui" "C:\Quake3\hello\code\q3_ui\ui_sppostgame.c"
@if errorlevel 1 goto quit

echo compiling cgame\ui_spreset.c
lcc -DQ3_VM -DCGAME -S -Wf-target=bytecode -Wf-g  -I"C:\Quake3\hello\code\cgame" -I"C:\Quake3\hello\code\game" -I"C:\Quake3\hello\code\q3_ui" "C:\Quake3\hello\code\q3_ui\ui_spreset.c"
@if errorlevel 1 goto quit

echo compiling cgame\ui_spskill.c
lcc -DQ3_VM -DCGAME -S -Wf-target=bytecode -Wf-g  -I"C:\Quake3\hello\code\cgame" -I"C:\Quake3\hello\code\game" -I"C:\Quake3\hello\code\q3_ui" "C:\Quake3\hello\code\q3_ui\ui_spskill.c"
@if errorlevel 1 goto quit

echo compiling cgame\ui_startserver.c
lcc -DQ3_VM -DCGAME -S -Wf-target=bytecode -Wf-g  -I"C:\Quake3\hello\code\cgame" -I"C:\Quake3\hello\code\game" -I"C:\Quake3\hello\code\q3_ui" "C:\Quake3\hello\code\q3_ui\ui_startserver.c"
@if errorlevel 1 goto quit

echo compiling cgame\ui_team.c
lcc -DQ3_VM -DCGAME -S -Wf-target=bytecode -Wf-g  -I"C:\Quake3\hello\code\cgame" -I"C:\Quake3\hello\code\game" -I"C:\Quake3\hello\code\q3_ui" "C:\Quake3\hello\code\q3_ui\ui_team.c"
@if errorlevel 1 goto quit

echo compiling cgame\ui_teamorders.c
lcc -DQ3_VM -DCGAME -S -Wf-target=bytecode -Wf-g  -I"C:\Quake3\hello\code\cgame" -I"C:\Quake3\hello\code\game" -I"C:\Quake3\hello\code\q3_ui" "C:\Quake3\hello\code\q3_ui\ui_teamorders.c"
@if errorlevel 1 goto quit

echo compiling cgame\ui_video.c
lcc -DQ3_VM -DCGAME -S -Wf-target=bytecode -Wf-g  -I"C:\Quake3\hello\code\cgame" -I"C:\Quake3\hello\code\game" -I"C:\Quake3\hello\code\q3_ui" "C:\Quake3\hello\code\q3_ui\ui_video.c"
@if errorlevel 1 goto quit

q3asm -f q3_ui

:quit
q3_ui.q3asm:

Code: Select all

-o "../../vm/q3_ui"
ui_main
ui_syscalls
ui_gameinfo
ui_atoms
ui_cinematics
ui_connect
ui_controls2
ui_demo2
ui_mfield
ui_credits
ui_menu
ui_ingame
ui_confirm
ui_setup
ui_options
ui_display
ui_sound
ui_network
ui_playermodel
ui_players
ui_playersettings
ui_preferences
ui_qmenu
ui_serverinfo
ui_servers2
ui_sparena
ui_specifyserver
ui_sppostgame
ui_splevel
ui_spskill
ui_startserver
ui_team
ui_video
ui_addbots
ui_removebots
ui_teamorders
ui_cdkey
ui_mods
../game/bg_misc
../game/bg_lib
../game/q_math
../game/q_shared
just copy the batch files and put them in their respective folders and then open command prompt and type their file name in. Compile should run fine.
*note that the qvms are saved to the folder "C:\quake3\hello\vm"
so if you dont see it in your game/cgame/q3_ui folder you know the reason why ;)

I also haven't fixed this because it doesn't bother me but the q3_ui batch file echos that its compiling the ui files from the cgame folder. Just ignore that since it's compiling from the q3_ui folder just like it should.

Hope that helps.
Silicone_Milk
Posts: 2237
Joined: Sat Mar 12, 2005 10:49 pm

Post by Silicone_Milk »

oh yea almost forgot. The cg_syscalls.asm, g_syscalls.asm, and ui_syscalls.asm files will be giving you a lot of crap saying so-and-so symbol isn't defined. The asm files aren't complete and you need to define them manually so I have these .asm files you need to paste in to your working directories.
Cgame, Game, UI folders respectively:

cg_syscalls.asm:

Code: Select all

code

equ	trap_Print					-1
equ	trap_Error					-2
equ	trap_Milliseconds			-3
equ	trap_Cvar_Register			-4
equ	trap_Cvar_Update			-5
equ	trap_Cvar_Set				-6
equ trap_Cvar_VariableStringBuffer -7
equ	trap_Argc					-8
equ	trap_Argv					-9
equ	trap_Args					-10
equ	trap_FS_FOpenFile			-11
equ	trap_FS_Read				-12
equ	trap_FS_Write				-13 
equ	trap_FS_FCloseFile			-14
equ	trap_SendConsoleCommand		-15
equ	trap_AddCommand				-16
equ	trap_SendClientCommand		-17
equ	trap_UpdateScreen			-18
equ	trap_CM_LoadMap				-19
equ	trap_CM_NumInlineModels		-20
equ	trap_CM_InlineModel			-21
equ	trap_CM_LoadModel			-22
equ	trap_CM_TempBoxModel		-23
equ	trap_CM_PointContents		-24
equ	trap_CM_TransformedPointContents	-25
equ	trap_CM_BoxTrace			-26
equ	trap_CM_TransformedBoxTrace	-27
equ	trap_CM_MarkFragments		-28
equ	trap_S_StartSound			-29
equ	trap_S_StartLocalSound		-30
equ	trap_S_ClearLoopingSounds	-31
equ	trap_S_AddLoopingSound		-32
equ	trap_S_UpdateEntityPosition	-33
equ	trap_S_Respatialize			-34
equ	trap_S_RegisterSound		-35
equ	trap_S_StartBackgroundTrack	-36
equ	trap_R_LoadWorldMap			-37
equ	trap_R_RegisterModel		-38
equ	trap_R_RegisterSkin			-39
equ	trap_R_RegisterShader		-40
equ	trap_R_ClearScene			-41
equ	trap_R_AddRefEntityToScene	-42
equ	trap_R_AddPolyToScene		-43
equ	trap_R_AddLightToScene		-44
equ	trap_R_RenderScene			-45
equ	trap_R_SetColor				-46
equ	trap_R_DrawStretchPic		-47
equ	trap_R_ModelBounds			-48
equ	trap_R_LerpTag				-49
equ	trap_GetGlconfig			-50
equ	trap_GetGameState			-51
equ	trap_GetCurrentSnapshotNumber	-52
equ	trap_GetSnapshot			-53
equ	trap_GetServerCommand		-54
equ	trap_GetCurrentCmdNumber	-55
equ	trap_GetUserCmd				-56
equ	trap_SetUserCmdValue		-57
equ	trap_R_RegisterShaderNoMip		-58
equ	trap_MemoryRemaining		-59
equ     trap_SnapVector                 -60
equ     trap_S_AddRealLoopingSound      -61
equ     trap_S_StopLoopingSound     -62
equ     trap_R_LightForPoint        -63
equ     trap_R_RemapShader          -64



equ	memset						-101
equ	memcpy						-102
equ	strncpy						-103
equ	sin							-104
equ	cos							-105
equ	atan2						-106
equ	sqrt						-107
equ floor						-108
equ	ceil						-109
equ	testPrintInt				-110
equ	testPrintFloat				-111
equ     acos                                    -112

g_syscalls.asm:

Code: Select all

code

equ	trap_Printf				-1
equ	trap_Error				-2
equ	trap_Milliseconds		-3
equ	trap_Cvar_Register		-4
equ	trap_Cvar_Update		-5
equ	trap_Cvar_Set			-6
equ	trap_Cvar_VariableIntegerValue	-7
equ	trap_Cvar_VariableStringBuffer	-8
equ	trap_Argc				-9
equ	trap_Argv				-10
equ	trap_FS_FOpenFile		-11
equ	trap_FS_Read			-12
equ	trap_FS_Write			-13
equ	trap_FS_FCloseFile		-14
equ	trap_SendConsoleCommand	-15
equ	trap_LocateGameData		-16
equ	trap_DropClient			-17
equ	trap_SendServerCommand	-18
equ	trap_SetConfigstring	-19
equ	trap_GetConfigstring	-20
equ	trap_GetUserinfo		-21
equ	trap_SetUserinfo		-22
equ	trap_GetServerinfo		-23
equ	trap_SetBrushModel		-24
equ	trap_Trace				-25
equ	trap_PointContents		-26
equ trap_InPVS				-27
equ	trap_InPVSIgnorePortals	-28
equ	trap_AdjustAreaPortalState	-29
equ	trap_AreasConnected		-30
equ	trap_LinkEntity			-31
equ	trap_UnlinkEntity		-32
equ	trap_EntitiesInBox		-33
equ	trap_EntityContact		-34
equ	trap_BotAllocateClient	-35
equ	trap_BotFreeClient		-36
equ	trap_GetUsercmd			-37
equ	trap_GetEntityToken		-38
equ	trap_FS_GetFileList		-39
equ trap_DebugPolygonCreate	-40
equ trap_DebugPolygonDelete	-41
equ trap_SnapVector -42

equ	memset					-101
equ	memcpy					-102
equ	strncpy					-103
equ	sin						-104
equ	cos						-105
equ	atan2					-106
equ	sqrt					-107
equ     vsprintf                                -108
equ     strcmp                                  -109
equ     srand                                   -110
equ     qsort                                   -111
equ     strlen                                  -112
equ     atoi                                    -113

equ floor					-114
equ	ceil					-115
equ	testPrintInt			-116
equ	testPrintFloat			-117
equ     rand                            -118
equ     strcpy                          -119
equ     atof                            -120
equ     sscanf                          -121
equ     strcat                          -122
equ     toupper                         -123
equ     strstr                          -124
equ     memmove                         -125
equ     abs                             -126
equ     strchr                          -127
equ     fabs -128
equ     tolower -129



equ trap_BotLibSetup					-201
equ trap_BotLibShutdown					-202
equ trap_BotLibVarSet					-203
equ trap_BotLibVarGet					-204
equ trap_BotLibDefine					-205
equ trap_BotLibStartFrame				-206
equ trap_BotLibLoadMap					-207
equ trap_BotLibUpdateEntity				-208
equ trap_BotLibTest						-209

equ trap_BotGetSnapshotEntity			-210
equ trap_BotGetConsoleMessage			-211
equ trap_BotUserCommand					-212
equ trap_BotGetServerCommand                    -213



equ trap_AAS_EntityVisible				-301
equ trap_AAS_InFieldOfVision			-302
equ trap_AAS_VisibleClients				-303
equ trap_AAS_EntityInfo					-304

equ trap_AAS_Initialized				-305
equ trap_AAS_PresenceTypeBoundingBox	-306
equ trap_AAS_Time						-307

equ trap_AAS_PointAreaNum				-308
equ trap_AAS_TraceAreas					-309

equ trap_AAS_PointContents				-310
equ trap_AAS_NextBSPEntity				-311
equ trap_AAS_ValueForBSPEpairKey		-312
equ trap_AAS_VectorForBSPEpairKey		-313
equ trap_AAS_FloatForBSPEpairKey		-314
equ trap_AAS_IntForBSPEpairKey			-315

equ trap_AAS_AreaReachability			-316

equ trap_AAS_AreaTravelTimeToGoalArea	-317

equ trap_AAS_Swimming					-318
equ trap_AAS_PredictClientMovement		-319

equ trap_AAS_EnableRoutingArea   -320
equ trap_AAS_BBoxAreas           -321
equ trap_AAS_AreaInfo            -322
equ trap_AAS_PredictRoute        -323




equ trap_EA_Say							-401
equ trap_EA_SayTeam						-402
equ trap_EA_UseItem						-403
equ trap_EA_DropItem					-404
equ trap_EA_UseInv						-405
equ trap_EA_DropInv						-406
equ trap_EA_Gesture						-407
equ trap_EA_Command						-408

equ trap_EA_SelectWeapon				-409
equ trap_EA_Talk						-410
equ trap_EA_Attack						-411
equ trap_EA_Use							-412
equ trap_EA_Respawn						-413
equ trap_EA_Jump						-414
equ trap_EA_DelayedJump					-415
equ trap_EA_Crouch						-416
equ trap_EA_MoveUp						-417
equ trap_EA_MoveDown					-418
equ trap_EA_MoveForward					-419
equ trap_EA_MoveBack					-420
equ trap_EA_MoveLeft					-421
equ trap_EA_MoveRight					-422
equ trap_EA_Move						-423
equ trap_EA_View						-424

equ trap_EA_EndRegular					-425
equ trap_EA_GetInput					-426
equ trap_EA_ResetInput					-427

equ trap_EA_Action                                      -428



equ trap_BotLoadCharacter				-501
equ trap_BotFreeCharacter				-502
equ trap_Characteristic_Float			-503
equ trap_Characteristic_BFloat			-504
equ trap_Characteristic_Integer			-505
equ trap_Characteristic_BInteger		-506
equ trap_Characteristic_String			-507

equ trap_BotAllocChatState				-508
equ trap_BotFreeChatState				-509
equ trap_BotQueueConsoleMessage			-510
equ trap_BotRemoveConsoleMessage		-511
equ trap_BotNextConsoleMessage			-512
equ trap_BotNumConsoleMessages			-513
equ trap_BotInitialChat					-514
equ trap_BotReplyChat					-515
equ trap_BotChatLength					-516
equ trap_BotEnterChat					-517
equ trap_StringContains					-518
equ trap_BotFindMatch					-519
equ trap_BotMatchVariable				-520
equ trap_UnifyWhiteSpaces				-521
equ trap_BotReplaceSynonyms				-522
equ trap_BotLoadChatFile				-523
equ trap_BotSetChatGender				-524
equ trap_BotSetChatName					-525

equ trap_BotResetGoalState				-526
equ trap_BotResetAvoidGoals				-527
equ trap_BotPushGoal					-528
equ trap_BotPopGoal						-529
equ trap_BotEmptyGoalStack				-530
equ trap_BotDumpAvoidGoals				-531
equ trap_BotDumpGoalStack				-532
equ trap_BotGoalName					-533
equ trap_BotGetTopGoal					-534
equ trap_BotGetSecondGoal				-535
equ trap_BotChooseLTGItem				-536
equ trap_BotChooseNBGItem				-537
equ trap_BotTouchingGoal				-538
equ trap_BotItemGoalInVisButNotVisible	-539
equ trap_BotGetLevelItemGoal			-540
equ trap_BotAvoidGoalTime				-541
equ trap_BotInitLevelItems				-542
equ trap_BotUpdateEntityItems			-543
equ trap_BotLoadItemWeights				-544
equ trap_BotFreeItemWeights				-546
equ trap_BotSaveGoalFuzzyLogic			-546
equ trap_BotAllocGoalState				-547
equ trap_BotFreeGoalState				-548

equ trap_BotResetMoveState				-549
equ trap_BotMoveToGoal					-550
equ trap_BotMoveInDirection				-551
equ trap_BotResetAvoidReach				-552
equ trap_BotResetLastAvoidReach			-553
equ trap_BotReachabilityArea			-554
equ trap_BotMovementViewTarget			-555
equ trap_BotAllocMoveState				-556
equ trap_BotFreeMoveState				-557
equ trap_BotInitMoveState				-558

equ trap_BotChooseBestFightWeapon		-559
equ trap_BotGetWeaponInfo				-560
equ trap_BotLoadWeaponWeights			-561
equ trap_BotAllocWeaponState			-562
equ trap_BotFreeWeaponState				-563
equ trap_BotResetWeaponState			-564
equ trap_GeneticParentsAndChildSelection -565
equ trap_BotInterbreedGoalFuzzyLogic	-566
equ trap_BotMutateGoalFuzzyLogic		-567
equ trap_BotGetNextCampSpotGoal			-568
equ trap_BotGetMapLocationGoal			-569
equ trap_BotNumInitialChats				-570
equ trap_BotGetChatMessage				-571
equ trap_BotRemoveFromAvoidGoals		-572
equ trap_BotPredictVisiblePosition		-573
equ trap_BotSetAvoidGoalTime                    -574
equ trap_BotAddAvoidSpot                        -575

and
ui_syscalls.asm:

Code: Select all

code

equ	trap_Error								-1
equ	trap_Print								-2
equ	trap_Milliseconds						-3
equ	trap_Cvar_Set							-4
equ	trap_Cvar_VariableValue					-5
equ	trap_Cvar_VariableStringBuffer			-6
equ	trap_Cvar_SetValue						-7
equ	trap_Cvar_Reset							-8
equ	trap_Cvar_Create						-9
equ	trap_Cvar_InfoStringBuffer				-10
equ	trap_Argc								-11
equ	trap_Argv								-12
equ	trap_Cmd_ExecuteText					-13
equ	trap_FS_FOpenFile						-14
equ	trap_FS_Read							-15
equ	trap_FS_Write							-16
equ	trap_FS_FCloseFile						-17
equ	trap_FS_GetFileList						-18
equ	trap_R_RegisterModel					-19
equ	trap_R_RegisterSkin						-20
equ	trap_R_RegisterShaderNoMip				-21
equ	trap_R_ClearScene						-22
equ	trap_R_AddRefEntityToScene				-23
equ	trap_R_AddPolyToScene					-24
equ	trap_R_AddLightToScene					-25
equ	trap_R_RenderScene						-26
equ	trap_R_SetColor							-27
equ	trap_R_DrawStretchPic					-28
equ	trap_UpdateScreen						-29
equ	trap_CM_LerpTag							-30
equ	trap_CM_LoadModel						-31
equ	trap_S_RegisterSound					-32
equ	trap_S_StartLocalSound					-33
equ	trap_Key_KeynumToStringBuf				-34
equ	trap_Key_GetBindingBuf					-35
equ	trap_Key_SetBinding						-36
equ	trap_Key_IsDown							-37
equ	trap_Key_GetOverstrikeMode				-38
equ	trap_Key_SetOverstrikeMode				-39
equ	trap_Key_ClearStates					-40
equ	trap_Key_GetCatcher						-41
equ	trap_Key_SetCatcher						-42        
equ	trap_GetClipboardData					-43
equ	trap_GetGlconfig						-44
equ	trap_GetClientState						-45
equ	trap_GetConfigString					-46
equ	trap_LAN_GetLocalServerCount			-47
equ	trap_LAN_GetLocalServerAddressString	-48
equ	trap_LAN_GetGlobalServerCount			-49
equ	trap_LAN_GetGlobalServerAddressString	-50
equ	trap_LAN_GetPingQueueCount				-51
equ	trap_LAN_ClearPing						-52
equ	trap_LAN_GetPing						-53
equ	trap_LAN_GetPingInfo					-54
equ	trap_Cvar_Register						-55
equ trap_Cvar_Update						-56
equ trap_MemoryRemaining					-57
equ	trap_GetCDKey							-58
equ	trap_SetCDKey							-59
equ     trap_VerifyCDKey  -60
equ     trap_LAN_GetServerCount -61
equ     trap_LAN_GetServerAddressString -62
equ     trap_SetPbClStatus -63

equ	memset					-101
equ	memcpy					-102
equ	strncpy					-103
equ	sin						-104
equ	cos						-105
equ	atan2					-106
equ	sqrt					-107
equ floor					-111
equ	ceil					-112
equ	testPrintInt				-113
equ	testPrintFloat				-114

replace your old *_syscalls.asm files with these and they should work fine.
Locked