taniwha wrote:You want to put the "fence" around "the following engines", not "work"

and you don't really need to emphasize the word that much (but that's up to you).
I certainly don't want to restrict my MOD to certain engines but when I asked at Func_msgboard (
http://www.celephais.net/board/view_thread.php?id=60452 - post 370+) about the Quakespasm engine and the error 'PF_VarString: Overflow' I was told more or less 'Go away and stop doing things you are not suppose to do with this engine!'. I will gladly work with any engine developer to get round problems but being told 'no go away' does not really offer any chance of fixing things.
Spike wrote:1: ent counts can be quite high with particles etc all moving at once at once, thus it requires an engine with increased packet sizes/ent limits. Fair enough, not much you can do about that one without sacrificing stuff. You could make some temp1 flag to disable particles I suppose, which might help with coop/internet games even with fitzquake etc.
My mod uses a crazy amount of ENTS / particles and the engine will crash if 'max_edicts' is not set higher for engines that don't change when needed. This also has a nasty side effect of making the demo files huge because each particle is an entity that lives for a certain amount of time and then removed. Is there a way to mark all the particles ENTS with a temporary flag so they are not saved in demo files and do not impact other parts of the engine? I also have plans to switch off most of the particles for DM game play, but that is something I was going to implement later, the primary focus is SP at the moment.
Spike wrote:2: "gl_texturemode 3\n" stuffcmds - that should be "gl_texturemode gl_nearest_mipmap_nearest\n" (I assume) if you want greater engine compat. This should be an easy change that won't break fitzquake, while the more verbose form is understood even by vanilla glquake.
That is something I fixed in the latest version 1.1 (links above), this is the QC I use now:
Code: Select all
// Based on serverflag update linear filtering
if (serverflags & SVR_PIXELSOFF) stuffcmd(client, "\ngl_texturemode GL_LINEAR_MIPMAP_LINEAR\n");
else stuffcmd(client, "\ngl_texturemode GL_NEAREST_MIPMAP_LINEAR\n");
Spike wrote:3: scr_menusize - this is specific to fitzquake. Other engines tend to use vid_conwidth/vid_conheight, but setting those correctly is often too much of a hassle. Presumably the sensible thing to do here is to move that setting into your default.cfg file instead, though their regular config might still override that... Not really sure if this can be fixed in a portable way, other than to directly detect the client engine and then pick the appropriate stuffcmd.
This is fixed in the latest version 1.1 (links above). I originally had a pile of entities in the map doing stuff commands when the client was put into the server, I got the idea from looking at the honey source files by CZG. This was a really bad idea and eventually someone told me to use the quake.rc file instead. All the menu commands are in the right place (quake.rc) and not in the map files anymore.
Code: Select all
//-----------------------------------------------------------
// Shadow Settings
// If you don't like it, override with autoexec.cfg
//-----------------------------------------------------------
gl_clear 1
gl_overbright 1
scr_menuscale 2
scr_conspeed 600
r_wateralpha 0.65
crosshair 1
taniwha wrote:Darn, it was working in quakeforge until I opened the book. qf got stuck spewing "SZ_GetSpace: overflow".
Here is the QC I use and if there is a better way of doing this I will gladly change my QC to fix this problem. I also use something similar for fading models (distraction bolts fade on impact) and fading stealth walls (the dragon closet is an example of this)
Code: Select all
float BOOK_FADEOUT = 192; // Background density while reading books
//----------------------------------------------------------------------
// Store self so think functions can work correctly
// direction = TRUE, fade up ; FALSE, fade down
//----------------------------------------------------------------------
void(float direction) book_fadeuse =
{
local entity tself;
tself = self;
self = self.ghostmarker;
self.height = direction;
self.use();
self = tself;
};
//----------------------------------------------------------------------
void() book_fade =
{
self.count = (self.amuletfade + 2 ) * 0.1;
self.lip = ((time - self.ltime) / self.count) * BOOK_FADEOUT;
if (!self.amuletfade) self.lip = BOOK_FADEOUT - self.lip;
if (self.lip < 0 ) self.lip = 0;
else if (self.lip > BOOK_FADEOUT) self.lip = BOOK_FADEOUT;
else self.nextthink = time;
// Change screen background density (makes text easier to read)
stuffcmd(self.enemy, "\nv_cshift 0 0 0 ");
stuffcmd(self.enemy, ftos(self.lip) );
stuffcmd(self.enemy, "\n");
};
//----------------------------------------------------------------------
void() book_fadetrigger =
{
self.amuletfade = self.height;
self.think = book_fade;
self.nextthink = time;
self.ltime = self.nextthink;
};
//----------------------------------------------------------------------
void() book_fadesetup =
{
// Find player for distance check
if (!self.enemy) {
self.enemy = find(world, classname, "player");
// If cannot find the player, try again later
if ( self.enemy.flags & FL_CLIENT ) {
self.use = book_fadetrigger;
}
else {
self.enemy = world;
self.nextthink = time + 0.1;
}
}
};
//----------------------------------------------------------------------
void() book_fadecontroller =
{
self.ghostmarker = spawn();
self.ghostmarker.owner = self;
self.ghostmarker.movetype = MOVETYPE_NONE;
self.ghostmarker.solid = SOLID_NOT;
self.ghostmarker.classtype = CT_BOOKFADER;
self.ghostmarker.oldorigin = self.origin + '0 0 32';
setorigin(self.ghostmarker, self.ghostmarker.oldorigin);
setsize (self.ghostmarker, VEC_ORIGIN, VEC_ORIGIN);
self.ghostmarker.amuletfade = TRUE;
self.ghostmarker.lip = 0;
self.ghostmarker.think = book_fadesetup;
self.ghostmarker.nextthink = time + 0.2;
}
If there are anything else going wrong please let me know and I will gladly fix the problems. I just don't know enough about all the different engines and what stuff is constant across all engines. I developed my MOD using the Fitz engine and I assumed because it is so old everyone used that engine as a baseline.
Well he was evil, but he did build a lot of roads. - Gogglor