changes since r6: rebased to quakespasm svn revision 1374 (0.92.2) basic download support (client+server). protocol extension compatible with darkplaces servers (because its really simple). only sent to clients with known extensions to avoid invalid-command spam (unfortunately this means dp clients too, although they tend to not support fitz/666 anyway, which is still the default) only allowed for maps/models/progs/sound subdirs. only precached models+sounds will be downloaded, and the world's lit file. protocol: nehaha bjp3(10002) supported, as both client and server. server does not send alpha info, as DP clients fail to parse this properly. this does not include generic stuff like nehahra's mod-specific cvars, commands, etc. protocol: dpp7(3504) partially supported, as client only. should still be okay for limit-breaking maps with non-dp-specific gamecode. some tempentity effects added for compat, some will still be errors, some will spam warnings about having no particle effect available (r_particledesc for those). dp servers running dpmod+smc 'should' be okay, with the same constraints that affect qss clients on qss servers running the same mods. clientside model effects stubbed. no csqc support, obviously. no prydoncursor support, hopefully few mods will actually use this. pointparticles/trailparticles will work, but are limited to the effectinfo.txt file, and client/server mismatches will screw everything up. voip protocol extension implemented opus will be used for encoding, cl_voip_opus_bitrate can be used to tweak bandwidth, use the lowest value that you find acceptable. libopus was already a dependancy of quakespasm, for music reasons I guess. speex is not enabled in this build, which makes ezquake voip mutually inaudiable, fte may also favour speex for encoding (and requires the same external opus dll, you might need to update fte for opus to work reliably). set cl_voip_send 1 for voice activation, or bind something to +voip for push-to-talk set cl_voip_test 1 temporarily if you want to see what you sound like compared to other people requires sdl 2.0.5 for audio capture (will fall back on directsound in windows builds with older sdl versions, but other platforms will have no audio capture without sdl2.0.5). raised limits for fleeky's all-episodes-in-one-map map (https://github.com/plankatron/quakemash). subdivided(sky) surfaces outside 9999qu no longer crash with a stack overflow. raised model precache limit to 4k (e1-4.bsp has about 2300 inline models). removed static sounds limit. entity limit raised to 15000 by default (I assume people have enough ram nowadays) multiple gamedir support. prefix a gamedir with a * to mark it as private (not reported to clients / nor overrides for servers). tab completion no longer case sensitive (still case sensitive when you actually hit enter, however) console edit line defaults to insert mode. fixed possible bug with invisible entities(my fault) dynamic window resizing in sdl2 (might truncate prior console prints, higher resolutions will result in fewer console lines shown, like other resize changes do). reconnect command now works properly while on a server. show ping times to the scoreboard extended bf command to take rgba values. Attempt to autodetect whether maps were watervised. Treats wateralpha as 1 on map load, although you can override it via the console. Water+Tele+Slime+Lava detected separately. Added support for startmap_sp and startmap_dm aliases. Dedicated servers now exec default.cfg again. No more mods broken by a lack of custom cvar defaults. changes since r5: rewrote demo recording, avoiding issues with many static models and oversized signon buffers. +button3 through 8 commands supported added apropos command, though it goes only on command/cvar names pk3 support paks.lst file that assigns a specific order pak/pk3 enumeration, for other packages. autodetect sbar types, so quoth no longer needs to pretend to be hipnotic (although still is for purposes of protocol 15, sigh). stereo wavs are now parsed, but converted to mono at load. fix .movetype=push reverting to .solid=bsp resulting in a crash. changes since r4: added cl_nopext cvar to disable the protocol extensions. added emulation for misc_model, if the mod does not provide one. added emiteffectnum field (and emiteffect field emulation, so you don't have to guess at particle numbers from maps). r_effect command now supports a forward term, to emit particles forwards instead of ... yes, down. misc particle system changes to make it more robust rewrote static entities to avoid packet overflows (as was already done with baselines). rewrote surface emittence to provide "_texpart_*" worldspawn fields to spawn named particles over those surfaces. changes since r3: Bumped lightstyles from 64 to 255. will only give network differences if they're actually used. Saved games now save model+sound+particle precaches and extra lightstyles, so nothing is broken from slightly different state when reloading. Added support for proquake's 16bit angles hack Added proquake-compatible rcon (on the server, anyway). Added botclients. Try to more-closely match dp's effectinfo behaviour. Added PEXT2_PREDINFO support, giving lower latency/smaller stats. changes since r2: Added PEXT2_REPLACEMENTDELTAS for smaller network updates (nack-based entity deltas). Updated sv_protocol behaviour to deal with fte's protocol extensions. rewrote baselines to avoid signon packet overflows. changes since r1: particle system tweak, uses optimised traceline instead of borrowing the server's and then crashing in various situations. changes since r0: Added many many ssqc extension builtins. Rewrote networking to utilise single-port-servers. Added IPv6 support. Added support for dpmaster, to automatically list/advertise servers globally. Added support for FTE's particle system. Wrote alternative to SV_TouchLinks, to avoid crashes. Rewrote clientcmds. set/seta comands bindlist.lst file parsing for custom binds menu prior version of the changelog: extra builtins - added lots of misc builtins, including: string manipulation+buffers, file access, bsp introspection, maths, tracebox, botclient stuff, clientcommands, etc. Setting pr_checkextensions 0 will a) prevent extensions from being advertised to the mod. b) display a warning when any extended builtin is used (assuming it would otherwise crash anyway). stub builtins - also added stubs for builtins that either don't make sense in quakespasm or would need protocol extensions. these are merely present to avoid crashes and will display a warning the first time they're called. multicast - supports pvs culling. still does not support phs. precache builtins - these can now be used mid-map. be warned that this will result in other clients disconnecting (will still display warnings on the server). misc stuff - MOVETYPE_FOLLOW and SOLID_CORPSE now work, .movement is supported. cvar changes - for mods, autocvars now work. the set+seta command also now works. I bumped the cbuf size, because not only were well-documented mods were being punished for it, but also stuffcmded aliases were overflowing it. clc_stringcmd - rewrote client->server string commands a little. this security fix blocks clients from being able to execute server-side aliases/cvars with names similar to 'allowed' console commands. SV_TouchLinks - rewrote this to avoid potential crashes within recursive touch events (yes, this can happen in rare cases, even in the prior quakespasm version). may have minor behaviour differences, pr_checkextensions 0 disables this, restoring prior behaviour including instability-from-recursion. single server socket - the server now only uses a single socket per protocol family. this makes NATs/firewalls much easier to deal with as servers no longer need to be DMZoned, only a single port needs to be forwarded.. ipv6 - this build can natively use ipv6, but will still assume ipv4 first. uses non-hybrid sockets so this should work on winxp too. use -noudp4 or -noudp6 to disable one and not the other. by default it'll try to use both. reduced mtu size to avoid connectivity issues. still higher than vanilla though, which may also cause other issues. master servers - it is now possible to automatically list your server globally. hurrah... unfortunately the server list is still lame and provides no ping info, so have fun with that. :) thanks to ipv6, servers might get listed twice. you can turn this on with sv_public, or via the 'new game' menu. proquake angles - now uses 16bit angles when connecting to proquake servers, or really most protocol15 servers including qrack+dp+etc. also advertises protocols, allowing fte servers to serve protocol 666+999 as needed. bug fixes - spritegroups will now animate properly - this was a vanilla glquake bug. model loader - alpha-tested models now supported spr32 sprites now supported (still using alpha testing rather than changing all sprites to use blending, so the alpha channel might as well still be 1bit) many limit-exceeding models will now load properly, or just safely fail to load rather than crashing the engine. note that some limits were not properly enforced before, and this might mean that a couple of models will newly fail to load (but won't crash the engine any more). known-but-unsupported model formats will display a more helpful message, without crashing. unknown formats will similarly no longer crash. bspx coloured lighting is now supported (somewhat common in the qw community). use -bspxlit argument with tyrutils-ericw's light util and discard the lit. added support for tyrutil-ericw's qbsp's -notex argument that omits textures, reducing file size and avoiding gpl violations. still doesn't do replacements though. fixed bsps that were compiled with vanilla qbsp's -noclip argument. will retain the correct view height, but will otherwise use the point-hull for everything, so not that useful. binds menu - if provided, will parse a bindlist.lst file from the gamedir. this should take the form of lines like: +thecommand "some desc" "optional much longer description of it" lines with a command that is just a hyphen are treated as comments/separators. quakespasm ignores that third part, fte displays it on mouse-over. if any binds are provided this way, they will completely replace the built-in list. there is no limit to the binds that can be added, the menu will scroll, but there's no indicator that there are more/less. particles - now includes fte's scriptable particle system. the config parser is a little different from fte (fte uses actual console commands, qs parses directly without the console). this means that configs are limited to just r_part+r_effect+r_trail. setting cvars from particle configs are not supported here. also currently missing support for models, embedded shaders (obviously), stains, viewspace particles. tga images are supported, png+jpg are not. no effects will be loaded by default, causing the engine to fall back on the existing particle system until a config is loaded. users can set r_particledesc if they really specific particle effects. mods should include the config name as a namespace/prefix. example usage (using FTE_SV_POINTPARTICLES with FTE_PART_NAMESPACES): float myexplosion = particleeffectnum("mypartcfg.myexplosion"); pointparticles(myexplosion, self.origin, trace_plane_normal, 1); note that DP_SV_POINTPARTICLES and FTE_SV_POINTPARTICLES qc extensions are supposed to be identical, except that *certain* mods see DP_ and assume the entire particle system too, which is NOT the case, hence the need to check both extensions. note that if FTE_PART_NAMESPACES is supported, then particleeffectnum("mypartcfg.myexplosion") will automatically load the 'mypartcfg' particle set, however the engine deals with that. note that for dp compat, if FTE_PART_NAMESPACE_EFFECTINFO is supported, then "effectinfo.*" or "effectinfo_*.*" are supported namespaces that will should be compatible with DP's effects (if you ignore the prefix). Precaching a single particle effect like this will include this config for all particles with no namespace. So for dp compat, you can use the following: if (checkextension("FTE_SV_POINTPARTICLES") || checkextension("DP_SV_POINTPARTICLES")) { if (checkextension("FTE_PART_NAMESPACE_EFFECTINFO")) { particleeffectnum("effectinfo.dummy"); //so clients will attempt to load the effectinfo namespace, if not already available. particleeffectnum(strcat("effectinfo_", mapname, ".dummy")); //map-specific effects } //else we have no idea where we're loading the config from... lets hope its either dp or the user helps us out //do precaches myexplosioneffect = particleeffectnum("myexplosioneffect"); } //later if (myexplosioneffect) pointparticles(myexplosioneffect, self.origin, trace_plane_normal, 1); else te_explosion(self.origin); //'generic' fallback (or you can just set 'r_particledesc effectinfo' in your mod's default.cfg and hope the user doesn't change it to something else) note that particleeffectnum acts as a precache. you don't need to cache the result in a spawn function, but you do need to have called it early enough to avoid warning message. note that any use of particleeffectnum will cause other clients to disconnect with 'illegible server message'. it is *ENTIRELY* the modder's/user's responsibility to keep things consistent and not garish. pay close attention to particle sizes, texture resolution, etc. mappers can add something like the following to their worldspawn entity: "_texpart_sky1" "weather.tex_rainsky" surfaces with the "sky1" texture will then act as emitters. this includes _texpart_*teleport or whatever. this doesn't require new gamecode. r_partredirect can be used to redirect emitters (or effects) dynamically. redirections are normally meant to be a user feature, so mods should probably try to avoid tex_* effects in case the user switches gamedirs. this command can work recursively, up to 5 itterations. replacement network protocol - namely FTE's nack-based PEXT2_REPLACEMENTDELTAS protocol extension. if you're a networking nerd, the archetecture is documented here: https://sourceforge.net/p/fteqw/code/HEAD/tree/trunk/specs/replacementdeltas.txt?format=raw The extension applies to a base protocol, in this case 15, 666, or 999. There are some differences for QW vs NQ base protocols due to the netchan, these are not applicable to quakespasm. the protocol is specced for lots of extended entity state, but most of that will be ignored/unused by the rest of the engine, and consequently won't be transmitted either. automatically disabled per-client if unsupported by that client all of the below will result in 'illegible server message' in older clients. usage of other extensions will be silently stripped, which may cause weirdness (eg: viewmodelforclient). use of custom particles (particleeffectnum, trailparticles, pointparticles) use of late precaches (at least if they were not already precached in a spawn function) [you shouldn't rely on this anyway]. this server implementation has not been applied to everything: makestatic - static entities will not benefit from extensions like EF_NOSHADOW. entities are sent as deltas from the previous packet entity data is split up to not exceed the mtu (without needing netchan changes) with PEXT2_PREDINFO, stats are also sent semi-unreliably using the same mechanism (avoids reliables-stall issues). clc_clientdata is redundant. all stats have full precision. protocol does not change simply because a mission pack is loaded. gamedir added to serverinfo, the client responds by displaying a warning if the gamedir does not match baselines are generated per-client and split over multiple packets, so the signon buffer size is no longer a limiting factor for maps with insane entity counts (for all supported protocols). MAX_VISEDICTS is gone. however, try not to have them all visible at once. drawing 5k or 10k entities is a massive performance drain, as can them all getting angry at the player. this implementation will reduce overall data sizes by avoiding retransmissions, but there is no rate limiting which can result in significant burst. this may result in extra packetloss bursts if you have saturated tcp/etc connections running at the time. packetloss is detected serverside and triggers resends it will recover fully, but new entities appearing may have significant delays to them (especially if static) proportionally to other entities. interpolation code unchanged, there is no time drifting, which means the engine will not be able to hide packetloss, resulting in slightly jerky player movement. because of this FTE will still be smoother for internet play. still playable while simulating 50% packetloss, but not smooth. this tested with no extra ping, so would be worse online. the protocol does not carry nextthink hints, and quakespasm is too stupid to infer intervals, so assumes interpolation intervals of 0.1. the protocol supports prediction, but this implementation does not. To prevent the server from detecting replacement deltas (so they don't appear in demos), use "sv_protocol 666-" (omitting the - will neither enable nor disable fte extensions). To re-enable extensions, use "sv_protocol FTE+666" Other than a couple of extended svcs that a mod might use, 666 is effectively obsolete (but still useful as a base protocol for earlier quakespasm, fitzquake, etc). Using 999 as the base protocol still provides map size increases. This will also cause custom particle effects to become invisible to all clients. To prevent the client from advertising support for replacement deltas, use 'cl_nopext 1'. The server will fall back to only the base protocol, if *either* the client or server has it disabled (or both, obviously). Ideally, leave it enabled on the server and disable it as desired on the client, but I guess people are not familiar with that yet. This will allow you to record compatible demos even if you don't have rcon access to the server. lightstyles - bumped to 255 (the last index is not valid in bsps, so not relevant). presense of additional lightmaps won't bug anything out, but actually using them might break other clients if they don't support this raised limit yet. rcon - proquake-compatible rcon is implemented server-side. WARNING: the password is sent as plain text! it is NOT secure! (protocol limitation from ) set rcon_password to enable it, the default blank value will unconditionally treat all attempts as invalid. no client support. there's no real reason for this, I just didn't bother writing the code (presumably it would be like the 'test' command, but *vomit*). pk3 support - pk3s are supported now. *.pak and *.pk3 will be loaded by default (in no particular order, other than pakX.pak getting loaded in order first). you can override pak ordering by creating a 'pak.lst' file with the desired order (this will override pakX.pak files too, so these should also be listed). this makes qrp textures etc much easier to load, which can also make load times worse, and be ugly, so watch out for that. standard deflate compression is supported, but is a little unoptimised. zip64 files are parsed, but offsets above 2gb will not work on operating systems where 'long' is still 32bit. symlinks are ignored. spanned zips are not supported. contained filenames are case-sensitive. system paths now override the pak files that they contain (id1/default.cfg actually takes precidence now). shareware mode restricts progs.dat in the same way that it did subdirectories, in order to retain the same approximate level of restrictions (you'll just have to add it to quakespasm.pak instead). test mods: dpmod - a quick test of this seems to run fine, with the exception of a few non-generic particle effect builtins which are still stubs, mostly modified quad-damage effects. smc - this does actually run, but is not exactly enjoyable due to: use of md3 format (these models will be invisible) no shader support (hey, at least qs won't obey the 'depthfunc equal' lines) smc loves late precaches (spammy). additionally an smc bug causes monsters to be spawned underground (monsters can't move). there's likely other issues. I've not tested it that extensively. (some files are included in this zip to disable parts of the mod which are buggy / not supported). arcane dimensions - urm. still works?.. gains DP_QC_GETSURFACE, so broken vanilla skies stop being broken (ad's only use for this extension). gains EF_NOSHADOW. ad's engine particle system usage assumes dp internals, and needs a tweak in order to get it to behave more generically. issues: (note that listed critisisms are not always bad things for the average qs user, but are probably bad for _someone_ and do limit potential mods) (some things can only be good, except for how invasive such a thing would be resulting in too many bugs, or I'm just too lazy/selfish to do them myself) protocol changes - late precaches are in, but will still display warnings if depended upon. late precaches can still be an issue if the reliable is delayed while the unreliable is not (which is pretty much always, sounds and particles will have issues, but models will generally be okay). sounds are still sent fully unreliably. this means they are subject to packetloss, and is especially significant on func_plat entities (where the sounds are typically looping, and thus might never be replaced/stopped). staticsounds still use the sv.signon buffer, and are thus still limited to the underlying protocol and single-signon-buffer size. pointparticles and trailparticles are new, but there is no support for most extended TE_* values (rain+snow are the only added TEs). Use pointparticles if you need such other effects. while the protocol supports a range of extra entity state, much of that data is still unused (parsed and not sent). including ef_additive, etc not added - voip would be a nice idea for all those first-playthrough map demos no download mechanism added. I would want to use paks, which would make this far too complex. there's no automatic gamedir switching either. (there is a gamedir hint, but currently it results in only a warning print because I really cba to rewrite quakespasm's filesystem code) serious dp protocol issues - sending 666 or 999 to a dp client results in dp spamming loads of useless gibberish that obscures the actual error, such that few people actually report the actual problem... the only way I can think of getting DP to be remotely sane is to send it an svc_version for it to crap out on, reducing the spam in the hopes that people will read up a little. the alternative is to hack in some 'cmd dpcheck $somedponlycvar' and see what the client says that cvar is set to (if $foo is supported). unfortunately there's no version cvar, or any other kind of useful feature that I'm aware of, so this would fuck up for other clients with seta etc getting saved into $gamedir/config.cfg and then poluting other engines. (this is not a new issue) proquake+vanilla sucks: sv_protocol=666 has higher limits. if this is inadvertantly set, then the server is permitted to send larger serverinfo packets (that exceed the 8192 limit). proquake then displays 'read error' (due to recvfrom returning EMSGSIZE), which is awkward but not our bug, just a vanilla limitation that makes diagnosing the actual error a nightmare. (this is not a new issue and applies to older versions of quakespasm too) note that reliables larger than 8192 but with an mtu compatible with vanilla can be used to crash both vanilla and proquake. this is true even if it is a client that sent the packets, crashing the server. (this is not present in qss) limited renderer changes - no md3 support no iqm support harsh mdl limits sprites still alpha-tested still using render-to-texture instead of glsl for drawing water (which would allow mipmaps and anisotropic filtering, instead of using a random noise texture...) randomization - quakespasm likes seeding the random number generator as a handy trick... which can result in timers+particles getting a little too predictable filesystem updates - 'game' console command is still stupid (backwards, hardcoded special cases, limited path counts) I did add a 'gamedir' command as an alternative name for 'game', because quakeworld. I'd do show_fps too, but cvars make that messy. console - is still annoying still prints non-ascii/non-unicode chars to stdout, which may include escape codes or other xterm/etc exploits. con_printf is still horribly slow (at least with vsync), and likely to crash on someone... and not just me. fixing this would make a few poorly designed blocking things not refresh properly. no markup - all that ^1funny ^2and ^3annoying ^7text isn't handled, and remains as gibberish. menu - still no mouse support still no way to add mod-specific cvars onto the menu