Thx Preach
#3489 posted by
ranger on 2024/11/30 16:53:17
For Monster Vs Monster teams I believe the Qreate mod added monster teams, and a few other misc mod did too?
"Across the map, team A fights with team B, even when the player is nowhere nearby. A victorious team emerges in each fight, and for the player the only evidence of all this groundbreaking AI is a pile of corpses from team A, and some half-health monsters from team B."
actually this is perfectly fine for my mod!
Attenuation
#3490 posted by
ranger on 2024/11/30 16:58:51
I presume the values are?
ATTN_NONE 0.0
ATTN_NORM 1.0
ATTN_IDLE 2.0
ATTN_STATIC 3.0
and is there a chart for how far Attenuation value affects sound range?
-
so to make sure
sound (self, CHAN_WEAPON, "enforcer/enfire.wav", 1.00, ATTN_NORM);
1.00 is the volume & I can change ATTN_NORM to a number?
so
sound (self, CHAN_WEAPON, "enforcer/enfire.wav", 0.50, 0.1);
means half volume but 10x the sound range?
and I can also use 0.01 for 100x the range?
Teams Also
#3491 posted by
ranger on 2024/11/30 17:22:32
Do I have to add .float monster_team to defs.qc?
and/or add monster.monster_team to each monster in the mod?
Sounds Right
#3492 posted by
Preach on 2024/11/30 21:22:42
Your code looks correct. I can't quantify exactly how much further the sound goes when you set attenuation to 0.1, but it will be a long way. Give it a try, and you can always adjust it later.
I'd recommend downloading the source code for Qreate and see how they did it. I mentioned that the built-in function in the Quake engine is called "checkclient", and the function which calls it in QuakeC is called "FindClient" found in the ai.qc file. If you look for that in the mod source, you should get some idea how they did it.
Adding field definitions to the bottom of defs.qc is a good choice. You should only define a field once. It can be used from that point onwards in the compilation. defs.qc is a particularly good choice because it's usually the FIRST file to be compiled, so all your code will be able to see the definition.
Compiler For QC?
#3493 posted by
ranger on 2024/12/01 08:05:31
noob question, but how do i compile the QC code to progs.dat?
Resources
#3494 posted by
Preach on 2024/12/02 21:14:57
The short version:
https://quakewiki.org/wiki/Compiling_QuakeC
The slightly longer version with an example to try out and check you got it working:
https://www.quaddicted.com/webarchive/minion.planetquake.gamespy.com/tutorial/tutor7.htm
The two differ in which compiler they recommend. I agree with the recommendation in at the first link, FTEQCC is the better of the options.