2004-08-23 00:15:46 +00:00
/*
Copyright ( C ) 1996 - 1997 Id Software , Inc .
This program is free software ; you can redistribute it and / or
modify it under the terms of the GNU General Public License
as published by the Free Software Foundation ; either version 2
of the License , or ( at your option ) any later version .
This program is distributed in the hope that it will be useful ,
but WITHOUT ANY WARRANTY ; without even the implied warranty of
2005-02-06 02:47:36 +00:00
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE .
2004-08-23 00:15:46 +00:00
See the GNU General Public License for more details .
You should have received a copy of the GNU General Public License
along with this program ; if not , write to the Free Software
Foundation , Inc . , 59 Temple Place - Suite 330 , Boston , MA 02111 - 1307 , USA .
*/
// cl_ents.c -- entity parsing and management
# include "quakedef.h"
2004-10-19 16:10:14 +00:00
# include "particles.h"
2009-11-04 21:16:50 +00:00
# include "shader.h"
2015-10-11 11:34:58 +00:00
# include "glquake.h"
2004-08-23 00:15:46 +00:00
extern cvar_t cl_predict_players ;
2012-04-24 07:59:11 +00:00
extern cvar_t cl_predict_players_frac ;
2015-06-28 03:43:10 +00:00
extern cvar_t cl_predict_players_latency ;
extern cvar_t cl_predict_players_nudge ;
2011-12-05 15:23:40 +00:00
extern cvar_t cl_lerp_players ;
2019-01-20 01:00:18 +00:00
extern cvar_t cl_lerp_maxinterval ;
2020-09-29 07:09:01 +00:00
extern cvar_t cl_lerp_maxdistance ;
2004-08-23 00:15:46 +00:00
extern cvar_t cl_solid_players ;
extern cvar_t cl_item_bobbing ;
2005-01-17 17:40:37 +00:00
extern cvar_t r_rocketlight ;
extern cvar_t r_lightflicker ;
2019-09-04 07:59:40 +00:00
extern cvar_t r_dimlight_colour ;
extern cvar_t r_brightlight_colour ;
2020-09-29 07:09:01 +00:00
extern cvar_t r_redlight_colour ;
extern cvar_t r_greenlight_colour ;
extern cvar_t r_bluelight_colour ;
2005-01-17 17:40:37 +00:00
extern cvar_t cl_r2g ;
extern cvar_t r_powerupglow ;
2005-04-16 16:21:27 +00:00
extern cvar_t v_powerupshell ;
2005-04-26 16:04:12 +00:00
extern cvar_t cl_nolerp ;
2008-12-03 02:42:05 +00:00
extern cvar_t cl_nolerp_netquake ;
2009-11-04 21:16:50 +00:00
extern cvar_t r_torch ;
2011-04-30 17:21:10 +00:00
extern cvar_t r_shadows ;
2012-02-12 05:18:31 +00:00
extern cvar_t r_showbboxes ;
2015-08-10 18:28:23 +00:00
extern cvar_t gl_simpleitems ;
Too many changes, sorry.
Change revision displays, use the SVN commit date instead of using __DATE__ (when there's no local changes). This should allow reproducible builds.
Added s_al_disable cvar, to block openal and all the various problems people have had with it, without having to name an explicit fallback (which would vary by system).
Add mastervolume cvar (for ss).
Add r_shadows 2 (aka fake shadows - for ss).
Add scr_loadingscreen_aspect -1 setting, to disable levelshots entirely, also disables the progress bar (for ss).
Better support for some effectinfo hacks (for ss).
Added dpcompat_nocsqcwarnings (because of lazy+buggy mods like ss).
Rework the dpcsqc versions of project+unproject builtins for better compat (for ss).
Added dpcompat_csqcinputeventtypes to block unexpected csqc input events (for ss).
Better compat with DP's loadfont console command (for ss).
Added dpcompat_smallerfonts cvar to replicate a DP bug (for ss).
Detect dp's m_draw extension, to work around it (for ss).
Cvar dpcompat_ignoremodificationtimes added. A value of 0 favour the most recently modified file, 1 will use DP-like alphabetically sorted preferences (for ss).
loadfont builtin can now accept outline=1 in the sizes arg for slightly more readable fonts.
Fix bbox calcs for rotated entities, fix needed for r_ignorenetpvs 0.
Hackily parse emoji.json to provide :poop: etc suggestions.
Skip prediction entirely when there's no local entity info. This fixes stair-smoothing in xonotic.
screenshot_cubemap will now capture half-float images when saving to ktx or dds files.
Fix support for xcf files larger than 4gb, mostly to avoid compiler warnings.
Fixed size of gfx/loading.lmp when replacement textures are used.
Added mipmap support for rg8 and l8a8 textures.
r_hdr_framebuffer cvar updated to support format names instead of random negative numbers. Description updated to name some interesting ones.
Perform autoupdate _checks_ ONLY with explicit user confirmation (actual updating already needed user confirmation, but this extra step should reduce the chances of us getting wrongly accused of exfiltrating user data if we're run in a sandbox - we ONLY ever included the updating engine's version in the checks, though there's nothing we can do to avoid sending the user's router's IP).
Removed the 'summon satan all over your harddrive' quit message, in case paranoid security researchers are idiots and don't bother doing actual research.
Removed the triptohell.info and fte.triptohell.info certificates, they really need to stop being self-signed. The updates domain is still self-signed for autoupdates.
Video drivers are now able to report supported video resolutions, visible to menuqc. Currently only works with SDL2 builds.
Added setmousepos builtin. Should work with glx+win32 build.
VF_SKYROOM_CAMERA can now accept an extra two args, setviewprop(VF_SKYROOM_CAMERA, org, axis, degrees).
Removed v_skyroom_origin+v_skyroom_orientation cvars in favour just v_skyroom, which should make it behave more like the 'fog' command (used when csqc isn't overriding).
Added R_EndPolygonRibbon builtin to make it faster+easier to generate textured ribbon/cable/etc wide lines (for TW).
sdl: Fix up sys_sdl.c's file enumeration to support wildcards in directories.
edit command now displays end1.bin/end2.bin correctly, because we can.
Finally add support for f_modified - though ruleset_allow_larger_models and ruleset_allow_overlong_sounds generally make it redundant.
Fix threading race condition in sha1 lookups.
Updated f_ruleset to include the same extra flags reported by ezquake.
A mod's default.fmf file can now contain an eg 'mainconfig config.cfg' line (to explicitly set the main config saved with cfg_save_auto 1 etc).
fmf: basegame steam:GameName/GameDir can be used to try to load a mod directory from an installed steam game. The resulting gamedir will be read-only.
HOMEDIR CHANGE: use homedirs only if the basedir cannot be written or a homedir already exists, which should further reduce the probability of microsoft randomly uploading our data to their cloud (but mostly because its annoying to never know where your data is written).
Fixed buf_cvarlist, should work in xonotic now, and without segfaults.
Added an extra arg to URI_Get_Callback calls - the response size, also changed the tempstring to contain all bytes of the response, you need to be careful about nulls though.
Try to work around nvidia's forced-panning bug on x11 when changing video modes. This might screw with other programs.
sdl: support custom icons.
sdl: support choosing a specific display.
Added some documentation to menuqc builtins.
menusys: use outlines for slightly more readable fonts.
menusys: switch vid_width and vid_height combos into a single video mode combo to set both according to reported video modes.
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@5581 fc73d0e0-1445-4013-8a0c-d673dee63da5
2019-11-20 03:09:50 +00:00
float r_blobshadows ;
2005-01-18 20:15:20 +00:00
extern cvar_t cl_gibfilter , cl_deadbodyfilter ;
2004-08-23 00:15:46 +00:00
extern int cl_playerindex ;
2020-04-19 01:23:32 +00:00
static qboolean cl_expandvisents ;
2004-08-23 00:15:46 +00:00
2017-01-13 00:39:50 +00:00
extern world_t csqc_world ;
2012-02-12 05:18:31 +00:00
static struct predicted_player
{
2004-08-23 00:15:46 +00:00
int flags ;
qboolean active ;
vec3_t origin ; // predicted origin
2004-12-15 17:47:42 +00:00
vec3_t oldo ;
vec3_t olda ;
vec3_t oldv ;
qboolean predict ;
player_state_t * oldstate ;
2004-08-23 00:15:46 +00:00
} predicted_players [ MAX_CLIENTS ] ;
2016-07-12 00:40:13 +00:00
static void CL_LerpNetFrameState ( framestate_t * fs , lerpents_t * le ) ;
2012-02-12 05:18:31 +00:00
void CL_PlayerFrameUpdated ( player_state_t * plstate , entity_state_t * state , int sequence ) ;
2013-09-06 22:57:44 +00:00
void CL_AckedInputFrame ( int inseq , int outseq , qboolean worldstateokay ) ;
2012-02-12 05:18:31 +00:00
2009-07-18 20:46:42 +00:00
2005-01-18 20:15:20 +00:00
extern int cl_playerindex , cl_h_playerindex , cl_rocketindex , cl_grenadeindex , cl_gib1index , cl_gib2index , cl_gib3index ;
qboolean CL_FilterModelindex ( int modelindex , int frame )
{
if ( modelindex = = cl_playerindex )
{
2009-11-04 21:16:50 +00:00
if ( cl_deadbodyfilter . ival = = 2 )
2005-01-18 20:15:20 +00:00
{
if ( frame > = 41 & & frame < = 102 )
return true ;
}
2009-11-04 21:16:50 +00:00
else if ( cl_deadbodyfilter . ival )
2005-01-18 20:15:20 +00:00
{
if ( frame = = 49 | | frame = = 60 | | frame = = 69 | | frame = = 84 | | frame = = 93 | | frame = = 102 )
return true ;
}
}
2009-11-04 21:16:50 +00:00
if ( cl_gibfilter . ival & & (
2005-02-06 02:47:36 +00:00
modelindex = = cl_h_playerindex | |
2005-01-18 20:15:20 +00:00
modelindex = = cl_gib1index | |
modelindex = = cl_gib2index | |
modelindex = = cl_gib3index ) )
return true ;
return false ;
}
2005-01-17 17:40:37 +00:00
2016-07-12 00:40:13 +00:00
static void * AllocateBoneSpace ( packet_entities_t * pack , unsigned char bonecount , unsigned int * allocationpos )
{
size_t space = bonecount * sizeof ( short ) * 7 ;
void * r ;
if ( pack - > bonedatacur + space > pack - > bonedatamax )
{ //expand the storage as needed. messy, but whatever.
pack - > bonedatamax = pack - > bonedatacur + space ;
pack - > bonedata = BZ_Realloc ( pack - > bonedata , pack - > bonedatamax ) ;
}
r = pack - > bonedata + pack - > bonedatacur ;
* allocationpos = pack - > bonedatacur ;
pack - > bonedatacur + = space ;
return r ;
}
void * GetBoneSpace ( packet_entities_t * pack , unsigned int allocationpos )
{
if ( allocationpos > = pack - > bonedatacur )
return NULL ;
return pack - > bonedata + allocationpos ;
}
2004-08-23 00:15:46 +00:00
//============================================================
2010-07-12 22:46:37 +00:00
void CL_FreeDlights ( void )
{
2012-02-12 05:33:16 +00:00
# ifdef RTLIGHTS
2012-02-12 05:18:31 +00:00
int i ;
------------------------------------------------------------------------
r4169 | acceptthis | 2013-01-17 08:55:12 +0000 (Thu, 17 Jan 2013) | 31 lines
removed MAX_VISEDICTS limit.
PEXT2_REPLACEMENTDELTAS tweaked, now has 4 million entity limit. still not enabled by default.
TE_BEAM now maps to a separate TEQW_BEAM to avoid conflicts with QW.
added android multitouch emulation for windows/rawinput (in_simulatemultitouch).
split topcolor/bottomcolor from scoreboard, for dp's colormap|1024 feature.
now using utf-8 for windows consoles.
qcc warnings/errors now give clickable console links for quick+easy editing.
disabled menutint when the currently active item changes contrast or gamma (for OneManClan).
Added support for drawfont/drawfontscale.
tweaked the qcvm a little to reduce the number of pointers.
.doll file loading. still experimental and will likely crash. requires csqc active, even if its a dummy progs. this will be fixed in time. Still other things that need cleaning up.
windows: gl_font "?" shows the standard windows font-selection dialog, and can be used to select windows fonts. not all work. and you probably don't want to use windings.
fixed splitscreen support when playing mvds. added mini-scoreboards to splitscreen.
editor/debugger now shows asm if there's no linenumber info. also, pressing f1 for help shows the shortcuts.
Added support for .framegroups files for psk(psa) and iqm formats.
True support for ezquake's colour codes. Mutually exclusive with background colours.
path command output slightly more readable.
added support for digest_hex (MD4, SHA1, CRC16).
skingroups now colourmap correctly.
Fix terrain colour hints, and litdata from the wrong bsp.
fix ftp dual-homed issue. support epsv command, and enable ipv6 (eprt still not supported).
remove d3d11 compilation from the makefile. the required headers are not provided by mingw, and are not available to the build bot, so don't bother.
fix v *= v.x and similar opcodes.
fteqcc: fixed support for áéíóú type chars in names. utf-8 files now properly supported (even with the utf-8 bom/identifier). utf-16 also supported.
fteqcc: fixed '#if 1 == 3 && 4' parsing.
fteqcc: -Werror acts on the warning, rather than as a separate error. Line numbers are thus more readable.
fteqcc: copyright message now includes compile date instead.
fteqccgui: the treeview control is now coloured depending on whether there were warnings/errors in the last compile.
fteqccgui: the output window is now focused and scrolls down as compilation progresses.
pr_dumpplatform command dumps out some pragmas to convert more serious warnings to errors. This is to avoid the infamous 'fteqcc sucks cos my code sucks' issue.
rewrote prespawn/modelist/soundlist code. server tracks progress now.
------------------------------------------------------------------------
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@4167 fc73d0e0-1445-4013-8a0c-d673dee63da5
2013-03-12 22:29:40 +00:00
if ( cl_dlights )
for ( i = 0 ; i < rtlights_max ; i + + )
2015-10-11 11:34:58 +00:00
{
2018-11-19 06:37:25 +00:00
if ( cl_dlights [ i ] . customstyle )
Z_Free ( cl_dlights [ i ] . customstyle ) ;
------------------------------------------------------------------------
r4169 | acceptthis | 2013-01-17 08:55:12 +0000 (Thu, 17 Jan 2013) | 31 lines
removed MAX_VISEDICTS limit.
PEXT2_REPLACEMENTDELTAS tweaked, now has 4 million entity limit. still not enabled by default.
TE_BEAM now maps to a separate TEQW_BEAM to avoid conflicts with QW.
added android multitouch emulation for windows/rawinput (in_simulatemultitouch).
split topcolor/bottomcolor from scoreboard, for dp's colormap|1024 feature.
now using utf-8 for windows consoles.
qcc warnings/errors now give clickable console links for quick+easy editing.
disabled menutint when the currently active item changes contrast or gamma (for OneManClan).
Added support for drawfont/drawfontscale.
tweaked the qcvm a little to reduce the number of pointers.
.doll file loading. still experimental and will likely crash. requires csqc active, even if its a dummy progs. this will be fixed in time. Still other things that need cleaning up.
windows: gl_font "?" shows the standard windows font-selection dialog, and can be used to select windows fonts. not all work. and you probably don't want to use windings.
fixed splitscreen support when playing mvds. added mini-scoreboards to splitscreen.
editor/debugger now shows asm if there's no linenumber info. also, pressing f1 for help shows the shortcuts.
Added support for .framegroups files for psk(psa) and iqm formats.
True support for ezquake's colour codes. Mutually exclusive with background colours.
path command output slightly more readable.
added support for digest_hex (MD4, SHA1, CRC16).
skingroups now colourmap correctly.
Fix terrain colour hints, and litdata from the wrong bsp.
fix ftp dual-homed issue. support epsv command, and enable ipv6 (eprt still not supported).
remove d3d11 compilation from the makefile. the required headers are not provided by mingw, and are not available to the build bot, so don't bother.
fix v *= v.x and similar opcodes.
fteqcc: fixed support for áéíóú type chars in names. utf-8 files now properly supported (even with the utf-8 bom/identifier). utf-16 also supported.
fteqcc: fixed '#if 1 == 3 && 4' parsing.
fteqcc: -Werror acts on the warning, rather than as a separate error. Line numbers are thus more readable.
fteqcc: copyright message now includes compile date instead.
fteqccgui: the treeview control is now coloured depending on whether there were warnings/errors in the last compile.
fteqccgui: the output window is now focused and scrolls down as compilation progresses.
pr_dumpplatform command dumps out some pragmas to convert more serious warnings to errors. This is to avoid the infamous 'fteqcc sucks cos my code sucks' issue.
rewrote prespawn/modelist/soundlist code. server tracks progress now.
------------------------------------------------------------------------
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@4167 fc73d0e0-1445-4013-8a0c-d673dee63da5
2013-03-12 22:29:40 +00:00
if ( cl_dlights [ i ] . worldshadowmesh )
SH_FreeShadowMesh ( cl_dlights [ i ] . worldshadowmesh ) ;
2015-10-11 11:34:58 +00:00
2015-10-11 12:01:29 +00:00
# ifdef GLQUAKE
2015-10-11 11:34:58 +00:00
if ( cl_dlights [ i ] . coronaocclusionquery )
qglDeleteQueriesARB ( 1 , & cl_dlights [ i ] . coronaocclusionquery ) ;
2015-10-11 12:01:29 +00:00
# endif
2015-10-11 11:34:58 +00:00
}
2012-02-12 05:33:16 +00:00
# endif
2012-02-12 05:18:31 +00:00
2010-07-12 22:46:37 +00:00
rtlights_max = cl_maxdlights = 0 ;
BZ_Free ( cl_dlights ) ;
cl_dlights = NULL ;
}
2009-11-04 21:16:50 +00:00
void CL_InitDlights ( void )
{
2015-10-11 11:34:58 +00:00
CL_FreeDlights ( ) ;
2009-11-04 21:16:50 +00:00
rtlights_max = cl_maxdlights = RTL_FIRST ;
2010-07-12 22:46:37 +00:00
cl_dlights = BZ_Realloc ( cl_dlights , sizeof ( * cl_dlights ) * cl_maxdlights ) ;
2009-11-04 21:16:50 +00:00
memset ( cl_dlights , 0 , sizeof ( * cl_dlights ) * cl_maxdlights ) ;
}
2018-11-19 06:37:25 +00:00
void CL_CloneDlight ( dlight_t * dl , dlight_t * src )
{
char * customstyle = dl - > customstyle ;
void * sm = dl - > worldshadowmesh ;
unsigned int oq = dl - > coronaocclusionquery ;
unsigned int oqr = ( dl - > key = = src - > key ) ? dl - > coronaocclusionresult : false ;
memcpy ( dl , src , sizeof ( * dl ) ) ;
dl - > coronaocclusionquery = oq ;
dl - > coronaocclusionresult = oqr ;
dl - > rebuildcache = true ;
dl - > worldshadowmesh = sm ;
dl - > customstyle = src - > customstyle ? Z_StrDup ( src - > customstyle ) : NULL ;
Z_Free ( customstyle ) ;
}
2009-07-05 18:45:53 +00:00
static void CL_ClearDlight ( dlight_t * dl , int key )
{
2015-10-11 11:34:58 +00:00
void * sm = dl - > worldshadowmesh ;
unsigned int oq = dl - > coronaocclusionquery ;
unsigned int oqr = ( dl - > key = = key ) ? dl - > coronaocclusionresult : false ;
2018-11-19 06:37:25 +00:00
Z_Free ( dl - > customstyle ) ;
2009-07-05 18:45:53 +00:00
memset ( dl , 0 , sizeof ( * dl ) ) ;
2015-10-11 11:34:58 +00:00
dl - > coronaocclusionquery = oq ;
dl - > coronaocclusionresult = oqr ;
Fixes, workarounds, and breakages. Hexen2 should work much better (-hexen2 says no mission pack, -portals says h2mp). Started working on splitting bigcoords per client, far too much work still to go on that. Removed gl_ztrick entirely. Enabled csprogs download by default. Added client support for fitzquake's 666 protocol, needs testing, some cleanup for dp protocols too, no server support, couldn't selectively enable it anyway. Now attempting to cache shadow meshes for explosions and stuff. Played with lightmaps a little, should potentially run a little faster on certain (intel?) cards. Tweeked npfte a little to try to avoid deadlocks and crashes. Fixed sky worldspawn parsing. Added h2mp's model format. Fixed baseline issue in q2 client, made servers generate q2 baselines. MOVETYPE_PUSH will not rotate extra if rotation is forced. Made status command show allowed client types. Changed lighting on weapons - should now be shaded.
git-svn-id: https://svn.code.sf.net/p/fteqw/code/branches/wip@3572 fc73d0e0-1445-4013-8a0c-d673dee63da5
2010-08-11 03:36:31 +00:00
dl - > rebuildcache = true ;
dl - > worldshadowmesh = sm ;
2009-07-05 18:45:53 +00:00
dl - > axis [ 0 ] [ 0 ] = 1 ;
dl - > axis [ 1 ] [ 1 ] = 1 ;
dl - > axis [ 2 ] [ 2 ] = 1 ;
dl - > key = key ;
dl - > flags = LFLAG_DYNAMIC ;
2011-07-30 14:14:56 +00:00
dl - > color [ 0 ] = 1 ;
dl - > color [ 1 ] = 1 ;
dl - > color [ 2 ] = 1 ;
2014-04-13 04:23:13 +00:00
dl - > corona = bound ( 0 , 1 * 0.25 , 1 ) ;
2013-03-12 23:17:40 +00:00
dl - > coronascale = bound ( 0 , r_flashblendscale . value , 1 ) ;
2019-09-10 15:40:04 +00:00
dl - > style = - 1 ;
2013-10-08 14:28:11 +00:00
# ifdef RTLIGHTS
2012-12-04 19:37:57 +00:00
dl - > lightcolourscales [ 0 ] = r_shadow_realtime_dlight_ambient . value ;
dl - > lightcolourscales [ 1 ] = r_shadow_realtime_dlight_diffuse . value ;
dl - > lightcolourscales [ 2 ] = r_shadow_realtime_dlight_specular . value ;
2013-10-08 14:28:11 +00:00
# endif
2009-11-04 21:16:50 +00:00
// if (r_shadow_realtime_dlight_shadowmap.value)
// dl->flags |= LFLAG_SHADOWMAP;
}
dlight_t * CL_AllocSlight ( void )
{
dlight_t * dl ;
2018-11-19 06:37:25 +00:00
int i ;
for ( i = RTL_FIRST ; i < rtlights_max ; i + + )
2009-11-04 21:16:50 +00:00
{
2018-11-19 06:37:25 +00:00
if ( cl_dlights [ i ] . radius < = 0 )
break ;
2009-11-04 21:16:50 +00:00
}
2018-11-19 06:37:25 +00:00
if ( i = = rtlights_max )
{
if ( rtlights_max = = cl_maxdlights )
{
cl_maxdlights = rtlights_max + 8 ;
cl_dlights = BZ_Realloc ( cl_dlights , sizeof ( * cl_dlights ) * cl_maxdlights ) ;
memset ( & cl_dlights [ rtlights_max ] , 0 , sizeof ( * cl_dlights ) * ( cl_maxdlights - rtlights_max ) ) ;
}
i = rtlights_max + + ;
}
dl = & cl_dlights [ i ] ;
2009-11-04 21:16:50 +00:00
CL_ClearDlight ( dl , 0 ) ;
2018-01-22 19:18:04 +00:00
dl - > flags = LFLAG_REALTIMEMODE ;
2011-12-26 15:19:13 +00:00
dl - > corona = 0 ;
2009-11-04 21:16:50 +00:00
return dl ;
2009-07-05 18:45:53 +00:00
}
2004-08-23 00:15:46 +00:00
/*
= = = = = = = = = = = = = = =
CL_AllocDlight
= = = = = = = = = = = = = = =
*/
dlight_t * CL_AllocDlight ( int key )
{
int i ;
dlight_t * dl ;
// first look for an exact key match
if ( key )
{
2009-11-04 21:16:50 +00:00
dl = cl_dlights + rtlights_first ;
for ( i = rtlights_first ; i < RTL_FIRST ; i + + , dl + + )
2004-08-23 00:15:46 +00:00
{
if ( dl - > key = = key )
{
2009-07-05 18:45:53 +00:00
CL_ClearDlight ( dl , key ) ;
2004-08-23 00:15:46 +00:00
return dl ;
}
}
}
2009-11-04 21:16:50 +00:00
//default to the first
dl = & cl_dlights [ rtlights_first ? rtlights_first - 1 : 0 ] ;
//try and find one that is free
for ( i = RTL_FIRST ; i > rtlights_first & & i > 0 ; )
2004-08-23 00:15:46 +00:00
{
2009-11-04 21:16:50 +00:00
i - - ;
if ( ! cl_dlights [ i ] . radius )
{
dl = & cl_dlights [ i ] ;
break ;
}
2004-08-23 00:15:46 +00:00
}
2009-11-04 21:16:50 +00:00
if ( rtlights_first > dl - cl_dlights )
rtlights_first = dl - cl_dlights ;
2004-08-23 00:15:46 +00:00
2009-07-05 18:45:53 +00:00
CL_ClearDlight ( dl , key ) ;
2004-08-23 00:15:46 +00:00
return dl ;
}
/*
= = = = = = = = = = = = = = =
CL_NewDlight
= = = = = = = = = = = = = = =
*/
2011-12-27 08:35:19 +00:00
dlight_t * CL_NewDlight ( int key , const vec3_t org , float radius , float time ,
2004-08-23 00:15:46 +00:00
float r , float g , float b )
{
dlight_t * dl ;
dl = CL_AllocDlight ( key ) ;
2009-11-04 21:16:50 +00:00
VectorCopy ( org , dl - > origin ) ;
2004-08-23 00:15:46 +00:00
dl - > radius = radius ;
dl - > die = cl . time + time ;
dl - > color [ 0 ] = r ;
dl - > color [ 1 ] = g ;
dl - > color [ 2 ] = b ;
2008-12-23 02:55:20 +00:00
return dl ;
2004-08-23 00:15:46 +00:00
}
/*
= = = = = = = = = = = = = = =
CL_DecayLights
= = = = = = = = = = = = = = =
*/
void CL_DecayLights ( void )
{
int i ;
dlight_t * dl ;
2013-06-23 02:17:02 +00:00
float frametime = host_frametime ;
2004-08-23 00:15:46 +00:00
if ( cl . paused ) //DON'T DO IT!!!
2013-06-23 02:17:02 +00:00
frametime = 0 ;
2004-08-23 00:15:46 +00:00
2009-11-04 21:16:50 +00:00
dl = cl_dlights + rtlights_first ;
for ( i = rtlights_first ; i < RTL_FIRST ; i + + , dl + + )
2004-08-23 00:15:46 +00:00
{
2004-11-27 08:16:25 +00:00
if ( ! dl - > radius )
2009-11-04 21:16:50 +00:00
{
2004-08-23 00:15:46 +00:00
continue ;
2009-11-04 21:16:50 +00:00
}
2004-11-27 08:16:25 +00:00
2009-07-05 18:45:53 +00:00
if ( ! dl - > die )
{
continue ;
}
2004-11-27 08:16:25 +00:00
if ( dl - > die < ( float ) cl . time )
{
2009-11-04 21:16:50 +00:00
if ( i = = rtlights_first )
rtlights_first + + ;
2004-11-27 08:16:25 +00:00
dl - > radius = 0 ;
continue ;
}
2005-02-06 02:47:36 +00:00
2018-01-03 04:40:06 +00:00
if ( r_dynamic . ival = = 2 )
{ //don't decay quite so fast, this should aproximate winquake a bit better.
dl - > die - = frametime * 0.5 ;
dl - > radius - = frametime * dl - > decay * 0.5 ;
}
else
dl - > radius - = frametime * dl - > decay ;
2004-08-23 00:15:46 +00:00
if ( dl - > radius < 0 )
2006-05-11 03:14:41 +00:00
{
2009-11-04 21:16:50 +00:00
if ( i = = rtlights_first )
rtlights_first + + ;
2004-08-23 00:15:46 +00:00
dl - > radius = 0 ;
2006-05-11 03:14:41 +00:00
continue ;
}
2004-08-23 00:15:46 +00:00
if ( dl - > channelfade [ 0 ] )
{
2013-06-23 02:17:02 +00:00
dl - > color [ 0 ] - = frametime * dl - > channelfade [ 0 ] ;
2004-08-23 00:15:46 +00:00
if ( dl - > color [ 0 ] < 0 )
dl - > color [ 0 ] = 0 ;
}
if ( dl - > channelfade [ 1 ] )
{
2013-06-23 02:17:02 +00:00
dl - > color [ 1 ] - = frametime * dl - > channelfade [ 1 ] ;
2004-08-23 00:15:46 +00:00
if ( dl - > color [ 1 ] < 0 )
dl - > color [ 1 ] = 0 ;
}
if ( dl - > channelfade [ 2 ] )
{
2013-06-23 02:17:02 +00:00
dl - > color [ 2 ] - = frametime * dl - > channelfade [ 2 ] ;
2004-08-23 00:15:46 +00:00
if ( dl - > color [ 2 ] < 0 )
dl - > color [ 2 ] = 0 ;
}
}
}
/*
= = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = =
PACKET ENTITY PARSING / LINKING
= = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = =
*/
/*
= = = = = = = = = = = = = = = = = =
CL_ParseDelta
Can go from either a baseline or a previous packet_entity
= = = = = = = = = = = = = = = = = =
*/
2011-10-27 15:46:36 +00:00
//int bitcounts[32]; /// just for protocol profiling
2016-07-12 00:40:13 +00:00
void CLQW_ParseDelta ( entity_state_t * from , entity_state_t * to , int bits )
2004-08-23 00:15:46 +00:00
{
int i ;
# ifdef PROTOCOLEXTENSIONS
int morebits = 0 ;
# endif
// set everything to the state we are delta'ing from
* to = * from ;
to - > number = bits & 511 ;
2016-07-12 00:40:13 +00:00
to - > sequence = cls . netchan . incoming_sequence ;
2004-08-23 00:15:46 +00:00
bits & = ~ 511 ;
if ( bits & U_MOREBITS )
{ // read in the low order bits
i = MSG_ReadByte ( ) ;
bits | = i ;
}
// count the bits for net profiling
2011-10-27 15:46:36 +00:00
// for (i=0 ; i<16 ; i++)
// if (bits&(1<<i))
// bitcounts[i]++;
2004-08-23 00:15:46 +00:00
# ifdef PROTOCOLEXTENSIONS
2013-09-06 22:57:44 +00:00
if ( ( bits & U_EVENMORE ) & & ( cls . fteprotocolextensions & ( PEXT_SCALE | PEXT_TRANS | PEXT_FATNESS | PEXT_HEXEN2 | PEXT_COLOURMOD | PEXT_DPFLAGS | PEXT_MODELDBL | PEXT_ENTITYDBL | PEXT_ENTITYDBL2 ) ) )
2004-08-23 00:15:46 +00:00
morebits = MSG_ReadByte ( ) ;
if ( morebits & U_YETMORE )
morebits | = MSG_ReadByte ( ) < < 8 ;
# endif
2012-02-12 05:18:31 +00:00
if ( ( morebits & U_ENTITYDBL ) & & ( cls . fteprotocolextensions & PEXT_ENTITYDBL ) )
to - > number + = 512 ;
if ( ( morebits & U_ENTITYDBL2 ) & & ( cls . fteprotocolextensions & PEXT_ENTITYDBL2 ) )
to - > number + = 1024 ;
2004-08-23 00:15:46 +00:00
if ( bits & U_MODEL )
2011-07-30 14:14:56 +00:00
{
2004-08-23 00:15:46 +00:00
to - > modelindex = MSG_ReadByte ( ) ;
2012-02-12 05:18:31 +00:00
if ( morebits & U_MODELDBL & & ( cls . fteprotocolextensions & PEXT_MODELDBL ) )
2011-07-30 14:14:56 +00:00
to - > modelindex + = 256 ;
}
2012-02-12 05:18:31 +00:00
else if ( morebits & U_MODELDBL & & ( cls . fteprotocolextensions & PEXT_MODELDBL ) )
2011-07-30 14:14:56 +00:00
to - > modelindex = MSG_ReadShort ( ) ;
2004-08-23 00:15:46 +00:00
if ( bits & U_FRAME )
to - > frame = MSG_ReadByte ( ) ;
if ( bits & U_COLORMAP )
to - > colormap = MSG_ReadByte ( ) ;
if ( bits & U_SKIN )
2012-02-12 05:18:31 +00:00
{
2004-08-23 00:15:46 +00:00
to - > skinnum = MSG_ReadByte ( ) ;
2012-02-12 05:18:31 +00:00
if ( to - > skinnum > = 256 - 32 ) /*final 32 skins are taken as a content value instead*/
to - > skinnum = ( char ) to - > skinnum ;
}
2004-08-23 00:15:46 +00:00
if ( bits & U_EFFECTS )
2005-08-26 22:56:51 +00:00
to - > effects = ( to - > effects & 0xff00 ) | MSG_ReadByte ( ) ;
2004-08-23 00:15:46 +00:00
if ( bits & U_ORIGIN1 )
2017-12-28 16:24:50 +00:00
{
if ( cls . ezprotocolextensions1 & EZPEXT1_FLOATENTCOORDS )
to - > origin [ 0 ] = MSG_ReadCoordFloat ( ) ;
else
to - > origin [ 0 ] = MSG_ReadCoord ( ) ;
}
2005-02-06 02:47:36 +00:00
2004-08-23 00:15:46 +00:00
if ( bits & U_ANGLE1 )
to - > angles [ 0 ] = MSG_ReadAngle ( ) ;
if ( bits & U_ORIGIN2 )
2017-12-28 16:24:50 +00:00
{
if ( cls . ezprotocolextensions1 & EZPEXT1_FLOATENTCOORDS )
to - > origin [ 1 ] = MSG_ReadCoordFloat ( ) ;
else
to - > origin [ 1 ] = MSG_ReadCoord ( ) ;
}
2005-02-06 02:47:36 +00:00
2004-08-23 00:15:46 +00:00
if ( bits & U_ANGLE2 )
to - > angles [ 1 ] = MSG_ReadAngle ( ) ;
if ( bits & U_ORIGIN3 )
2017-12-28 16:24:50 +00:00
{
if ( cls . ezprotocolextensions1 & EZPEXT1_FLOATENTCOORDS )
2019-03-23 07:06:37 +00:00
to - > origin [ 2 ] = MSG_ReadCoordFloat ( ) ;
2017-12-28 16:24:50 +00:00
else
to - > origin [ 2 ] = MSG_ReadCoord ( ) ;
}
2005-02-06 02:47:36 +00:00
2004-08-23 00:15:46 +00:00
if ( bits & U_ANGLE3 )
to - > angles [ 2 ] = MSG_ReadAngle ( ) ;
2016-07-12 00:40:13 +00:00
to - > solidsize = ES_SOLID_BSP ;
2004-08-23 00:15:46 +00:00
if ( bits & U_SOLID )
{
2016-07-12 00:40:13 +00:00
//doesn't mean anything in vanilla. solidity is infered instead.
2004-08-23 00:15:46 +00:00
}
# ifdef PEXT_SCALE
2011-08-16 04:12:15 +00:00
if ( ( morebits & U_SCALE ) & & ( cls . fteprotocolextensions & PEXT_SCALE ) )
2005-07-01 19:23:00 +00:00
to - > scale = MSG_ReadByte ( ) ;
2004-08-23 00:15:46 +00:00
# endif
# ifdef PEXT_TRANS
2011-08-16 04:12:15 +00:00
if ( ( morebits & U_TRANS ) & & ( cls . fteprotocolextensions & PEXT_TRANS ) )
2005-07-01 19:23:00 +00:00
to - > trans = MSG_ReadByte ( ) ;
2004-08-23 00:15:46 +00:00
# endif
# ifdef PEXT_FATNESS
2011-08-16 04:12:15 +00:00
if ( ( morebits & U_FATNESS ) & & ( cls . fteprotocolextensions & PEXT_FATNESS ) )
2005-07-01 19:23:00 +00:00
to - > fatness = MSG_ReadChar ( ) ;
2004-08-23 00:15:46 +00:00
# endif
2011-08-16 04:12:15 +00:00
if ( ( morebits & U_DRAWFLAGS ) & & ( cls . fteprotocolextensions & PEXT_HEXEN2 ) )
2005-05-15 18:49:04 +00:00
to - > hexen2flags = MSG_ReadByte ( ) ;
2011-08-16 04:12:15 +00:00
if ( ( morebits & U_ABSLIGHT ) & & ( cls . fteprotocolextensions & PEXT_HEXEN2 ) )
2004-08-23 00:15:46 +00:00
to - > abslight = MSG_ReadByte ( ) ;
2011-08-16 04:12:15 +00:00
if ( ( morebits & U_COLOURMOD ) & & ( cls . fteprotocolextensions & PEXT_COLOURMOD ) )
2006-03-12 06:23:52 +00:00
{
to - > colormod [ 0 ] = MSG_ReadByte ( ) ;
to - > colormod [ 1 ] = MSG_ReadByte ( ) ;
to - > colormod [ 2 ] = MSG_ReadByte ( ) ;
}
2005-05-15 18:49:04 +00:00
if ( morebits & U_DPFLAGS ) // && cls.fteprotocolextensions & PEXT_DPFLAGS)
{
// these are bits for the 'flags' field of the entity_state_t
i = MSG_ReadByte ( ) ;
2009-07-18 20:46:42 +00:00
to - > dpflags = i ;
2005-05-15 18:49:04 +00:00
}
2012-07-21 04:43:31 +00:00
if ( ! ( cls . fteprotocolextensions & PEXT_DPFLAGS ) )
{
if ( to - > frame )
to - > dpflags | = RENDER_STEP ;
}
2005-07-01 19:23:00 +00:00
if ( morebits & U_TAGINFO )
{
to - > tagentity = MSG_ReadShort ( ) ;
to - > tagindex = MSG_ReadShort ( ) ;
}
2005-08-07 18:08:13 +00:00
if ( morebits & U_LIGHT )
{
to - > light [ 0 ] = MSG_ReadShort ( ) ;
to - > light [ 1 ] = MSG_ReadShort ( ) ;
to - > light [ 2 ] = MSG_ReadShort ( ) ;
to - > light [ 3 ] = MSG_ReadShort ( ) ;
to - > lightstyle = MSG_ReadByte ( ) ;
to - > lightpflags = MSG_ReadByte ( ) ;
}
2005-05-15 18:49:04 +00:00
2005-08-26 22:56:51 +00:00
if ( morebits & U_EFFECTS16 )
to - > effects = ( to - > effects & 0x00ff ) | ( MSG_ReadByte ( ) < < 8 ) ;
2004-08-23 00:15:46 +00:00
}
/*
= = = = = = = = = = = = = = = = =
FlushEntityPacket
= = = = = = = = = = = = = = = = =
*/
void FlushEntityPacket ( void )
{
int word ;
entity_state_t olde , newe ;
Con_DPrintf ( " FlushEntityPacket \n " ) ;
memset ( & olde , 0 , sizeof ( olde ) ) ;
cl . validsequence = 0 ; // can't render a frame
2013-03-12 22:53:23 +00:00
cl . inframes [ cls . netchan . incoming_sequence & UPDATE_MASK ] . invalid = true ;
2004-08-23 00:15:46 +00:00
// read it all, but ignore it
while ( 1 )
{
word = ( unsigned short ) MSG_ReadShort ( ) ;
if ( msg_badread )
{ // something didn't parse right...
Host_EndGame ( " msg_badread in packetentities " ) ;
return ;
}
if ( ! word )
break ; // done
2016-07-12 00:40:13 +00:00
CLQW_ParseDelta ( & olde , & newe , word ) ;
2012-02-12 05:18:31 +00:00
}
}
2016-07-12 00:40:13 +00:00
void CLFTE_ReadDelta ( unsigned int entnum , entity_state_t * news , entity_state_t * olds , entity_state_t * baseline , packet_entities_t * newp , packet_entities_t * oldp )
2012-02-12 05:18:31 +00:00
{
2015-02-02 08:01:53 +00:00
unsigned int predbits = 0 ;
2012-02-12 05:18:31 +00:00
unsigned int bits ;
bits = MSG_ReadByte ( ) ;
if ( bits & UF_EXTEND1 )
bits | = MSG_ReadByte ( ) < < 8 ;
if ( bits & UF_EXTEND2 )
bits | = MSG_ReadByte ( ) < < 16 ;
if ( bits & UF_EXTEND3 )
bits | = MSG_ReadByte ( ) < < 24 ;
if ( cl_shownet . ival > = 3 )
2013-03-12 22:35:33 +00:00
Con_Printf ( " %3i: Update %4i 0x%x \n " , msg_readcount , entnum , bits ) ;
2012-02-12 05:18:31 +00:00
if ( bits & UF_RESET )
2012-02-14 15:50:34 +00:00
{
// Con_Printf("%3i: Reset %i @ %i\n", msg_readcount, entnum, cls.netchan.incoming_sequence);
2012-02-12 05:18:31 +00:00
* news = * baseline ;
2012-02-14 15:50:34 +00:00
}
2012-02-12 05:18:31 +00:00
else if ( ! olds )
{
2012-02-14 15:50:34 +00:00
/*reset got lost, probably the data will be filled in later - FIXME: we should probably ignore this entity*/
2013-03-12 22:35:33 +00:00
Con_DPrintf ( " New entity %i without reset \n " , entnum ) ;
2012-07-05 19:42:36 +00:00
* news = nullentitystate ;
2012-02-14 15:50:34 +00:00
// *news = *baseline;
2012-02-12 05:18:31 +00:00
}
else
* news = * olds ;
news - > number = entnum ;
2016-07-12 00:40:13 +00:00
news - > sequence = cls . netchan . incoming_sequence ;
2012-02-12 05:18:31 +00:00
if ( bits & UF_FRAME )
{
if ( bits & UF_16BIT )
news - > frame = MSG_ReadShort ( ) ;
else
news - > frame = MSG_ReadByte ( ) ;
}
if ( bits & UF_ORIGINXY )
{
news - > origin [ 0 ] = MSG_ReadCoord ( ) ;
news - > origin [ 1 ] = MSG_ReadCoord ( ) ;
}
if ( bits & UF_ORIGINZ )
news - > origin [ 2 ] = MSG_ReadCoord ( ) ;
2015-02-02 08:01:53 +00:00
if ( ( bits & UF_PREDINFO ) & & ! ( cls . fteprotocolextensions2 & PEXT2_PREDINFO ) )
2012-02-12 05:18:31 +00:00
{
/*predicted stuff gets more precise angles*/
if ( bits & UF_ANGLESXZ )
{
news - > angles [ 0 ] = MSG_ReadAngle16 ( ) ;
news - > angles [ 2 ] = MSG_ReadAngle16 ( ) ;
}
if ( bits & UF_ANGLESY )
news - > angles [ 1 ] = MSG_ReadAngle16 ( ) ;
}
else
{
if ( bits & UF_ANGLESXZ )
{
news - > angles [ 0 ] = MSG_ReadAngle ( ) ;
news - > angles [ 2 ] = MSG_ReadAngle ( ) ;
}
if ( bits & UF_ANGLESY )
news - > angles [ 1 ] = MSG_ReadAngle ( ) ;
}
if ( ( bits & ( UF_EFFECTS | UF_EFFECTS2 ) ) = = ( UF_EFFECTS | UF_EFFECTS2 ) )
news - > effects = MSG_ReadLong ( ) ;
else if ( bits & UF_EFFECTS2 )
Reworked client support for DPP5+. less code now, its much more graceful.
added waterfog command. waterfog overrides regular fog only when the view is in water.
fixed 64bit printf format specifiers. should work better on winxp64.
fixed some spec angle weirdness.
fixed viewsize 99.99 weirdness with ezhud.
fixed extra offset on the console (exhibited in 64bit builds, but not limited to).
fixed .avi playback, can now actually display frames again.
reimplemented line sparks.
fixed r_editlights_save flipping the light's pitch.
fixed issue with oggs failing to load.
fixed condump to cope with unicode properly.
made sv_bigcoords default except in quake. hexen2 kinda needs it for bsp angle precision.
fixed nq server to not stall weirdly on map changes.
fixed qwprogs svc_cdtrack not bugging out with nq clients on the server.
fixed restart command to load the last map run by the server, instead of start.bsp (when idle)
optimised d3d9 renderer a little. now uses less draw calls, especially with complex scenes. seems to get higher framerates than opengl now.
fixed d3d9 renderer to not bug out quite so much when run fullscreen (shader subsystem is now correctly initialised).
fixed a couple of bugs from font change. also now supports utf-8 in a few more places.
r_editlights_reload no longer generates rtlights inside the void. this resolves a few glitches (but should also help framerates a little).
fixed so corona-only lights won't generate shadowmaps and waste lots of time.
removed lots of #defines from qclib. I should never have made them in the first place, but I was lazy. obviously there's more left that I cba to remove yet.
fixed nested calls with variant-vectors. this fixes csaddon's light editor.
fixed qcc hc calling conventions using redundant stores.
disabled keywords can still be used by using __keyword instead.
fixed ftegccgui grep feature.
fixed motionless-dog qcc bug.
tweaked qcc warnings a little. -Wall is now a viable setting. you should be able to fix all those warnings.
fixed qw svc_intermission + dpp5+ clients bug.
fixed annoying spam about disconnecting in hexen2.
rewrote status command a little to cope with ipv6 addresses more gracefully
fixed significant stall when hibernating/debugging a server with a player sitting on it.
fixed truelightning.
fixed rocketlight overriding pflags.
fixed torches vanishing on vid_restart.
fixed issue with decal scaling.
fixed findentityfield builtin.
fixed fteqcc issue with ptr+1
fixed use of arrays inside class functions.
fixed/implemented fteqcc emulation of pointer opcodes.
added __inout keyword to fteqcc, so that it doesn't feel so horrendous.
fixed sizeof(*foo)
fixed *struct = struct;
fixed recursive structs.
fixed fteqcc warning report.
fixed sdl2 controller support, hopefully.
attempted to implement xinput, including per-player audio playback.
slightly fixed relaxed attitude to mouse focus when running fullscreen.
fixed weird warnings/errors with 'ent.arrayhead' terms. now generates sane errors.
implemented bindmaps (for csqc).
fixed crashing bug with eprint builtin.
implemented subset of music_playlist_* functionality. significant changes to music playback.
fixed some more dpcsqc compat.
fixed binds menu. now displays and accepts modifiers.
fixed issues with huge lightmaps.
fixed protocol determinism with dp clients connecting to fte servers. the initial getchallenge request now inhibits vanilla nq connection requests.
implemented support for 'dupe' userinfo key, allowing clients to request client->server packet duplication. should probably queue them tbh.
implemented sv_saveentfile command.
fixed resume after breaking inside a stepped-over function.
fixed erroneous footer after debugging.
(I wonder just how many things I broke with these fixes)
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@4946 fc73d0e0-1445-4013-8a0c-d673dee63da5
2015-07-26 10:56:18 +00:00
news - > effects = ( unsigned short ) MSG_ReadShort ( ) ;
2012-02-12 05:18:31 +00:00
else if ( bits & UF_EFFECTS )
news - > effects = MSG_ReadByte ( ) ;
news - > u . q1 . movement [ 0 ] = 0 ;
news - > u . q1 . movement [ 1 ] = 0 ;
news - > u . q1 . movement [ 2 ] = 0 ;
news - > u . q1 . velocity [ 0 ] = 0 ;
news - > u . q1 . velocity [ 1 ] = 0 ;
news - > u . q1 . velocity [ 2 ] = 0 ;
if ( bits & UF_PREDINFO )
{
predbits = MSG_ReadByte ( ) ;
if ( predbits & UFP_FORWARD )
news - > u . q1 . movement [ 0 ] = MSG_ReadShort ( ) ;
else
news - > u . q1 . movement [ 0 ] = 0 ;
if ( predbits & UFP_SIDE )
news - > u . q1 . movement [ 1 ] = MSG_ReadShort ( ) ;
else
news - > u . q1 . movement [ 1 ] = 0 ;
if ( predbits & UFP_UP )
news - > u . q1 . movement [ 2 ] = MSG_ReadShort ( ) ;
else
news - > u . q1 . movement [ 2 ] = 0 ;
if ( predbits & UFP_MOVETYPE )
news - > u . q1 . pmovetype = MSG_ReadByte ( ) ;
if ( predbits & UFP_VELOCITYXY )
{
news - > u . q1 . velocity [ 0 ] = MSG_ReadShort ( ) ;
news - > u . q1 . velocity [ 1 ] = MSG_ReadShort ( ) ;
}
else
{
news - > u . q1 . velocity [ 0 ] = 0 ;
news - > u . q1 . velocity [ 1 ] = 0 ;
}
if ( predbits & UFP_VELOCITYZ )
news - > u . q1 . velocity [ 2 ] = MSG_ReadShort ( ) ;
else
news - > u . q1 . velocity [ 2 ] = 0 ;
if ( predbits & UFP_MSEC )
news - > u . q1 . msec = MSG_ReadByte ( ) ;
else
news - > u . q1 . msec = 0 ;
2015-02-02 08:01:53 +00:00
if ( cls . fteprotocolextensions2 & PEXT2_PREDINFO )
{
if ( predbits & UFP_VIEWANGLE )
{
if ( bits & UF_ANGLESXZ )
{
news - > u . q1 . vangle [ 0 ] = MSG_ReadShort ( ) ;
news - > u . q1 . vangle [ 2 ] = MSG_ReadShort ( ) ;
}
if ( bits & UF_ANGLESY )
news - > u . q1 . vangle [ 1 ] = MSG_ReadShort ( ) ;
}
}
else
2012-02-14 15:50:34 +00:00
{
2015-02-02 08:01:53 +00:00
if ( predbits & UFP_WEAPONFRAME_OLD )
{
news - > u . q1 . weaponframe = MSG_ReadByte ( ) ;
if ( news - > u . q1 . weaponframe & 0x80 )
news - > u . q1 . weaponframe = ( news - > u . q1 . weaponframe & 127 ) | ( MSG_ReadByte ( ) < < 7 ) ;
}
2012-02-14 15:50:34 +00:00
}
2012-02-12 05:18:31 +00:00
}
else
2015-02-02 08:01:53 +00:00
{
2012-02-12 05:18:31 +00:00
news - > u . q1 . msec = 0 ;
2015-02-02 08:01:53 +00:00
}
2015-02-07 22:34:22 +00:00
if ( ! ( predbits & UFP_VIEWANGLE ) | | ! ( cls . fteprotocolextensions2 & PEXT2_PREDINFO ) )
2015-02-02 08:01:53 +00:00
{
Reworked client support for DPP5+. less code now, its much more graceful.
added waterfog command. waterfog overrides regular fog only when the view is in water.
fixed 64bit printf format specifiers. should work better on winxp64.
fixed some spec angle weirdness.
fixed viewsize 99.99 weirdness with ezhud.
fixed extra offset on the console (exhibited in 64bit builds, but not limited to).
fixed .avi playback, can now actually display frames again.
reimplemented line sparks.
fixed r_editlights_save flipping the light's pitch.
fixed issue with oggs failing to load.
fixed condump to cope with unicode properly.
made sv_bigcoords default except in quake. hexen2 kinda needs it for bsp angle precision.
fixed nq server to not stall weirdly on map changes.
fixed qwprogs svc_cdtrack not bugging out with nq clients on the server.
fixed restart command to load the last map run by the server, instead of start.bsp (when idle)
optimised d3d9 renderer a little. now uses less draw calls, especially with complex scenes. seems to get higher framerates than opengl now.
fixed d3d9 renderer to not bug out quite so much when run fullscreen (shader subsystem is now correctly initialised).
fixed a couple of bugs from font change. also now supports utf-8 in a few more places.
r_editlights_reload no longer generates rtlights inside the void. this resolves a few glitches (but should also help framerates a little).
fixed so corona-only lights won't generate shadowmaps and waste lots of time.
removed lots of #defines from qclib. I should never have made them in the first place, but I was lazy. obviously there's more left that I cba to remove yet.
fixed nested calls with variant-vectors. this fixes csaddon's light editor.
fixed qcc hc calling conventions using redundant stores.
disabled keywords can still be used by using __keyword instead.
fixed ftegccgui grep feature.
fixed motionless-dog qcc bug.
tweaked qcc warnings a little. -Wall is now a viable setting. you should be able to fix all those warnings.
fixed qw svc_intermission + dpp5+ clients bug.
fixed annoying spam about disconnecting in hexen2.
rewrote status command a little to cope with ipv6 addresses more gracefully
fixed significant stall when hibernating/debugging a server with a player sitting on it.
fixed truelightning.
fixed rocketlight overriding pflags.
fixed torches vanishing on vid_restart.
fixed issue with decal scaling.
fixed findentityfield builtin.
fixed fteqcc issue with ptr+1
fixed use of arrays inside class functions.
fixed/implemented fteqcc emulation of pointer opcodes.
added __inout keyword to fteqcc, so that it doesn't feel so horrendous.
fixed sizeof(*foo)
fixed *struct = struct;
fixed recursive structs.
fixed fteqcc warning report.
fixed sdl2 controller support, hopefully.
attempted to implement xinput, including per-player audio playback.
slightly fixed relaxed attitude to mouse focus when running fullscreen.
fixed weird warnings/errors with 'ent.arrayhead' terms. now generates sane errors.
implemented bindmaps (for csqc).
fixed crashing bug with eprint builtin.
implemented subset of music_playlist_* functionality. significant changes to music playback.
fixed some more dpcsqc compat.
fixed binds menu. now displays and accepts modifiers.
fixed issues with huge lightmaps.
fixed protocol determinism with dp clients connecting to fte servers. the initial getchallenge request now inhibits vanilla nq connection requests.
implemented support for 'dupe' userinfo key, allowing clients to request client->server packet duplication. should probably queue them tbh.
implemented sv_saveentfile command.
fixed resume after breaking inside a stepped-over function.
fixed erroneous footer after debugging.
(I wonder just how many things I broke with these fixes)
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@4946 fc73d0e0-1445-4013-8a0c-d673dee63da5
2015-07-26 10:56:18 +00:00
if ( bits & UF_ANGLESXZ )
news - > u . q1 . vangle [ 0 ] = ANGLE2SHORT ( news - > angles [ 0 ] * ( ( bits & UF_PREDINFO ) ? - 3 : - 1 ) ) ;
if ( bits & UF_ANGLESY )
news - > u . q1 . vangle [ 1 ] = ANGLE2SHORT ( news - > angles [ 1 ] ) ;
if ( bits & UF_ANGLESXZ )
news - > u . q1 . vangle [ 2 ] = ANGLE2SHORT ( news - > angles [ 2 ] ) ;
2015-02-02 08:01:53 +00:00
}
2012-02-12 05:18:31 +00:00
if ( bits & UF_MODEL )
{
if ( bits & UF_16BIT )
news - > modelindex = MSG_ReadShort ( ) ;
else
news - > modelindex = MSG_ReadByte ( ) ;
}
if ( bits & UF_SKIN )
{
if ( bits & UF_16BIT )
news - > skinnum = MSG_ReadShort ( ) ;
else
news - > skinnum = MSG_ReadByte ( ) ;
}
if ( bits & UF_COLORMAP )
news - > colormap = MSG_ReadByte ( ) ;
if ( bits & UF_SOLID )
2016-07-12 00:40:13 +00:00
{
if ( cls . fteprotocolextensions2 & PEXT2_NEWSIZEENCODING )
{
qbyte enc = MSG_ReadByte ( ) ;
if ( enc = = 0 )
news - > solidsize = ES_SOLID_NOT ;
else if ( enc = = 1 )
news - > solidsize = ES_SOLID_BSP ;
else if ( enc = = 2 )
news - > solidsize = ES_SOLID_HULL1 ;
else if ( enc = = 3 )
news - > solidsize = ES_SOLID_HULL2 ;
else if ( enc = = 16 )
news - > solidsize = MSG_ReadSize16 ( & net_message ) ;
else if ( enc = = 32 )
news - > solidsize = MSG_ReadLong ( ) ;
else
Sys_Error ( " Solid+Size encoding not known " ) ;
}
else
news - > solidsize = MSG_ReadSize16 ( & net_message ) ;
}
2012-02-12 05:18:31 +00:00
if ( bits & UF_FLAGS )
news - > dpflags = MSG_ReadByte ( ) ;
if ( bits & UF_ALPHA )
news - > trans = MSG_ReadByte ( ) ;
if ( bits & UF_SCALE )
news - > scale = MSG_ReadByte ( ) ;
2016-07-12 00:40:13 +00:00
if ( bits & UF_BONEDATA )
2013-03-12 22:35:33 +00:00
{
2016-07-12 00:40:13 +00:00
unsigned char fl = MSG_ReadByte ( ) ;
if ( fl & 0x80 )
{
//this is NOT finalized
short * bonedata ;
int i ;
news - > bonecount = MSG_ReadByte ( ) ;
bonedata = AllocateBoneSpace ( newp , news - > bonecount , & news - > boneoffset ) ;
for ( i = 0 ; i < news - > bonecount * 7 ; i + + )
bonedata [ i ] = MSG_ReadShort ( ) ;
}
else
news - > bonecount = 0 ; //oo, it went away.
if ( fl & 0x40 )
{
news - > basebone = MSG_ReadByte ( ) ;
news - > baseframe = MSG_ReadShort ( ) ;
}
else
{
news - > basebone = 0 ;
news - > baseframe = 0 ;
}
//fixme: basebone, baseframe, etc.
if ( fl & 0x3f )
Host_EndGame ( " unsupported entity delta info \n " ) ;
}
else if ( news - > bonecount )
{ //still has bone data from the previous frame.
short * bonedata = AllocateBoneSpace ( newp , news - > bonecount , & news - > boneoffset ) ;
memcpy ( bonedata , oldp - > bonedata + olds - > boneoffset , sizeof ( short ) * 7 * news - > bonecount ) ;
2013-03-12 22:35:33 +00:00
}
2016-07-12 00:40:13 +00:00
2012-02-12 05:18:31 +00:00
if ( bits & UF_DRAWFLAGS )
2013-03-12 22:35:33 +00:00
{
2012-02-12 05:18:31 +00:00
news - > hexen2flags = MSG_ReadByte ( ) ;
2016-07-12 00:40:13 +00:00
if ( ( news - > hexen2flags & MLS_MASK ) = = MLS_ABSLIGHT )
2013-03-12 22:35:33 +00:00
news - > abslight = MSG_ReadByte ( ) ;
else
news - > abslight = 0 ;
}
2012-02-12 05:18:31 +00:00
if ( bits & UF_TAGINFO )
{
------------------------------------------------------------------------
r4169 | acceptthis | 2013-01-17 08:55:12 +0000 (Thu, 17 Jan 2013) | 31 lines
removed MAX_VISEDICTS limit.
PEXT2_REPLACEMENTDELTAS tweaked, now has 4 million entity limit. still not enabled by default.
TE_BEAM now maps to a separate TEQW_BEAM to avoid conflicts with QW.
added android multitouch emulation for windows/rawinput (in_simulatemultitouch).
split topcolor/bottomcolor from scoreboard, for dp's colormap|1024 feature.
now using utf-8 for windows consoles.
qcc warnings/errors now give clickable console links for quick+easy editing.
disabled menutint when the currently active item changes contrast or gamma (for OneManClan).
Added support for drawfont/drawfontscale.
tweaked the qcvm a little to reduce the number of pointers.
.doll file loading. still experimental and will likely crash. requires csqc active, even if its a dummy progs. this will be fixed in time. Still other things that need cleaning up.
windows: gl_font "?" shows the standard windows font-selection dialog, and can be used to select windows fonts. not all work. and you probably don't want to use windings.
fixed splitscreen support when playing mvds. added mini-scoreboards to splitscreen.
editor/debugger now shows asm if there's no linenumber info. also, pressing f1 for help shows the shortcuts.
Added support for .framegroups files for psk(psa) and iqm formats.
True support for ezquake's colour codes. Mutually exclusive with background colours.
path command output slightly more readable.
added support for digest_hex (MD4, SHA1, CRC16).
skingroups now colourmap correctly.
Fix terrain colour hints, and litdata from the wrong bsp.
fix ftp dual-homed issue. support epsv command, and enable ipv6 (eprt still not supported).
remove d3d11 compilation from the makefile. the required headers are not provided by mingw, and are not available to the build bot, so don't bother.
fix v *= v.x and similar opcodes.
fteqcc: fixed support for áéíóú type chars in names. utf-8 files now properly supported (even with the utf-8 bom/identifier). utf-16 also supported.
fteqcc: fixed '#if 1 == 3 && 4' parsing.
fteqcc: -Werror acts on the warning, rather than as a separate error. Line numbers are thus more readable.
fteqcc: copyright message now includes compile date instead.
fteqccgui: the treeview control is now coloured depending on whether there were warnings/errors in the last compile.
fteqccgui: the output window is now focused and scrolls down as compilation progresses.
pr_dumpplatform command dumps out some pragmas to convert more serious warnings to errors. This is to avoid the infamous 'fteqcc sucks cos my code sucks' issue.
rewrote prespawn/modelist/soundlist code. server tracks progress now.
------------------------------------------------------------------------
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@4167 fc73d0e0-1445-4013-8a0c-d673dee63da5
2013-03-12 22:29:40 +00:00
news - > tagentity = MSGCL_ReadEntity ( ) ;
2012-02-12 05:18:31 +00:00
news - > tagindex = MSG_ReadByte ( ) ;
2017-06-21 01:24:25 +00:00
if ( news - > tagindex = = 0xff )
news - > tagindex = ~ 0 ;
2012-02-12 05:18:31 +00:00
}
if ( bits & UF_LIGHT )
{
news - > light [ 0 ] = MSG_ReadShort ( ) ;
news - > light [ 1 ] = MSG_ReadShort ( ) ;
2013-10-29 17:38:22 +00:00
news - > light [ 2 ] = MSG_ReadShort ( ) ;
news - > light [ 3 ] = MSG_ReadShort ( ) ;
2012-02-12 05:18:31 +00:00
news - > lightstyle = MSG_ReadByte ( ) ;
news - > lightpflags = MSG_ReadByte ( ) ;
}
2012-07-05 19:42:36 +00:00
if ( bits & UF_TRAILEFFECT )
2016-10-22 07:06:51 +00:00
{
unsigned short s ;
s = MSG_ReadShort ( ) ;
news - > u . q1 . traileffectnum = s & 0x3fff ;
if ( news - > u . q1 . traileffectnum > = countof ( cl . particle_ssprecache ) )
news - > u . q1 . traileffectnum = 0 ;
if ( s & 0x8000 )
news - > u . q1 . emiteffectnum = MSG_ReadShort ( ) & 0x3fff ;
else
news - > u . q1 . emiteffectnum = 0 ;
if ( news - > u . q1 . emiteffectnum > = countof ( cl . particle_ssprecache ) )
news - > u . q1 . emiteffectnum = 0 ;
}
2012-07-05 19:42:36 +00:00
2012-02-12 05:18:31 +00:00
if ( bits & UF_COLORMOD )
{
news - > colormod [ 0 ] = MSG_ReadByte ( ) ;
news - > colormod [ 1 ] = MSG_ReadByte ( ) ;
news - > colormod [ 2 ] = MSG_ReadByte ( ) ;
}
------------------------------------------------------------------------
r4169 | acceptthis | 2013-01-17 08:55:12 +0000 (Thu, 17 Jan 2013) | 31 lines
removed MAX_VISEDICTS limit.
PEXT2_REPLACEMENTDELTAS tweaked, now has 4 million entity limit. still not enabled by default.
TE_BEAM now maps to a separate TEQW_BEAM to avoid conflicts with QW.
added android multitouch emulation for windows/rawinput (in_simulatemultitouch).
split topcolor/bottomcolor from scoreboard, for dp's colormap|1024 feature.
now using utf-8 for windows consoles.
qcc warnings/errors now give clickable console links for quick+easy editing.
disabled menutint when the currently active item changes contrast or gamma (for OneManClan).
Added support for drawfont/drawfontscale.
tweaked the qcvm a little to reduce the number of pointers.
.doll file loading. still experimental and will likely crash. requires csqc active, even if its a dummy progs. this will be fixed in time. Still other things that need cleaning up.
windows: gl_font "?" shows the standard windows font-selection dialog, and can be used to select windows fonts. not all work. and you probably don't want to use windings.
fixed splitscreen support when playing mvds. added mini-scoreboards to splitscreen.
editor/debugger now shows asm if there's no linenumber info. also, pressing f1 for help shows the shortcuts.
Added support for .framegroups files for psk(psa) and iqm formats.
True support for ezquake's colour codes. Mutually exclusive with background colours.
path command output slightly more readable.
added support for digest_hex (MD4, SHA1, CRC16).
skingroups now colourmap correctly.
Fix terrain colour hints, and litdata from the wrong bsp.
fix ftp dual-homed issue. support epsv command, and enable ipv6 (eprt still not supported).
remove d3d11 compilation from the makefile. the required headers are not provided by mingw, and are not available to the build bot, so don't bother.
fix v *= v.x and similar opcodes.
fteqcc: fixed support for áéíóú type chars in names. utf-8 files now properly supported (even with the utf-8 bom/identifier). utf-16 also supported.
fteqcc: fixed '#if 1 == 3 && 4' parsing.
fteqcc: -Werror acts on the warning, rather than as a separate error. Line numbers are thus more readable.
fteqcc: copyright message now includes compile date instead.
fteqccgui: the treeview control is now coloured depending on whether there were warnings/errors in the last compile.
fteqccgui: the output window is now focused and scrolls down as compilation progresses.
pr_dumpplatform command dumps out some pragmas to convert more serious warnings to errors. This is to avoid the infamous 'fteqcc sucks cos my code sucks' issue.
rewrote prespawn/modelist/soundlist code. server tracks progress now.
------------------------------------------------------------------------
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@4167 fc73d0e0-1445-4013-8a0c-d673dee63da5
2013-03-12 22:29:40 +00:00
if ( bits & UF_GLOW )
2012-02-12 05:18:31 +00:00
{
------------------------------------------------------------------------
r4169 | acceptthis | 2013-01-17 08:55:12 +0000 (Thu, 17 Jan 2013) | 31 lines
removed MAX_VISEDICTS limit.
PEXT2_REPLACEMENTDELTAS tweaked, now has 4 million entity limit. still not enabled by default.
TE_BEAM now maps to a separate TEQW_BEAM to avoid conflicts with QW.
added android multitouch emulation for windows/rawinput (in_simulatemultitouch).
split topcolor/bottomcolor from scoreboard, for dp's colormap|1024 feature.
now using utf-8 for windows consoles.
qcc warnings/errors now give clickable console links for quick+easy editing.
disabled menutint when the currently active item changes contrast or gamma (for OneManClan).
Added support for drawfont/drawfontscale.
tweaked the qcvm a little to reduce the number of pointers.
.doll file loading. still experimental and will likely crash. requires csqc active, even if its a dummy progs. this will be fixed in time. Still other things that need cleaning up.
windows: gl_font "?" shows the standard windows font-selection dialog, and can be used to select windows fonts. not all work. and you probably don't want to use windings.
fixed splitscreen support when playing mvds. added mini-scoreboards to splitscreen.
editor/debugger now shows asm if there's no linenumber info. also, pressing f1 for help shows the shortcuts.
Added support for .framegroups files for psk(psa) and iqm formats.
True support for ezquake's colour codes. Mutually exclusive with background colours.
path command output slightly more readable.
added support for digest_hex (MD4, SHA1, CRC16).
skingroups now colourmap correctly.
Fix terrain colour hints, and litdata from the wrong bsp.
fix ftp dual-homed issue. support epsv command, and enable ipv6 (eprt still not supported).
remove d3d11 compilation from the makefile. the required headers are not provided by mingw, and are not available to the build bot, so don't bother.
fix v *= v.x and similar opcodes.
fteqcc: fixed support for áéíóú type chars in names. utf-8 files now properly supported (even with the utf-8 bom/identifier). utf-16 also supported.
fteqcc: fixed '#if 1 == 3 && 4' parsing.
fteqcc: -Werror acts on the warning, rather than as a separate error. Line numbers are thus more readable.
fteqcc: copyright message now includes compile date instead.
fteqccgui: the treeview control is now coloured depending on whether there were warnings/errors in the last compile.
fteqccgui: the output window is now focused and scrolls down as compilation progresses.
pr_dumpplatform command dumps out some pragmas to convert more serious warnings to errors. This is to avoid the infamous 'fteqcc sucks cos my code sucks' issue.
rewrote prespawn/modelist/soundlist code. server tracks progress now.
------------------------------------------------------------------------
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@4167 fc73d0e0-1445-4013-8a0c-d673dee63da5
2013-03-12 22:29:40 +00:00
news - > glowsize = MSG_ReadByte ( ) ;
news - > glowcolour = MSG_ReadByte ( ) ;
2012-02-12 05:18:31 +00:00
news - > glowmod [ 0 ] = MSG_ReadByte ( ) ;
news - > glowmod [ 1 ] = MSG_ReadByte ( ) ;
news - > glowmod [ 2 ] = MSG_ReadByte ( ) ;
}
if ( bits & UF_FATNESS )
news - > fatness = MSG_ReadByte ( ) ;
2012-07-05 19:42:36 +00:00
if ( bits & UF_MODELINDEX2 )
{
if ( bits & UF_16BIT )
news - > modelindex2 = MSG_ReadShort ( ) ;
else
news - > modelindex2 = MSG_ReadByte ( ) ;
}
if ( bits & UF_GRAVITYDIR )
{
news - > u . q1 . gravitydir [ 0 ] = MSG_ReadByte ( ) ;
news - > u . q1 . gravitydir [ 1 ] = MSG_ReadByte ( ) ;
}
2015-01-12 12:28:13 +00:00
if ( bits & UF_UNUSED2 )
{
2016-07-12 00:40:13 +00:00
Host_EndGame ( " UF_UNUSED2 bit \n " ) ;
2015-01-12 12:28:13 +00:00
}
if ( bits & UF_UNUSED1 )
{
2016-07-12 00:40:13 +00:00
Host_EndGame ( " UF_UNUSED1 bit \n " ) ;
2015-01-12 12:28:13 +00:00
}
2012-07-05 19:42:36 +00:00
}
void CLFTE_ParseBaseline ( entity_state_t * es , qboolean numberisimportant )
{
int entnum = 0 ;
if ( numberisimportant )
------------------------------------------------------------------------
r4169 | acceptthis | 2013-01-17 08:55:12 +0000 (Thu, 17 Jan 2013) | 31 lines
removed MAX_VISEDICTS limit.
PEXT2_REPLACEMENTDELTAS tweaked, now has 4 million entity limit. still not enabled by default.
TE_BEAM now maps to a separate TEQW_BEAM to avoid conflicts with QW.
added android multitouch emulation for windows/rawinput (in_simulatemultitouch).
split topcolor/bottomcolor from scoreboard, for dp's colormap|1024 feature.
now using utf-8 for windows consoles.
qcc warnings/errors now give clickable console links for quick+easy editing.
disabled menutint when the currently active item changes contrast or gamma (for OneManClan).
Added support for drawfont/drawfontscale.
tweaked the qcvm a little to reduce the number of pointers.
.doll file loading. still experimental and will likely crash. requires csqc active, even if its a dummy progs. this will be fixed in time. Still other things that need cleaning up.
windows: gl_font "?" shows the standard windows font-selection dialog, and can be used to select windows fonts. not all work. and you probably don't want to use windings.
fixed splitscreen support when playing mvds. added mini-scoreboards to splitscreen.
editor/debugger now shows asm if there's no linenumber info. also, pressing f1 for help shows the shortcuts.
Added support for .framegroups files for psk(psa) and iqm formats.
True support for ezquake's colour codes. Mutually exclusive with background colours.
path command output slightly more readable.
added support for digest_hex (MD4, SHA1, CRC16).
skingroups now colourmap correctly.
Fix terrain colour hints, and litdata from the wrong bsp.
fix ftp dual-homed issue. support epsv command, and enable ipv6 (eprt still not supported).
remove d3d11 compilation from the makefile. the required headers are not provided by mingw, and are not available to the build bot, so don't bother.
fix v *= v.x and similar opcodes.
fteqcc: fixed support for áéíóú type chars in names. utf-8 files now properly supported (even with the utf-8 bom/identifier). utf-16 also supported.
fteqcc: fixed '#if 1 == 3 && 4' parsing.
fteqcc: -Werror acts on the warning, rather than as a separate error. Line numbers are thus more readable.
fteqcc: copyright message now includes compile date instead.
fteqccgui: the treeview control is now coloured depending on whether there were warnings/errors in the last compile.
fteqccgui: the output window is now focused and scrolls down as compilation progresses.
pr_dumpplatform command dumps out some pragmas to convert more serious warnings to errors. This is to avoid the infamous 'fteqcc sucks cos my code sucks' issue.
rewrote prespawn/modelist/soundlist code. server tracks progress now.
------------------------------------------------------------------------
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@4167 fc73d0e0-1445-4013-8a0c-d673dee63da5
2013-03-12 22:29:40 +00:00
entnum = MSGCL_ReadEntity ( ) ;
2016-07-12 00:40:13 +00:00
CLFTE_ReadDelta ( entnum , es , & nullentitystate , & nullentitystate , NULL , NULL ) ;
2012-02-12 05:18:31 +00:00
}
2013-09-06 22:57:44 +00:00
void CL_PredictEntityMovement ( entity_state_t * estate , float age ) ;
2012-02-14 15:50:34 +00:00
/*
Note : strictly speaking , you don ' t need multiple frames , just two and flip between them .
FTE retains the full 64 frames because its interpolation will go multiple packets back in time to cover packet loss .
*/
2012-02-12 05:18:31 +00:00
void CLFTE_ParseEntities ( void )
{
int oldpacket , newpacket ;
packet_entities_t * oldp , * newp , nullp ;
2016-07-12 00:40:13 +00:00
entity_state_t * news , * olds ;
------------------------------------------------------------------------
r4169 | acceptthis | 2013-01-17 08:55:12 +0000 (Thu, 17 Jan 2013) | 31 lines
removed MAX_VISEDICTS limit.
PEXT2_REPLACEMENTDELTAS tweaked, now has 4 million entity limit. still not enabled by default.
TE_BEAM now maps to a separate TEQW_BEAM to avoid conflicts with QW.
added android multitouch emulation for windows/rawinput (in_simulatemultitouch).
split topcolor/bottomcolor from scoreboard, for dp's colormap|1024 feature.
now using utf-8 for windows consoles.
qcc warnings/errors now give clickable console links for quick+easy editing.
disabled menutint when the currently active item changes contrast or gamma (for OneManClan).
Added support for drawfont/drawfontscale.
tweaked the qcvm a little to reduce the number of pointers.
.doll file loading. still experimental and will likely crash. requires csqc active, even if its a dummy progs. this will be fixed in time. Still other things that need cleaning up.
windows: gl_font "?" shows the standard windows font-selection dialog, and can be used to select windows fonts. not all work. and you probably don't want to use windings.
fixed splitscreen support when playing mvds. added mini-scoreboards to splitscreen.
editor/debugger now shows asm if there's no linenumber info. also, pressing f1 for help shows the shortcuts.
Added support for .framegroups files for psk(psa) and iqm formats.
True support for ezquake's colour codes. Mutually exclusive with background colours.
path command output slightly more readable.
added support for digest_hex (MD4, SHA1, CRC16).
skingroups now colourmap correctly.
Fix terrain colour hints, and litdata from the wrong bsp.
fix ftp dual-homed issue. support epsv command, and enable ipv6 (eprt still not supported).
remove d3d11 compilation from the makefile. the required headers are not provided by mingw, and are not available to the build bot, so don't bother.
fix v *= v.x and similar opcodes.
fteqcc: fixed support for áéíóú type chars in names. utf-8 files now properly supported (even with the utf-8 bom/identifier). utf-16 also supported.
fteqcc: fixed '#if 1 == 3 && 4' parsing.
fteqcc: -Werror acts on the warning, rather than as a separate error. Line numbers are thus more readable.
fteqcc: copyright message now includes compile date instead.
fteqccgui: the treeview control is now coloured depending on whether there were warnings/errors in the last compile.
fteqccgui: the output window is now focused and scrolls down as compilation progresses.
pr_dumpplatform command dumps out some pragmas to convert more serious warnings to errors. This is to avoid the infamous 'fteqcc sucks cos my code sucks' issue.
rewrote prespawn/modelist/soundlist code. server tracks progress now.
------------------------------------------------------------------------
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@4167 fc73d0e0-1445-4013-8a0c-d673dee63da5
2013-03-12 22:29:40 +00:00
unsigned int newnum , oldnum ;
2012-02-12 05:18:31 +00:00
int oldindex ;
qboolean isvalid = false ;
------------------------------------------------------------------------
r4169 | acceptthis | 2013-01-17 08:55:12 +0000 (Thu, 17 Jan 2013) | 31 lines
removed MAX_VISEDICTS limit.
PEXT2_REPLACEMENTDELTAS tweaked, now has 4 million entity limit. still not enabled by default.
TE_BEAM now maps to a separate TEQW_BEAM to avoid conflicts with QW.
added android multitouch emulation for windows/rawinput (in_simulatemultitouch).
split topcolor/bottomcolor from scoreboard, for dp's colormap|1024 feature.
now using utf-8 for windows consoles.
qcc warnings/errors now give clickable console links for quick+easy editing.
disabled menutint when the currently active item changes contrast or gamma (for OneManClan).
Added support for drawfont/drawfontscale.
tweaked the qcvm a little to reduce the number of pointers.
.doll file loading. still experimental and will likely crash. requires csqc active, even if its a dummy progs. this will be fixed in time. Still other things that need cleaning up.
windows: gl_font "?" shows the standard windows font-selection dialog, and can be used to select windows fonts. not all work. and you probably don't want to use windings.
fixed splitscreen support when playing mvds. added mini-scoreboards to splitscreen.
editor/debugger now shows asm if there's no linenumber info. also, pressing f1 for help shows the shortcuts.
Added support for .framegroups files for psk(psa) and iqm formats.
True support for ezquake's colour codes. Mutually exclusive with background colours.
path command output slightly more readable.
added support for digest_hex (MD4, SHA1, CRC16).
skingroups now colourmap correctly.
Fix terrain colour hints, and litdata from the wrong bsp.
fix ftp dual-homed issue. support epsv command, and enable ipv6 (eprt still not supported).
remove d3d11 compilation from the makefile. the required headers are not provided by mingw, and are not available to the build bot, so don't bother.
fix v *= v.x and similar opcodes.
fteqcc: fixed support for áéíóú type chars in names. utf-8 files now properly supported (even with the utf-8 bom/identifier). utf-16 also supported.
fteqcc: fixed '#if 1 == 3 && 4' parsing.
fteqcc: -Werror acts on the warning, rather than as a separate error. Line numbers are thus more readable.
fteqcc: copyright message now includes compile date instead.
fteqccgui: the treeview control is now coloured depending on whether there were warnings/errors in the last compile.
fteqccgui: the output window is now focused and scrolls down as compilation progresses.
pr_dumpplatform command dumps out some pragmas to convert more serious warnings to errors. This is to avoid the infamous 'fteqcc sucks cos my code sucks' issue.
rewrote prespawn/modelist/soundlist code. server tracks progress now.
------------------------------------------------------------------------
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@4167 fc73d0e0-1445-4013-8a0c-d673dee63da5
2013-03-12 22:29:40 +00:00
qboolean removeflag ;
2013-03-12 22:53:23 +00:00
int inputframe = cls . netchan . incoming_sequence ;
2017-09-20 11:27:13 +00:00
# if defined(QUAKESTATS) || defined(NQPROT)
2017-02-21 21:18:48 +00:00
int i ;
2017-09-20 11:27:13 +00:00
# endif
2012-02-12 05:18:31 +00:00
// int i;
// for (i = cl.validsequence+1; i < cls.netchan.incoming_sequence; i++)
// {
// Con_Printf("CL: Dropped %i\n", i);
// }
2013-03-12 22:44:00 +00:00
if ( cls . demoplayback = = DPB_MVD | | cls . demoplayback = = DPB_EZTV )
{
cls . netchan . incoming_sequence + + ;
cls . netchan . incoming_acknowledged + + ;
}
2013-03-12 22:35:33 +00:00
# ifdef NQPROT
2013-03-12 22:44:00 +00:00
else if ( cls . protocol = = CP_NETQUAKE )
2013-03-12 22:35:33 +00:00
{
2013-09-06 22:57:44 +00:00
cls . netchan . incoming_sequence + + ;
2013-03-12 22:35:33 +00:00
cl . last_servermessage = realtime ;
2013-03-12 22:53:23 +00:00
if ( cls . fteprotocolextensions2 & PEXT2_PREDINFO )
2016-10-22 07:06:51 +00:00
{
inputframe = ( unsigned short ) MSG_ReadShort ( ) ;
inputframe = ( cl . movesequence & 0xffff0000 ) | inputframe ;
if ( inputframe > cl . movesequence )
inputframe - = 0x00010000 ; //err, if its in the future then cl.movesequence must have wrapped.
}
2013-08-21 07:14:39 +00:00
else
inputframe = cl . movesequence ;
2013-03-12 22:35:33 +00:00
if ( cl . numackframes = = sizeof ( cl . ackframes ) / sizeof ( cl . ackframes [ 0 ] ) )
cl . numackframes - - ;
2013-03-12 22:44:00 +00:00
if ( ! cl . validsequence )
cl . ackframes [ cl . numackframes + + ] = - 1 ;
else
cl . ackframes [ cl . numackframes + + ] = cls . netchan . incoming_sequence ;
2013-03-12 22:35:33 +00:00
2013-07-26 17:19:06 +00:00
{
extern vec3_t demoangles ;
int fr = cls . netchan . incoming_sequence & UPDATE_MASK ;
for ( i = 0 ; i < MAX_SPLITS ; i + + )
cl . inframes [ fr & UPDATE_MASK ] . packet_entities . fixangles [ i ] = false ;
if ( cls . demoplayback )
{
cl . inframes [ fr & UPDATE_MASK ] . packet_entities . fixangles [ 0 ] = 2 ;
VectorCopy ( demoangles , cl . inframes [ fr & UPDATE_MASK ] . packet_entities . fixedangles [ 0 ] ) ;
}
}
2013-03-12 22:44:00 +00:00
// if (cl.validsequence != cls.netchan.incoming_sequence-1)
// Con_Printf("CLIENT: Dropped a frame\n");
2013-03-12 22:35:33 +00:00
}
# endif
2012-02-12 05:18:31 +00:00
newpacket = cls . netchan . incoming_sequence & UPDATE_MASK ;
oldpacket = cl . validsequence & UPDATE_MASK ;
2013-03-12 22:53:23 +00:00
newp = & cl . inframes [ newpacket ] . packet_entities ;
oldp = & cl . inframes [ oldpacket ] . packet_entities ;
cl . inframes [ newpacket ] . invalid = true ;
2013-09-06 22:57:44 +00:00
cl . inframes [ newpacket ] . receivedtime = realtime ;
cl . inframes [ newpacket ] . frameid = cls . netchan . incoming_sequence ;
2012-02-12 05:18:31 +00:00
2017-02-22 00:16:43 +00:00
# ifdef QUAKESTATS
2017-02-21 21:18:48 +00:00
for ( i = 0 ; i < cl . splitclients ; i + + )
{
cl . inframes [ newpacket & UPDATE_MASK ] . packet_entities . punchangle [ i ] [ 0 ] = cl . playerview [ i ] . statsf [ STAT_PUNCHANGLE_X ] ;
cl . inframes [ newpacket & UPDATE_MASK ] . packet_entities . punchangle [ i ] [ 1 ] = cl . playerview [ i ] . statsf [ STAT_PUNCHANGLE_Y ] ;
cl . inframes [ newpacket & UPDATE_MASK ] . packet_entities . punchangle [ i ] [ 2 ] = cl . playerview [ i ] . statsf [ STAT_PUNCHANGLE_Z ] ;
cl . inframes [ newpacket & UPDATE_MASK ] . packet_entities . punchorigin [ i ] [ 0 ] = cl . playerview [ i ] . statsf [ STAT_PUNCHVECTOR_X ] ;
cl . inframes [ newpacket & UPDATE_MASK ] . packet_entities . punchorigin [ i ] [ 1 ] = cl . playerview [ i ] . statsf [ STAT_PUNCHVECTOR_Y ] ;
cl . inframes [ newpacket & UPDATE_MASK ] . packet_entities . punchorigin [ i ] [ 2 ] = cl . playerview [ i ] . statsf [ STAT_PUNCHVECTOR_Z ] ;
}
2017-02-22 00:16:43 +00:00
# endif
2017-02-21 21:18:48 +00:00
2012-02-12 05:18:31 +00:00
2013-03-12 22:35:33 +00:00
if ( ! cl . validsequence | | cls . netchan . incoming_sequence - cl . validsequence > = UPDATE_BACKUP - 1 | | oldp = = newp )
2012-02-12 05:18:31 +00:00
{
2013-03-12 22:35:33 +00:00
//yes, this results in a load of invalid packets for a while.
//server is meant to notice and send a reset packet, which causes it to become valid again
2012-02-12 05:18:31 +00:00
oldp = & nullp ;
oldp - > num_entities = 0 ;
oldp - > max_entities = 0 ;
}
else
isvalid = true ;
newp - > servertime = MSG_ReadFloat ( ) ;
2014-04-13 04:23:13 +00:00
if ( cl . gametime ! = newp - > servertime )
{
cl . oldgametime = cl . gametime ;
cl . oldgametimemark = cl . gametimemark ;
cl . gametime = newp - > servertime ;
cl . gametimemark = realtime ;
}
2012-02-12 05:18:31 +00:00
/*clear all entities*/
newp - > num_entities = 0 ;
2016-07-12 00:40:13 +00:00
newp - > bonedatacur = 0 ;
2012-02-12 05:18:31 +00:00
oldindex = 0 ;
while ( 1 )
{
------------------------------------------------------------------------
r4169 | acceptthis | 2013-01-17 08:55:12 +0000 (Thu, 17 Jan 2013) | 31 lines
removed MAX_VISEDICTS limit.
PEXT2_REPLACEMENTDELTAS tweaked, now has 4 million entity limit. still not enabled by default.
TE_BEAM now maps to a separate TEQW_BEAM to avoid conflicts with QW.
added android multitouch emulation for windows/rawinput (in_simulatemultitouch).
split topcolor/bottomcolor from scoreboard, for dp's colormap|1024 feature.
now using utf-8 for windows consoles.
qcc warnings/errors now give clickable console links for quick+easy editing.
disabled menutint when the currently active item changes contrast or gamma (for OneManClan).
Added support for drawfont/drawfontscale.
tweaked the qcvm a little to reduce the number of pointers.
.doll file loading. still experimental and will likely crash. requires csqc active, even if its a dummy progs. this will be fixed in time. Still other things that need cleaning up.
windows: gl_font "?" shows the standard windows font-selection dialog, and can be used to select windows fonts. not all work. and you probably don't want to use windings.
fixed splitscreen support when playing mvds. added mini-scoreboards to splitscreen.
editor/debugger now shows asm if there's no linenumber info. also, pressing f1 for help shows the shortcuts.
Added support for .framegroups files for psk(psa) and iqm formats.
True support for ezquake's colour codes. Mutually exclusive with background colours.
path command output slightly more readable.
added support for digest_hex (MD4, SHA1, CRC16).
skingroups now colourmap correctly.
Fix terrain colour hints, and litdata from the wrong bsp.
fix ftp dual-homed issue. support epsv command, and enable ipv6 (eprt still not supported).
remove d3d11 compilation from the makefile. the required headers are not provided by mingw, and are not available to the build bot, so don't bother.
fix v *= v.x and similar opcodes.
fteqcc: fixed support for áéíóú type chars in names. utf-8 files now properly supported (even with the utf-8 bom/identifier). utf-16 also supported.
fteqcc: fixed '#if 1 == 3 && 4' parsing.
fteqcc: -Werror acts on the warning, rather than as a separate error. Line numbers are thus more readable.
fteqcc: copyright message now includes compile date instead.
fteqccgui: the treeview control is now coloured depending on whether there were warnings/errors in the last compile.
fteqccgui: the output window is now focused and scrolls down as compilation progresses.
pr_dumpplatform command dumps out some pragmas to convert more serious warnings to errors. This is to avoid the infamous 'fteqcc sucks cos my code sucks' issue.
rewrote prespawn/modelist/soundlist code. server tracks progress now.
------------------------------------------------------------------------
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@4167 fc73d0e0-1445-4013-8a0c-d673dee63da5
2013-03-12 22:29:40 +00:00
//high bit means remove, second high bit means 22bit index
newnum = ( unsigned short ) ( short ) MSG_ReadShort ( ) ;
removeflag = ! ! ( newnum & 0x8000 ) ;
if ( newnum & 0x4000 )
newnum = ( newnum & 0x3fff ) | ( MSG_ReadByte ( ) < < 14 ) ;
else
newnum & = ~ 0x8000 ;
if ( ( ! newnum & & ! removeflag ) | | msg_badread )
2012-02-12 05:18:31 +00:00
{
/*reached the end, don't forget old entities*/
while ( oldindex < oldp - > num_entities )
{
if ( newp - > num_entities > = newp - > max_entities )
{
newp - > max_entities = newp - > num_entities + 1 ;
newp - > entities = BZ_Realloc ( newp - > entities , sizeof ( entity_state_t ) * newp - > max_entities ) ;
}
2016-07-12 00:40:13 +00:00
//copy it over
news = & newp - > entities [ newp - > num_entities + + ] ;
olds = & oldp - > entities [ oldindex + + ] ;
* news = * olds ;
if ( news - > bonecount )
{ //still has bone data somehow.
short * bonedata = AllocateBoneSpace ( newp , news - > bonecount , & news - > boneoffset ) ;
memcpy ( bonedata , oldp - > bonedata + olds - > boneoffset , sizeof ( short ) * 7 * news - > bonecount ) ;
}
2012-02-12 05:18:31 +00:00
}
break ;
}
------------------------------------------------------------------------
r4169 | acceptthis | 2013-01-17 08:55:12 +0000 (Thu, 17 Jan 2013) | 31 lines
removed MAX_VISEDICTS limit.
PEXT2_REPLACEMENTDELTAS tweaked, now has 4 million entity limit. still not enabled by default.
TE_BEAM now maps to a separate TEQW_BEAM to avoid conflicts with QW.
added android multitouch emulation for windows/rawinput (in_simulatemultitouch).
split topcolor/bottomcolor from scoreboard, for dp's colormap|1024 feature.
now using utf-8 for windows consoles.
qcc warnings/errors now give clickable console links for quick+easy editing.
disabled menutint when the currently active item changes contrast or gamma (for OneManClan).
Added support for drawfont/drawfontscale.
tweaked the qcvm a little to reduce the number of pointers.
.doll file loading. still experimental and will likely crash. requires csqc active, even if its a dummy progs. this will be fixed in time. Still other things that need cleaning up.
windows: gl_font "?" shows the standard windows font-selection dialog, and can be used to select windows fonts. not all work. and you probably don't want to use windings.
fixed splitscreen support when playing mvds. added mini-scoreboards to splitscreen.
editor/debugger now shows asm if there's no linenumber info. also, pressing f1 for help shows the shortcuts.
Added support for .framegroups files for psk(psa) and iqm formats.
True support for ezquake's colour codes. Mutually exclusive with background colours.
path command output slightly more readable.
added support for digest_hex (MD4, SHA1, CRC16).
skingroups now colourmap correctly.
Fix terrain colour hints, and litdata from the wrong bsp.
fix ftp dual-homed issue. support epsv command, and enable ipv6 (eprt still not supported).
remove d3d11 compilation from the makefile. the required headers are not provided by mingw, and are not available to the build bot, so don't bother.
fix v *= v.x and similar opcodes.
fteqcc: fixed support for áéíóú type chars in names. utf-8 files now properly supported (even with the utf-8 bom/identifier). utf-16 also supported.
fteqcc: fixed '#if 1 == 3 && 4' parsing.
fteqcc: -Werror acts on the warning, rather than as a separate error. Line numbers are thus more readable.
fteqcc: copyright message now includes compile date instead.
fteqccgui: the treeview control is now coloured depending on whether there were warnings/errors in the last compile.
fteqccgui: the output window is now focused and scrolls down as compilation progresses.
pr_dumpplatform command dumps out some pragmas to convert more serious warnings to errors. This is to avoid the infamous 'fteqcc sucks cos my code sucks' issue.
rewrote prespawn/modelist/soundlist code. server tracks progress now.
------------------------------------------------------------------------
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@4167 fc73d0e0-1445-4013-8a0c-d673dee63da5
2013-03-12 22:29:40 +00:00
oldnum = ( oldindex > = oldp - > num_entities ) ? 0xffffffff : oldp - > entities [ oldindex ] . number ;
2012-02-12 05:18:31 +00:00
/*if we skipped some, then they were unchanged*/
------------------------------------------------------------------------
r4169 | acceptthis | 2013-01-17 08:55:12 +0000 (Thu, 17 Jan 2013) | 31 lines
removed MAX_VISEDICTS limit.
PEXT2_REPLACEMENTDELTAS tweaked, now has 4 million entity limit. still not enabled by default.
TE_BEAM now maps to a separate TEQW_BEAM to avoid conflicts with QW.
added android multitouch emulation for windows/rawinput (in_simulatemultitouch).
split topcolor/bottomcolor from scoreboard, for dp's colormap|1024 feature.
now using utf-8 for windows consoles.
qcc warnings/errors now give clickable console links for quick+easy editing.
disabled menutint when the currently active item changes contrast or gamma (for OneManClan).
Added support for drawfont/drawfontscale.
tweaked the qcvm a little to reduce the number of pointers.
.doll file loading. still experimental and will likely crash. requires csqc active, even if its a dummy progs. this will be fixed in time. Still other things that need cleaning up.
windows: gl_font "?" shows the standard windows font-selection dialog, and can be used to select windows fonts. not all work. and you probably don't want to use windings.
fixed splitscreen support when playing mvds. added mini-scoreboards to splitscreen.
editor/debugger now shows asm if there's no linenumber info. also, pressing f1 for help shows the shortcuts.
Added support for .framegroups files for psk(psa) and iqm formats.
True support for ezquake's colour codes. Mutually exclusive with background colours.
path command output slightly more readable.
added support for digest_hex (MD4, SHA1, CRC16).
skingroups now colourmap correctly.
Fix terrain colour hints, and litdata from the wrong bsp.
fix ftp dual-homed issue. support epsv command, and enable ipv6 (eprt still not supported).
remove d3d11 compilation from the makefile. the required headers are not provided by mingw, and are not available to the build bot, so don't bother.
fix v *= v.x and similar opcodes.
fteqcc: fixed support for áéíóú type chars in names. utf-8 files now properly supported (even with the utf-8 bom/identifier). utf-16 also supported.
fteqcc: fixed '#if 1 == 3 && 4' parsing.
fteqcc: -Werror acts on the warning, rather than as a separate error. Line numbers are thus more readable.
fteqcc: copyright message now includes compile date instead.
fteqccgui: the treeview control is now coloured depending on whether there were warnings/errors in the last compile.
fteqccgui: the output window is now focused and scrolls down as compilation progresses.
pr_dumpplatform command dumps out some pragmas to convert more serious warnings to errors. This is to avoid the infamous 'fteqcc sucks cos my code sucks' issue.
rewrote prespawn/modelist/soundlist code. server tracks progress now.
------------------------------------------------------------------------
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@4167 fc73d0e0-1445-4013-8a0c-d673dee63da5
2013-03-12 22:29:40 +00:00
while ( newnum > oldnum )
2012-02-12 05:18:31 +00:00
{
if ( newp - > num_entities > = newp - > max_entities )
{
newp - > max_entities = newp - > num_entities + 1 ;
newp - > entities = BZ_Realloc ( newp - > entities , sizeof ( entity_state_t ) * newp - > max_entities ) ;
}
2016-07-12 00:40:13 +00:00
//copy it over
news = & newp - > entities [ newp - > num_entities + + ] ;
olds = & oldp - > entities [ oldindex + + ] ;
* news = * olds ;
if ( news - > bonecount )
{ //still has bone data somehow.
short * bonedata = AllocateBoneSpace ( newp , news - > bonecount , & news - > boneoffset ) ;
memcpy ( bonedata , oldp - > bonedata + olds - > boneoffset , sizeof ( short ) * 7 * news - > bonecount ) ;
}
2012-02-12 05:18:31 +00:00
------------------------------------------------------------------------
r4169 | acceptthis | 2013-01-17 08:55:12 +0000 (Thu, 17 Jan 2013) | 31 lines
removed MAX_VISEDICTS limit.
PEXT2_REPLACEMENTDELTAS tweaked, now has 4 million entity limit. still not enabled by default.
TE_BEAM now maps to a separate TEQW_BEAM to avoid conflicts with QW.
added android multitouch emulation for windows/rawinput (in_simulatemultitouch).
split topcolor/bottomcolor from scoreboard, for dp's colormap|1024 feature.
now using utf-8 for windows consoles.
qcc warnings/errors now give clickable console links for quick+easy editing.
disabled menutint when the currently active item changes contrast or gamma (for OneManClan).
Added support for drawfont/drawfontscale.
tweaked the qcvm a little to reduce the number of pointers.
.doll file loading. still experimental and will likely crash. requires csqc active, even if its a dummy progs. this will be fixed in time. Still other things that need cleaning up.
windows: gl_font "?" shows the standard windows font-selection dialog, and can be used to select windows fonts. not all work. and you probably don't want to use windings.
fixed splitscreen support when playing mvds. added mini-scoreboards to splitscreen.
editor/debugger now shows asm if there's no linenumber info. also, pressing f1 for help shows the shortcuts.
Added support for .framegroups files for psk(psa) and iqm formats.
True support for ezquake's colour codes. Mutually exclusive with background colours.
path command output slightly more readable.
added support for digest_hex (MD4, SHA1, CRC16).
skingroups now colourmap correctly.
Fix terrain colour hints, and litdata from the wrong bsp.
fix ftp dual-homed issue. support epsv command, and enable ipv6 (eprt still not supported).
remove d3d11 compilation from the makefile. the required headers are not provided by mingw, and are not available to the build bot, so don't bother.
fix v *= v.x and similar opcodes.
fteqcc: fixed support for áéíóú type chars in names. utf-8 files now properly supported (even with the utf-8 bom/identifier). utf-16 also supported.
fteqcc: fixed '#if 1 == 3 && 4' parsing.
fteqcc: -Werror acts on the warning, rather than as a separate error. Line numbers are thus more readable.
fteqcc: copyright message now includes compile date instead.
fteqccgui: the treeview control is now coloured depending on whether there were warnings/errors in the last compile.
fteqccgui: the output window is now focused and scrolls down as compilation progresses.
pr_dumpplatform command dumps out some pragmas to convert more serious warnings to errors. This is to avoid the infamous 'fteqcc sucks cos my code sucks' issue.
rewrote prespawn/modelist/soundlist code. server tracks progress now.
------------------------------------------------------------------------
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@4167 fc73d0e0-1445-4013-8a0c-d673dee63da5
2013-03-12 22:29:40 +00:00
oldnum = ( oldindex > = oldp - > num_entities ) ? 0xffffffff : oldp - > entities [ oldindex ] . number ;
2012-02-12 05:18:31 +00:00
}
------------------------------------------------------------------------
r4169 | acceptthis | 2013-01-17 08:55:12 +0000 (Thu, 17 Jan 2013) | 31 lines
removed MAX_VISEDICTS limit.
PEXT2_REPLACEMENTDELTAS tweaked, now has 4 million entity limit. still not enabled by default.
TE_BEAM now maps to a separate TEQW_BEAM to avoid conflicts with QW.
added android multitouch emulation for windows/rawinput (in_simulatemultitouch).
split topcolor/bottomcolor from scoreboard, for dp's colormap|1024 feature.
now using utf-8 for windows consoles.
qcc warnings/errors now give clickable console links for quick+easy editing.
disabled menutint when the currently active item changes contrast or gamma (for OneManClan).
Added support for drawfont/drawfontscale.
tweaked the qcvm a little to reduce the number of pointers.
.doll file loading. still experimental and will likely crash. requires csqc active, even if its a dummy progs. this will be fixed in time. Still other things that need cleaning up.
windows: gl_font "?" shows the standard windows font-selection dialog, and can be used to select windows fonts. not all work. and you probably don't want to use windings.
fixed splitscreen support when playing mvds. added mini-scoreboards to splitscreen.
editor/debugger now shows asm if there's no linenumber info. also, pressing f1 for help shows the shortcuts.
Added support for .framegroups files for psk(psa) and iqm formats.
True support for ezquake's colour codes. Mutually exclusive with background colours.
path command output slightly more readable.
added support for digest_hex (MD4, SHA1, CRC16).
skingroups now colourmap correctly.
Fix terrain colour hints, and litdata from the wrong bsp.
fix ftp dual-homed issue. support epsv command, and enable ipv6 (eprt still not supported).
remove d3d11 compilation from the makefile. the required headers are not provided by mingw, and are not available to the build bot, so don't bother.
fix v *= v.x and similar opcodes.
fteqcc: fixed support for áéíóú type chars in names. utf-8 files now properly supported (even with the utf-8 bom/identifier). utf-16 also supported.
fteqcc: fixed '#if 1 == 3 && 4' parsing.
fteqcc: -Werror acts on the warning, rather than as a separate error. Line numbers are thus more readable.
fteqcc: copyright message now includes compile date instead.
fteqccgui: the treeview control is now coloured depending on whether there were warnings/errors in the last compile.
fteqccgui: the output window is now focused and scrolls down as compilation progresses.
pr_dumpplatform command dumps out some pragmas to convert more serious warnings to errors. This is to avoid the infamous 'fteqcc sucks cos my code sucks' issue.
rewrote prespawn/modelist/soundlist code. server tracks progress now.
------------------------------------------------------------------------
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@4167 fc73d0e0-1445-4013-8a0c-d673dee63da5
2013-03-12 22:29:40 +00:00
if ( removeflag )
2012-02-12 05:18:31 +00:00
{
if ( cl_shownet . ival > = 3 )
2013-03-12 22:35:33 +00:00
Con_Printf ( " %3i: Remove %i @ %i \n " , msg_readcount , newnum , cls . netchan . incoming_sequence ) ;
------------------------------------------------------------------------
r4169 | acceptthis | 2013-01-17 08:55:12 +0000 (Thu, 17 Jan 2013) | 31 lines
removed MAX_VISEDICTS limit.
PEXT2_REPLACEMENTDELTAS tweaked, now has 4 million entity limit. still not enabled by default.
TE_BEAM now maps to a separate TEQW_BEAM to avoid conflicts with QW.
added android multitouch emulation for windows/rawinput (in_simulatemultitouch).
split topcolor/bottomcolor from scoreboard, for dp's colormap|1024 feature.
now using utf-8 for windows consoles.
qcc warnings/errors now give clickable console links for quick+easy editing.
disabled menutint when the currently active item changes contrast or gamma (for OneManClan).
Added support for drawfont/drawfontscale.
tweaked the qcvm a little to reduce the number of pointers.
.doll file loading. still experimental and will likely crash. requires csqc active, even if its a dummy progs. this will be fixed in time. Still other things that need cleaning up.
windows: gl_font "?" shows the standard windows font-selection dialog, and can be used to select windows fonts. not all work. and you probably don't want to use windings.
fixed splitscreen support when playing mvds. added mini-scoreboards to splitscreen.
editor/debugger now shows asm if there's no linenumber info. also, pressing f1 for help shows the shortcuts.
Added support for .framegroups files for psk(psa) and iqm formats.
True support for ezquake's colour codes. Mutually exclusive with background colours.
path command output slightly more readable.
added support for digest_hex (MD4, SHA1, CRC16).
skingroups now colourmap correctly.
Fix terrain colour hints, and litdata from the wrong bsp.
fix ftp dual-homed issue. support epsv command, and enable ipv6 (eprt still not supported).
remove d3d11 compilation from the makefile. the required headers are not provided by mingw, and are not available to the build bot, so don't bother.
fix v *= v.x and similar opcodes.
fteqcc: fixed support for áéíóú type chars in names. utf-8 files now properly supported (even with the utf-8 bom/identifier). utf-16 also supported.
fteqcc: fixed '#if 1 == 3 && 4' parsing.
fteqcc: -Werror acts on the warning, rather than as a separate error. Line numbers are thus more readable.
fteqcc: copyright message now includes compile date instead.
fteqccgui: the treeview control is now coloured depending on whether there were warnings/errors in the last compile.
fteqccgui: the output window is now focused and scrolls down as compilation progresses.
pr_dumpplatform command dumps out some pragmas to convert more serious warnings to errors. This is to avoid the infamous 'fteqcc sucks cos my code sucks' issue.
rewrote prespawn/modelist/soundlist code. server tracks progress now.
------------------------------------------------------------------------
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@4167 fc73d0e0-1445-4013-8a0c-d673dee63da5
2013-03-12 22:29:40 +00:00
if ( ! newnum )
{
/*removal of world - means forget all entities*/
if ( cl_shownet . ival > = 3 )
2013-03-12 22:35:33 +00:00
Con_Printf ( " %3i: Reset all \n " , msg_readcount ) ;
------------------------------------------------------------------------
r4169 | acceptthis | 2013-01-17 08:55:12 +0000 (Thu, 17 Jan 2013) | 31 lines
removed MAX_VISEDICTS limit.
PEXT2_REPLACEMENTDELTAS tweaked, now has 4 million entity limit. still not enabled by default.
TE_BEAM now maps to a separate TEQW_BEAM to avoid conflicts with QW.
added android multitouch emulation for windows/rawinput (in_simulatemultitouch).
split topcolor/bottomcolor from scoreboard, for dp's colormap|1024 feature.
now using utf-8 for windows consoles.
qcc warnings/errors now give clickable console links for quick+easy editing.
disabled menutint when the currently active item changes contrast or gamma (for OneManClan).
Added support for drawfont/drawfontscale.
tweaked the qcvm a little to reduce the number of pointers.
.doll file loading. still experimental and will likely crash. requires csqc active, even if its a dummy progs. this will be fixed in time. Still other things that need cleaning up.
windows: gl_font "?" shows the standard windows font-selection dialog, and can be used to select windows fonts. not all work. and you probably don't want to use windings.
fixed splitscreen support when playing mvds. added mini-scoreboards to splitscreen.
editor/debugger now shows asm if there's no linenumber info. also, pressing f1 for help shows the shortcuts.
Added support for .framegroups files for psk(psa) and iqm formats.
True support for ezquake's colour codes. Mutually exclusive with background colours.
path command output slightly more readable.
added support for digest_hex (MD4, SHA1, CRC16).
skingroups now colourmap correctly.
Fix terrain colour hints, and litdata from the wrong bsp.
fix ftp dual-homed issue. support epsv command, and enable ipv6 (eprt still not supported).
remove d3d11 compilation from the makefile. the required headers are not provided by mingw, and are not available to the build bot, so don't bother.
fix v *= v.x and similar opcodes.
fteqcc: fixed support for áéíóú type chars in names. utf-8 files now properly supported (even with the utf-8 bom/identifier). utf-16 also supported.
fteqcc: fixed '#if 1 == 3 && 4' parsing.
fteqcc: -Werror acts on the warning, rather than as a separate error. Line numbers are thus more readable.
fteqcc: copyright message now includes compile date instead.
fteqccgui: the treeview control is now coloured depending on whether there were warnings/errors in the last compile.
fteqccgui: the output window is now focused and scrolls down as compilation progresses.
pr_dumpplatform command dumps out some pragmas to convert more serious warnings to errors. This is to avoid the infamous 'fteqcc sucks cos my code sucks' issue.
rewrote prespawn/modelist/soundlist code. server tracks progress now.
------------------------------------------------------------------------
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@4167 fc73d0e0-1445-4013-8a0c-d673dee63da5
2013-03-12 22:29:40 +00:00
newp - > num_entities = 0 ;
2013-03-12 22:35:33 +00:00
oldp = & nullp ;
oldp - > num_entities = 0 ;
oldp - > max_entities = 0 ;
------------------------------------------------------------------------
r4169 | acceptthis | 2013-01-17 08:55:12 +0000 (Thu, 17 Jan 2013) | 31 lines
removed MAX_VISEDICTS limit.
PEXT2_REPLACEMENTDELTAS tweaked, now has 4 million entity limit. still not enabled by default.
TE_BEAM now maps to a separate TEQW_BEAM to avoid conflicts with QW.
added android multitouch emulation for windows/rawinput (in_simulatemultitouch).
split topcolor/bottomcolor from scoreboard, for dp's colormap|1024 feature.
now using utf-8 for windows consoles.
qcc warnings/errors now give clickable console links for quick+easy editing.
disabled menutint when the currently active item changes contrast or gamma (for OneManClan).
Added support for drawfont/drawfontscale.
tweaked the qcvm a little to reduce the number of pointers.
.doll file loading. still experimental and will likely crash. requires csqc active, even if its a dummy progs. this will be fixed in time. Still other things that need cleaning up.
windows: gl_font "?" shows the standard windows font-selection dialog, and can be used to select windows fonts. not all work. and you probably don't want to use windings.
fixed splitscreen support when playing mvds. added mini-scoreboards to splitscreen.
editor/debugger now shows asm if there's no linenumber info. also, pressing f1 for help shows the shortcuts.
Added support for .framegroups files for psk(psa) and iqm formats.
True support for ezquake's colour codes. Mutually exclusive with background colours.
path command output slightly more readable.
added support for digest_hex (MD4, SHA1, CRC16).
skingroups now colourmap correctly.
Fix terrain colour hints, and litdata from the wrong bsp.
fix ftp dual-homed issue. support epsv command, and enable ipv6 (eprt still not supported).
remove d3d11 compilation from the makefile. the required headers are not provided by mingw, and are not available to the build bot, so don't bother.
fix v *= v.x and similar opcodes.
fteqcc: fixed support for áéíóú type chars in names. utf-8 files now properly supported (even with the utf-8 bom/identifier). utf-16 also supported.
fteqcc: fixed '#if 1 == 3 && 4' parsing.
fteqcc: -Werror acts on the warning, rather than as a separate error. Line numbers are thus more readable.
fteqcc: copyright message now includes compile date instead.
fteqccgui: the treeview control is now coloured depending on whether there were warnings/errors in the last compile.
fteqccgui: the output window is now focused and scrolls down as compilation progresses.
pr_dumpplatform command dumps out some pragmas to convert more serious warnings to errors. This is to avoid the infamous 'fteqcc sucks cos my code sucks' issue.
rewrote prespawn/modelist/soundlist code. server tracks progress now.
------------------------------------------------------------------------
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@4167 fc73d0e0-1445-4013-8a0c-d673dee63da5
2013-03-12 22:29:40 +00:00
isvalid = true ;
2016-07-12 00:40:13 +00:00
cls . demohadkeyframe = true ; //we can reactivate deltas when recording now.
------------------------------------------------------------------------
r4169 | acceptthis | 2013-01-17 08:55:12 +0000 (Thu, 17 Jan 2013) | 31 lines
removed MAX_VISEDICTS limit.
PEXT2_REPLACEMENTDELTAS tweaked, now has 4 million entity limit. still not enabled by default.
TE_BEAM now maps to a separate TEQW_BEAM to avoid conflicts with QW.
added android multitouch emulation for windows/rawinput (in_simulatemultitouch).
split topcolor/bottomcolor from scoreboard, for dp's colormap|1024 feature.
now using utf-8 for windows consoles.
qcc warnings/errors now give clickable console links for quick+easy editing.
disabled menutint when the currently active item changes contrast or gamma (for OneManClan).
Added support for drawfont/drawfontscale.
tweaked the qcvm a little to reduce the number of pointers.
.doll file loading. still experimental and will likely crash. requires csqc active, even if its a dummy progs. this will be fixed in time. Still other things that need cleaning up.
windows: gl_font "?" shows the standard windows font-selection dialog, and can be used to select windows fonts. not all work. and you probably don't want to use windings.
fixed splitscreen support when playing mvds. added mini-scoreboards to splitscreen.
editor/debugger now shows asm if there's no linenumber info. also, pressing f1 for help shows the shortcuts.
Added support for .framegroups files for psk(psa) and iqm formats.
True support for ezquake's colour codes. Mutually exclusive with background colours.
path command output slightly more readable.
added support for digest_hex (MD4, SHA1, CRC16).
skingroups now colourmap correctly.
Fix terrain colour hints, and litdata from the wrong bsp.
fix ftp dual-homed issue. support epsv command, and enable ipv6 (eprt still not supported).
remove d3d11 compilation from the makefile. the required headers are not provided by mingw, and are not available to the build bot, so don't bother.
fix v *= v.x and similar opcodes.
fteqcc: fixed support for áéíóú type chars in names. utf-8 files now properly supported (even with the utf-8 bom/identifier). utf-16 also supported.
fteqcc: fixed '#if 1 == 3 && 4' parsing.
fteqcc: -Werror acts on the warning, rather than as a separate error. Line numbers are thus more readable.
fteqcc: copyright message now includes compile date instead.
fteqccgui: the treeview control is now coloured depending on whether there were warnings/errors in the last compile.
fteqccgui: the output window is now focused and scrolls down as compilation progresses.
pr_dumpplatform command dumps out some pragmas to convert more serious warnings to errors. This is to avoid the infamous 'fteqcc sucks cos my code sucks' issue.
rewrote prespawn/modelist/soundlist code. server tracks progress now.
------------------------------------------------------------------------
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@4167 fc73d0e0-1445-4013-8a0c-d673dee63da5
2013-03-12 22:29:40 +00:00
continue ;
}
if ( oldnum = = newnum )
2012-02-12 05:18:31 +00:00
oldindex + + ;
continue ;
}
else
{
if ( ! CL_CheckBaselines ( newnum ) )
Host_EndGame ( " CL_ParsePacketEntities: check baselines failed with size %i " , newnum ) ;
if ( newp - > num_entities > = newp - > max_entities )
{
newp - > max_entities = newp - > num_entities + 1 ;
newp - > entities = BZ_Realloc ( newp - > entities , sizeof ( entity_state_t ) * newp - > max_entities ) ;
}
if ( oldnum = = newnum )
2016-07-12 00:40:13 +00:00
CLFTE_ReadDelta ( newnum , & newp - > entities [ newp - > num_entities + + ] , & oldp - > entities [ oldindex + + ] , cl_baselines + newnum , newp , oldp ) ;
2012-02-12 05:18:31 +00:00
else
2016-07-12 00:40:13 +00:00
CLFTE_ReadDelta ( newnum , & newp - > entities [ newp - > num_entities + + ] , NULL , cl_baselines + newnum , newp , NULL ) ;
2012-02-12 05:18:31 +00:00
}
2004-08-23 00:15:46 +00:00
}
2012-02-12 05:18:31 +00:00
2013-09-06 22:57:44 +00:00
if ( cl . do_lerp_players )
2012-02-14 15:50:34 +00:00
{
2015-06-28 03:43:10 +00:00
float packetage = ( realtime - cl . outframes [ cl . ackedmovesequence & UPDATE_MASK ] . senttime ) - cls . latency * cl_predict_players_latency . value + cl_predict_players_nudge . value ;
2013-09-06 22:57:44 +00:00
//predict in-place based upon calculated latencies and stuff, stuff can then be interpolated properly
for ( oldindex = 0 ; oldindex < newp - > num_entities ; oldindex + + )
2012-02-14 15:50:34 +00:00
{
2015-01-21 18:18:37 +00:00
CL_PredictEntityMovement ( newp - > entities + oldindex , ( newp - > entities [ oldindex ] . u . q1 . msec / 1000.0f + packetage ) * 0.5 ) ;
2012-02-14 15:50:34 +00:00
}
}
2012-02-12 05:18:31 +00:00
if ( isvalid )
{
cl . oldvalidsequence = cl . validsequence ;
cl . validsequence = cls . netchan . incoming_sequence ;
2013-09-06 22:57:44 +00:00
CL_AckedInputFrame ( cls . netchan . incoming_sequence , inputframe , true ) ;
2013-03-12 22:53:23 +00:00
cl . inframes [ newpacket ] . invalid = false ;
2012-02-12 05:18:31 +00:00
}
else
2012-02-14 15:50:34 +00:00
{
newp - > num_entities = 0 ;
2012-02-12 05:18:31 +00:00
cl . validsequence = 0 ;
2013-07-26 17:19:06 +00:00
2013-09-06 22:57:44 +00:00
CL_AckedInputFrame ( cls . netchan . incoming_sequence , inputframe , false ) ;
2012-02-14 15:50:34 +00:00
}
2004-08-23 00:15:46 +00:00
}
/*
= = = = = = = = = = = = = = = = = =
CL_ParsePacketEntities
An svc_packetentities has just been parsed , deal with the
rest of the data stream .
= = = = = = = = = = = = = = = = = =
*/
------------------------------------------------------------------------
r4169 | acceptthis | 2013-01-17 08:55:12 +0000 (Thu, 17 Jan 2013) | 31 lines
removed MAX_VISEDICTS limit.
PEXT2_REPLACEMENTDELTAS tweaked, now has 4 million entity limit. still not enabled by default.
TE_BEAM now maps to a separate TEQW_BEAM to avoid conflicts with QW.
added android multitouch emulation for windows/rawinput (in_simulatemultitouch).
split topcolor/bottomcolor from scoreboard, for dp's colormap|1024 feature.
now using utf-8 for windows consoles.
qcc warnings/errors now give clickable console links for quick+easy editing.
disabled menutint when the currently active item changes contrast or gamma (for OneManClan).
Added support for drawfont/drawfontscale.
tweaked the qcvm a little to reduce the number of pointers.
.doll file loading. still experimental and will likely crash. requires csqc active, even if its a dummy progs. this will be fixed in time. Still other things that need cleaning up.
windows: gl_font "?" shows the standard windows font-selection dialog, and can be used to select windows fonts. not all work. and you probably don't want to use windings.
fixed splitscreen support when playing mvds. added mini-scoreboards to splitscreen.
editor/debugger now shows asm if there's no linenumber info. also, pressing f1 for help shows the shortcuts.
Added support for .framegroups files for psk(psa) and iqm formats.
True support for ezquake's colour codes. Mutually exclusive with background colours.
path command output slightly more readable.
added support for digest_hex (MD4, SHA1, CRC16).
skingroups now colourmap correctly.
Fix terrain colour hints, and litdata from the wrong bsp.
fix ftp dual-homed issue. support epsv command, and enable ipv6 (eprt still not supported).
remove d3d11 compilation from the makefile. the required headers are not provided by mingw, and are not available to the build bot, so don't bother.
fix v *= v.x and similar opcodes.
fteqcc: fixed support for áéíóú type chars in names. utf-8 files now properly supported (even with the utf-8 bom/identifier). utf-16 also supported.
fteqcc: fixed '#if 1 == 3 && 4' parsing.
fteqcc: -Werror acts on the warning, rather than as a separate error. Line numbers are thus more readable.
fteqcc: copyright message now includes compile date instead.
fteqccgui: the treeview control is now coloured depending on whether there were warnings/errors in the last compile.
fteqccgui: the output window is now focused and scrolls down as compilation progresses.
pr_dumpplatform command dumps out some pragmas to convert more serious warnings to errors. This is to avoid the infamous 'fteqcc sucks cos my code sucks' issue.
rewrote prespawn/modelist/soundlist code. server tracks progress now.
------------------------------------------------------------------------
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@4167 fc73d0e0-1445-4013-8a0c-d673dee63da5
2013-03-12 22:29:40 +00:00
void CLQW_ParsePacketEntities ( qboolean delta )
2004-08-23 00:15:46 +00:00
{
int oldpacket , newpacket ;
packet_entities_t * oldp , * newp , dummy ;
int oldindex , newindex ;
int word , newnum , oldnum ;
qboolean full ;
2004-12-08 04:14:52 +00:00
int from ;
2005-11-30 01:20:53 +00:00
2009-11-04 21:16:50 +00:00
newpacket = cls . netchan . incoming_sequence & UPDATE_MASK ;
2013-03-12 22:53:23 +00:00
newp = & cl . inframes [ newpacket ] . packet_entities ;
cl . inframes [ newpacket ] . invalid = false ;
2013-09-06 22:57:44 +00:00
cl . inframes [ newpacket ] . frameid = cls . netchan . incoming_sequence ;
cl . inframes [ newpacket ] . receivedtime = realtime ;
2009-11-04 21:16:50 +00:00
2015-08-07 17:49:49 +00:00
if ( cls . protocol = = CP_QUAKEWORLD & & ( cls . demoplayback = = DPB_MVD | | cls . demoplayback = = DPB_EZTV ) )
2010-03-14 14:35:56 +00:00
{
2012-08-04 01:35:52 +00:00
extern float olddemotime ; //time from the most recent demo packet
2010-03-14 14:35:56 +00:00
cl . oldgametime = cl . gametime ;
cl . oldgametimemark = cl . gametimemark ;
2015-08-07 17:49:49 +00:00
cl . gametime = olddemotime + cl . demogametimebias ;
2010-03-14 14:35:56 +00:00
cl . gametimemark = realtime ;
}
else if ( ! ( cls . fteprotocolextensions & PEXT_ACCURATETIMINGS ) & & cls . protocol = = CP_QUAKEWORLD )
2005-11-30 01:20:53 +00:00
{
2015-06-05 09:04:05 +00:00
extern cvar_t cl_demospeed ;
float scale = cls . demoplayback ? cl_demospeed . value : 1 ;
2005-11-30 01:20:53 +00:00
cl . oldgametime = cl . gametime ;
cl . oldgametimemark = cl . gametimemark ;
2015-06-05 09:04:05 +00:00
if ( realtime - cl . gametimemark > 0 )
cl . gametime + = ( realtime - cl . gametimemark ) * scale ; //cl.frames[newpacket].senttime - cl.frames[(newpacket-1)&UPDATE_MASK].senttime;
2005-11-30 01:20:53 +00:00
cl . gametimemark = realtime ;
2009-11-04 21:16:50 +00:00
}
2010-12-05 02:46:07 +00:00
newp - > servertime = cl . gametime ;
2005-11-26 03:02:55 +00:00
2004-08-23 00:15:46 +00:00
if ( delta )
{
from = MSG_ReadByte ( ) ;
2007-02-23 00:21:33 +00:00
// Con_Printf("%i %i from %i\n", cls.netchan.outgoing_sequence, cls.netchan.incoming_sequence, from);
2013-03-12 22:53:23 +00:00
oldpacket = cl . inframes [ newpacket ] . delta_sequence ;
2008-01-09 00:52:31 +00:00
if ( cls . demoplayback = = DPB_MVD | | cls . demoplayback = = DPB_EZTV )
2004-08-23 00:15:46 +00:00
from = oldpacket = cls . netchan . incoming_sequence - 1 ;
2004-12-08 04:14:52 +00:00
if ( cls . netchan . outgoing_sequence - cls . netchan . incoming_sequence > = UPDATE_BACKUP - 1 ) {
// there are no valid frames left, so drop it
FlushEntityPacket ( ) ;
cl . validsequence = 0 ;
return ;
}
if ( ( from & UPDATE_MASK ) ! = ( oldpacket & UPDATE_MASK ) ) {
2004-08-23 00:15:46 +00:00
Con_DPrintf ( " WARNING: from mismatch \n " ) ;
2005-05-13 10:42:48 +00:00
// FlushEntityPacket ();
// cl.validsequence = 0;
// return;
2004-12-08 04:14:52 +00:00
}
2004-08-23 00:15:46 +00:00
2007-02-23 00:21:33 +00:00
if ( cls . netchan . outgoing_sequence - oldpacket > = UPDATE_BACKUP - 1 )
{
2004-12-08 04:14:52 +00:00
// we can't use this, it is too old
2004-08-23 00:15:46 +00:00
FlushEntityPacket ( ) ;
2004-12-08 04:14:52 +00:00
// don't clear cl.validsequence, so that frames can still be rendered;
// it is possible that a fresh packet will be received before
// (outgoing_sequence - incoming_sequence) exceeds UPDATE_BACKUP - 1
2004-08-23 00:15:46 +00:00
return ;
}
2004-12-08 04:14:52 +00:00
2013-03-12 22:53:23 +00:00
oldp = & cl . inframes [ oldpacket & UPDATE_MASK ] . packet_entities ;
2004-12-08 04:14:52 +00:00
full = false ;
2004-08-23 00:15:46 +00:00
}
else
{ // this is a full update that we can start delta compressing from now
oldp = & dummy ;
dummy . num_entities = 0 ;
full = true ;
}
2013-07-26 17:19:06 +00:00
//FIXME
2004-12-08 04:14:52 +00:00
cl . oldvalidsequence = cl . validsequence ;
cl . validsequence = cls . netchan . incoming_sequence ;
2013-09-06 22:57:44 +00:00
CL_AckedInputFrame ( cls . netchan . incoming_sequence , cls . netchan . incoming_sequence , true ) ;
2004-12-08 04:14:52 +00:00
2004-08-23 00:15:46 +00:00
oldindex = 0 ;
newindex = 0 ;
newp - > num_entities = 0 ;
while ( 1 )
{
word = ( unsigned short ) MSG_ReadShort ( ) ;
if ( msg_badread )
{ // something didn't parse right...
Host_EndGame ( " msg_badread in packetentities " ) ;
return ;
}
if ( ! word )
{
while ( oldindex < oldp - > num_entities )
{ // copy all the rest of the entities from the old packet
//Con_Printf ("copy %i\n", oldp->entities[oldindex].number);
if ( newindex > = newp - > max_entities )
{
newp - > max_entities = newindex + 1 ;
2011-05-29 04:26:29 +00:00
newp - > entities = BZ_Realloc ( newp - > entities , sizeof ( entity_state_t ) * newp - > max_entities ) ;
2004-08-23 00:15:46 +00:00
}
if ( oldindex > = oldp - > max_entities )
Host_EndGame ( " Old packet entity too big \n " ) ;
newp - > entities [ newindex ] = oldp - > entities [ oldindex ] ;
newindex + + ;
oldindex + + ;
}
break ;
}
newnum = word & 511 ;
if ( word & U_MOREBITS )
{
int oldpos = msg_readcount ;
int excessive ;
excessive = MSG_ReadByte ( ) ;
if ( excessive & U_EVENMORE )
{
excessive = MSG_ReadByte ( ) ;
if ( excessive & U_ENTITYDBL )
newnum + = 512 ;
if ( excessive & U_ENTITYDBL2 )
newnum + = 1024 ;
2005-02-06 02:47:36 +00:00
}
2004-08-23 00:15:46 +00:00
msg_readcount = oldpos ; //undo the read...
}
oldnum = oldindex > = oldp - > num_entities ? 9999 : oldp - > entities [ oldindex ] . number ;
while ( newnum > oldnum )
{
if ( full )
{
Con_Printf ( " WARNING: oldcopy on full update " ) ;
FlushEntityPacket ( ) ;
return ;
}
//Con_Printf ("copy %i\n", oldnum);
// copy one of the old entities over to the new packet unchanged
if ( newindex > = newp - > max_entities )
{
newp - > max_entities = newindex + 1 ;
newp - > entities = BZ_Realloc ( newp - > entities , sizeof ( entity_state_t ) * newp - > max_entities ) ;
}
if ( oldindex > = oldp - > max_entities )
Host_EndGame ( " Old packet entity too big \n " ) ;
newp - > entities [ newindex ] = oldp - > entities [ oldindex ] ;
newindex + + ;
oldindex + + ;
oldnum = oldindex > = oldp - > num_entities ? 9999 : oldp - > entities [ oldindex ] . number ;
}
if ( newnum < oldnum )
{ // new from baseline
//Con_Printf ("baseline %i\n", newnum);
if ( word & U_REMOVE )
2005-10-20 00:04:57 +00:00
{ //really read the extra entity number if required
if ( word & U_MOREBITS )
if ( MSG_ReadByte ( ) & U_EVENMORE )
MSG_ReadByte ( ) ;
2004-08-23 00:15:46 +00:00
if ( full )
{
cl . validsequence = 0 ;
Con_Printf ( " WARNING: U_REMOVE on full update \n " ) ;
FlushEntityPacket ( ) ;
return ;
}
continue ;
}
if ( newindex > = newp - > max_entities )
{
newp - > max_entities = newindex + 1 ;
newp - > entities = BZ_Realloc ( newp - > entities , sizeof ( entity_state_t ) * newp - > max_entities ) ;
}
2006-07-24 04:24:41 +00:00
if ( ! CL_CheckBaselines ( newnum ) )
Host_EndGame ( " CL_ParsePacketEntities: check baselines failed with size %i " , newnum ) ;
2016-07-12 00:40:13 +00:00
CLQW_ParseDelta ( cl_baselines + newnum , & newp - > entities [ newindex ] , word ) ;
2004-08-23 00:15:46 +00:00
newindex + + ;
continue ;
}
if ( newnum = = oldnum )
{ // delta from previous
if ( full )
{
cl . validsequence = 0 ;
Con_Printf ( " WARNING: delta on full update " ) ;
}
if ( word & U_REMOVE )
{
2005-10-20 00:04:57 +00:00
if ( word & U_MOREBITS )
if ( MSG_ReadByte ( ) & U_EVENMORE )
MSG_ReadByte ( ) ;
2004-08-23 00:15:46 +00:00
oldindex + + ;
continue ;
}
if ( newindex > = newp - > max_entities )
{
newp - > max_entities = newindex + 1 ;
newp - > entities = BZ_Realloc ( newp - > entities , sizeof ( entity_state_t ) * newp - > max_entities ) ;
}
//Con_Printf ("delta %i\n",newnum);
2016-07-12 00:40:13 +00:00
CLQW_ParseDelta ( & oldp - > entities [ oldindex ] , & newp - > entities [ newindex ] , word ) ;
2004-08-23 00:15:46 +00:00
newindex + + ;
oldindex + + ;
}
}
newp - > num_entities = newindex ;
}
2004-11-29 01:21:00 +00:00
2004-08-23 00:15:46 +00:00
entity_state_t * CL_FindOldPacketEntity ( int num )
{
int pnum ;
entity_state_t * s1 ;
packet_entities_t * pack ;
2005-05-26 12:55:34 +00:00
if ( ! cl . validsequence )
2004-09-30 22:40:24 +00:00
return NULL ;
2013-03-12 22:53:23 +00:00
pack = & cl . inframes [ ( cls . netchan . incoming_sequence - 1 ) & UPDATE_MASK ] . packet_entities ;
2004-08-23 00:15:46 +00:00
for ( pnum = 0 ; pnum < pack - > num_entities ; pnum + + )
{
s1 = & pack - > entities [ pnum ] ;
if ( num = = s1 - > number )
return s1 ;
}
return NULL ;
}
2004-11-29 01:21:00 +00:00
# ifdef NQPROT
2016-07-12 00:40:13 +00:00
void DP5_ParseDelta ( entity_state_t * s , packet_entities_t * pack )
2004-11-27 08:16:25 +00:00
{
2019-09-04 07:59:40 +00:00
unsigned int bits ;
Reworked client support for DPP5+. less code now, its much more graceful.
added waterfog command. waterfog overrides regular fog only when the view is in water.
fixed 64bit printf format specifiers. should work better on winxp64.
fixed some spec angle weirdness.
fixed viewsize 99.99 weirdness with ezhud.
fixed extra offset on the console (exhibited in 64bit builds, but not limited to).
fixed .avi playback, can now actually display frames again.
reimplemented line sparks.
fixed r_editlights_save flipping the light's pitch.
fixed issue with oggs failing to load.
fixed condump to cope with unicode properly.
made sv_bigcoords default except in quake. hexen2 kinda needs it for bsp angle precision.
fixed nq server to not stall weirdly on map changes.
fixed qwprogs svc_cdtrack not bugging out with nq clients on the server.
fixed restart command to load the last map run by the server, instead of start.bsp (when idle)
optimised d3d9 renderer a little. now uses less draw calls, especially with complex scenes. seems to get higher framerates than opengl now.
fixed d3d9 renderer to not bug out quite so much when run fullscreen (shader subsystem is now correctly initialised).
fixed a couple of bugs from font change. also now supports utf-8 in a few more places.
r_editlights_reload no longer generates rtlights inside the void. this resolves a few glitches (but should also help framerates a little).
fixed so corona-only lights won't generate shadowmaps and waste lots of time.
removed lots of #defines from qclib. I should never have made them in the first place, but I was lazy. obviously there's more left that I cba to remove yet.
fixed nested calls with variant-vectors. this fixes csaddon's light editor.
fixed qcc hc calling conventions using redundant stores.
disabled keywords can still be used by using __keyword instead.
fixed ftegccgui grep feature.
fixed motionless-dog qcc bug.
tweaked qcc warnings a little. -Wall is now a viable setting. you should be able to fix all those warnings.
fixed qw svc_intermission + dpp5+ clients bug.
fixed annoying spam about disconnecting in hexen2.
rewrote status command a little to cope with ipv6 addresses more gracefully
fixed significant stall when hibernating/debugging a server with a player sitting on it.
fixed truelightning.
fixed rocketlight overriding pflags.
fixed torches vanishing on vid_restart.
fixed issue with decal scaling.
fixed findentityfield builtin.
fixed fteqcc issue with ptr+1
fixed use of arrays inside class functions.
fixed/implemented fteqcc emulation of pointer opcodes.
added __inout keyword to fteqcc, so that it doesn't feel so horrendous.
fixed sizeof(*foo)
fixed *struct = struct;
fixed recursive structs.
fixed fteqcc warning report.
fixed sdl2 controller support, hopefully.
attempted to implement xinput, including per-player audio playback.
slightly fixed relaxed attitude to mouse focus when running fullscreen.
fixed weird warnings/errors with 'ent.arrayhead' terms. now generates sane errors.
implemented bindmaps (for csqc).
fixed crashing bug with eprint builtin.
implemented subset of music_playlist_* functionality. significant changes to music playback.
fixed some more dpcsqc compat.
fixed binds menu. now displays and accepts modifiers.
fixed issues with huge lightmaps.
fixed protocol determinism with dp clients connecting to fte servers. the initial getchallenge request now inhibits vanilla nq connection requests.
implemented support for 'dupe' userinfo key, allowing clients to request client->server packet duplication. should probably queue them tbh.
implemented sv_saveentfile command.
fixed resume after breaking inside a stepped-over function.
fixed erroneous footer after debugging.
(I wonder just how many things I broke with these fixes)
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@4946 fc73d0e0-1445-4013-8a0c-d673dee63da5
2015-07-26 10:56:18 +00:00
if ( cl_shownet . ival > = 3 )
Con_Printf ( " %3i: Update %i " , msg_readcount , s - > number ) ;
2004-11-27 08:16:25 +00:00
bits = MSG_ReadByte ( ) ;
if ( bits & E5_EXTEND1 )
{
bits | = MSG_ReadByte ( ) < < 8 ;
if ( bits & E5_EXTEND2 )
{
bits | = MSG_ReadByte ( ) < < 16 ;
if ( bits & E5_EXTEND3 )
bits | = MSG_ReadByte ( ) < < 24 ;
}
}
2005-09-26 03:40:09 +00:00
Reworked client support for DPP5+. less code now, its much more graceful.
added waterfog command. waterfog overrides regular fog only when the view is in water.
fixed 64bit printf format specifiers. should work better on winxp64.
fixed some spec angle weirdness.
fixed viewsize 99.99 weirdness with ezhud.
fixed extra offset on the console (exhibited in 64bit builds, but not limited to).
fixed .avi playback, can now actually display frames again.
reimplemented line sparks.
fixed r_editlights_save flipping the light's pitch.
fixed issue with oggs failing to load.
fixed condump to cope with unicode properly.
made sv_bigcoords default except in quake. hexen2 kinda needs it for bsp angle precision.
fixed nq server to not stall weirdly on map changes.
fixed qwprogs svc_cdtrack not bugging out with nq clients on the server.
fixed restart command to load the last map run by the server, instead of start.bsp (when idle)
optimised d3d9 renderer a little. now uses less draw calls, especially with complex scenes. seems to get higher framerates than opengl now.
fixed d3d9 renderer to not bug out quite so much when run fullscreen (shader subsystem is now correctly initialised).
fixed a couple of bugs from font change. also now supports utf-8 in a few more places.
r_editlights_reload no longer generates rtlights inside the void. this resolves a few glitches (but should also help framerates a little).
fixed so corona-only lights won't generate shadowmaps and waste lots of time.
removed lots of #defines from qclib. I should never have made them in the first place, but I was lazy. obviously there's more left that I cba to remove yet.
fixed nested calls with variant-vectors. this fixes csaddon's light editor.
fixed qcc hc calling conventions using redundant stores.
disabled keywords can still be used by using __keyword instead.
fixed ftegccgui grep feature.
fixed motionless-dog qcc bug.
tweaked qcc warnings a little. -Wall is now a viable setting. you should be able to fix all those warnings.
fixed qw svc_intermission + dpp5+ clients bug.
fixed annoying spam about disconnecting in hexen2.
rewrote status command a little to cope with ipv6 addresses more gracefully
fixed significant stall when hibernating/debugging a server with a player sitting on it.
fixed truelightning.
fixed rocketlight overriding pflags.
fixed torches vanishing on vid_restart.
fixed issue with decal scaling.
fixed findentityfield builtin.
fixed fteqcc issue with ptr+1
fixed use of arrays inside class functions.
fixed/implemented fteqcc emulation of pointer opcodes.
added __inout keyword to fteqcc, so that it doesn't feel so horrendous.
fixed sizeof(*foo)
fixed *struct = struct;
fixed recursive structs.
fixed fteqcc warning report.
fixed sdl2 controller support, hopefully.
attempted to implement xinput, including per-player audio playback.
slightly fixed relaxed attitude to mouse focus when running fullscreen.
fixed weird warnings/errors with 'ent.arrayhead' terms. now generates sane errors.
implemented bindmaps (for csqc).
fixed crashing bug with eprint builtin.
implemented subset of music_playlist_* functionality. significant changes to music playback.
fixed some more dpcsqc compat.
fixed binds menu. now displays and accepts modifiers.
fixed issues with huge lightmaps.
fixed protocol determinism with dp clients connecting to fte servers. the initial getchallenge request now inhibits vanilla nq connection requests.
implemented support for 'dupe' userinfo key, allowing clients to request client->server packet duplication. should probably queue them tbh.
implemented sv_saveentfile command.
fixed resume after breaking inside a stepped-over function.
fixed erroneous footer after debugging.
(I wonder just how many things I broke with these fixes)
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@4946 fc73d0e0-1445-4013-8a0c-d673dee63da5
2015-07-26 10:56:18 +00:00
if ( cl_shownet . ival > = 3 )
{
if ( bits & E5_FULLUPDATE ) Con_Printf ( " full " ) ;
if ( bits & E5_ORIGIN ) Con_Printf ( " origin " ) ;
if ( bits & E5_ANGLES ) Con_Printf ( " angles " ) ;
if ( bits & E5_MODEL ) Con_Printf ( " model " ) ;
if ( bits & E5_FRAME ) Con_Printf ( " frame " ) ;
if ( bits & E5_SKIN ) Con_Printf ( " kin " ) ;
if ( bits & E5_EFFECTS ) Con_Printf ( " effects " ) ;
if ( bits & E5_EXTEND1 ) Con_Printf ( " extend1 " ) ;
if ( bits & E5_FLAGS ) Con_Printf ( " flags " ) ;
if ( bits & E5_ALPHA ) Con_Printf ( " alpha " ) ;
if ( bits & E5_SCALE ) Con_Printf ( " scale " ) ;
if ( bits & E5_ORIGIN32 ) Con_Printf ( " origin32 " ) ;
if ( bits & E5_ANGLES16 ) Con_Printf ( " angles16 " ) ;
if ( bits & E5_MODEL16 ) Con_Printf ( " model16 " ) ;
if ( bits & E5_COLORMAP ) Con_Printf ( " colormap " ) ;
if ( bits & E5_EXTEND2 ) Con_Printf ( " extend2 " ) ;
if ( bits & E5_ATTACHMENT ) Con_Printf ( " attachment " ) ;
if ( bits & E5_LIGHT ) Con_Printf ( " light " ) ;
if ( bits & E5_GLOW ) Con_Printf ( " glow " ) ;
if ( bits & E5_EFFECTS16 ) Con_Printf ( " effects16 " ) ;
if ( bits & E5_EFFECTS32 ) Con_Printf ( " effects32 " ) ;
if ( bits & E5_FRAME16 ) Con_Printf ( " frame16 " ) ;
if ( bits & E5_COLORMOD ) Con_Printf ( " colormod " ) ;
if ( bits & E5_EXTEND3 ) Con_Printf ( " extend3 " ) ;
if ( bits & E5_GLOWMOD ) Con_Printf ( " glowmod " ) ;
if ( bits & E5_COMPLEXANIMATION ) Con_Printf ( " complexanimation " ) ;
if ( bits & E5_TRAILEFFECTNUM ) Con_Printf ( " traileffectnum " ) ;
if ( bits & E5_UNUSED27 ) Con_Printf ( " unused27 " ) ;
if ( bits & E5_UNUSED28 ) Con_Printf ( " unused28 " ) ;
if ( bits & E5_UNUSED29 ) Con_Printf ( " unused29 " ) ;
if ( bits & E5_UNUSED30 ) Con_Printf ( " unused30 " ) ;
if ( bits & E5_EXTEND4 ) Con_Printf ( " extend4 " ) ;
Con_Printf ( " \n " ) ;
}
2005-09-26 03:40:09 +00:00
if ( bits & E5_ALLUNUSED )
{
Host_EndGame ( " Detected 'unused' bits in DP5+ entity delta - %x (%x) \n " , bits , ( bits & E5_ALLUNUSED ) ) ;
}
2004-11-27 08:16:25 +00:00
if ( bits & E5_FULLUPDATE )
{
2005-05-15 18:49:04 +00:00
int num ;
num = s - > number ;
2013-03-12 23:09:25 +00:00
* s = nullentitystate ;
2005-05-15 18:49:04 +00:00
s - > number = num ;
2016-07-12 00:40:13 +00:00
s - > solidsize = ES_SOLID_BSP ;
2004-11-27 08:16:25 +00:00
// s->active = true;
}
if ( bits & E5_FLAGS )
2005-05-17 02:36:54 +00:00
{
int i = MSG_ReadByte ( ) ;
2011-10-27 15:46:36 +00:00
s - > dpflags = i ;
2005-05-17 02:36:54 +00:00
}
2004-11-27 08:16:25 +00:00
if ( bits & E5_ORIGIN )
{
if ( bits & E5_ORIGIN32 )
{
s - > origin [ 0 ] = MSG_ReadFloat ( ) ;
s - > origin [ 1 ] = MSG_ReadFloat ( ) ;
s - > origin [ 2 ] = MSG_ReadFloat ( ) ;
}
else
{
s - > origin [ 0 ] = MSG_ReadShort ( ) * ( 1 / 8.0f ) ;
s - > origin [ 1 ] = MSG_ReadShort ( ) * ( 1 / 8.0f ) ;
s - > origin [ 2 ] = MSG_ReadShort ( ) * ( 1 / 8.0f ) ;
}
}
if ( bits & E5_ANGLES )
{
if ( bits & E5_ANGLES16 )
{
2005-02-06 02:47:36 +00:00
s - > angles [ 0 ] = MSG_ReadAngle16 ( ) ;
s - > angles [ 1 ] = MSG_ReadAngle16 ( ) ;
s - > angles [ 2 ] = MSG_ReadAngle16 ( ) ;
2004-11-27 08:16:25 +00:00
}
else
{
s - > angles [ 0 ] = MSG_ReadChar ( ) * ( 360.0 / 256 ) ;
s - > angles [ 1 ] = MSG_ReadChar ( ) * ( 360.0 / 256 ) ;
s - > angles [ 2 ] = MSG_ReadChar ( ) * ( 360.0 / 256 ) ;
}
}
if ( bits & E5_MODEL )
{
if ( bits & E5_MODEL16 )
s - > modelindex = ( unsigned short ) MSG_ReadShort ( ) ;
else
s - > modelindex = MSG_ReadByte ( ) ;
}
if ( bits & E5_FRAME )
{
if ( bits & E5_FRAME16 )
s - > frame = ( unsigned short ) MSG_ReadShort ( ) ;
else
s - > frame = MSG_ReadByte ( ) ;
}
if ( bits & E5_SKIN )
s - > skinnum = MSG_ReadByte ( ) ;
if ( bits & E5_EFFECTS )
{
if ( bits & E5_EFFECTS32 )
s - > effects = ( unsigned int ) MSG_ReadLong ( ) ;
else if ( bits & E5_EFFECTS16 )
s - > effects = ( unsigned short ) MSG_ReadShort ( ) ;
else
s - > effects = MSG_ReadByte ( ) ;
}
if ( bits & E5_ALPHA )
2005-07-01 19:23:00 +00:00
s - > trans = MSG_ReadByte ( ) ;
2004-11-27 08:16:25 +00:00
if ( bits & E5_SCALE )
2005-07-01 19:23:00 +00:00
s - > scale = MSG_ReadByte ( ) ;
2004-11-27 08:16:25 +00:00
if ( bits & E5_COLORMAP )
s - > colormap = MSG_ReadByte ( ) ;
if ( bits & E5_ATTACHMENT )
{
------------------------------------------------------------------------
r4169 | acceptthis | 2013-01-17 08:55:12 +0000 (Thu, 17 Jan 2013) | 31 lines
removed MAX_VISEDICTS limit.
PEXT2_REPLACEMENTDELTAS tweaked, now has 4 million entity limit. still not enabled by default.
TE_BEAM now maps to a separate TEQW_BEAM to avoid conflicts with QW.
added android multitouch emulation for windows/rawinput (in_simulatemultitouch).
split topcolor/bottomcolor from scoreboard, for dp's colormap|1024 feature.
now using utf-8 for windows consoles.
qcc warnings/errors now give clickable console links for quick+easy editing.
disabled menutint when the currently active item changes contrast or gamma (for OneManClan).
Added support for drawfont/drawfontscale.
tweaked the qcvm a little to reduce the number of pointers.
.doll file loading. still experimental and will likely crash. requires csqc active, even if its a dummy progs. this will be fixed in time. Still other things that need cleaning up.
windows: gl_font "?" shows the standard windows font-selection dialog, and can be used to select windows fonts. not all work. and you probably don't want to use windings.
fixed splitscreen support when playing mvds. added mini-scoreboards to splitscreen.
editor/debugger now shows asm if there's no linenumber info. also, pressing f1 for help shows the shortcuts.
Added support for .framegroups files for psk(psa) and iqm formats.
True support for ezquake's colour codes. Mutually exclusive with background colours.
path command output slightly more readable.
added support for digest_hex (MD4, SHA1, CRC16).
skingroups now colourmap correctly.
Fix terrain colour hints, and litdata from the wrong bsp.
fix ftp dual-homed issue. support epsv command, and enable ipv6 (eprt still not supported).
remove d3d11 compilation from the makefile. the required headers are not provided by mingw, and are not available to the build bot, so don't bother.
fix v *= v.x and similar opcodes.
fteqcc: fixed support for áéíóú type chars in names. utf-8 files now properly supported (even with the utf-8 bom/identifier). utf-16 also supported.
fteqcc: fixed '#if 1 == 3 && 4' parsing.
fteqcc: -Werror acts on the warning, rather than as a separate error. Line numbers are thus more readable.
fteqcc: copyright message now includes compile date instead.
fteqccgui: the treeview control is now coloured depending on whether there were warnings/errors in the last compile.
fteqccgui: the output window is now focused and scrolls down as compilation progresses.
pr_dumpplatform command dumps out some pragmas to convert more serious warnings to errors. This is to avoid the infamous 'fteqcc sucks cos my code sucks' issue.
rewrote prespawn/modelist/soundlist code. server tracks progress now.
------------------------------------------------------------------------
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@4167 fc73d0e0-1445-4013-8a0c-d673dee63da5
2013-03-12 22:29:40 +00:00
s - > tagentity = MSGCL_ReadEntity ( ) ;
2005-07-01 19:23:00 +00:00
s - > tagindex = MSG_ReadByte ( ) ;
2004-11-27 08:16:25 +00:00
}
if ( bits & E5_LIGHT )
{
2005-09-26 03:40:09 +00:00
s - > light [ 0 ] = MSG_ReadShort ( ) ;
s - > light [ 1 ] = MSG_ReadShort ( ) ;
s - > light [ 2 ] = MSG_ReadShort ( ) ;
s - > light [ 3 ] = MSG_ReadShort ( ) ;
s - > lightstyle = MSG_ReadByte ( ) ;
s - > lightpflags = MSG_ReadByte ( ) ;
2004-11-27 08:16:25 +00:00
}
if ( bits & E5_GLOW )
{
2005-05-19 02:53:03 +00:00
s - > glowsize = MSG_ReadByte ( ) ;
s - > glowcolour = MSG_ReadByte ( ) ;
2004-11-27 08:16:25 +00:00
}
2005-09-26 03:40:09 +00:00
if ( bits & E5_COLORMOD )
{
2006-02-27 00:42:25 +00:00
s - > colormod [ 0 ] = MSG_ReadByte ( ) ;
s - > colormod [ 1 ] = MSG_ReadByte ( ) ;
s - > colormod [ 2 ] = MSG_ReadByte ( ) ;
2005-09-26 03:40:09 +00:00
}
2012-02-12 05:18:31 +00:00
if ( bits & E5_GLOWMOD )
{
s - > glowmod [ 0 ] = MSG_ReadByte ( ) ;
s - > glowmod [ 1 ] = MSG_ReadByte ( ) ;
s - > glowmod [ 2 ] = MSG_ReadByte ( ) ;
}
2016-07-12 00:40:13 +00:00
if ( bits & E5_COMPLEXANIMATION )
{
int type = MSG_ReadByte ( ) ;
int i , numbones ;
if ( type = = 4 )
{
short * bonedata ;
/*modelindex = */ MSG_ReadShort ( ) ;
numbones = MSG_ReadByte ( ) ;
bonedata = AllocateBoneSpace ( pack , numbones , & s - > boneoffset ) ;
s - > bonecount = numbones ;
for ( i = 0 ; i < numbones * 7 ; i + + )
bonedata [ i ] = MSG_ReadShort ( ) ;
}
else if ( type < 4 )
{ //n-way blends
s - > bonecount = 0 ;
type + + ;
for ( i = 0 ; i < type ; i + + )
/*frame = */ MSG_ReadShort ( ) ;
for ( i = 0 ; i < type ; i + + )
/*age = */ MSG_ReadShort ( ) ;
for ( i = 0 ; i < type ; i + + )
/*frac = */ ( type = = 1 ) ? 255 : MSG_ReadByte ( ) ;
}
else
Host_Error ( " E5_COMPLEXANIMATION: Parse error - unknown type %i \n " , type ) ;
}
2014-04-24 01:53:01 +00:00
if ( bits & E5_TRAILEFFECTNUM )
s - > u . q1 . traileffectnum = MSG_ReadShort ( ) ;
2004-11-27 08:16:25 +00:00
}
Reworked client support for DPP5+. less code now, its much more graceful.
added waterfog command. waterfog overrides regular fog only when the view is in water.
fixed 64bit printf format specifiers. should work better on winxp64.
fixed some spec angle weirdness.
fixed viewsize 99.99 weirdness with ezhud.
fixed extra offset on the console (exhibited in 64bit builds, but not limited to).
fixed .avi playback, can now actually display frames again.
reimplemented line sparks.
fixed r_editlights_save flipping the light's pitch.
fixed issue with oggs failing to load.
fixed condump to cope with unicode properly.
made sv_bigcoords default except in quake. hexen2 kinda needs it for bsp angle precision.
fixed nq server to not stall weirdly on map changes.
fixed qwprogs svc_cdtrack not bugging out with nq clients on the server.
fixed restart command to load the last map run by the server, instead of start.bsp (when idle)
optimised d3d9 renderer a little. now uses less draw calls, especially with complex scenes. seems to get higher framerates than opengl now.
fixed d3d9 renderer to not bug out quite so much when run fullscreen (shader subsystem is now correctly initialised).
fixed a couple of bugs from font change. also now supports utf-8 in a few more places.
r_editlights_reload no longer generates rtlights inside the void. this resolves a few glitches (but should also help framerates a little).
fixed so corona-only lights won't generate shadowmaps and waste lots of time.
removed lots of #defines from qclib. I should never have made them in the first place, but I was lazy. obviously there's more left that I cba to remove yet.
fixed nested calls with variant-vectors. this fixes csaddon's light editor.
fixed qcc hc calling conventions using redundant stores.
disabled keywords can still be used by using __keyword instead.
fixed ftegccgui grep feature.
fixed motionless-dog qcc bug.
tweaked qcc warnings a little. -Wall is now a viable setting. you should be able to fix all those warnings.
fixed qw svc_intermission + dpp5+ clients bug.
fixed annoying spam about disconnecting in hexen2.
rewrote status command a little to cope with ipv6 addresses more gracefully
fixed significant stall when hibernating/debugging a server with a player sitting on it.
fixed truelightning.
fixed rocketlight overriding pflags.
fixed torches vanishing on vid_restart.
fixed issue with decal scaling.
fixed findentityfield builtin.
fixed fteqcc issue with ptr+1
fixed use of arrays inside class functions.
fixed/implemented fteqcc emulation of pointer opcodes.
added __inout keyword to fteqcc, so that it doesn't feel so horrendous.
fixed sizeof(*foo)
fixed *struct = struct;
fixed recursive structs.
fixed fteqcc warning report.
fixed sdl2 controller support, hopefully.
attempted to implement xinput, including per-player audio playback.
slightly fixed relaxed attitude to mouse focus when running fullscreen.
fixed weird warnings/errors with 'ent.arrayhead' terms. now generates sane errors.
implemented bindmaps (for csqc).
fixed crashing bug with eprint builtin.
implemented subset of music_playlist_* functionality. significant changes to music playback.
fixed some more dpcsqc compat.
fixed binds menu. now displays and accepts modifiers.
fixed issues with huge lightmaps.
fixed protocol determinism with dp clients connecting to fte servers. the initial getchallenge request now inhibits vanilla nq connection requests.
implemented support for 'dupe' userinfo key, allowing clients to request client->server packet duplication. should probably queue them tbh.
implemented sv_saveentfile command.
fixed resume after breaking inside a stepped-over function.
fixed erroneous footer after debugging.
(I wonder just how many things I broke with these fixes)
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@4946 fc73d0e0-1445-4013-8a0c-d673dee63da5
2015-07-26 10:56:18 +00:00
static int QDECL CLDP_SortEntities ( const void * va , const void * vb )
{
const entity_state_t * a = va , * b = vb ;
2016-07-12 00:40:13 +00:00
if ( a - > inactiveflag ! = b - > inactiveflag )
return a - > inactiveflag ? 1 : - 1 ;
if ( a - > number ! = b - > number )
return a - > number < b - > number ? - 1 : 1 ;
return 0 ;
Reworked client support for DPP5+. less code now, its much more graceful.
added waterfog command. waterfog overrides regular fog only when the view is in water.
fixed 64bit printf format specifiers. should work better on winxp64.
fixed some spec angle weirdness.
fixed viewsize 99.99 weirdness with ezhud.
fixed extra offset on the console (exhibited in 64bit builds, but not limited to).
fixed .avi playback, can now actually display frames again.
reimplemented line sparks.
fixed r_editlights_save flipping the light's pitch.
fixed issue with oggs failing to load.
fixed condump to cope with unicode properly.
made sv_bigcoords default except in quake. hexen2 kinda needs it for bsp angle precision.
fixed nq server to not stall weirdly on map changes.
fixed qwprogs svc_cdtrack not bugging out with nq clients on the server.
fixed restart command to load the last map run by the server, instead of start.bsp (when idle)
optimised d3d9 renderer a little. now uses less draw calls, especially with complex scenes. seems to get higher framerates than opengl now.
fixed d3d9 renderer to not bug out quite so much when run fullscreen (shader subsystem is now correctly initialised).
fixed a couple of bugs from font change. also now supports utf-8 in a few more places.
r_editlights_reload no longer generates rtlights inside the void. this resolves a few glitches (but should also help framerates a little).
fixed so corona-only lights won't generate shadowmaps and waste lots of time.
removed lots of #defines from qclib. I should never have made them in the first place, but I was lazy. obviously there's more left that I cba to remove yet.
fixed nested calls with variant-vectors. this fixes csaddon's light editor.
fixed qcc hc calling conventions using redundant stores.
disabled keywords can still be used by using __keyword instead.
fixed ftegccgui grep feature.
fixed motionless-dog qcc bug.
tweaked qcc warnings a little. -Wall is now a viable setting. you should be able to fix all those warnings.
fixed qw svc_intermission + dpp5+ clients bug.
fixed annoying spam about disconnecting in hexen2.
rewrote status command a little to cope with ipv6 addresses more gracefully
fixed significant stall when hibernating/debugging a server with a player sitting on it.
fixed truelightning.
fixed rocketlight overriding pflags.
fixed torches vanishing on vid_restart.
fixed issue with decal scaling.
fixed findentityfield builtin.
fixed fteqcc issue with ptr+1
fixed use of arrays inside class functions.
fixed/implemented fteqcc emulation of pointer opcodes.
added __inout keyword to fteqcc, so that it doesn't feel so horrendous.
fixed sizeof(*foo)
fixed *struct = struct;
fixed recursive structs.
fixed fteqcc warning report.
fixed sdl2 controller support, hopefully.
attempted to implement xinput, including per-player audio playback.
slightly fixed relaxed attitude to mouse focus when running fullscreen.
fixed weird warnings/errors with 'ent.arrayhead' terms. now generates sane errors.
implemented bindmaps (for csqc).
fixed crashing bug with eprint builtin.
implemented subset of music_playlist_* functionality. significant changes to music playback.
fixed some more dpcsqc compat.
fixed binds menu. now displays and accepts modifiers.
fixed issues with huge lightmaps.
fixed protocol determinism with dp clients connecting to fte servers. the initial getchallenge request now inhibits vanilla nq connection requests.
implemented support for 'dupe' userinfo key, allowing clients to request client->server packet duplication. should probably queue them tbh.
implemented sv_saveentfile command.
fixed resume after breaking inside a stepped-over function.
fixed erroneous footer after debugging.
(I wonder just how many things I broke with these fixes)
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@4946 fc73d0e0-1445-4013-8a0c-d673dee63da5
2015-07-26 10:56:18 +00:00
}
2012-02-12 05:18:31 +00:00
void CLDP_ParseDarkPlaces5Entities ( void ) //the things I do.. :o(
2004-11-27 08:16:25 +00:00
{
//the incoming entities do not come in in any order. :(
//well, they come in in order of priorities, but that's not useful to us.
//I guess this means we'll have to go slowly.
2012-01-28 10:30:44 +00:00
//dp deltas update in-place
//this gets in the way of tracking multiple frames, and thus doesn't match fte too well
Reworked client support for DPP5+. less code now, its much more graceful.
added waterfog command. waterfog overrides regular fog only when the view is in water.
fixed 64bit printf format specifiers. should work better on winxp64.
fixed some spec angle weirdness.
fixed viewsize 99.99 weirdness with ezhud.
fixed extra offset on the console (exhibited in 64bit builds, but not limited to).
fixed .avi playback, can now actually display frames again.
reimplemented line sparks.
fixed r_editlights_save flipping the light's pitch.
fixed issue with oggs failing to load.
fixed condump to cope with unicode properly.
made sv_bigcoords default except in quake. hexen2 kinda needs it for bsp angle precision.
fixed nq server to not stall weirdly on map changes.
fixed qwprogs svc_cdtrack not bugging out with nq clients on the server.
fixed restart command to load the last map run by the server, instead of start.bsp (when idle)
optimised d3d9 renderer a little. now uses less draw calls, especially with complex scenes. seems to get higher framerates than opengl now.
fixed d3d9 renderer to not bug out quite so much when run fullscreen (shader subsystem is now correctly initialised).
fixed a couple of bugs from font change. also now supports utf-8 in a few more places.
r_editlights_reload no longer generates rtlights inside the void. this resolves a few glitches (but should also help framerates a little).
fixed so corona-only lights won't generate shadowmaps and waste lots of time.
removed lots of #defines from qclib. I should never have made them in the first place, but I was lazy. obviously there's more left that I cba to remove yet.
fixed nested calls with variant-vectors. this fixes csaddon's light editor.
fixed qcc hc calling conventions using redundant stores.
disabled keywords can still be used by using __keyword instead.
fixed ftegccgui grep feature.
fixed motionless-dog qcc bug.
tweaked qcc warnings a little. -Wall is now a viable setting. you should be able to fix all those warnings.
fixed qw svc_intermission + dpp5+ clients bug.
fixed annoying spam about disconnecting in hexen2.
rewrote status command a little to cope with ipv6 addresses more gracefully
fixed significant stall when hibernating/debugging a server with a player sitting on it.
fixed truelightning.
fixed rocketlight overriding pflags.
fixed torches vanishing on vid_restart.
fixed issue with decal scaling.
fixed findentityfield builtin.
fixed fteqcc issue with ptr+1
fixed use of arrays inside class functions.
fixed/implemented fteqcc emulation of pointer opcodes.
added __inout keyword to fteqcc, so that it doesn't feel so horrendous.
fixed sizeof(*foo)
fixed *struct = struct;
fixed recursive structs.
fixed fteqcc warning report.
fixed sdl2 controller support, hopefully.
attempted to implement xinput, including per-player audio playback.
slightly fixed relaxed attitude to mouse focus when running fullscreen.
fixed weird warnings/errors with 'ent.arrayhead' terms. now generates sane errors.
implemented bindmaps (for csqc).
fixed crashing bug with eprint builtin.
implemented subset of music_playlist_* functionality. significant changes to music playback.
fixed some more dpcsqc compat.
fixed binds menu. now displays and accepts modifiers.
fixed issues with huge lightmaps.
fixed protocol determinism with dp clients connecting to fte servers. the initial getchallenge request now inhibits vanilla nq connection requests.
implemented support for 'dupe' userinfo key, allowing clients to request client->server packet duplication. should probably queue them tbh.
implemented sv_saveentfile command.
fixed resume after breaking inside a stepped-over function.
fixed erroneous footer after debugging.
(I wonder just how many things I broke with these fixes)
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@4946 fc73d0e0-1445-4013-8a0c-d673dee63da5
2015-07-26 10:56:18 +00:00
packet_entities_t * oldpack , * newpack ;
2004-11-27 08:16:25 +00:00
2005-02-06 02:47:36 +00:00
entity_state_t * to , * from ;
2013-05-11 05:03:07 +00:00
unsigned int read ;
Reworked client support for DPP5+. less code now, its much more graceful.
added waterfog command. waterfog overrides regular fog only when the view is in water.
fixed 64bit printf format specifiers. should work better on winxp64.
fixed some spec angle weirdness.
fixed viewsize 99.99 weirdness with ezhud.
fixed extra offset on the console (exhibited in 64bit builds, but not limited to).
fixed .avi playback, can now actually display frames again.
reimplemented line sparks.
fixed r_editlights_save flipping the light's pitch.
fixed issue with oggs failing to load.
fixed condump to cope with unicode properly.
made sv_bigcoords default except in quake. hexen2 kinda needs it for bsp angle precision.
fixed nq server to not stall weirdly on map changes.
fixed qwprogs svc_cdtrack not bugging out with nq clients on the server.
fixed restart command to load the last map run by the server, instead of start.bsp (when idle)
optimised d3d9 renderer a little. now uses less draw calls, especially with complex scenes. seems to get higher framerates than opengl now.
fixed d3d9 renderer to not bug out quite so much when run fullscreen (shader subsystem is now correctly initialised).
fixed a couple of bugs from font change. also now supports utf-8 in a few more places.
r_editlights_reload no longer generates rtlights inside the void. this resolves a few glitches (but should also help framerates a little).
fixed so corona-only lights won't generate shadowmaps and waste lots of time.
removed lots of #defines from qclib. I should never have made them in the first place, but I was lazy. obviously there's more left that I cba to remove yet.
fixed nested calls with variant-vectors. this fixes csaddon's light editor.
fixed qcc hc calling conventions using redundant stores.
disabled keywords can still be used by using __keyword instead.
fixed ftegccgui grep feature.
fixed motionless-dog qcc bug.
tweaked qcc warnings a little. -Wall is now a viable setting. you should be able to fix all those warnings.
fixed qw svc_intermission + dpp5+ clients bug.
fixed annoying spam about disconnecting in hexen2.
rewrote status command a little to cope with ipv6 addresses more gracefully
fixed significant stall when hibernating/debugging a server with a player sitting on it.
fixed truelightning.
fixed rocketlight overriding pflags.
fixed torches vanishing on vid_restart.
fixed issue with decal scaling.
fixed findentityfield builtin.
fixed fteqcc issue with ptr+1
fixed use of arrays inside class functions.
fixed/implemented fteqcc emulation of pointer opcodes.
added __inout keyword to fteqcc, so that it doesn't feel so horrendous.
fixed sizeof(*foo)
fixed *struct = struct;
fixed recursive structs.
fixed fteqcc warning report.
fixed sdl2 controller support, hopefully.
attempted to implement xinput, including per-player audio playback.
slightly fixed relaxed attitude to mouse focus when running fullscreen.
fixed weird warnings/errors with 'ent.arrayhead' terms. now generates sane errors.
implemented bindmaps (for csqc).
fixed crashing bug with eprint builtin.
implemented subset of music_playlist_* functionality. significant changes to music playback.
fixed some more dpcsqc compat.
fixed binds menu. now displays and accepts modifiers.
fixed issues with huge lightmaps.
fixed protocol determinism with dp clients connecting to fte servers. the initial getchallenge request now inhibits vanilla nq connection requests.
implemented support for 'dupe' userinfo key, allowing clients to request client->server packet duplication. should probably queue them tbh.
implemented sv_saveentfile command.
fixed resume after breaking inside a stepped-over function.
fixed erroneous footer after debugging.
(I wonder just how many things I broke with these fixes)
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@4946 fc73d0e0-1445-4013-8a0c-d673dee63da5
2015-07-26 10:56:18 +00:00
int oldi ;
2004-11-27 08:16:25 +00:00
qboolean remove ;
2013-07-26 17:19:06 +00:00
//server->client sequence
2013-03-12 22:35:33 +00:00
if ( cl . numackframes = = sizeof ( cl . ackframes ) / sizeof ( cl . ackframes [ 0 ] ) )
cl . numackframes - - ;
cl . ackframes [ cl . numackframes + + ] = MSG_ReadLong ( ) ; /*server sequence to be acked*/
2004-11-27 08:16:25 +00:00
2013-07-26 17:19:06 +00:00
//client->server sequence ack
Fixes, workarounds, and breakages. Hexen2 should work much better (-hexen2 says no mission pack, -portals says h2mp). Started working on splitting bigcoords per client, far too much work still to go on that. Removed gl_ztrick entirely. Enabled csprogs download by default. Added client support for fitzquake's 666 protocol, needs testing, some cleanup for dp protocols too, no server support, couldn't selectively enable it anyway. Now attempting to cache shadow meshes for explosions and stuff. Played with lightmaps a little, should potentially run a little faster on certain (intel?) cards. Tweeked npfte a little to try to avoid deadlocks and crashes. Fixed sky worldspawn parsing. Added h2mp's model format. Fixed baseline issue in q2 client, made servers generate q2 baselines. MOVETYPE_PUSH will not rotate extra if rotation is forced. Made status command show allowed client types. Changed lighting on weapons - should now be shaded.
git-svn-id: https://svn.code.sf.net/p/fteqw/code/branches/wip@3572 fc73d0e0-1445-4013-8a0c-d673dee63da5
2010-08-11 03:36:31 +00:00
if ( cls . protocol_nq > = CPNQ_DP7 )
2013-09-06 22:57:44 +00:00
CL_AckedInputFrame ( cls . netchan . incoming_sequence , MSG_ReadLong ( ) , true ) ; /*client input sequence which has been acked*/
2005-05-26 12:55:34 +00:00
Reworked client support for DPP5+. less code now, its much more graceful.
added waterfog command. waterfog overrides regular fog only when the view is in water.
fixed 64bit printf format specifiers. should work better on winxp64.
fixed some spec angle weirdness.
fixed viewsize 99.99 weirdness with ezhud.
fixed extra offset on the console (exhibited in 64bit builds, but not limited to).
fixed .avi playback, can now actually display frames again.
reimplemented line sparks.
fixed r_editlights_save flipping the light's pitch.
fixed issue with oggs failing to load.
fixed condump to cope with unicode properly.
made sv_bigcoords default except in quake. hexen2 kinda needs it for bsp angle precision.
fixed nq server to not stall weirdly on map changes.
fixed qwprogs svc_cdtrack not bugging out with nq clients on the server.
fixed restart command to load the last map run by the server, instead of start.bsp (when idle)
optimised d3d9 renderer a little. now uses less draw calls, especially with complex scenes. seems to get higher framerates than opengl now.
fixed d3d9 renderer to not bug out quite so much when run fullscreen (shader subsystem is now correctly initialised).
fixed a couple of bugs from font change. also now supports utf-8 in a few more places.
r_editlights_reload no longer generates rtlights inside the void. this resolves a few glitches (but should also help framerates a little).
fixed so corona-only lights won't generate shadowmaps and waste lots of time.
removed lots of #defines from qclib. I should never have made them in the first place, but I was lazy. obviously there's more left that I cba to remove yet.
fixed nested calls with variant-vectors. this fixes csaddon's light editor.
fixed qcc hc calling conventions using redundant stores.
disabled keywords can still be used by using __keyword instead.
fixed ftegccgui grep feature.
fixed motionless-dog qcc bug.
tweaked qcc warnings a little. -Wall is now a viable setting. you should be able to fix all those warnings.
fixed qw svc_intermission + dpp5+ clients bug.
fixed annoying spam about disconnecting in hexen2.
rewrote status command a little to cope with ipv6 addresses more gracefully
fixed significant stall when hibernating/debugging a server with a player sitting on it.
fixed truelightning.
fixed rocketlight overriding pflags.
fixed torches vanishing on vid_restart.
fixed issue with decal scaling.
fixed findentityfield builtin.
fixed fteqcc issue with ptr+1
fixed use of arrays inside class functions.
fixed/implemented fteqcc emulation of pointer opcodes.
added __inout keyword to fteqcc, so that it doesn't feel so horrendous.
fixed sizeof(*foo)
fixed *struct = struct;
fixed recursive structs.
fixed fteqcc warning report.
fixed sdl2 controller support, hopefully.
attempted to implement xinput, including per-player audio playback.
slightly fixed relaxed attitude to mouse focus when running fullscreen.
fixed weird warnings/errors with 'ent.arrayhead' terms. now generates sane errors.
implemented bindmaps (for csqc).
fixed crashing bug with eprint builtin.
implemented subset of music_playlist_* functionality. significant changes to music playback.
fixed some more dpcsqc compat.
fixed binds menu. now displays and accepts modifiers.
fixed issues with huge lightmaps.
fixed protocol determinism with dp clients connecting to fte servers. the initial getchallenge request now inhibits vanilla nq connection requests.
implemented support for 'dupe' userinfo key, allowing clients to request client->server packet duplication. should probably queue them tbh.
implemented sv_saveentfile command.
fixed resume after breaking inside a stepped-over function.
fixed erroneous footer after debugging.
(I wonder just how many things I broke with these fixes)
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@4946 fc73d0e0-1445-4013-8a0c-d673dee63da5
2015-07-26 10:56:18 +00:00
if ( cl . validsequence )
oldpack = & cl . inframes [ ( cl . validsequence ) & UPDATE_MASK ] . packet_entities ;
else
oldpack = NULL ;
cl . validsequence = cls . netchan . incoming_sequence ;
2013-03-12 22:53:23 +00:00
cl . inframes [ ( cls . netchan . incoming_sequence ) & UPDATE_MASK ] . receivedtime = realtime ;
2013-09-06 22:57:44 +00:00
cl . inframes [ ( cls . netchan . incoming_sequence ) & UPDATE_MASK ] . frameid = cls . netchan . incoming_sequence ;
Reworked client support for DPP5+. less code now, its much more graceful.
added waterfog command. waterfog overrides regular fog only when the view is in water.
fixed 64bit printf format specifiers. should work better on winxp64.
fixed some spec angle weirdness.
fixed viewsize 99.99 weirdness with ezhud.
fixed extra offset on the console (exhibited in 64bit builds, but not limited to).
fixed .avi playback, can now actually display frames again.
reimplemented line sparks.
fixed r_editlights_save flipping the light's pitch.
fixed issue with oggs failing to load.
fixed condump to cope with unicode properly.
made sv_bigcoords default except in quake. hexen2 kinda needs it for bsp angle precision.
fixed nq server to not stall weirdly on map changes.
fixed qwprogs svc_cdtrack not bugging out with nq clients on the server.
fixed restart command to load the last map run by the server, instead of start.bsp (when idle)
optimised d3d9 renderer a little. now uses less draw calls, especially with complex scenes. seems to get higher framerates than opengl now.
fixed d3d9 renderer to not bug out quite so much when run fullscreen (shader subsystem is now correctly initialised).
fixed a couple of bugs from font change. also now supports utf-8 in a few more places.
r_editlights_reload no longer generates rtlights inside the void. this resolves a few glitches (but should also help framerates a little).
fixed so corona-only lights won't generate shadowmaps and waste lots of time.
removed lots of #defines from qclib. I should never have made them in the first place, but I was lazy. obviously there's more left that I cba to remove yet.
fixed nested calls with variant-vectors. this fixes csaddon's light editor.
fixed qcc hc calling conventions using redundant stores.
disabled keywords can still be used by using __keyword instead.
fixed ftegccgui grep feature.
fixed motionless-dog qcc bug.
tweaked qcc warnings a little. -Wall is now a viable setting. you should be able to fix all those warnings.
fixed qw svc_intermission + dpp5+ clients bug.
fixed annoying spam about disconnecting in hexen2.
rewrote status command a little to cope with ipv6 addresses more gracefully
fixed significant stall when hibernating/debugging a server with a player sitting on it.
fixed truelightning.
fixed rocketlight overriding pflags.
fixed torches vanishing on vid_restart.
fixed issue with decal scaling.
fixed findentityfield builtin.
fixed fteqcc issue with ptr+1
fixed use of arrays inside class functions.
fixed/implemented fteqcc emulation of pointer opcodes.
added __inout keyword to fteqcc, so that it doesn't feel so horrendous.
fixed sizeof(*foo)
fixed *struct = struct;
fixed recursive structs.
fixed fteqcc warning report.
fixed sdl2 controller support, hopefully.
attempted to implement xinput, including per-player audio playback.
slightly fixed relaxed attitude to mouse focus when running fullscreen.
fixed weird warnings/errors with 'ent.arrayhead' terms. now generates sane errors.
implemented bindmaps (for csqc).
fixed crashing bug with eprint builtin.
implemented subset of music_playlist_* functionality. significant changes to music playback.
fixed some more dpcsqc compat.
fixed binds menu. now displays and accepts modifiers.
fixed issues with huge lightmaps.
fixed protocol determinism with dp clients connecting to fte servers. the initial getchallenge request now inhibits vanilla nq connection requests.
implemented support for 'dupe' userinfo key, allowing clients to request client->server packet duplication. should probably queue them tbh.
implemented sv_saveentfile command.
fixed resume after breaking inside a stepped-over function.
fixed erroneous footer after debugging.
(I wonder just how many things I broke with these fixes)
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@4946 fc73d0e0-1445-4013-8a0c-d673dee63da5
2015-07-26 10:56:18 +00:00
newpack = & cl . inframes [ ( cls . netchan . incoming_sequence ) & UPDATE_MASK ] . packet_entities ;
newpack - > servertime = cl . gametime ;
//copy old state to new state
if ( newpack ! = oldpack )
{
if ( oldpack )
{
newpack - > num_entities = oldpack - > num_entities ;
newpack - > max_entities = newpack - > num_entities + 16 ; //for slop for new ents, to reduce reallocs
newpack - > entities = BZ_Realloc ( newpack - > entities , sizeof ( entity_state_t ) * newpack - > max_entities ) ;
memcpy ( newpack - > entities , oldpack - > entities , sizeof ( entity_state_t ) * newpack - > num_entities ) ;
}
else
newpack - > num_entities = 0 ;
2016-07-12 00:40:13 +00:00
newpack - > bonedatacur = 0 ;
//flag them all as having old bones
//they'll be renewed after parsing
for ( oldi = 0 ; oldi < newpack - > num_entities ; oldi + + )
newpack - > entities [ oldi ] . boneoffset | = 0x80000000 ;
Reworked client support for DPP5+. less code now, its much more graceful.
added waterfog command. waterfog overrides regular fog only when the view is in water.
fixed 64bit printf format specifiers. should work better on winxp64.
fixed some spec angle weirdness.
fixed viewsize 99.99 weirdness with ezhud.
fixed extra offset on the console (exhibited in 64bit builds, but not limited to).
fixed .avi playback, can now actually display frames again.
reimplemented line sparks.
fixed r_editlights_save flipping the light's pitch.
fixed issue with oggs failing to load.
fixed condump to cope with unicode properly.
made sv_bigcoords default except in quake. hexen2 kinda needs it for bsp angle precision.
fixed nq server to not stall weirdly on map changes.
fixed qwprogs svc_cdtrack not bugging out with nq clients on the server.
fixed restart command to load the last map run by the server, instead of start.bsp (when idle)
optimised d3d9 renderer a little. now uses less draw calls, especially with complex scenes. seems to get higher framerates than opengl now.
fixed d3d9 renderer to not bug out quite so much when run fullscreen (shader subsystem is now correctly initialised).
fixed a couple of bugs from font change. also now supports utf-8 in a few more places.
r_editlights_reload no longer generates rtlights inside the void. this resolves a few glitches (but should also help framerates a little).
fixed so corona-only lights won't generate shadowmaps and waste lots of time.
removed lots of #defines from qclib. I should never have made them in the first place, but I was lazy. obviously there's more left that I cba to remove yet.
fixed nested calls with variant-vectors. this fixes csaddon's light editor.
fixed qcc hc calling conventions using redundant stores.
disabled keywords can still be used by using __keyword instead.
fixed ftegccgui grep feature.
fixed motionless-dog qcc bug.
tweaked qcc warnings a little. -Wall is now a viable setting. you should be able to fix all those warnings.
fixed qw svc_intermission + dpp5+ clients bug.
fixed annoying spam about disconnecting in hexen2.
rewrote status command a little to cope with ipv6 addresses more gracefully
fixed significant stall when hibernating/debugging a server with a player sitting on it.
fixed truelightning.
fixed rocketlight overriding pflags.
fixed torches vanishing on vid_restart.
fixed issue with decal scaling.
fixed findentityfield builtin.
fixed fteqcc issue with ptr+1
fixed use of arrays inside class functions.
fixed/implemented fteqcc emulation of pointer opcodes.
added __inout keyword to fteqcc, so that it doesn't feel so horrendous.
fixed sizeof(*foo)
fixed *struct = struct;
fixed recursive structs.
fixed fteqcc warning report.
fixed sdl2 controller support, hopefully.
attempted to implement xinput, including per-player audio playback.
slightly fixed relaxed attitude to mouse focus when running fullscreen.
fixed weird warnings/errors with 'ent.arrayhead' terms. now generates sane errors.
implemented bindmaps (for csqc).
fixed crashing bug with eprint builtin.
implemented subset of music_playlist_* functionality. significant changes to music playback.
fixed some more dpcsqc compat.
fixed binds menu. now displays and accepts modifiers.
fixed issues with huge lightmaps.
fixed protocol determinism with dp clients connecting to fte servers. the initial getchallenge request now inhibits vanilla nq connection requests.
implemented support for 'dupe' userinfo key, allowing clients to request client->server packet duplication. should probably queue them tbh.
implemented sv_saveentfile command.
fixed resume after breaking inside a stepped-over function.
fixed erroneous footer after debugging.
(I wonder just how many things I broke with these fixes)
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@4946 fc73d0e0-1445-4013-8a0c-d673dee63da5
2015-07-26 10:56:18 +00:00
}
2004-11-27 08:16:25 +00:00
2013-05-11 05:03:07 +00:00
for ( ; ; )
2004-11-27 08:16:25 +00:00
{
2013-05-11 05:03:07 +00:00
read = MSG_ReadShort ( ) ;
2004-11-27 08:16:25 +00:00
if ( msg_badread )
2015-09-06 03:30:28 +00:00
Host_EndGame ( " Corrupt entity message packet \n " ) ;
2004-11-27 08:16:25 +00:00
remove = ! ! ( read & 0x8000 ) ;
2013-05-11 05:03:07 +00:00
read & = 0x7fff ;
if ( remove & & ! read )
break ; //remove world signals end of packet.
2004-11-27 08:16:25 +00:00
2005-08-26 22:56:51 +00:00
if ( read > = MAX_EDICTS )
Host_EndGame ( " Too many entities. \n " ) ;
2013-03-12 23:09:25 +00:00
from = & nullentitystate ;
Reworked client support for DPP5+. less code now, its much more graceful.
added waterfog command. waterfog overrides regular fog only when the view is in water.
fixed 64bit printf format specifiers. should work better on winxp64.
fixed some spec angle weirdness.
fixed viewsize 99.99 weirdness with ezhud.
fixed extra offset on the console (exhibited in 64bit builds, but not limited to).
fixed .avi playback, can now actually display frames again.
reimplemented line sparks.
fixed r_editlights_save flipping the light's pitch.
fixed issue with oggs failing to load.
fixed condump to cope with unicode properly.
made sv_bigcoords default except in quake. hexen2 kinda needs it for bsp angle precision.
fixed nq server to not stall weirdly on map changes.
fixed qwprogs svc_cdtrack not bugging out with nq clients on the server.
fixed restart command to load the last map run by the server, instead of start.bsp (when idle)
optimised d3d9 renderer a little. now uses less draw calls, especially with complex scenes. seems to get higher framerates than opengl now.
fixed d3d9 renderer to not bug out quite so much when run fullscreen (shader subsystem is now correctly initialised).
fixed a couple of bugs from font change. also now supports utf-8 in a few more places.
r_editlights_reload no longer generates rtlights inside the void. this resolves a few glitches (but should also help framerates a little).
fixed so corona-only lights won't generate shadowmaps and waste lots of time.
removed lots of #defines from qclib. I should never have made them in the first place, but I was lazy. obviously there's more left that I cba to remove yet.
fixed nested calls with variant-vectors. this fixes csaddon's light editor.
fixed qcc hc calling conventions using redundant stores.
disabled keywords can still be used by using __keyword instead.
fixed ftegccgui grep feature.
fixed motionless-dog qcc bug.
tweaked qcc warnings a little. -Wall is now a viable setting. you should be able to fix all those warnings.
fixed qw svc_intermission + dpp5+ clients bug.
fixed annoying spam about disconnecting in hexen2.
rewrote status command a little to cope with ipv6 addresses more gracefully
fixed significant stall when hibernating/debugging a server with a player sitting on it.
fixed truelightning.
fixed rocketlight overriding pflags.
fixed torches vanishing on vid_restart.
fixed issue with decal scaling.
fixed findentityfield builtin.
fixed fteqcc issue with ptr+1
fixed use of arrays inside class functions.
fixed/implemented fteqcc emulation of pointer opcodes.
added __inout keyword to fteqcc, so that it doesn't feel so horrendous.
fixed sizeof(*foo)
fixed *struct = struct;
fixed recursive structs.
fixed fteqcc warning report.
fixed sdl2 controller support, hopefully.
attempted to implement xinput, including per-player audio playback.
slightly fixed relaxed attitude to mouse focus when running fullscreen.
fixed weird warnings/errors with 'ent.arrayhead' terms. now generates sane errors.
implemented bindmaps (for csqc).
fixed crashing bug with eprint builtin.
implemented subset of music_playlist_* functionality. significant changes to music playback.
fixed some more dpcsqc compat.
fixed binds menu. now displays and accepts modifiers.
fixed issues with huge lightmaps.
fixed protocol determinism with dp clients connecting to fte servers. the initial getchallenge request now inhibits vanilla nq connection requests.
implemented support for 'dupe' userinfo key, allowing clients to request client->server packet duplication. should probably queue them tbh.
implemented sv_saveentfile command.
fixed resume after breaking inside a stepped-over function.
fixed erroneous footer after debugging.
(I wonder just how many things I broke with these fixes)
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@4946 fc73d0e0-1445-4013-8a0c-d673dee63da5
2015-07-26 10:56:18 +00:00
to = NULL ;
2004-11-27 08:16:25 +00:00
Reworked client support for DPP5+. less code now, its much more graceful.
added waterfog command. waterfog overrides regular fog only when the view is in water.
fixed 64bit printf format specifiers. should work better on winxp64.
fixed some spec angle weirdness.
fixed viewsize 99.99 weirdness with ezhud.
fixed extra offset on the console (exhibited in 64bit builds, but not limited to).
fixed .avi playback, can now actually display frames again.
reimplemented line sparks.
fixed r_editlights_save flipping the light's pitch.
fixed issue with oggs failing to load.
fixed condump to cope with unicode properly.
made sv_bigcoords default except in quake. hexen2 kinda needs it for bsp angle precision.
fixed nq server to not stall weirdly on map changes.
fixed qwprogs svc_cdtrack not bugging out with nq clients on the server.
fixed restart command to load the last map run by the server, instead of start.bsp (when idle)
optimised d3d9 renderer a little. now uses less draw calls, especially with complex scenes. seems to get higher framerates than opengl now.
fixed d3d9 renderer to not bug out quite so much when run fullscreen (shader subsystem is now correctly initialised).
fixed a couple of bugs from font change. also now supports utf-8 in a few more places.
r_editlights_reload no longer generates rtlights inside the void. this resolves a few glitches (but should also help framerates a little).
fixed so corona-only lights won't generate shadowmaps and waste lots of time.
removed lots of #defines from qclib. I should never have made them in the first place, but I was lazy. obviously there's more left that I cba to remove yet.
fixed nested calls with variant-vectors. this fixes csaddon's light editor.
fixed qcc hc calling conventions using redundant stores.
disabled keywords can still be used by using __keyword instead.
fixed ftegccgui grep feature.
fixed motionless-dog qcc bug.
tweaked qcc warnings a little. -Wall is now a viable setting. you should be able to fix all those warnings.
fixed qw svc_intermission + dpp5+ clients bug.
fixed annoying spam about disconnecting in hexen2.
rewrote status command a little to cope with ipv6 addresses more gracefully
fixed significant stall when hibernating/debugging a server with a player sitting on it.
fixed truelightning.
fixed rocketlight overriding pflags.
fixed torches vanishing on vid_restart.
fixed issue with decal scaling.
fixed findentityfield builtin.
fixed fteqcc issue with ptr+1
fixed use of arrays inside class functions.
fixed/implemented fteqcc emulation of pointer opcodes.
added __inout keyword to fteqcc, so that it doesn't feel so horrendous.
fixed sizeof(*foo)
fixed *struct = struct;
fixed recursive structs.
fixed fteqcc warning report.
fixed sdl2 controller support, hopefully.
attempted to implement xinput, including per-player audio playback.
slightly fixed relaxed attitude to mouse focus when running fullscreen.
fixed weird warnings/errors with 'ent.arrayhead' terms. now generates sane errors.
implemented bindmaps (for csqc).
fixed crashing bug with eprint builtin.
implemented subset of music_playlist_* functionality. significant changes to music playback.
fixed some more dpcsqc compat.
fixed binds menu. now displays and accepts modifiers.
fixed issues with huge lightmaps.
fixed protocol determinism with dp clients connecting to fte servers. the initial getchallenge request now inhibits vanilla nq connection requests.
implemented support for 'dupe' userinfo key, allowing clients to request client->server packet duplication. should probably queue them tbh.
implemented sv_saveentfile command.
fixed resume after breaking inside a stepped-over function.
fixed erroneous footer after debugging.
(I wonder just how many things I broke with these fixes)
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@4946 fc73d0e0-1445-4013-8a0c-d673dee63da5
2015-07-26 10:56:18 +00:00
for ( oldi = 0 ; oldi < newpack - > num_entities ; oldi + + )
2004-11-27 08:16:25 +00:00
{
Reworked client support for DPP5+. less code now, its much more graceful.
added waterfog command. waterfog overrides regular fog only when the view is in water.
fixed 64bit printf format specifiers. should work better on winxp64.
fixed some spec angle weirdness.
fixed viewsize 99.99 weirdness with ezhud.
fixed extra offset on the console (exhibited in 64bit builds, but not limited to).
fixed .avi playback, can now actually display frames again.
reimplemented line sparks.
fixed r_editlights_save flipping the light's pitch.
fixed issue with oggs failing to load.
fixed condump to cope with unicode properly.
made sv_bigcoords default except in quake. hexen2 kinda needs it for bsp angle precision.
fixed nq server to not stall weirdly on map changes.
fixed qwprogs svc_cdtrack not bugging out with nq clients on the server.
fixed restart command to load the last map run by the server, instead of start.bsp (when idle)
optimised d3d9 renderer a little. now uses less draw calls, especially with complex scenes. seems to get higher framerates than opengl now.
fixed d3d9 renderer to not bug out quite so much when run fullscreen (shader subsystem is now correctly initialised).
fixed a couple of bugs from font change. also now supports utf-8 in a few more places.
r_editlights_reload no longer generates rtlights inside the void. this resolves a few glitches (but should also help framerates a little).
fixed so corona-only lights won't generate shadowmaps and waste lots of time.
removed lots of #defines from qclib. I should never have made them in the first place, but I was lazy. obviously there's more left that I cba to remove yet.
fixed nested calls with variant-vectors. this fixes csaddon's light editor.
fixed qcc hc calling conventions using redundant stores.
disabled keywords can still be used by using __keyword instead.
fixed ftegccgui grep feature.
fixed motionless-dog qcc bug.
tweaked qcc warnings a little. -Wall is now a viable setting. you should be able to fix all those warnings.
fixed qw svc_intermission + dpp5+ clients bug.
fixed annoying spam about disconnecting in hexen2.
rewrote status command a little to cope with ipv6 addresses more gracefully
fixed significant stall when hibernating/debugging a server with a player sitting on it.
fixed truelightning.
fixed rocketlight overriding pflags.
fixed torches vanishing on vid_restart.
fixed issue with decal scaling.
fixed findentityfield builtin.
fixed fteqcc issue with ptr+1
fixed use of arrays inside class functions.
fixed/implemented fteqcc emulation of pointer opcodes.
added __inout keyword to fteqcc, so that it doesn't feel so horrendous.
fixed sizeof(*foo)
fixed *struct = struct;
fixed recursive structs.
fixed fteqcc warning report.
fixed sdl2 controller support, hopefully.
attempted to implement xinput, including per-player audio playback.
slightly fixed relaxed attitude to mouse focus when running fullscreen.
fixed weird warnings/errors with 'ent.arrayhead' terms. now generates sane errors.
implemented bindmaps (for csqc).
fixed crashing bug with eprint builtin.
implemented subset of music_playlist_* functionality. significant changes to music playback.
fixed some more dpcsqc compat.
fixed binds menu. now displays and accepts modifiers.
fixed issues with huge lightmaps.
fixed protocol determinism with dp clients connecting to fte servers. the initial getchallenge request now inhibits vanilla nq connection requests.
implemented support for 'dupe' userinfo key, allowing clients to request client->server packet duplication. should probably queue them tbh.
implemented sv_saveentfile command.
fixed resume after breaking inside a stepped-over function.
fixed erroneous footer after debugging.
(I wonder just how many things I broke with these fixes)
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@4946 fc73d0e0-1445-4013-8a0c-d673dee63da5
2015-07-26 10:56:18 +00:00
if ( read = = newpack - > entities [ oldi ] . number )
2004-11-27 08:16:25 +00:00
{
Reworked client support for DPP5+. less code now, its much more graceful.
added waterfog command. waterfog overrides regular fog only when the view is in water.
fixed 64bit printf format specifiers. should work better on winxp64.
fixed some spec angle weirdness.
fixed viewsize 99.99 weirdness with ezhud.
fixed extra offset on the console (exhibited in 64bit builds, but not limited to).
fixed .avi playback, can now actually display frames again.
reimplemented line sparks.
fixed r_editlights_save flipping the light's pitch.
fixed issue with oggs failing to load.
fixed condump to cope with unicode properly.
made sv_bigcoords default except in quake. hexen2 kinda needs it for bsp angle precision.
fixed nq server to not stall weirdly on map changes.
fixed qwprogs svc_cdtrack not bugging out with nq clients on the server.
fixed restart command to load the last map run by the server, instead of start.bsp (when idle)
optimised d3d9 renderer a little. now uses less draw calls, especially with complex scenes. seems to get higher framerates than opengl now.
fixed d3d9 renderer to not bug out quite so much when run fullscreen (shader subsystem is now correctly initialised).
fixed a couple of bugs from font change. also now supports utf-8 in a few more places.
r_editlights_reload no longer generates rtlights inside the void. this resolves a few glitches (but should also help framerates a little).
fixed so corona-only lights won't generate shadowmaps and waste lots of time.
removed lots of #defines from qclib. I should never have made them in the first place, but I was lazy. obviously there's more left that I cba to remove yet.
fixed nested calls with variant-vectors. this fixes csaddon's light editor.
fixed qcc hc calling conventions using redundant stores.
disabled keywords can still be used by using __keyword instead.
fixed ftegccgui grep feature.
fixed motionless-dog qcc bug.
tweaked qcc warnings a little. -Wall is now a viable setting. you should be able to fix all those warnings.
fixed qw svc_intermission + dpp5+ clients bug.
fixed annoying spam about disconnecting in hexen2.
rewrote status command a little to cope with ipv6 addresses more gracefully
fixed significant stall when hibernating/debugging a server with a player sitting on it.
fixed truelightning.
fixed rocketlight overriding pflags.
fixed torches vanishing on vid_restart.
fixed issue with decal scaling.
fixed findentityfield builtin.
fixed fteqcc issue with ptr+1
fixed use of arrays inside class functions.
fixed/implemented fteqcc emulation of pointer opcodes.
added __inout keyword to fteqcc, so that it doesn't feel so horrendous.
fixed sizeof(*foo)
fixed *struct = struct;
fixed recursive structs.
fixed fteqcc warning report.
fixed sdl2 controller support, hopefully.
attempted to implement xinput, including per-player audio playback.
slightly fixed relaxed attitude to mouse focus when running fullscreen.
fixed weird warnings/errors with 'ent.arrayhead' terms. now generates sane errors.
implemented bindmaps (for csqc).
fixed crashing bug with eprint builtin.
implemented subset of music_playlist_* functionality. significant changes to music playback.
fixed some more dpcsqc compat.
fixed binds menu. now displays and accepts modifiers.
fixed issues with huge lightmaps.
fixed protocol determinism with dp clients connecting to fte servers. the initial getchallenge request now inhibits vanilla nq connection requests.
implemented support for 'dupe' userinfo key, allowing clients to request client->server packet duplication. should probably queue them tbh.
implemented sv_saveentfile command.
fixed resume after breaking inside a stepped-over function.
fixed erroneous footer after debugging.
(I wonder just how many things I broke with these fixes)
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@4946 fc73d0e0-1445-4013-8a0c-d673dee63da5
2015-07-26 10:56:18 +00:00
from = & newpack - > entities [ oldi ] ;
to = & newpack - > entities [ oldi ] ;
2004-11-27 08:16:25 +00:00
break ;
}
}
Reworked client support for DPP5+. less code now, its much more graceful.
added waterfog command. waterfog overrides regular fog only when the view is in water.
fixed 64bit printf format specifiers. should work better on winxp64.
fixed some spec angle weirdness.
fixed viewsize 99.99 weirdness with ezhud.
fixed extra offset on the console (exhibited in 64bit builds, but not limited to).
fixed .avi playback, can now actually display frames again.
reimplemented line sparks.
fixed r_editlights_save flipping the light's pitch.
fixed issue with oggs failing to load.
fixed condump to cope with unicode properly.
made sv_bigcoords default except in quake. hexen2 kinda needs it for bsp angle precision.
fixed nq server to not stall weirdly on map changes.
fixed qwprogs svc_cdtrack not bugging out with nq clients on the server.
fixed restart command to load the last map run by the server, instead of start.bsp (when idle)
optimised d3d9 renderer a little. now uses less draw calls, especially with complex scenes. seems to get higher framerates than opengl now.
fixed d3d9 renderer to not bug out quite so much when run fullscreen (shader subsystem is now correctly initialised).
fixed a couple of bugs from font change. also now supports utf-8 in a few more places.
r_editlights_reload no longer generates rtlights inside the void. this resolves a few glitches (but should also help framerates a little).
fixed so corona-only lights won't generate shadowmaps and waste lots of time.
removed lots of #defines from qclib. I should never have made them in the first place, but I was lazy. obviously there's more left that I cba to remove yet.
fixed nested calls with variant-vectors. this fixes csaddon's light editor.
fixed qcc hc calling conventions using redundant stores.
disabled keywords can still be used by using __keyword instead.
fixed ftegccgui grep feature.
fixed motionless-dog qcc bug.
tweaked qcc warnings a little. -Wall is now a viable setting. you should be able to fix all those warnings.
fixed qw svc_intermission + dpp5+ clients bug.
fixed annoying spam about disconnecting in hexen2.
rewrote status command a little to cope with ipv6 addresses more gracefully
fixed significant stall when hibernating/debugging a server with a player sitting on it.
fixed truelightning.
fixed rocketlight overriding pflags.
fixed torches vanishing on vid_restart.
fixed issue with decal scaling.
fixed findentityfield builtin.
fixed fteqcc issue with ptr+1
fixed use of arrays inside class functions.
fixed/implemented fteqcc emulation of pointer opcodes.
added __inout keyword to fteqcc, so that it doesn't feel so horrendous.
fixed sizeof(*foo)
fixed *struct = struct;
fixed recursive structs.
fixed fteqcc warning report.
fixed sdl2 controller support, hopefully.
attempted to implement xinput, including per-player audio playback.
slightly fixed relaxed attitude to mouse focus when running fullscreen.
fixed weird warnings/errors with 'ent.arrayhead' terms. now generates sane errors.
implemented bindmaps (for csqc).
fixed crashing bug with eprint builtin.
implemented subset of music_playlist_* functionality. significant changes to music playback.
fixed some more dpcsqc compat.
fixed binds menu. now displays and accepts modifiers.
fixed issues with huge lightmaps.
fixed protocol determinism with dp clients connecting to fte servers. the initial getchallenge request now inhibits vanilla nq connection requests.
implemented support for 'dupe' userinfo key, allowing clients to request client->server packet duplication. should probably queue them tbh.
implemented sv_saveentfile command.
fixed resume after breaking inside a stepped-over function.
fixed erroneous footer after debugging.
(I wonder just how many things I broke with these fixes)
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@4946 fc73d0e0-1445-4013-8a0c-d673dee63da5
2015-07-26 10:56:18 +00:00
if ( ! to )
{ //okay, so this is new
if ( newpack - > num_entities = = newpack - > max_entities )
{
newpack - > max_entities = newpack - > num_entities + 16 ;
newpack - > entities = BZ_Realloc ( newpack - > entities , sizeof ( entity_state_t ) * newpack - > max_entities ) ;
}
2004-11-27 08:16:25 +00:00
Reworked client support for DPP5+. less code now, its much more graceful.
added waterfog command. waterfog overrides regular fog only when the view is in water.
fixed 64bit printf format specifiers. should work better on winxp64.
fixed some spec angle weirdness.
fixed viewsize 99.99 weirdness with ezhud.
fixed extra offset on the console (exhibited in 64bit builds, but not limited to).
fixed .avi playback, can now actually display frames again.
reimplemented line sparks.
fixed r_editlights_save flipping the light's pitch.
fixed issue with oggs failing to load.
fixed condump to cope with unicode properly.
made sv_bigcoords default except in quake. hexen2 kinda needs it for bsp angle precision.
fixed nq server to not stall weirdly on map changes.
fixed qwprogs svc_cdtrack not bugging out with nq clients on the server.
fixed restart command to load the last map run by the server, instead of start.bsp (when idle)
optimised d3d9 renderer a little. now uses less draw calls, especially with complex scenes. seems to get higher framerates than opengl now.
fixed d3d9 renderer to not bug out quite so much when run fullscreen (shader subsystem is now correctly initialised).
fixed a couple of bugs from font change. also now supports utf-8 in a few more places.
r_editlights_reload no longer generates rtlights inside the void. this resolves a few glitches (but should also help framerates a little).
fixed so corona-only lights won't generate shadowmaps and waste lots of time.
removed lots of #defines from qclib. I should never have made them in the first place, but I was lazy. obviously there's more left that I cba to remove yet.
fixed nested calls with variant-vectors. this fixes csaddon's light editor.
fixed qcc hc calling conventions using redundant stores.
disabled keywords can still be used by using __keyword instead.
fixed ftegccgui grep feature.
fixed motionless-dog qcc bug.
tweaked qcc warnings a little. -Wall is now a viable setting. you should be able to fix all those warnings.
fixed qw svc_intermission + dpp5+ clients bug.
fixed annoying spam about disconnecting in hexen2.
rewrote status command a little to cope with ipv6 addresses more gracefully
fixed significant stall when hibernating/debugging a server with a player sitting on it.
fixed truelightning.
fixed rocketlight overriding pflags.
fixed torches vanishing on vid_restart.
fixed issue with decal scaling.
fixed findentityfield builtin.
fixed fteqcc issue with ptr+1
fixed use of arrays inside class functions.
fixed/implemented fteqcc emulation of pointer opcodes.
added __inout keyword to fteqcc, so that it doesn't feel so horrendous.
fixed sizeof(*foo)
fixed *struct = struct;
fixed recursive structs.
fixed fteqcc warning report.
fixed sdl2 controller support, hopefully.
attempted to implement xinput, including per-player audio playback.
slightly fixed relaxed attitude to mouse focus when running fullscreen.
fixed weird warnings/errors with 'ent.arrayhead' terms. now generates sane errors.
implemented bindmaps (for csqc).
fixed crashing bug with eprint builtin.
implemented subset of music_playlist_* functionality. significant changes to music playback.
fixed some more dpcsqc compat.
fixed binds menu. now displays and accepts modifiers.
fixed issues with huge lightmaps.
fixed protocol determinism with dp clients connecting to fte servers. the initial getchallenge request now inhibits vanilla nq connection requests.
implemented support for 'dupe' userinfo key, allowing clients to request client->server packet duplication. should probably queue them tbh.
implemented sv_saveentfile command.
fixed resume after breaking inside a stepped-over function.
fixed erroneous footer after debugging.
(I wonder just how many things I broke with these fixes)
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@4946 fc73d0e0-1445-4013-8a0c-d673dee63da5
2015-07-26 10:56:18 +00:00
to = & newpack - > entities [ newpack - > num_entities ] ;
newpack - > num_entities + + ;
2004-11-27 08:16:25 +00:00
}
memcpy ( to , from , sizeof ( * to ) ) ;
to - > number = read ;
Reworked client support for DPP5+. less code now, its much more graceful.
added waterfog command. waterfog overrides regular fog only when the view is in water.
fixed 64bit printf format specifiers. should work better on winxp64.
fixed some spec angle weirdness.
fixed viewsize 99.99 weirdness with ezhud.
fixed extra offset on the console (exhibited in 64bit builds, but not limited to).
fixed .avi playback, can now actually display frames again.
reimplemented line sparks.
fixed r_editlights_save flipping the light's pitch.
fixed issue with oggs failing to load.
fixed condump to cope with unicode properly.
made sv_bigcoords default except in quake. hexen2 kinda needs it for bsp angle precision.
fixed nq server to not stall weirdly on map changes.
fixed qwprogs svc_cdtrack not bugging out with nq clients on the server.
fixed restart command to load the last map run by the server, instead of start.bsp (when idle)
optimised d3d9 renderer a little. now uses less draw calls, especially with complex scenes. seems to get higher framerates than opengl now.
fixed d3d9 renderer to not bug out quite so much when run fullscreen (shader subsystem is now correctly initialised).
fixed a couple of bugs from font change. also now supports utf-8 in a few more places.
r_editlights_reload no longer generates rtlights inside the void. this resolves a few glitches (but should also help framerates a little).
fixed so corona-only lights won't generate shadowmaps and waste lots of time.
removed lots of #defines from qclib. I should never have made them in the first place, but I was lazy. obviously there's more left that I cba to remove yet.
fixed nested calls with variant-vectors. this fixes csaddon's light editor.
fixed qcc hc calling conventions using redundant stores.
disabled keywords can still be used by using __keyword instead.
fixed ftegccgui grep feature.
fixed motionless-dog qcc bug.
tweaked qcc warnings a little. -Wall is now a viable setting. you should be able to fix all those warnings.
fixed qw svc_intermission + dpp5+ clients bug.
fixed annoying spam about disconnecting in hexen2.
rewrote status command a little to cope with ipv6 addresses more gracefully
fixed significant stall when hibernating/debugging a server with a player sitting on it.
fixed truelightning.
fixed rocketlight overriding pflags.
fixed torches vanishing on vid_restart.
fixed issue with decal scaling.
fixed findentityfield builtin.
fixed fteqcc issue with ptr+1
fixed use of arrays inside class functions.
fixed/implemented fteqcc emulation of pointer opcodes.
added __inout keyword to fteqcc, so that it doesn't feel so horrendous.
fixed sizeof(*foo)
fixed *struct = struct;
fixed recursive structs.
fixed fteqcc warning report.
fixed sdl2 controller support, hopefully.
attempted to implement xinput, including per-player audio playback.
slightly fixed relaxed attitude to mouse focus when running fullscreen.
fixed weird warnings/errors with 'ent.arrayhead' terms. now generates sane errors.
implemented bindmaps (for csqc).
fixed crashing bug with eprint builtin.
implemented subset of music_playlist_* functionality. significant changes to music playback.
fixed some more dpcsqc compat.
fixed binds menu. now displays and accepts modifiers.
fixed issues with huge lightmaps.
fixed protocol determinism with dp clients connecting to fte servers. the initial getchallenge request now inhibits vanilla nq connection requests.
implemented support for 'dupe' userinfo key, allowing clients to request client->server packet duplication. should probably queue them tbh.
implemented sv_saveentfile command.
fixed resume after breaking inside a stepped-over function.
fixed erroneous footer after debugging.
(I wonder just how many things I broke with these fixes)
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@4946 fc73d0e0-1445-4013-8a0c-d673dee63da5
2015-07-26 10:56:18 +00:00
if ( remove )
{ //ent is meant to be removed. flag it as such. we'll strip it out later.
if ( cl_shownet . ival > = 3 )
Con_Printf ( " Remove %i \n " , read ) ;
to - > inactiveflag = 1 ;
2016-07-12 00:40:13 +00:00
to - > bonecount = 0 ;
Reworked client support for DPP5+. less code now, its much more graceful.
added waterfog command. waterfog overrides regular fog only when the view is in water.
fixed 64bit printf format specifiers. should work better on winxp64.
fixed some spec angle weirdness.
fixed viewsize 99.99 weirdness with ezhud.
fixed extra offset on the console (exhibited in 64bit builds, but not limited to).
fixed .avi playback, can now actually display frames again.
reimplemented line sparks.
fixed r_editlights_save flipping the light's pitch.
fixed issue with oggs failing to load.
fixed condump to cope with unicode properly.
made sv_bigcoords default except in quake. hexen2 kinda needs it for bsp angle precision.
fixed nq server to not stall weirdly on map changes.
fixed qwprogs svc_cdtrack not bugging out with nq clients on the server.
fixed restart command to load the last map run by the server, instead of start.bsp (when idle)
optimised d3d9 renderer a little. now uses less draw calls, especially with complex scenes. seems to get higher framerates than opengl now.
fixed d3d9 renderer to not bug out quite so much when run fullscreen (shader subsystem is now correctly initialised).
fixed a couple of bugs from font change. also now supports utf-8 in a few more places.
r_editlights_reload no longer generates rtlights inside the void. this resolves a few glitches (but should also help framerates a little).
fixed so corona-only lights won't generate shadowmaps and waste lots of time.
removed lots of #defines from qclib. I should never have made them in the first place, but I was lazy. obviously there's more left that I cba to remove yet.
fixed nested calls with variant-vectors. this fixes csaddon's light editor.
fixed qcc hc calling conventions using redundant stores.
disabled keywords can still be used by using __keyword instead.
fixed ftegccgui grep feature.
fixed motionless-dog qcc bug.
tweaked qcc warnings a little. -Wall is now a viable setting. you should be able to fix all those warnings.
fixed qw svc_intermission + dpp5+ clients bug.
fixed annoying spam about disconnecting in hexen2.
rewrote status command a little to cope with ipv6 addresses more gracefully
fixed significant stall when hibernating/debugging a server with a player sitting on it.
fixed truelightning.
fixed rocketlight overriding pflags.
fixed torches vanishing on vid_restart.
fixed issue with decal scaling.
fixed findentityfield builtin.
fixed fteqcc issue with ptr+1
fixed use of arrays inside class functions.
fixed/implemented fteqcc emulation of pointer opcodes.
added __inout keyword to fteqcc, so that it doesn't feel so horrendous.
fixed sizeof(*foo)
fixed *struct = struct;
fixed recursive structs.
fixed fteqcc warning report.
fixed sdl2 controller support, hopefully.
attempted to implement xinput, including per-player audio playback.
slightly fixed relaxed attitude to mouse focus when running fullscreen.
fixed weird warnings/errors with 'ent.arrayhead' terms. now generates sane errors.
implemented bindmaps (for csqc).
fixed crashing bug with eprint builtin.
implemented subset of music_playlist_* functionality. significant changes to music playback.
fixed some more dpcsqc compat.
fixed binds menu. now displays and accepts modifiers.
fixed issues with huge lightmaps.
fixed protocol determinism with dp clients connecting to fte servers. the initial getchallenge request now inhibits vanilla nq connection requests.
implemented support for 'dupe' userinfo key, allowing clients to request client->server packet duplication. should probably queue them tbh.
implemented sv_saveentfile command.
fixed resume after breaking inside a stepped-over function.
fixed erroneous footer after debugging.
(I wonder just how many things I broke with these fixes)
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@4946 fc73d0e0-1445-4013-8a0c-d673dee63da5
2015-07-26 10:56:18 +00:00
}
2012-01-28 10:30:44 +00:00
else
2004-11-27 08:16:25 +00:00
{
2017-05-28 15:42:32 +00:00
if ( cl_shownet . ival > 3 )
Con_Printf ( " Update %i \n " , read ) ;
2016-07-12 00:40:13 +00:00
DP5_ParseDelta ( to , newpack ) ;
to - > sequence = cls . netchan . incoming_sequence ;
Reworked client support for DPP5+. less code now, its much more graceful.
added waterfog command. waterfog overrides regular fog only when the view is in water.
fixed 64bit printf format specifiers. should work better on winxp64.
fixed some spec angle weirdness.
fixed viewsize 99.99 weirdness with ezhud.
fixed extra offset on the console (exhibited in 64bit builds, but not limited to).
fixed .avi playback, can now actually display frames again.
reimplemented line sparks.
fixed r_editlights_save flipping the light's pitch.
fixed issue with oggs failing to load.
fixed condump to cope with unicode properly.
made sv_bigcoords default except in quake. hexen2 kinda needs it for bsp angle precision.
fixed nq server to not stall weirdly on map changes.
fixed qwprogs svc_cdtrack not bugging out with nq clients on the server.
fixed restart command to load the last map run by the server, instead of start.bsp (when idle)
optimised d3d9 renderer a little. now uses less draw calls, especially with complex scenes. seems to get higher framerates than opengl now.
fixed d3d9 renderer to not bug out quite so much when run fullscreen (shader subsystem is now correctly initialised).
fixed a couple of bugs from font change. also now supports utf-8 in a few more places.
r_editlights_reload no longer generates rtlights inside the void. this resolves a few glitches (but should also help framerates a little).
fixed so corona-only lights won't generate shadowmaps and waste lots of time.
removed lots of #defines from qclib. I should never have made them in the first place, but I was lazy. obviously there's more left that I cba to remove yet.
fixed nested calls with variant-vectors. this fixes csaddon's light editor.
fixed qcc hc calling conventions using redundant stores.
disabled keywords can still be used by using __keyword instead.
fixed ftegccgui grep feature.
fixed motionless-dog qcc bug.
tweaked qcc warnings a little. -Wall is now a viable setting. you should be able to fix all those warnings.
fixed qw svc_intermission + dpp5+ clients bug.
fixed annoying spam about disconnecting in hexen2.
rewrote status command a little to cope with ipv6 addresses more gracefully
fixed significant stall when hibernating/debugging a server with a player sitting on it.
fixed truelightning.
fixed rocketlight overriding pflags.
fixed torches vanishing on vid_restart.
fixed issue with decal scaling.
fixed findentityfield builtin.
fixed fteqcc issue with ptr+1
fixed use of arrays inside class functions.
fixed/implemented fteqcc emulation of pointer opcodes.
added __inout keyword to fteqcc, so that it doesn't feel so horrendous.
fixed sizeof(*foo)
fixed *struct = struct;
fixed recursive structs.
fixed fteqcc warning report.
fixed sdl2 controller support, hopefully.
attempted to implement xinput, including per-player audio playback.
slightly fixed relaxed attitude to mouse focus when running fullscreen.
fixed weird warnings/errors with 'ent.arrayhead' terms. now generates sane errors.
implemented bindmaps (for csqc).
fixed crashing bug with eprint builtin.
implemented subset of music_playlist_* functionality. significant changes to music playback.
fixed some more dpcsqc compat.
fixed binds menu. now displays and accepts modifiers.
fixed issues with huge lightmaps.
fixed protocol determinism with dp clients connecting to fte servers. the initial getchallenge request now inhibits vanilla nq connection requests.
implemented support for 'dupe' userinfo key, allowing clients to request client->server packet duplication. should probably queue them tbh.
implemented sv_saveentfile command.
fixed resume after breaking inside a stepped-over function.
fixed erroneous footer after debugging.
(I wonder just how many things I broke with these fixes)
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@4946 fc73d0e0-1445-4013-8a0c-d673dee63da5
2015-07-26 10:56:18 +00:00
to - > inactiveflag = 0 ;
2004-11-27 08:16:25 +00:00
}
Reworked client support for DPP5+. less code now, its much more graceful.
added waterfog command. waterfog overrides regular fog only when the view is in water.
fixed 64bit printf format specifiers. should work better on winxp64.
fixed some spec angle weirdness.
fixed viewsize 99.99 weirdness with ezhud.
fixed extra offset on the console (exhibited in 64bit builds, but not limited to).
fixed .avi playback, can now actually display frames again.
reimplemented line sparks.
fixed r_editlights_save flipping the light's pitch.
fixed issue with oggs failing to load.
fixed condump to cope with unicode properly.
made sv_bigcoords default except in quake. hexen2 kinda needs it for bsp angle precision.
fixed nq server to not stall weirdly on map changes.
fixed qwprogs svc_cdtrack not bugging out with nq clients on the server.
fixed restart command to load the last map run by the server, instead of start.bsp (when idle)
optimised d3d9 renderer a little. now uses less draw calls, especially with complex scenes. seems to get higher framerates than opengl now.
fixed d3d9 renderer to not bug out quite so much when run fullscreen (shader subsystem is now correctly initialised).
fixed a couple of bugs from font change. also now supports utf-8 in a few more places.
r_editlights_reload no longer generates rtlights inside the void. this resolves a few glitches (but should also help framerates a little).
fixed so corona-only lights won't generate shadowmaps and waste lots of time.
removed lots of #defines from qclib. I should never have made them in the first place, but I was lazy. obviously there's more left that I cba to remove yet.
fixed nested calls with variant-vectors. this fixes csaddon's light editor.
fixed qcc hc calling conventions using redundant stores.
disabled keywords can still be used by using __keyword instead.
fixed ftegccgui grep feature.
fixed motionless-dog qcc bug.
tweaked qcc warnings a little. -Wall is now a viable setting. you should be able to fix all those warnings.
fixed qw svc_intermission + dpp5+ clients bug.
fixed annoying spam about disconnecting in hexen2.
rewrote status command a little to cope with ipv6 addresses more gracefully
fixed significant stall when hibernating/debugging a server with a player sitting on it.
fixed truelightning.
fixed rocketlight overriding pflags.
fixed torches vanishing on vid_restart.
fixed issue with decal scaling.
fixed findentityfield builtin.
fixed fteqcc issue with ptr+1
fixed use of arrays inside class functions.
fixed/implemented fteqcc emulation of pointer opcodes.
added __inout keyword to fteqcc, so that it doesn't feel so horrendous.
fixed sizeof(*foo)
fixed *struct = struct;
fixed recursive structs.
fixed fteqcc warning report.
fixed sdl2 controller support, hopefully.
attempted to implement xinput, including per-player audio playback.
slightly fixed relaxed attitude to mouse focus when running fullscreen.
fixed weird warnings/errors with 'ent.arrayhead' terms. now generates sane errors.
implemented bindmaps (for csqc).
fixed crashing bug with eprint builtin.
implemented subset of music_playlist_* functionality. significant changes to music playback.
fixed some more dpcsqc compat.
fixed binds menu. now displays and accepts modifiers.
fixed issues with huge lightmaps.
fixed protocol determinism with dp clients connecting to fte servers. the initial getchallenge request now inhibits vanilla nq connection requests.
implemented support for 'dupe' userinfo key, allowing clients to request client->server packet duplication. should probably queue them tbh.
implemented sv_saveentfile command.
fixed resume after breaking inside a stepped-over function.
fixed erroneous footer after debugging.
(I wonder just how many things I broke with these fixes)
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@4946 fc73d0e0-1445-4013-8a0c-d673dee63da5
2015-07-26 10:56:18 +00:00
}
2004-11-27 08:16:25 +00:00
Reworked client support for DPP5+. less code now, its much more graceful.
added waterfog command. waterfog overrides regular fog only when the view is in water.
fixed 64bit printf format specifiers. should work better on winxp64.
fixed some spec angle weirdness.
fixed viewsize 99.99 weirdness with ezhud.
fixed extra offset on the console (exhibited in 64bit builds, but not limited to).
fixed .avi playback, can now actually display frames again.
reimplemented line sparks.
fixed r_editlights_save flipping the light's pitch.
fixed issue with oggs failing to load.
fixed condump to cope with unicode properly.
made sv_bigcoords default except in quake. hexen2 kinda needs it for bsp angle precision.
fixed nq server to not stall weirdly on map changes.
fixed qwprogs svc_cdtrack not bugging out with nq clients on the server.
fixed restart command to load the last map run by the server, instead of start.bsp (when idle)
optimised d3d9 renderer a little. now uses less draw calls, especially with complex scenes. seems to get higher framerates than opengl now.
fixed d3d9 renderer to not bug out quite so much when run fullscreen (shader subsystem is now correctly initialised).
fixed a couple of bugs from font change. also now supports utf-8 in a few more places.
r_editlights_reload no longer generates rtlights inside the void. this resolves a few glitches (but should also help framerates a little).
fixed so corona-only lights won't generate shadowmaps and waste lots of time.
removed lots of #defines from qclib. I should never have made them in the first place, but I was lazy. obviously there's more left that I cba to remove yet.
fixed nested calls with variant-vectors. this fixes csaddon's light editor.
fixed qcc hc calling conventions using redundant stores.
disabled keywords can still be used by using __keyword instead.
fixed ftegccgui grep feature.
fixed motionless-dog qcc bug.
tweaked qcc warnings a little. -Wall is now a viable setting. you should be able to fix all those warnings.
fixed qw svc_intermission + dpp5+ clients bug.
fixed annoying spam about disconnecting in hexen2.
rewrote status command a little to cope with ipv6 addresses more gracefully
fixed significant stall when hibernating/debugging a server with a player sitting on it.
fixed truelightning.
fixed rocketlight overriding pflags.
fixed torches vanishing on vid_restart.
fixed issue with decal scaling.
fixed findentityfield builtin.
fixed fteqcc issue with ptr+1
fixed use of arrays inside class functions.
fixed/implemented fteqcc emulation of pointer opcodes.
added __inout keyword to fteqcc, so that it doesn't feel so horrendous.
fixed sizeof(*foo)
fixed *struct = struct;
fixed recursive structs.
fixed fteqcc warning report.
fixed sdl2 controller support, hopefully.
attempted to implement xinput, including per-player audio playback.
slightly fixed relaxed attitude to mouse focus when running fullscreen.
fixed weird warnings/errors with 'ent.arrayhead' terms. now generates sane errors.
implemented bindmaps (for csqc).
fixed crashing bug with eprint builtin.
implemented subset of music_playlist_* functionality. significant changes to music playback.
fixed some more dpcsqc compat.
fixed binds menu. now displays and accepts modifiers.
fixed issues with huge lightmaps.
fixed protocol determinism with dp clients connecting to fte servers. the initial getchallenge request now inhibits vanilla nq connection requests.
implemented support for 'dupe' userinfo key, allowing clients to request client->server packet duplication. should probably queue them tbh.
implemented sv_saveentfile command.
fixed resume after breaking inside a stepped-over function.
fixed erroneous footer after debugging.
(I wonder just how many things I broke with these fixes)
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@4946 fc73d0e0-1445-4013-8a0c-d673dee63da5
2015-07-26 10:56:18 +00:00
qsort ( newpack - > entities , newpack - > num_entities , sizeof ( entity_state_t ) , CLDP_SortEntities ) ;
2004-11-27 08:16:25 +00:00
Reworked client support for DPP5+. less code now, its much more graceful.
added waterfog command. waterfog overrides regular fog only when the view is in water.
fixed 64bit printf format specifiers. should work better on winxp64.
fixed some spec angle weirdness.
fixed viewsize 99.99 weirdness with ezhud.
fixed extra offset on the console (exhibited in 64bit builds, but not limited to).
fixed .avi playback, can now actually display frames again.
reimplemented line sparks.
fixed r_editlights_save flipping the light's pitch.
fixed issue with oggs failing to load.
fixed condump to cope with unicode properly.
made sv_bigcoords default except in quake. hexen2 kinda needs it for bsp angle precision.
fixed nq server to not stall weirdly on map changes.
fixed qwprogs svc_cdtrack not bugging out with nq clients on the server.
fixed restart command to load the last map run by the server, instead of start.bsp (when idle)
optimised d3d9 renderer a little. now uses less draw calls, especially with complex scenes. seems to get higher framerates than opengl now.
fixed d3d9 renderer to not bug out quite so much when run fullscreen (shader subsystem is now correctly initialised).
fixed a couple of bugs from font change. also now supports utf-8 in a few more places.
r_editlights_reload no longer generates rtlights inside the void. this resolves a few glitches (but should also help framerates a little).
fixed so corona-only lights won't generate shadowmaps and waste lots of time.
removed lots of #defines from qclib. I should never have made them in the first place, but I was lazy. obviously there's more left that I cba to remove yet.
fixed nested calls with variant-vectors. this fixes csaddon's light editor.
fixed qcc hc calling conventions using redundant stores.
disabled keywords can still be used by using __keyword instead.
fixed ftegccgui grep feature.
fixed motionless-dog qcc bug.
tweaked qcc warnings a little. -Wall is now a viable setting. you should be able to fix all those warnings.
fixed qw svc_intermission + dpp5+ clients bug.
fixed annoying spam about disconnecting in hexen2.
rewrote status command a little to cope with ipv6 addresses more gracefully
fixed significant stall when hibernating/debugging a server with a player sitting on it.
fixed truelightning.
fixed rocketlight overriding pflags.
fixed torches vanishing on vid_restart.
fixed issue with decal scaling.
fixed findentityfield builtin.
fixed fteqcc issue with ptr+1
fixed use of arrays inside class functions.
fixed/implemented fteqcc emulation of pointer opcodes.
added __inout keyword to fteqcc, so that it doesn't feel so horrendous.
fixed sizeof(*foo)
fixed *struct = struct;
fixed recursive structs.
fixed fteqcc warning report.
fixed sdl2 controller support, hopefully.
attempted to implement xinput, including per-player audio playback.
slightly fixed relaxed attitude to mouse focus when running fullscreen.
fixed weird warnings/errors with 'ent.arrayhead' terms. now generates sane errors.
implemented bindmaps (for csqc).
fixed crashing bug with eprint builtin.
implemented subset of music_playlist_* functionality. significant changes to music playback.
fixed some more dpcsqc compat.
fixed binds menu. now displays and accepts modifiers.
fixed issues with huge lightmaps.
fixed protocol determinism with dp clients connecting to fte servers. the initial getchallenge request now inhibits vanilla nq connection requests.
implemented support for 'dupe' userinfo key, allowing clients to request client->server packet duplication. should probably queue them tbh.
implemented sv_saveentfile command.
fixed resume after breaking inside a stepped-over function.
fixed erroneous footer after debugging.
(I wonder just how many things I broke with these fixes)
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@4946 fc73d0e0-1445-4013-8a0c-d673dee63da5
2015-07-26 10:56:18 +00:00
//get rid of any removed ents (we sorted these to the end)
while ( newpack - > num_entities )
{
if ( newpack - > entities [ newpack - > num_entities - 1 ] . inactiveflag )
newpack - > num_entities - - ;
2012-01-28 10:30:44 +00:00
else
Reworked client support for DPP5+. less code now, its much more graceful.
added waterfog command. waterfog overrides regular fog only when the view is in water.
fixed 64bit printf format specifiers. should work better on winxp64.
fixed some spec angle weirdness.
fixed viewsize 99.99 weirdness with ezhud.
fixed extra offset on the console (exhibited in 64bit builds, but not limited to).
fixed .avi playback, can now actually display frames again.
reimplemented line sparks.
fixed r_editlights_save flipping the light's pitch.
fixed issue with oggs failing to load.
fixed condump to cope with unicode properly.
made sv_bigcoords default except in quake. hexen2 kinda needs it for bsp angle precision.
fixed nq server to not stall weirdly on map changes.
fixed qwprogs svc_cdtrack not bugging out with nq clients on the server.
fixed restart command to load the last map run by the server, instead of start.bsp (when idle)
optimised d3d9 renderer a little. now uses less draw calls, especially with complex scenes. seems to get higher framerates than opengl now.
fixed d3d9 renderer to not bug out quite so much when run fullscreen (shader subsystem is now correctly initialised).
fixed a couple of bugs from font change. also now supports utf-8 in a few more places.
r_editlights_reload no longer generates rtlights inside the void. this resolves a few glitches (but should also help framerates a little).
fixed so corona-only lights won't generate shadowmaps and waste lots of time.
removed lots of #defines from qclib. I should never have made them in the first place, but I was lazy. obviously there's more left that I cba to remove yet.
fixed nested calls with variant-vectors. this fixes csaddon's light editor.
fixed qcc hc calling conventions using redundant stores.
disabled keywords can still be used by using __keyword instead.
fixed ftegccgui grep feature.
fixed motionless-dog qcc bug.
tweaked qcc warnings a little. -Wall is now a viable setting. you should be able to fix all those warnings.
fixed qw svc_intermission + dpp5+ clients bug.
fixed annoying spam about disconnecting in hexen2.
rewrote status command a little to cope with ipv6 addresses more gracefully
fixed significant stall when hibernating/debugging a server with a player sitting on it.
fixed truelightning.
fixed rocketlight overriding pflags.
fixed torches vanishing on vid_restart.
fixed issue with decal scaling.
fixed findentityfield builtin.
fixed fteqcc issue with ptr+1
fixed use of arrays inside class functions.
fixed/implemented fteqcc emulation of pointer opcodes.
added __inout keyword to fteqcc, so that it doesn't feel so horrendous.
fixed sizeof(*foo)
fixed *struct = struct;
fixed recursive structs.
fixed fteqcc warning report.
fixed sdl2 controller support, hopefully.
attempted to implement xinput, including per-player audio playback.
slightly fixed relaxed attitude to mouse focus when running fullscreen.
fixed weird warnings/errors with 'ent.arrayhead' terms. now generates sane errors.
implemented bindmaps (for csqc).
fixed crashing bug with eprint builtin.
implemented subset of music_playlist_* functionality. significant changes to music playback.
fixed some more dpcsqc compat.
fixed binds menu. now displays and accepts modifiers.
fixed issues with huge lightmaps.
fixed protocol determinism with dp clients connecting to fte servers. the initial getchallenge request now inhibits vanilla nq connection requests.
implemented support for 'dupe' userinfo key, allowing clients to request client->server packet duplication. should probably queue them tbh.
implemented sv_saveentfile command.
fixed resume after breaking inside a stepped-over function.
fixed erroneous footer after debugging.
(I wonder just how many things I broke with these fixes)
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@4946 fc73d0e0-1445-4013-8a0c-d673dee63da5
2015-07-26 10:56:18 +00:00
break ;
2004-11-27 08:16:25 +00:00
}
2016-07-12 00:40:13 +00:00
//make sure any bone states are refreshed
for ( oldi = 0 , to = newpack - > entities ; oldi < newpack - > num_entities ; oldi + + , to + + )
{
if ( to - > bonecount & & ( to - > boneoffset & 0x80000000 ) )
{
unsigned int oldoffset = to - > boneoffset & 0x7fffffff ;
void * dest = AllocateBoneSpace ( newpack , to - > bonecount , & to - > boneoffset ) ;
void * src = GetBoneSpace ( oldpack , oldoffset ) ;
memcpy ( dest , src , to - > bonecount * sizeof ( short ) * 7 ) ;
}
}
2004-11-27 08:16:25 +00:00
}
2004-08-23 00:15:46 +00:00
2004-11-23 01:10:10 +00:00
void CLNQ_ParseEntity ( unsigned int bits )
2004-08-23 00:15:46 +00:00
{
int i ;
2012-02-12 05:18:31 +00:00
int num ;
2012-01-17 07:57:46 +00:00
entity_state_t * state ; //, *from;
2004-08-23 00:15:46 +00:00
entity_state_t * base ;
packet_entities_t * pack ;
2004-11-23 01:10:10 +00:00
2017-07-12 08:15:27 +00:00
qboolean isnehahra = CPNQ_IS_BJP | | ( cls . protocol_nq = = CPNQ_NEHAHRA ) ;
2015-10-27 15:20:15 +00:00
2004-08-23 00:15:46 +00:00
if ( cls . signon = = 4 - 1 )
{ // first update is the final signon stage
cls . signon = 4 ;
CLNQ_SignonReply ( ) ;
2005-02-06 02:47:36 +00:00
}
2013-03-12 22:53:23 +00:00
pack = & cl . inframes [ cls . netchan . incoming_sequence & UPDATE_MASK ] . packet_entities ;
2004-08-23 00:15:46 +00:00
if ( bits & NQU_MOREBITS )
{
i = MSG_ReadByte ( ) ;
bits | = ( i < < 8 ) ;
}
2015-10-27 15:20:15 +00:00
2017-07-12 08:15:27 +00:00
if ( bits & DPU_EXTEND1 )
2004-11-23 01:10:10 +00:00
{
2017-07-12 08:15:27 +00:00
if ( ! isnehahra )
2015-10-27 15:20:15 +00:00
{
i = MSG_ReadByte ( ) ;
bits | = ( i < < 16 ) ;
2017-07-12 08:15:27 +00:00
if ( bits & DPU_EXTEND2 )
{
i = MSG_ReadByte ( ) ;
bits | = ( i < < 24 ) ;
}
2015-10-27 15:20:15 +00:00
}
2004-11-23 01:10:10 +00:00
}
2004-08-23 00:15:46 +00:00
2005-02-06 02:47:36 +00:00
if ( bits & NQU_LONGENTITY )
------------------------------------------------------------------------
r4169 | acceptthis | 2013-01-17 08:55:12 +0000 (Thu, 17 Jan 2013) | 31 lines
removed MAX_VISEDICTS limit.
PEXT2_REPLACEMENTDELTAS tweaked, now has 4 million entity limit. still not enabled by default.
TE_BEAM now maps to a separate TEQW_BEAM to avoid conflicts with QW.
added android multitouch emulation for windows/rawinput (in_simulatemultitouch).
split topcolor/bottomcolor from scoreboard, for dp's colormap|1024 feature.
now using utf-8 for windows consoles.
qcc warnings/errors now give clickable console links for quick+easy editing.
disabled menutint when the currently active item changes contrast or gamma (for OneManClan).
Added support for drawfont/drawfontscale.
tweaked the qcvm a little to reduce the number of pointers.
.doll file loading. still experimental and will likely crash. requires csqc active, even if its a dummy progs. this will be fixed in time. Still other things that need cleaning up.
windows: gl_font "?" shows the standard windows font-selection dialog, and can be used to select windows fonts. not all work. and you probably don't want to use windings.
fixed splitscreen support when playing mvds. added mini-scoreboards to splitscreen.
editor/debugger now shows asm if there's no linenumber info. also, pressing f1 for help shows the shortcuts.
Added support for .framegroups files for psk(psa) and iqm formats.
True support for ezquake's colour codes. Mutually exclusive with background colours.
path command output slightly more readable.
added support for digest_hex (MD4, SHA1, CRC16).
skingroups now colourmap correctly.
Fix terrain colour hints, and litdata from the wrong bsp.
fix ftp dual-homed issue. support epsv command, and enable ipv6 (eprt still not supported).
remove d3d11 compilation from the makefile. the required headers are not provided by mingw, and are not available to the build bot, so don't bother.
fix v *= v.x and similar opcodes.
fteqcc: fixed support for áéíóú type chars in names. utf-8 files now properly supported (even with the utf-8 bom/identifier). utf-16 also supported.
fteqcc: fixed '#if 1 == 3 && 4' parsing.
fteqcc: -Werror acts on the warning, rather than as a separate error. Line numbers are thus more readable.
fteqcc: copyright message now includes compile date instead.
fteqccgui: the treeview control is now coloured depending on whether there were warnings/errors in the last compile.
fteqccgui: the output window is now focused and scrolls down as compilation progresses.
pr_dumpplatform command dumps out some pragmas to convert more serious warnings to errors. This is to avoid the infamous 'fteqcc sucks cos my code sucks' issue.
rewrote prespawn/modelist/soundlist code. server tracks progress now.
------------------------------------------------------------------------
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@4167 fc73d0e0-1445-4013-8a0c-d673dee63da5
2013-03-12 22:29:40 +00:00
num = MSGCL_ReadEntity ( ) ;
2004-08-23 00:15:46 +00:00
else
num = MSG_ReadByte ( ) ;
// state = CL_FindPacketEntity(num);
// if (!state)
{
// if ((int)(lasttime*100) != (int)(realtime*100))
// pack->num_entities=0;
// else
if ( pack - > num_entities = = pack - > max_entities )
{
pack - > max_entities = pack - > num_entities + 1 ;
pack - > entities = BZ_Realloc ( pack - > entities , sizeof ( entity_state_t ) * pack - > max_entities ) ;
2008-11-09 22:29:28 +00:00
memset ( pack - > entities + pack - > num_entities , 0 , sizeof ( entity_state_t ) ) ;
2004-08-23 00:15:46 +00:00
}
state = & pack - > entities [ pack - > num_entities + + ] ;
}
2012-01-17 07:57:46 +00:00
// from = CL_FindOldPacketEntity(num); //this could be optimised.
2004-08-23 00:15:46 +00:00
2006-07-24 04:24:41 +00:00
if ( ! CL_CheckBaselines ( num ) )
Host_EndGame ( " CLNQ_ParseEntity: check baselines failed with size %i " , num ) ;
base = cl_baselines + num ;
2012-02-27 12:23:15 +00:00
memcpy ( state , base , sizeof ( * state ) ) ;
2004-08-23 00:15:46 +00:00
state - > number = num ;
2016-07-12 00:40:13 +00:00
state - > sequence = cls . netchan . incoming_sequence ;
state - > solidsize = ES_SOLID_BSP ;
2004-08-23 00:15:46 +00:00
2017-01-15 13:13:09 +00:00
state - > dpflags = 0 ;
2010-11-28 19:19:06 +00:00
2005-02-06 02:47:36 +00:00
if ( bits & NQU_MODEL )
2016-02-15 06:01:17 +00:00
{
if ( CPNQ_IS_BJP )
state - > modelindex = MSG_ReadShort ( ) ;
else
state - > modelindex = MSG_ReadByte ( ) ;
}
2004-08-23 00:15:46 +00:00
if ( bits & NQU_FRAME )
state - > frame = MSG_ReadByte ( ) ;
if ( bits & NQU_COLORMAP )
state - > colormap = MSG_ReadByte ( ) ;
if ( bits & NQU_SKIN )
state - > skinnum = MSG_ReadByte ( ) ;
if ( bits & NQU_EFFECTS )
state - > effects = MSG_ReadByte ( ) ;
if ( bits & NQU_ORIGIN1 )
state - > origin [ 0 ] = MSG_ReadCoord ( ) ;
if ( bits & NQU_ANGLE1 )
state - > angles [ 0 ] = MSG_ReadAngle ( ) ;
if ( bits & NQU_ORIGIN2 )
state - > origin [ 1 ] = MSG_ReadCoord ( ) ;
if ( bits & NQU_ANGLE2 )
state - > angles [ 1 ] = MSG_ReadAngle ( ) ;
if ( bits & NQU_ORIGIN3 )
state - > origin [ 2 ] = MSG_ReadCoord ( ) ;
if ( bits & NQU_ANGLE3 )
state - > angles [ 2 ] = MSG_ReadAngle ( ) ;
2017-01-15 13:13:09 +00:00
if ( bits & NQU_NOLERP )
state - > dpflags | = RENDER_STEP ;
2015-10-27 15:20:15 +00:00
if ( isnehahra )
{
if ( bits & DPU_EXTEND1 ) //U_TRANS
{
float tmp = MSG_ReadFloat ( ) ;
float alpha = MSG_ReadFloat ( ) ;
if ( tmp = = 2 )
{
if ( MSG_ReadFloat ( ) > 0.5 )
state - > effects | = EF_FULLBRIGHT ;
}
2017-07-12 08:15:27 +00:00
if ( ! alpha )
alpha = 1 ;
2015-10-27 15:20:15 +00:00
state - > trans = bound ( 0 , 255 * alpha , 255 ) ;
}
}
else if ( cls . protocol_nq = = CPNQ_FITZ666 )
Fixes, workarounds, and breakages. Hexen2 should work much better (-hexen2 says no mission pack, -portals says h2mp). Started working on splitting bigcoords per client, far too much work still to go on that. Removed gl_ztrick entirely. Enabled csprogs download by default. Added client support for fitzquake's 666 protocol, needs testing, some cleanup for dp protocols too, no server support, couldn't selectively enable it anyway. Now attempting to cache shadow meshes for explosions and stuff. Played with lightmaps a little, should potentially run a little faster on certain (intel?) cards. Tweeked npfte a little to try to avoid deadlocks and crashes. Fixed sky worldspawn parsing. Added h2mp's model format. Fixed baseline issue in q2 client, made servers generate q2 baselines. MOVETYPE_PUSH will not rotate extra if rotation is forced. Made status command show allowed client types. Changed lighting on weapons - should now be shaded.
git-svn-id: https://svn.code.sf.net/p/fteqw/code/branches/wip@3572 fc73d0e0-1445-4013-8a0c-d673dee63da5
2010-08-11 03:36:31 +00:00
{
if ( bits & FITZU_ALPHA )
2016-10-22 07:06:51 +00:00
state - > trans = ( MSG_ReadByte ( ) - 1 ) & 0xff ;
2012-02-27 12:23:15 +00:00
if ( bits & RMQU_SCALE )
state - > scale = MSG_ReadByte ( ) ;
2006-06-09 00:58:11 +00:00
Fixes, workarounds, and breakages. Hexen2 should work much better (-hexen2 says no mission pack, -portals says h2mp). Started working on splitting bigcoords per client, far too much work still to go on that. Removed gl_ztrick entirely. Enabled csprogs download by default. Added client support for fitzquake's 666 protocol, needs testing, some cleanup for dp protocols too, no server support, couldn't selectively enable it anyway. Now attempting to cache shadow meshes for explosions and stuff. Played with lightmaps a little, should potentially run a little faster on certain (intel?) cards. Tweeked npfte a little to try to avoid deadlocks and crashes. Fixed sky worldspawn parsing. Added h2mp's model format. Fixed baseline issue in q2 client, made servers generate q2 baselines. MOVETYPE_PUSH will not rotate extra if rotation is forced. Made status command show allowed client types. Changed lighting on weapons - should now be shaded.
git-svn-id: https://svn.code.sf.net/p/fteqw/code/branches/wip@3572 fc73d0e0-1445-4013-8a0c-d673dee63da5
2010-08-11 03:36:31 +00:00
if ( bits & FITZU_FRAME2 )
2012-02-27 12:23:15 +00:00
state - > frame = ( state - > frame & 0xff ) | ( MSG_ReadByte ( ) < < 8 ) ;
2006-06-09 00:58:11 +00:00
Fixes, workarounds, and breakages. Hexen2 should work much better (-hexen2 says no mission pack, -portals says h2mp). Started working on splitting bigcoords per client, far too much work still to go on that. Removed gl_ztrick entirely. Enabled csprogs download by default. Added client support for fitzquake's 666 protocol, needs testing, some cleanup for dp protocols too, no server support, couldn't selectively enable it anyway. Now attempting to cache shadow meshes for explosions and stuff. Played with lightmaps a little, should potentially run a little faster on certain (intel?) cards. Tweeked npfte a little to try to avoid deadlocks and crashes. Fixed sky worldspawn parsing. Added h2mp's model format. Fixed baseline issue in q2 client, made servers generate q2 baselines. MOVETYPE_PUSH will not rotate extra if rotation is forced. Made status command show allowed client types. Changed lighting on weapons - should now be shaded.
git-svn-id: https://svn.code.sf.net/p/fteqw/code/branches/wip@3572 fc73d0e0-1445-4013-8a0c-d673dee63da5
2010-08-11 03:36:31 +00:00
if ( bits & FITZU_MODEL2 )
2012-02-27 12:23:15 +00:00
state - > modelindex = ( state - > modelindex & 0xff ) | ( MSG_ReadByte ( ) < < 8 ) ;
2006-06-09 00:58:11 +00:00
Fixes, workarounds, and breakages. Hexen2 should work much better (-hexen2 says no mission pack, -portals says h2mp). Started working on splitting bigcoords per client, far too much work still to go on that. Removed gl_ztrick entirely. Enabled csprogs download by default. Added client support for fitzquake's 666 protocol, needs testing, some cleanup for dp protocols too, no server support, couldn't selectively enable it anyway. Now attempting to cache shadow meshes for explosions and stuff. Played with lightmaps a little, should potentially run a little faster on certain (intel?) cards. Tweeked npfte a little to try to avoid deadlocks and crashes. Fixed sky worldspawn parsing. Added h2mp's model format. Fixed baseline issue in q2 client, made servers generate q2 baselines. MOVETYPE_PUSH will not rotate extra if rotation is forced. Made status command show allowed client types. Changed lighting on weapons - should now be shaded.
git-svn-id: https://svn.code.sf.net/p/fteqw/code/branches/wip@3572 fc73d0e0-1445-4013-8a0c-d673dee63da5
2010-08-11 03:36:31 +00:00
if ( bits & FITZU_LERPFINISH )
MSG_ReadByte ( ) ;
}
2006-06-09 00:58:11 +00:00
else
2017-07-12 08:15:27 +00:00
{ //dp tends to leak stuff, so parse as quakedp if the normal protocol doesn't define it as something better.
// if (bits & DPU_DELTA) //should delta from the previous frame. DP doesn't generate this any more, so whatever.
// Host_EndGame("CLNQ_ParseEntity: DPU_DELTA not supported");
Fixes, workarounds, and breakages. Hexen2 should work much better (-hexen2 says no mission pack, -portals says h2mp). Started working on splitting bigcoords per client, far too much work still to go on that. Removed gl_ztrick entirely. Enabled csprogs download by default. Added client support for fitzquake's 666 protocol, needs testing, some cleanup for dp protocols too, no server support, couldn't selectively enable it anyway. Now attempting to cache shadow meshes for explosions and stuff. Played with lightmaps a little, should potentially run a little faster on certain (intel?) cards. Tweeked npfte a little to try to avoid deadlocks and crashes. Fixed sky worldspawn parsing. Added h2mp's model format. Fixed baseline issue in q2 client, made servers generate q2 baselines. MOVETYPE_PUSH will not rotate extra if rotation is forced. Made status command show allowed client types. Changed lighting on weapons - should now be shaded.
git-svn-id: https://svn.code.sf.net/p/fteqw/code/branches/wip@3572 fc73d0e0-1445-4013-8a0c-d673dee63da5
2010-08-11 03:36:31 +00:00
if ( bits & DPU_ALPHA )
2012-02-27 12:23:15 +00:00
state - > trans = MSG_ReadByte ( ) ;
2006-06-09 00:58:11 +00:00
Fixes, workarounds, and breakages. Hexen2 should work much better (-hexen2 says no mission pack, -portals says h2mp). Started working on splitting bigcoords per client, far too much work still to go on that. Removed gl_ztrick entirely. Enabled csprogs download by default. Added client support for fitzquake's 666 protocol, needs testing, some cleanup for dp protocols too, no server support, couldn't selectively enable it anyway. Now attempting to cache shadow meshes for explosions and stuff. Played with lightmaps a little, should potentially run a little faster on certain (intel?) cards. Tweeked npfte a little to try to avoid deadlocks and crashes. Fixed sky worldspawn parsing. Added h2mp's model format. Fixed baseline issue in q2 client, made servers generate q2 baselines. MOVETYPE_PUSH will not rotate extra if rotation is forced. Made status command show allowed client types. Changed lighting on weapons - should now be shaded.
git-svn-id: https://svn.code.sf.net/p/fteqw/code/branches/wip@3572 fc73d0e0-1445-4013-8a0c-d673dee63da5
2010-08-11 03:36:31 +00:00
if ( bits & DPU_SCALE )
2012-02-27 12:23:15 +00:00
state - > scale = MSG_ReadByte ( ) ;
2006-06-09 00:58:11 +00:00
Fixes, workarounds, and breakages. Hexen2 should work much better (-hexen2 says no mission pack, -portals says h2mp). Started working on splitting bigcoords per client, far too much work still to go on that. Removed gl_ztrick entirely. Enabled csprogs download by default. Added client support for fitzquake's 666 protocol, needs testing, some cleanup for dp protocols too, no server support, couldn't selectively enable it anyway. Now attempting to cache shadow meshes for explosions and stuff. Played with lightmaps a little, should potentially run a little faster on certain (intel?) cards. Tweeked npfte a little to try to avoid deadlocks and crashes. Fixed sky worldspawn parsing. Added h2mp's model format. Fixed baseline issue in q2 client, made servers generate q2 baselines. MOVETYPE_PUSH will not rotate extra if rotation is forced. Made status command show allowed client types. Changed lighting on weapons - should now be shaded.
git-svn-id: https://svn.code.sf.net/p/fteqw/code/branches/wip@3572 fc73d0e0-1445-4013-8a0c-d673dee63da5
2010-08-11 03:36:31 +00:00
if ( bits & DPU_EFFECTS2 )
state - > effects | = MSG_ReadByte ( ) < < 8 ;
2006-06-09 00:58:11 +00:00
Fixes, workarounds, and breakages. Hexen2 should work much better (-hexen2 says no mission pack, -portals says h2mp). Started working on splitting bigcoords per client, far too much work still to go on that. Removed gl_ztrick entirely. Enabled csprogs download by default. Added client support for fitzquake's 666 protocol, needs testing, some cleanup for dp protocols too, no server support, couldn't selectively enable it anyway. Now attempting to cache shadow meshes for explosions and stuff. Played with lightmaps a little, should potentially run a little faster on certain (intel?) cards. Tweeked npfte a little to try to avoid deadlocks and crashes. Fixed sky worldspawn parsing. Added h2mp's model format. Fixed baseline issue in q2 client, made servers generate q2 baselines. MOVETYPE_PUSH will not rotate extra if rotation is forced. Made status command show allowed client types. Changed lighting on weapons - should now be shaded.
git-svn-id: https://svn.code.sf.net/p/fteqw/code/branches/wip@3572 fc73d0e0-1445-4013-8a0c-d673dee63da5
2010-08-11 03:36:31 +00:00
if ( bits & DPU_GLOWSIZE )
state - > glowsize = MSG_ReadByte ( ) ;
2006-06-09 00:58:11 +00:00
Fixes, workarounds, and breakages. Hexen2 should work much better (-hexen2 says no mission pack, -portals says h2mp). Started working on splitting bigcoords per client, far too much work still to go on that. Removed gl_ztrick entirely. Enabled csprogs download by default. Added client support for fitzquake's 666 protocol, needs testing, some cleanup for dp protocols too, no server support, couldn't selectively enable it anyway. Now attempting to cache shadow meshes for explosions and stuff. Played with lightmaps a little, should potentially run a little faster on certain (intel?) cards. Tweeked npfte a little to try to avoid deadlocks and crashes. Fixed sky worldspawn parsing. Added h2mp's model format. Fixed baseline issue in q2 client, made servers generate q2 baselines. MOVETYPE_PUSH will not rotate extra if rotation is forced. Made status command show allowed client types. Changed lighting on weapons - should now be shaded.
git-svn-id: https://svn.code.sf.net/p/fteqw/code/branches/wip@3572 fc73d0e0-1445-4013-8a0c-d673dee63da5
2010-08-11 03:36:31 +00:00
if ( bits & DPU_GLOWCOLOR )
state - > glowcolour = MSG_ReadByte ( ) ;
2006-06-09 00:58:11 +00:00
Fixes, workarounds, and breakages. Hexen2 should work much better (-hexen2 says no mission pack, -portals says h2mp). Started working on splitting bigcoords per client, far too much work still to go on that. Removed gl_ztrick entirely. Enabled csprogs download by default. Added client support for fitzquake's 666 protocol, needs testing, some cleanup for dp protocols too, no server support, couldn't selectively enable it anyway. Now attempting to cache shadow meshes for explosions and stuff. Played with lightmaps a little, should potentially run a little faster on certain (intel?) cards. Tweeked npfte a little to try to avoid deadlocks and crashes. Fixed sky worldspawn parsing. Added h2mp's model format. Fixed baseline issue in q2 client, made servers generate q2 baselines. MOVETYPE_PUSH will not rotate extra if rotation is forced. Made status command show allowed client types. Changed lighting on weapons - should now be shaded.
git-svn-id: https://svn.code.sf.net/p/fteqw/code/branches/wip@3572 fc73d0e0-1445-4013-8a0c-d673dee63da5
2010-08-11 03:36:31 +00:00
if ( bits & DPU_COLORMOD )
{
i = MSG_ReadByte ( ) ; // follows format RRRGGGBB
state - > colormod [ 0 ] = ( qbyte ) ( ( ( i > > 5 ) & 7 ) * ( 32.0f / 7.0f ) ) ;
state - > colormod [ 1 ] = ( qbyte ) ( ( ( i > > 2 ) & 7 ) * ( 32.0f / 7.0f ) ) ;
state - > colormod [ 2 ] = ( qbyte ) ( ( i & 3 ) * ( 32.0f / 3.0f ) ) ;
}
2017-01-15 13:13:09 +00:00
if ( bits & DPU_GLOWTRAIL )
state - > dpflags | = RENDER_GLOWTRAIL ;
Fixes, workarounds, and breakages. Hexen2 should work much better (-hexen2 says no mission pack, -portals says h2mp). Started working on splitting bigcoords per client, far too much work still to go on that. Removed gl_ztrick entirely. Enabled csprogs download by default. Added client support for fitzquake's 666 protocol, needs testing, some cleanup for dp protocols too, no server support, couldn't selectively enable it anyway. Now attempting to cache shadow meshes for explosions and stuff. Played with lightmaps a little, should potentially run a little faster on certain (intel?) cards. Tweeked npfte a little to try to avoid deadlocks and crashes. Fixed sky worldspawn parsing. Added h2mp's model format. Fixed baseline issue in q2 client, made servers generate q2 baselines. MOVETYPE_PUSH will not rotate extra if rotation is forced. Made status command show allowed client types. Changed lighting on weapons - should now be shaded.
git-svn-id: https://svn.code.sf.net/p/fteqw/code/branches/wip@3572 fc73d0e0-1445-4013-8a0c-d673dee63da5
2010-08-11 03:36:31 +00:00
if ( bits & DPU_FRAME2 )
state - > frame | = MSG_ReadByte ( ) < < 8 ;
if ( bits & DPU_MODEL2 )
state - > modelindex | = MSG_ReadByte ( ) < < 8 ;
2017-01-15 13:13:09 +00:00
if ( bits & DPU_VIEWMODEL )
state - > dpflags | = RENDER_VIEWMODEL ;
if ( bits & DPU_EXTERIORMODEL )
state - > dpflags | = RENDER_EXTERIORMODEL ;
Fixes, workarounds, and breakages. Hexen2 should work much better (-hexen2 says no mission pack, -portals says h2mp). Started working on splitting bigcoords per client, far too much work still to go on that. Removed gl_ztrick entirely. Enabled csprogs download by default. Added client support for fitzquake's 666 protocol, needs testing, some cleanup for dp protocols too, no server support, couldn't selectively enable it anyway. Now attempting to cache shadow meshes for explosions and stuff. Played with lightmaps a little, should potentially run a little faster on certain (intel?) cards. Tweeked npfte a little to try to avoid deadlocks and crashes. Fixed sky worldspawn parsing. Added h2mp's model format. Fixed baseline issue in q2 client, made servers generate q2 baselines. MOVETYPE_PUSH will not rotate extra if rotation is forced. Made status command show allowed client types. Changed lighting on weapons - should now be shaded.
git-svn-id: https://svn.code.sf.net/p/fteqw/code/branches/wip@3572 fc73d0e0-1445-4013-8a0c-d673dee63da5
2010-08-11 03:36:31 +00:00
}
2004-08-23 00:15:46 +00:00
}
# endif
# ifdef PEXT_SETVIEW
entity_state_t * CL_FindPacketEntity ( int num )
{
int pnum ;
entity_state_t * s1 ;
2018-10-11 10:31:23 +00:00
packet_entities_t * pack = cl . currentpackentities ;
if ( pack )
for ( pnum = 0 ; pnum < pack - > num_entities ; pnum + + )
{
s1 = & pack - > entities [ pnum ] ;
2004-08-23 00:15:46 +00:00
2018-10-11 10:31:23 +00:00
if ( num = = s1 - > number )
return s1 ;
}
2004-08-23 00:15:46 +00:00
return NULL ;
}
# endif
2009-07-18 20:46:42 +00:00
void CL_RotateAroundTag ( entity_t * ent , int entnum , int parenttagent , int parenttagnum )
2004-10-10 06:32:29 +00:00
{
entity_state_t * ps ;
float * org = NULL , * ang = NULL ;
2004-11-17 17:55:19 +00:00
vec3_t axis [ 3 ] ;
2005-06-14 04:52:10 +00:00
float transform [ 12 ] , parent [ 12 ] , result [ 12 ] , old [ 12 ] , temp [ 12 ] ;
2004-11-17 17:55:19 +00:00
2016-01-18 05:22:07 +00:00
model_t * model ;
2008-12-23 02:55:20 +00:00
framestate_t fstate ;
2004-10-10 06:32:29 +00:00
2014-04-12 03:30:27 +00:00
if ( parenttagent > = cl . maxlerpents )
2008-11-09 22:29:28 +00:00
{
Con_Printf ( " tag entity out of range! \n " ) ;
return ;
}
2016-01-18 05:22:07 +00:00
//old is the entity's relative transform (relative to the parent entity's tag)
old [ 0 ] = ent - > axis [ 0 ] [ 0 ] ;
old [ 1 ] = ent - > axis [ 1 ] [ 0 ] ;
old [ 2 ] = ent - > axis [ 2 ] [ 0 ] ;
old [ 3 ] = ent - > origin [ 0 ] ;
old [ 4 ] = ent - > axis [ 0 ] [ 1 ] ;
old [ 5 ] = ent - > axis [ 1 ] [ 1 ] ;
old [ 6 ] = ent - > axis [ 2 ] [ 1 ] ;
old [ 7 ] = ent - > origin [ 1 ] ;
old [ 8 ] = ent - > axis [ 0 ] [ 2 ] ;
old [ 9 ] = ent - > axis [ 1 ] [ 2 ] ;
old [ 10 ] = ent - > axis [ 2 ] [ 2 ] ;
old [ 11 ] = ent - > origin [ 2 ] ;
2008-12-23 02:55:20 +00:00
memset ( & fstate , 0 , sizeof ( fstate ) ) ;
2009-07-18 20:46:42 +00:00
//for visibility checks
ent - > keynum = parenttagent ;
2005-02-28 07:16:19 +00:00
2009-07-18 20:46:42 +00:00
ps = CL_FindPacketEntity ( parenttagent ) ;
2004-10-10 06:32:29 +00:00
if ( ps )
{
2016-01-18 05:22:07 +00:00
if ( parenttagent > = cl . maxlerpents )
{
org = ps - > origin ;
ang = ps - > angles ;
}
else
{
lerpents_t * le = & cl . lerpents [ parenttagent ] ;
org = le - > origin ;
ang = le - > angles ;
}
2005-07-01 19:23:00 +00:00
2016-01-18 05:22:07 +00:00
if ( ps - > modelindex < = countof ( cl . model_precache ) & & cl . model_precache [ ps - > modelindex ] & & cl . model_precache [ ps - > modelindex ] - > loadstate = = MLS_LOADED )
model = cl . model_precache [ ps - > modelindex ] ;
else
model = NULL ;
if ( model & & model - > type = = mod_alias )
2020-10-06 03:17:28 +00:00
AngleVectorsMesh ( ang , axis [ 0 ] , axis [ 1 ] , axis [ 2 ] ) ;
2016-01-18 05:22:07 +00:00
else
AngleVectors ( ang , axis [ 0 ] , axis [ 1 ] , axis [ 2 ] ) ;
VectorInverse ( axis [ 1 ] ) ;
parent [ 0 ] = axis [ 0 ] [ 0 ] ;
parent [ 1 ] = axis [ 1 ] [ 0 ] ;
parent [ 2 ] = axis [ 2 ] [ 0 ] ;
parent [ 3 ] = org [ 0 ] ;
parent [ 4 ] = axis [ 0 ] [ 1 ] ;
parent [ 5 ] = axis [ 1 ] [ 1 ] ;
parent [ 6 ] = axis [ 2 ] [ 1 ] ;
parent [ 7 ] = org [ 1 ] ;
parent [ 8 ] = axis [ 0 ] [ 2 ] ;
parent [ 9 ] = axis [ 1 ] [ 2 ] ;
parent [ 10 ] = axis [ 2 ] [ 2 ] ;
parent [ 11 ] = org [ 2 ] ;
2009-07-18 20:46:42 +00:00
2016-07-12 00:40:13 +00:00
CL_LerpNetFrameState ( & fstate , & cl . lerpents [ parenttagent ] ) ;
2013-12-29 22:48:28 +00:00
/*inherit certain properties from the parent entity*/
if ( ps - > dpflags & RENDER_VIEWMODEL )
2014-03-31 17:06:41 +00:00
ent - > flags | = RF_WEAPONMODEL | Q2RF_MINLIGHT | RF_DEPTHHACK ;
2013-12-29 22:48:28 +00:00
if ( ( ps - > dpflags & RENDER_EXTERIORMODEL ) | | r_refdef . playerview - > viewentity = = ps - > number )
2014-03-31 17:06:41 +00:00
ent - > flags | = RF_EXTERNALMODEL ;
2013-12-29 22:48:28 +00:00
2015-10-27 15:20:15 +00:00
//hack for xonotic.
if ( ( ent - > flags & RF_WEAPONMODEL ) & & ent - > playerindex = = - 1 & & ps - > colormap > 0 & & ps - > colormap < = cl . allocated_client_slots )
2013-12-29 22:48:28 +00:00
{
ent - > playerindex = ps - > colormap - 1 ;
2018-03-04 14:41:16 +00:00
ent - > topcolour = cl . players [ ent - > playerindex ] . dtopcolor ;
ent - > bottomcolour = cl . players [ ent - > playerindex ] . dbottomcolor ;
2013-12-29 22:48:28 +00:00
}
2004-10-10 06:32:29 +00:00
}
else
{
extern int parsecountmod ;
2005-02-06 02:47:36 +00:00
// Con_Printf("tagent %i\n", tagent);
2013-06-23 02:17:02 +00:00
if ( parenttagent < = cl . allocated_client_slots & & parenttagent > 0 )
2004-10-10 06:32:29 +00:00
{
2013-06-23 02:17:02 +00:00
if ( parenttagent = = cl . playerview [ 0 ] . playernum + 1 )
2004-10-10 06:32:29 +00:00
{
2012-07-05 19:42:36 +00:00
org = cl . playerview [ 0 ] . simorg ;
ang = cl . playerview [ 0 ] . simangles ;
2004-10-10 06:32:29 +00:00
}
else
{
2013-03-12 22:53:23 +00:00
org = cl . inframes [ parsecountmod ] . playerstate [ parenttagent - 1 ] . origin ;
ang = cl . inframes [ parsecountmod ] . playerstate [ parenttagent - 1 ] . viewangles ;
2004-10-10 06:32:29 +00:00
}
2016-01-18 05:22:07 +00:00
model = cl . model_precache [ cl . inframes [ parsecountmod ] . playerstate [ parenttagent - 1 ] . modelindex ] ;
2009-07-18 20:46:42 +00:00
2016-07-12 00:40:13 +00:00
CL_LerpNetFrameState ( & fstate , & cl . lerpplayers [ parenttagent - 1 ] ) ;
2004-10-10 06:32:29 +00:00
}
2009-02-03 00:08:32 +00:00
else
2009-07-18 20:46:42 +00:00
{
2016-07-12 00:40:13 +00:00
CL_LerpNetFrameState ( & fstate , & cl . lerpents [ parenttagent ] ) ;
2009-02-03 00:08:32 +00:00
model = 0 ;
2009-07-18 20:46:42 +00:00
}
2004-10-10 06:32:29 +00:00
}
{
2009-07-18 20:46:42 +00:00
// fstate.g[FS_REG].lerpfrac = CL_EntLerpFactor(tagent);
// fstate.g[FS_REG].frametime[0] = cl.time - cl.lerpents[tagent].framechange;
// fstate.g[FS_REG].frametime[1] = cl.time - cl.lerpents[tagent].oldframechange;
2016-01-18 05:22:07 +00:00
if ( Mod_GetTag ( model , parenttagnum , & fstate , transform ) )
2004-11-17 17:55:19 +00:00
{
2016-01-18 05:22:07 +00:00
// parent -> transform -> old
R_ConcatTransforms ( ( void * ) parent , ( void * ) transform , ( void * ) temp ) ;
R_ConcatTransforms ( ( void * ) temp , ( void * ) old , ( void * ) result ) ;
2005-06-14 04:52:10 +00:00
ent - > axis [ 0 ] [ 0 ] = result [ 0 ] ;
ent - > axis [ 1 ] [ 0 ] = result [ 1 ] ;
ent - > axis [ 2 ] [ 0 ] = result [ 2 ] ;
ent - > origin [ 0 ] = result [ 3 ] ;
ent - > axis [ 0 ] [ 1 ] = result [ 4 ] ;
ent - > axis [ 1 ] [ 1 ] = result [ 5 ] ;
ent - > axis [ 2 ] [ 1 ] = result [ 6 ] ;
ent - > origin [ 1 ] = result [ 7 ] ;
ent - > axis [ 0 ] [ 2 ] = result [ 8 ] ;
ent - > axis [ 1 ] [ 2 ] = result [ 9 ] ;
ent - > axis [ 2 ] [ 2 ] = result [ 10 ] ;
ent - > origin [ 2 ] = result [ 11 ] ;
2004-11-17 17:55:19 +00:00
}
else //hrm.
2005-02-06 02:47:36 +00:00
{
2015-10-27 15:20:15 +00:00
R_ConcatTransforms ( ( void * ) parent , ( void * ) old , ( void * ) result ) ;
2006-02-01 22:36:12 +00:00
ent - > axis [ 0 ] [ 0 ] = result [ 0 ] ;
ent - > axis [ 1 ] [ 0 ] = result [ 1 ] ;
ent - > axis [ 2 ] [ 0 ] = result [ 2 ] ;
ent - > origin [ 0 ] = result [ 3 ] ;
ent - > axis [ 0 ] [ 1 ] = result [ 4 ] ;
ent - > axis [ 1 ] [ 1 ] = result [ 5 ] ;
ent - > axis [ 2 ] [ 1 ] = result [ 6 ] ;
ent - > origin [ 1 ] = result [ 7 ] ;
ent - > axis [ 0 ] [ 2 ] = result [ 8 ] ;
ent - > axis [ 1 ] [ 2 ] = result [ 9 ] ;
ent - > axis [ 2 ] [ 2 ] = result [ 10 ] ;
ent - > origin [ 2 ] = result [ 11 ] ;
2005-02-06 02:47:36 +00:00
}
2004-10-10 06:32:29 +00:00
}
2016-01-18 05:22:07 +00:00
if ( ps & & ps - > tagentity )
CL_RotateAroundTag ( ent , entnum , ps - > tagentity , ps - > tagindex ) ;
2004-10-10 06:32:29 +00:00
}
2005-02-28 07:16:19 +00:00
2005-08-03 23:14:59 +00:00
void V_AddAxisEntity ( entity_t * in )
{
entity_t * ent ;
------------------------------------------------------------------------
r4169 | acceptthis | 2013-01-17 08:55:12 +0000 (Thu, 17 Jan 2013) | 31 lines
removed MAX_VISEDICTS limit.
PEXT2_REPLACEMENTDELTAS tweaked, now has 4 million entity limit. still not enabled by default.
TE_BEAM now maps to a separate TEQW_BEAM to avoid conflicts with QW.
added android multitouch emulation for windows/rawinput (in_simulatemultitouch).
split topcolor/bottomcolor from scoreboard, for dp's colormap|1024 feature.
now using utf-8 for windows consoles.
qcc warnings/errors now give clickable console links for quick+easy editing.
disabled menutint when the currently active item changes contrast or gamma (for OneManClan).
Added support for drawfont/drawfontscale.
tweaked the qcvm a little to reduce the number of pointers.
.doll file loading. still experimental and will likely crash. requires csqc active, even if its a dummy progs. this will be fixed in time. Still other things that need cleaning up.
windows: gl_font "?" shows the standard windows font-selection dialog, and can be used to select windows fonts. not all work. and you probably don't want to use windings.
fixed splitscreen support when playing mvds. added mini-scoreboards to splitscreen.
editor/debugger now shows asm if there's no linenumber info. also, pressing f1 for help shows the shortcuts.
Added support for .framegroups files for psk(psa) and iqm formats.
True support for ezquake's colour codes. Mutually exclusive with background colours.
path command output slightly more readable.
added support for digest_hex (MD4, SHA1, CRC16).
skingroups now colourmap correctly.
Fix terrain colour hints, and litdata from the wrong bsp.
fix ftp dual-homed issue. support epsv command, and enable ipv6 (eprt still not supported).
remove d3d11 compilation from the makefile. the required headers are not provided by mingw, and are not available to the build bot, so don't bother.
fix v *= v.x and similar opcodes.
fteqcc: fixed support for áéíóú type chars in names. utf-8 files now properly supported (even with the utf-8 bom/identifier). utf-16 also supported.
fteqcc: fixed '#if 1 == 3 && 4' parsing.
fteqcc: -Werror acts on the warning, rather than as a separate error. Line numbers are thus more readable.
fteqcc: copyright message now includes compile date instead.
fteqccgui: the treeview control is now coloured depending on whether there were warnings/errors in the last compile.
fteqccgui: the output window is now focused and scrolls down as compilation progresses.
pr_dumpplatform command dumps out some pragmas to convert more serious warnings to errors. This is to avoid the infamous 'fteqcc sucks cos my code sucks' issue.
rewrote prespawn/modelist/soundlist code. server tracks progress now.
------------------------------------------------------------------------
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@4167 fc73d0e0-1445-4013-8a0c-d673dee63da5
2013-03-12 22:29:40 +00:00
if ( cl_numvisedicts = = cl_maxvisedicts )
2005-08-03 23:14:59 +00:00
{
return ; // object list is full
}
ent = & cl_visedicts [ cl_numvisedicts ] ;
cl_numvisedicts + + ;
* ent = * in ;
}
------------------------------------------------------------------------
r4169 | acceptthis | 2013-01-17 08:55:12 +0000 (Thu, 17 Jan 2013) | 31 lines
removed MAX_VISEDICTS limit.
PEXT2_REPLACEMENTDELTAS tweaked, now has 4 million entity limit. still not enabled by default.
TE_BEAM now maps to a separate TEQW_BEAM to avoid conflicts with QW.
added android multitouch emulation for windows/rawinput (in_simulatemultitouch).
split topcolor/bottomcolor from scoreboard, for dp's colormap|1024 feature.
now using utf-8 for windows consoles.
qcc warnings/errors now give clickable console links for quick+easy editing.
disabled menutint when the currently active item changes contrast or gamma (for OneManClan).
Added support for drawfont/drawfontscale.
tweaked the qcvm a little to reduce the number of pointers.
.doll file loading. still experimental and will likely crash. requires csqc active, even if its a dummy progs. this will be fixed in time. Still other things that need cleaning up.
windows: gl_font "?" shows the standard windows font-selection dialog, and can be used to select windows fonts. not all work. and you probably don't want to use windings.
fixed splitscreen support when playing mvds. added mini-scoreboards to splitscreen.
editor/debugger now shows asm if there's no linenumber info. also, pressing f1 for help shows the shortcuts.
Added support for .framegroups files for psk(psa) and iqm formats.
True support for ezquake's colour codes. Mutually exclusive with background colours.
path command output slightly more readable.
added support for digest_hex (MD4, SHA1, CRC16).
skingroups now colourmap correctly.
Fix terrain colour hints, and litdata from the wrong bsp.
fix ftp dual-homed issue. support epsv command, and enable ipv6 (eprt still not supported).
remove d3d11 compilation from the makefile. the required headers are not provided by mingw, and are not available to the build bot, so don't bother.
fix v *= v.x and similar opcodes.
fteqcc: fixed support for áéíóú type chars in names. utf-8 files now properly supported (even with the utf-8 bom/identifier). utf-16 also supported.
fteqcc: fixed '#if 1 == 3 && 4' parsing.
fteqcc: -Werror acts on the warning, rather than as a separate error. Line numbers are thus more readable.
fteqcc: copyright message now includes compile date instead.
fteqccgui: the treeview control is now coloured depending on whether there were warnings/errors in the last compile.
fteqccgui: the output window is now focused and scrolls down as compilation progresses.
pr_dumpplatform command dumps out some pragmas to convert more serious warnings to errors. This is to avoid the infamous 'fteqcc sucks cos my code sucks' issue.
rewrote prespawn/modelist/soundlist code. server tracks progress now.
------------------------------------------------------------------------
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@4167 fc73d0e0-1445-4013-8a0c-d673dee63da5
2013-03-12 22:29:40 +00:00
void V_ClearEntity ( entity_t * e )
{
memset ( e , 0 , sizeof ( * e ) ) ;
2019-04-07 16:41:09 +00:00
e - > pvscache . num_leafs = - 1 ;
------------------------------------------------------------------------
r4169 | acceptthis | 2013-01-17 08:55:12 +0000 (Thu, 17 Jan 2013) | 31 lines
removed MAX_VISEDICTS limit.
PEXT2_REPLACEMENTDELTAS tweaked, now has 4 million entity limit. still not enabled by default.
TE_BEAM now maps to a separate TEQW_BEAM to avoid conflicts with QW.
added android multitouch emulation for windows/rawinput (in_simulatemultitouch).
split topcolor/bottomcolor from scoreboard, for dp's colormap|1024 feature.
now using utf-8 for windows consoles.
qcc warnings/errors now give clickable console links for quick+easy editing.
disabled menutint when the currently active item changes contrast or gamma (for OneManClan).
Added support for drawfont/drawfontscale.
tweaked the qcvm a little to reduce the number of pointers.
.doll file loading. still experimental and will likely crash. requires csqc active, even if its a dummy progs. this will be fixed in time. Still other things that need cleaning up.
windows: gl_font "?" shows the standard windows font-selection dialog, and can be used to select windows fonts. not all work. and you probably don't want to use windings.
fixed splitscreen support when playing mvds. added mini-scoreboards to splitscreen.
editor/debugger now shows asm if there's no linenumber info. also, pressing f1 for help shows the shortcuts.
Added support for .framegroups files for psk(psa) and iqm formats.
True support for ezquake's colour codes. Mutually exclusive with background colours.
path command output slightly more readable.
added support for digest_hex (MD4, SHA1, CRC16).
skingroups now colourmap correctly.
Fix terrain colour hints, and litdata from the wrong bsp.
fix ftp dual-homed issue. support epsv command, and enable ipv6 (eprt still not supported).
remove d3d11 compilation from the makefile. the required headers are not provided by mingw, and are not available to the build bot, so don't bother.
fix v *= v.x and similar opcodes.
fteqcc: fixed support for áéíóú type chars in names. utf-8 files now properly supported (even with the utf-8 bom/identifier). utf-16 also supported.
fteqcc: fixed '#if 1 == 3 && 4' parsing.
fteqcc: -Werror acts on the warning, rather than as a separate error. Line numbers are thus more readable.
fteqcc: copyright message now includes compile date instead.
fteqccgui: the treeview control is now coloured depending on whether there were warnings/errors in the last compile.
fteqccgui: the output window is now focused and scrolls down as compilation progresses.
pr_dumpplatform command dumps out some pragmas to convert more serious warnings to errors. This is to avoid the infamous 'fteqcc sucks cos my code sucks' issue.
rewrote prespawn/modelist/soundlist code. server tracks progress now.
------------------------------------------------------------------------
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@4167 fc73d0e0-1445-4013-8a0c-d673dee63da5
2013-03-12 22:29:40 +00:00
e - > playerindex = - 1 ;
e - > topcolour = TOP_DEFAULT ;
e - > bottomcolour = BOTTOM_DEFAULT ;
}
2011-04-25 03:25:22 +00:00
entity_t * V_AddEntity ( entity_t * in )
2005-02-28 07:16:19 +00:00
{
entity_t * ent ;
2005-06-04 04:20:20 +00:00
------------------------------------------------------------------------
r4169 | acceptthis | 2013-01-17 08:55:12 +0000 (Thu, 17 Jan 2013) | 31 lines
removed MAX_VISEDICTS limit.
PEXT2_REPLACEMENTDELTAS tweaked, now has 4 million entity limit. still not enabled by default.
TE_BEAM now maps to a separate TEQW_BEAM to avoid conflicts with QW.
added android multitouch emulation for windows/rawinput (in_simulatemultitouch).
split topcolor/bottomcolor from scoreboard, for dp's colormap|1024 feature.
now using utf-8 for windows consoles.
qcc warnings/errors now give clickable console links for quick+easy editing.
disabled menutint when the currently active item changes contrast or gamma (for OneManClan).
Added support for drawfont/drawfontscale.
tweaked the qcvm a little to reduce the number of pointers.
.doll file loading. still experimental and will likely crash. requires csqc active, even if its a dummy progs. this will be fixed in time. Still other things that need cleaning up.
windows: gl_font "?" shows the standard windows font-selection dialog, and can be used to select windows fonts. not all work. and you probably don't want to use windings.
fixed splitscreen support when playing mvds. added mini-scoreboards to splitscreen.
editor/debugger now shows asm if there's no linenumber info. also, pressing f1 for help shows the shortcuts.
Added support for .framegroups files for psk(psa) and iqm formats.
True support for ezquake's colour codes. Mutually exclusive with background colours.
path command output slightly more readable.
added support for digest_hex (MD4, SHA1, CRC16).
skingroups now colourmap correctly.
Fix terrain colour hints, and litdata from the wrong bsp.
fix ftp dual-homed issue. support epsv command, and enable ipv6 (eprt still not supported).
remove d3d11 compilation from the makefile. the required headers are not provided by mingw, and are not available to the build bot, so don't bother.
fix v *= v.x and similar opcodes.
fteqcc: fixed support for áéíóú type chars in names. utf-8 files now properly supported (even with the utf-8 bom/identifier). utf-16 also supported.
fteqcc: fixed '#if 1 == 3 && 4' parsing.
fteqcc: -Werror acts on the warning, rather than as a separate error. Line numbers are thus more readable.
fteqcc: copyright message now includes compile date instead.
fteqccgui: the treeview control is now coloured depending on whether there were warnings/errors in the last compile.
fteqccgui: the output window is now focused and scrolls down as compilation progresses.
pr_dumpplatform command dumps out some pragmas to convert more serious warnings to errors. This is to avoid the infamous 'fteqcc sucks cos my code sucks' issue.
rewrote prespawn/modelist/soundlist code. server tracks progress now.
------------------------------------------------------------------------
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@4167 fc73d0e0-1445-4013-8a0c-d673dee63da5
2013-03-12 22:29:40 +00:00
if ( cl_numvisedicts = = cl_maxvisedicts )
2005-06-04 04:20:20 +00:00
{
2011-04-25 03:25:22 +00:00
return NULL ; // object list is full
2005-06-04 04:20:20 +00:00
}
2005-02-28 07:16:19 +00:00
ent = & cl_visedicts [ cl_numvisedicts ] ;
cl_numvisedicts + + ;
* ent = * in ;
2020-10-06 03:17:28 +00:00
AngleVectorsMesh ( ent - > angles , ent - > axis [ 0 ] , ent - > axis [ 1 ] , ent - > axis [ 2 ] ) ;
2005-02-28 07:16:19 +00:00
VectorInverse ( ent - > axis [ 1 ] ) ;
2011-04-25 03:25:22 +00:00
return ent ;
2005-02-28 07:16:19 +00:00
}
2011-06-29 18:39:11 +00:00
/*
2008-12-23 02:55:20 +00:00
void VQ2_AddLerpEntity ( entity_t * in ) //a convienience function
2005-03-18 06:14:07 +00:00
{
entity_t * ent ;
float fwds , back ;
int i ;
if ( cl_numvisedicts = = MAX_VISEDICTS )
return ; // object list is full
ent = & cl_visedicts [ cl_numvisedicts ] ;
cl_numvisedicts + + ;
* ent = * in ;
2008-12-23 02:55:20 +00:00
fwds = ent - > framestate . g [ FS_REG ] . lerpfrac ;
back = 1 - ent - > framestate . g [ FS_REG ] . lerpfrac ;
2005-03-18 06:14:07 +00:00
for ( i = 0 ; i < 3 ; i + + )
{
ent - > origin [ i ] = in - > origin [ i ] * fwds + in - > oldorigin [ i ] * back ;
}
2008-12-23 02:55:20 +00:00
ent - > framestate . g [ FS_REG ] . lerpfrac = back ;
2005-05-15 18:49:04 +00:00
2020-10-06 03:17:28 +00:00
AngleVectorsMesh ( ent - > angles , ent - > axis [ 0 ] , ent - > axis [ 1 ] , ent - > axis [ 2 ] ) ;
2005-03-18 06:14:07 +00:00
VectorInverse ( ent - > axis [ 1 ] ) ;
}
2011-06-29 18:39:11 +00:00
*/
2009-11-04 21:16:50 +00:00
int V_AddLight ( int entsource , vec3_t org , float quant , float r , float g , float b )
2007-05-25 22:16:29 +00:00
{
2015-10-11 11:34:58 +00:00
return CL_NewDlight ( entsource , org , quant , - 0.1 , r * 5 , g * 5 , b * 5 ) - cl_dlights ;
2007-05-25 22:16:29 +00:00
}
------------------------------------------------------------------------
r4169 | acceptthis | 2013-01-17 08:55:12 +0000 (Thu, 17 Jan 2013) | 31 lines
removed MAX_VISEDICTS limit.
PEXT2_REPLACEMENTDELTAS tweaked, now has 4 million entity limit. still not enabled by default.
TE_BEAM now maps to a separate TEQW_BEAM to avoid conflicts with QW.
added android multitouch emulation for windows/rawinput (in_simulatemultitouch).
split topcolor/bottomcolor from scoreboard, for dp's colormap|1024 feature.
now using utf-8 for windows consoles.
qcc warnings/errors now give clickable console links for quick+easy editing.
disabled menutint when the currently active item changes contrast or gamma (for OneManClan).
Added support for drawfont/drawfontscale.
tweaked the qcvm a little to reduce the number of pointers.
.doll file loading. still experimental and will likely crash. requires csqc active, even if its a dummy progs. this will be fixed in time. Still other things that need cleaning up.
windows: gl_font "?" shows the standard windows font-selection dialog, and can be used to select windows fonts. not all work. and you probably don't want to use windings.
fixed splitscreen support when playing mvds. added mini-scoreboards to splitscreen.
editor/debugger now shows asm if there's no linenumber info. also, pressing f1 for help shows the shortcuts.
Added support for .framegroups files for psk(psa) and iqm formats.
True support for ezquake's colour codes. Mutually exclusive with background colours.
path command output slightly more readable.
added support for digest_hex (MD4, SHA1, CRC16).
skingroups now colourmap correctly.
Fix terrain colour hints, and litdata from the wrong bsp.
fix ftp dual-homed issue. support epsv command, and enable ipv6 (eprt still not supported).
remove d3d11 compilation from the makefile. the required headers are not provided by mingw, and are not available to the build bot, so don't bother.
fix v *= v.x and similar opcodes.
fteqcc: fixed support for áéíóú type chars in names. utf-8 files now properly supported (even with the utf-8 bom/identifier). utf-16 also supported.
fteqcc: fixed '#if 1 == 3 && 4' parsing.
fteqcc: -Werror acts on the warning, rather than as a separate error. Line numbers are thus more readable.
fteqcc: copyright message now includes compile date instead.
fteqccgui: the treeview control is now coloured depending on whether there were warnings/errors in the last compile.
fteqccgui: the output window is now focused and scrolls down as compilation progresses.
pr_dumpplatform command dumps out some pragmas to convert more serious warnings to errors. This is to avoid the infamous 'fteqcc sucks cos my code sucks' issue.
rewrote prespawn/modelist/soundlist code. server tracks progress now.
------------------------------------------------------------------------
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@4167 fc73d0e0-1445-4013-8a0c-d673dee63da5
2013-03-12 22:29:40 +00:00
void CLQ1_AddOrientedHalfSphere ( shader_t * shader , float radius , float gap , float * matrix , float r , float g , float b , float a )
2012-02-12 05:18:31 +00:00
{
------------------------------------------------------------------------
r4169 | acceptthis | 2013-01-17 08:55:12 +0000 (Thu, 17 Jan 2013) | 31 lines
removed MAX_VISEDICTS limit.
PEXT2_REPLACEMENTDELTAS tweaked, now has 4 million entity limit. still not enabled by default.
TE_BEAM now maps to a separate TEQW_BEAM to avoid conflicts with QW.
added android multitouch emulation for windows/rawinput (in_simulatemultitouch).
split topcolor/bottomcolor from scoreboard, for dp's colormap|1024 feature.
now using utf-8 for windows consoles.
qcc warnings/errors now give clickable console links for quick+easy editing.
disabled menutint when the currently active item changes contrast or gamma (for OneManClan).
Added support for drawfont/drawfontscale.
tweaked the qcvm a little to reduce the number of pointers.
.doll file loading. still experimental and will likely crash. requires csqc active, even if its a dummy progs. this will be fixed in time. Still other things that need cleaning up.
windows: gl_font "?" shows the standard windows font-selection dialog, and can be used to select windows fonts. not all work. and you probably don't want to use windings.
fixed splitscreen support when playing mvds. added mini-scoreboards to splitscreen.
editor/debugger now shows asm if there's no linenumber info. also, pressing f1 for help shows the shortcuts.
Added support for .framegroups files for psk(psa) and iqm formats.
True support for ezquake's colour codes. Mutually exclusive with background colours.
path command output slightly more readable.
added support for digest_hex (MD4, SHA1, CRC16).
skingroups now colourmap correctly.
Fix terrain colour hints, and litdata from the wrong bsp.
fix ftp dual-homed issue. support epsv command, and enable ipv6 (eprt still not supported).
remove d3d11 compilation from the makefile. the required headers are not provided by mingw, and are not available to the build bot, so don't bother.
fix v *= v.x and similar opcodes.
fteqcc: fixed support for áéíóú type chars in names. utf-8 files now properly supported (even with the utf-8 bom/identifier). utf-16 also supported.
fteqcc: fixed '#if 1 == 3 && 4' parsing.
fteqcc: -Werror acts on the warning, rather than as a separate error. Line numbers are thus more readable.
fteqcc: copyright message now includes compile date instead.
fteqccgui: the treeview control is now coloured depending on whether there were warnings/errors in the last compile.
fteqccgui: the output window is now focused and scrolls down as compilation progresses.
pr_dumpplatform command dumps out some pragmas to convert more serious warnings to errors. This is to avoid the infamous 'fteqcc sucks cos my code sucks' issue.
rewrote prespawn/modelist/soundlist code. server tracks progress now.
------------------------------------------------------------------------
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@4167 fc73d0e0-1445-4013-8a0c-d673dee63da5
2013-03-12 22:29:40 +00:00
//use simple algo
//a series of cylinders that gets progressively narrower
2018-04-27 16:40:50 +00:00
const int latsteps = 16 ;
const int lngsteps = 8 ; //16;
------------------------------------------------------------------------
r4169 | acceptthis | 2013-01-17 08:55:12 +0000 (Thu, 17 Jan 2013) | 31 lines
removed MAX_VISEDICTS limit.
PEXT2_REPLACEMENTDELTAS tweaked, now has 4 million entity limit. still not enabled by default.
TE_BEAM now maps to a separate TEQW_BEAM to avoid conflicts with QW.
added android multitouch emulation for windows/rawinput (in_simulatemultitouch).
split topcolor/bottomcolor from scoreboard, for dp's colormap|1024 feature.
now using utf-8 for windows consoles.
qcc warnings/errors now give clickable console links for quick+easy editing.
disabled menutint when the currently active item changes contrast or gamma (for OneManClan).
Added support for drawfont/drawfontscale.
tweaked the qcvm a little to reduce the number of pointers.
.doll file loading. still experimental and will likely crash. requires csqc active, even if its a dummy progs. this will be fixed in time. Still other things that need cleaning up.
windows: gl_font "?" shows the standard windows font-selection dialog, and can be used to select windows fonts. not all work. and you probably don't want to use windings.
fixed splitscreen support when playing mvds. added mini-scoreboards to splitscreen.
editor/debugger now shows asm if there's no linenumber info. also, pressing f1 for help shows the shortcuts.
Added support for .framegroups files for psk(psa) and iqm formats.
True support for ezquake's colour codes. Mutually exclusive with background colours.
path command output slightly more readable.
added support for digest_hex (MD4, SHA1, CRC16).
skingroups now colourmap correctly.
Fix terrain colour hints, and litdata from the wrong bsp.
fix ftp dual-homed issue. support epsv command, and enable ipv6 (eprt still not supported).
remove d3d11 compilation from the makefile. the required headers are not provided by mingw, and are not available to the build bot, so don't bother.
fix v *= v.x and similar opcodes.
fteqcc: fixed support for áéíóú type chars in names. utf-8 files now properly supported (even with the utf-8 bom/identifier). utf-16 also supported.
fteqcc: fixed '#if 1 == 3 && 4' parsing.
fteqcc: -Werror acts on the warning, rather than as a separate error. Line numbers are thus more readable.
fteqcc: copyright message now includes compile date instead.
fteqccgui: the treeview control is now coloured depending on whether there were warnings/errors in the last compile.
fteqccgui: the output window is now focused and scrolls down as compilation progresses.
pr_dumpplatform command dumps out some pragmas to convert more serious warnings to errors. This is to avoid the infamous 'fteqcc sucks cos my code sucks' issue.
rewrote prespawn/modelist/soundlist code. server tracks progress now.
------------------------------------------------------------------------
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@4167 fc73d0e0-1445-4013-8a0c-d673dee63da5
2013-03-12 22:29:40 +00:00
float cradius ;
int v , i , j ;
scenetris_t * t ;
vec3_t corner ;
float x , y ;
int flags = BEF_NODLIGHT | BEF_NOSHADOWS ;
if ( ! r & & ! g & & ! b )
return ;
/*reuse the previous trigroup if its the same shader*/
2018-04-27 16:40:50 +00:00
if ( cl_numstris & & cl_stris [ cl_numstris - 1 ] . shader = = shader & & cl_stris [ cl_numstris - 1 ] . flags = = flags & & cl_stris [ cl_numstris - 1 ] . numvert < MAX_INDICIES - ( latsteps - 1 ) * ( lngsteps - 1 ) )
------------------------------------------------------------------------
r4169 | acceptthis | 2013-01-17 08:55:12 +0000 (Thu, 17 Jan 2013) | 31 lines
removed MAX_VISEDICTS limit.
PEXT2_REPLACEMENTDELTAS tweaked, now has 4 million entity limit. still not enabled by default.
TE_BEAM now maps to a separate TEQW_BEAM to avoid conflicts with QW.
added android multitouch emulation for windows/rawinput (in_simulatemultitouch).
split topcolor/bottomcolor from scoreboard, for dp's colormap|1024 feature.
now using utf-8 for windows consoles.
qcc warnings/errors now give clickable console links for quick+easy editing.
disabled menutint when the currently active item changes contrast or gamma (for OneManClan).
Added support for drawfont/drawfontscale.
tweaked the qcvm a little to reduce the number of pointers.
.doll file loading. still experimental and will likely crash. requires csqc active, even if its a dummy progs. this will be fixed in time. Still other things that need cleaning up.
windows: gl_font "?" shows the standard windows font-selection dialog, and can be used to select windows fonts. not all work. and you probably don't want to use windings.
fixed splitscreen support when playing mvds. added mini-scoreboards to splitscreen.
editor/debugger now shows asm if there's no linenumber info. also, pressing f1 for help shows the shortcuts.
Added support for .framegroups files for psk(psa) and iqm formats.
True support for ezquake's colour codes. Mutually exclusive with background colours.
path command output slightly more readable.
added support for digest_hex (MD4, SHA1, CRC16).
skingroups now colourmap correctly.
Fix terrain colour hints, and litdata from the wrong bsp.
fix ftp dual-homed issue. support epsv command, and enable ipv6 (eprt still not supported).
remove d3d11 compilation from the makefile. the required headers are not provided by mingw, and are not available to the build bot, so don't bother.
fix v *= v.x and similar opcodes.
fteqcc: fixed support for áéíóú type chars in names. utf-8 files now properly supported (even with the utf-8 bom/identifier). utf-16 also supported.
fteqcc: fixed '#if 1 == 3 && 4' parsing.
fteqcc: -Werror acts on the warning, rather than as a separate error. Line numbers are thus more readable.
fteqcc: copyright message now includes compile date instead.
fteqccgui: the treeview control is now coloured depending on whether there were warnings/errors in the last compile.
fteqccgui: the output window is now focused and scrolls down as compilation progresses.
pr_dumpplatform command dumps out some pragmas to convert more serious warnings to errors. This is to avoid the infamous 'fteqcc sucks cos my code sucks' issue.
rewrote prespawn/modelist/soundlist code. server tracks progress now.
------------------------------------------------------------------------
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@4167 fc73d0e0-1445-4013-8a0c-d673dee63da5
2013-03-12 22:29:40 +00:00
t = & cl_stris [ cl_numstris - 1 ] ;
else
{
if ( cl_numstris = = cl_maxstris )
{
cl_maxstris + = 8 ;
cl_stris = BZ_Realloc ( cl_stris , sizeof ( * cl_stris ) * cl_maxstris ) ;
}
t = & cl_stris [ cl_numstris + + ] ;
t - > shader = shader ;
t - > numidx = 0 ;
t - > numvert = 0 ;
t - > firstidx = cl_numstrisidx ;
t - > firstvert = cl_numstrisvert ;
t - > flags = flags ;
}
if ( cl_numstrisvert + latsteps * lngsteps > cl_maxstrisvert )
2019-02-19 06:49:03 +00:00
cl_stris_ExpandVerts ( cl_numstrisvert + latsteps * lngsteps ) ;
------------------------------------------------------------------------
r4169 | acceptthis | 2013-01-17 08:55:12 +0000 (Thu, 17 Jan 2013) | 31 lines
removed MAX_VISEDICTS limit.
PEXT2_REPLACEMENTDELTAS tweaked, now has 4 million entity limit. still not enabled by default.
TE_BEAM now maps to a separate TEQW_BEAM to avoid conflicts with QW.
added android multitouch emulation for windows/rawinput (in_simulatemultitouch).
split topcolor/bottomcolor from scoreboard, for dp's colormap|1024 feature.
now using utf-8 for windows consoles.
qcc warnings/errors now give clickable console links for quick+easy editing.
disabled menutint when the currently active item changes contrast or gamma (for OneManClan).
Added support for drawfont/drawfontscale.
tweaked the qcvm a little to reduce the number of pointers.
.doll file loading. still experimental and will likely crash. requires csqc active, even if its a dummy progs. this will be fixed in time. Still other things that need cleaning up.
windows: gl_font "?" shows the standard windows font-selection dialog, and can be used to select windows fonts. not all work. and you probably don't want to use windings.
fixed splitscreen support when playing mvds. added mini-scoreboards to splitscreen.
editor/debugger now shows asm if there's no linenumber info. also, pressing f1 for help shows the shortcuts.
Added support for .framegroups files for psk(psa) and iqm formats.
True support for ezquake's colour codes. Mutually exclusive with background colours.
path command output slightly more readable.
added support for digest_hex (MD4, SHA1, CRC16).
skingroups now colourmap correctly.
Fix terrain colour hints, and litdata from the wrong bsp.
fix ftp dual-homed issue. support epsv command, and enable ipv6 (eprt still not supported).
remove d3d11 compilation from the makefile. the required headers are not provided by mingw, and are not available to the build bot, so don't bother.
fix v *= v.x and similar opcodes.
fteqcc: fixed support for áéíóú type chars in names. utf-8 files now properly supported (even with the utf-8 bom/identifier). utf-16 also supported.
fteqcc: fixed '#if 1 == 3 && 4' parsing.
fteqcc: -Werror acts on the warning, rather than as a separate error. Line numbers are thus more readable.
fteqcc: copyright message now includes compile date instead.
fteqccgui: the treeview control is now coloured depending on whether there were warnings/errors in the last compile.
fteqccgui: the output window is now focused and scrolls down as compilation progresses.
pr_dumpplatform command dumps out some pragmas to convert more serious warnings to errors. This is to avoid the infamous 'fteqcc sucks cos my code sucks' issue.
rewrote prespawn/modelist/soundlist code. server tracks progress now.
------------------------------------------------------------------------
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@4167 fc73d0e0-1445-4013-8a0c-d673dee63da5
2013-03-12 22:29:40 +00:00
if ( cl_maxstrisidx < cl_numstrisidx + latsteps * ( lngsteps - 1 ) * 6 )
{
cl_maxstrisidx = cl_numstrisidx + latsteps * ( lngsteps - 1 ) * 6 + 64 ;
cl_strisidx = BZ_Realloc ( cl_strisidx , sizeof ( * cl_strisidx ) * cl_maxstrisidx ) ;
}
for ( i = 0 ; i < latsteps ; i + + )
{
x = sin ( i * 2 * M_PI / latsteps ) ;
y = cos ( i * 2 * M_PI / latsteps ) ;
for ( j = 0 ; j < lngsteps ; j + + )
{
v = i * lngsteps + j ;
cradius = sin ( j * 0.5 * M_PI / ( lngsteps - 1 ) ) * radius ;
corner [ 0 ] = x * cradius ;
corner [ 1 ] = y * cradius ;
corner [ 2 ] = ( cos ( j * 0.5 * M_PI / ( lngsteps - 1 ) ) * - radius ) - gap ;
Matrix3x4_RM_Transform3 ( matrix , corner , cl_strisvertv [ cl_numstrisvert + v ] ) ;
cl_strisvertt [ cl_numstrisvert + v ] [ 0 ] = 0 ;
cl_strisvertt [ cl_numstrisvert + v ] [ 1 ] = 0 ;
cl_strisvertc [ cl_numstrisvert + v ] [ 0 ] = r ;
cl_strisvertc [ cl_numstrisvert + v ] [ 1 ] = g ;
cl_strisvertc [ cl_numstrisvert + v ] [ 2 ] = b ;
cl_strisvertc [ cl_numstrisvert + v ] [ 3 ] = a ;
}
}
if ( radius < 0 )
{
for ( i = 0 ; i < lngsteps - 1 ; i + + )
{
v = latsteps - 1 ;
for ( v = 0 ; v < latsteps - 1 ; v + + )
{
2018-04-27 16:40:50 +00:00
cl_strisidx [ cl_numstrisidx + + ] = cl_numstrisvert - t - > firstvert + lngsteps + v * lngsteps + i ;
cl_strisidx [ cl_numstrisidx + + ] = cl_numstrisvert - t - > firstvert + 0 + v * lngsteps + i ;
cl_strisidx [ cl_numstrisidx + + ] = cl_numstrisvert - t - > firstvert + 1 + v * lngsteps + i ;
cl_strisidx [ cl_numstrisidx + + ] = cl_numstrisvert - t - > firstvert + lngsteps + 1 + v * lngsteps + i ;
cl_strisidx [ cl_numstrisidx + + ] = cl_numstrisvert - t - > firstvert + lngsteps + v * lngsteps + i ;
cl_strisidx [ cl_numstrisidx + + ] = cl_numstrisvert - t - > firstvert + 1 + v * lngsteps + i ;
------------------------------------------------------------------------
r4169 | acceptthis | 2013-01-17 08:55:12 +0000 (Thu, 17 Jan 2013) | 31 lines
removed MAX_VISEDICTS limit.
PEXT2_REPLACEMENTDELTAS tweaked, now has 4 million entity limit. still not enabled by default.
TE_BEAM now maps to a separate TEQW_BEAM to avoid conflicts with QW.
added android multitouch emulation for windows/rawinput (in_simulatemultitouch).
split topcolor/bottomcolor from scoreboard, for dp's colormap|1024 feature.
now using utf-8 for windows consoles.
qcc warnings/errors now give clickable console links for quick+easy editing.
disabled menutint when the currently active item changes contrast or gamma (for OneManClan).
Added support for drawfont/drawfontscale.
tweaked the qcvm a little to reduce the number of pointers.
.doll file loading. still experimental and will likely crash. requires csqc active, even if its a dummy progs. this will be fixed in time. Still other things that need cleaning up.
windows: gl_font "?" shows the standard windows font-selection dialog, and can be used to select windows fonts. not all work. and you probably don't want to use windings.
fixed splitscreen support when playing mvds. added mini-scoreboards to splitscreen.
editor/debugger now shows asm if there's no linenumber info. also, pressing f1 for help shows the shortcuts.
Added support for .framegroups files for psk(psa) and iqm formats.
True support for ezquake's colour codes. Mutually exclusive with background colours.
path command output slightly more readable.
added support for digest_hex (MD4, SHA1, CRC16).
skingroups now colourmap correctly.
Fix terrain colour hints, and litdata from the wrong bsp.
fix ftp dual-homed issue. support epsv command, and enable ipv6 (eprt still not supported).
remove d3d11 compilation from the makefile. the required headers are not provided by mingw, and are not available to the build bot, so don't bother.
fix v *= v.x and similar opcodes.
fteqcc: fixed support for áéíóú type chars in names. utf-8 files now properly supported (even with the utf-8 bom/identifier). utf-16 also supported.
fteqcc: fixed '#if 1 == 3 && 4' parsing.
fteqcc: -Werror acts on the warning, rather than as a separate error. Line numbers are thus more readable.
fteqcc: copyright message now includes compile date instead.
fteqccgui: the treeview control is now coloured depending on whether there were warnings/errors in the last compile.
fteqccgui: the output window is now focused and scrolls down as compilation progresses.
pr_dumpplatform command dumps out some pragmas to convert more serious warnings to errors. This is to avoid the infamous 'fteqcc sucks cos my code sucks' issue.
rewrote prespawn/modelist/soundlist code. server tracks progress now.
------------------------------------------------------------------------
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@4167 fc73d0e0-1445-4013-8a0c-d673dee63da5
2013-03-12 22:29:40 +00:00
}
2018-04-27 16:40:50 +00:00
cl_strisidx [ cl_numstrisidx + + ] = cl_numstrisvert - t - > firstvert + i ;
cl_strisidx [ cl_numstrisidx + + ] = cl_numstrisvert - t - > firstvert + 0 + v * lngsteps + i ;
cl_strisidx [ cl_numstrisidx + + ] = cl_numstrisvert - t - > firstvert + 1 + v * lngsteps + i ;
cl_strisidx [ cl_numstrisidx + + ] = cl_numstrisvert - t - > firstvert + 1 + i ;
cl_strisidx [ cl_numstrisidx + + ] = cl_numstrisvert - t - > firstvert + i ;
cl_strisidx [ cl_numstrisidx + + ] = cl_numstrisvert - t - > firstvert + 1 + v * lngsteps + i ;
------------------------------------------------------------------------
r4169 | acceptthis | 2013-01-17 08:55:12 +0000 (Thu, 17 Jan 2013) | 31 lines
removed MAX_VISEDICTS limit.
PEXT2_REPLACEMENTDELTAS tweaked, now has 4 million entity limit. still not enabled by default.
TE_BEAM now maps to a separate TEQW_BEAM to avoid conflicts with QW.
added android multitouch emulation for windows/rawinput (in_simulatemultitouch).
split topcolor/bottomcolor from scoreboard, for dp's colormap|1024 feature.
now using utf-8 for windows consoles.
qcc warnings/errors now give clickable console links for quick+easy editing.
disabled menutint when the currently active item changes contrast or gamma (for OneManClan).
Added support for drawfont/drawfontscale.
tweaked the qcvm a little to reduce the number of pointers.
.doll file loading. still experimental and will likely crash. requires csqc active, even if its a dummy progs. this will be fixed in time. Still other things that need cleaning up.
windows: gl_font "?" shows the standard windows font-selection dialog, and can be used to select windows fonts. not all work. and you probably don't want to use windings.
fixed splitscreen support when playing mvds. added mini-scoreboards to splitscreen.
editor/debugger now shows asm if there's no linenumber info. also, pressing f1 for help shows the shortcuts.
Added support for .framegroups files for psk(psa) and iqm formats.
True support for ezquake's colour codes. Mutually exclusive with background colours.
path command output slightly more readable.
added support for digest_hex (MD4, SHA1, CRC16).
skingroups now colourmap correctly.
Fix terrain colour hints, and litdata from the wrong bsp.
fix ftp dual-homed issue. support epsv command, and enable ipv6 (eprt still not supported).
remove d3d11 compilation from the makefile. the required headers are not provided by mingw, and are not available to the build bot, so don't bother.
fix v *= v.x and similar opcodes.
fteqcc: fixed support for áéíóú type chars in names. utf-8 files now properly supported (even with the utf-8 bom/identifier). utf-16 also supported.
fteqcc: fixed '#if 1 == 3 && 4' parsing.
fteqcc: -Werror acts on the warning, rather than as a separate error. Line numbers are thus more readable.
fteqcc: copyright message now includes compile date instead.
fteqccgui: the treeview control is now coloured depending on whether there were warnings/errors in the last compile.
fteqccgui: the output window is now focused and scrolls down as compilation progresses.
pr_dumpplatform command dumps out some pragmas to convert more serious warnings to errors. This is to avoid the infamous 'fteqcc sucks cos my code sucks' issue.
rewrote prespawn/modelist/soundlist code. server tracks progress now.
------------------------------------------------------------------------
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@4167 fc73d0e0-1445-4013-8a0c-d673dee63da5
2013-03-12 22:29:40 +00:00
}
}
else
{
for ( i = 0 ; i < lngsteps - 1 ; i + + )
{
v = latsteps - 1 ;
for ( v = 0 ; v < latsteps - 1 ; v + + )
{
2018-04-27 16:40:50 +00:00
cl_strisidx [ cl_numstrisidx + + ] = cl_numstrisvert - t - > firstvert + 0 + v * lngsteps + i ;
cl_strisidx [ cl_numstrisidx + + ] = cl_numstrisvert - t - > firstvert + lngsteps + v * lngsteps + i ;
cl_strisidx [ cl_numstrisidx + + ] = cl_numstrisvert - t - > firstvert + 1 + v * lngsteps + i ;
cl_strisidx [ cl_numstrisidx + + ] = cl_numstrisvert - t - > firstvert + lngsteps + v * lngsteps + i ;
cl_strisidx [ cl_numstrisidx + + ] = cl_numstrisvert - t - > firstvert + lngsteps + 1 + v * lngsteps + i ;
cl_strisidx [ cl_numstrisidx + + ] = cl_numstrisvert - t - > firstvert + 1 + v * lngsteps + i ;
------------------------------------------------------------------------
r4169 | acceptthis | 2013-01-17 08:55:12 +0000 (Thu, 17 Jan 2013) | 31 lines
removed MAX_VISEDICTS limit.
PEXT2_REPLACEMENTDELTAS tweaked, now has 4 million entity limit. still not enabled by default.
TE_BEAM now maps to a separate TEQW_BEAM to avoid conflicts with QW.
added android multitouch emulation for windows/rawinput (in_simulatemultitouch).
split topcolor/bottomcolor from scoreboard, for dp's colormap|1024 feature.
now using utf-8 for windows consoles.
qcc warnings/errors now give clickable console links for quick+easy editing.
disabled menutint when the currently active item changes contrast or gamma (for OneManClan).
Added support for drawfont/drawfontscale.
tweaked the qcvm a little to reduce the number of pointers.
.doll file loading. still experimental and will likely crash. requires csqc active, even if its a dummy progs. this will be fixed in time. Still other things that need cleaning up.
windows: gl_font "?" shows the standard windows font-selection dialog, and can be used to select windows fonts. not all work. and you probably don't want to use windings.
fixed splitscreen support when playing mvds. added mini-scoreboards to splitscreen.
editor/debugger now shows asm if there's no linenumber info. also, pressing f1 for help shows the shortcuts.
Added support for .framegroups files for psk(psa) and iqm formats.
True support for ezquake's colour codes. Mutually exclusive with background colours.
path command output slightly more readable.
added support for digest_hex (MD4, SHA1, CRC16).
skingroups now colourmap correctly.
Fix terrain colour hints, and litdata from the wrong bsp.
fix ftp dual-homed issue. support epsv command, and enable ipv6 (eprt still not supported).
remove d3d11 compilation from the makefile. the required headers are not provided by mingw, and are not available to the build bot, so don't bother.
fix v *= v.x and similar opcodes.
fteqcc: fixed support for áéíóú type chars in names. utf-8 files now properly supported (even with the utf-8 bom/identifier). utf-16 also supported.
fteqcc: fixed '#if 1 == 3 && 4' parsing.
fteqcc: -Werror acts on the warning, rather than as a separate error. Line numbers are thus more readable.
fteqcc: copyright message now includes compile date instead.
fteqccgui: the treeview control is now coloured depending on whether there were warnings/errors in the last compile.
fteqccgui: the output window is now focused and scrolls down as compilation progresses.
pr_dumpplatform command dumps out some pragmas to convert more serious warnings to errors. This is to avoid the infamous 'fteqcc sucks cos my code sucks' issue.
rewrote prespawn/modelist/soundlist code. server tracks progress now.
------------------------------------------------------------------------
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@4167 fc73d0e0-1445-4013-8a0c-d673dee63da5
2013-03-12 22:29:40 +00:00
}
2018-04-27 16:40:50 +00:00
cl_strisidx [ cl_numstrisidx + + ] = cl_numstrisvert - t - > firstvert + 0 + v * lngsteps + i ;
cl_strisidx [ cl_numstrisidx + + ] = cl_numstrisvert - t - > firstvert + i ;
cl_strisidx [ cl_numstrisidx + + ] = cl_numstrisvert - t - > firstvert + 1 + v * lngsteps + i ;
cl_strisidx [ cl_numstrisidx + + ] = cl_numstrisvert - t - > firstvert + i ;
cl_strisidx [ cl_numstrisidx + + ] = cl_numstrisvert - t - > firstvert + 1 + i ;
cl_strisidx [ cl_numstrisidx + + ] = cl_numstrisvert - t - > firstvert + 1 + v * lngsteps + i ;
------------------------------------------------------------------------
r4169 | acceptthis | 2013-01-17 08:55:12 +0000 (Thu, 17 Jan 2013) | 31 lines
removed MAX_VISEDICTS limit.
PEXT2_REPLACEMENTDELTAS tweaked, now has 4 million entity limit. still not enabled by default.
TE_BEAM now maps to a separate TEQW_BEAM to avoid conflicts with QW.
added android multitouch emulation for windows/rawinput (in_simulatemultitouch).
split topcolor/bottomcolor from scoreboard, for dp's colormap|1024 feature.
now using utf-8 for windows consoles.
qcc warnings/errors now give clickable console links for quick+easy editing.
disabled menutint when the currently active item changes contrast or gamma (for OneManClan).
Added support for drawfont/drawfontscale.
tweaked the qcvm a little to reduce the number of pointers.
.doll file loading. still experimental and will likely crash. requires csqc active, even if its a dummy progs. this will be fixed in time. Still other things that need cleaning up.
windows: gl_font "?" shows the standard windows font-selection dialog, and can be used to select windows fonts. not all work. and you probably don't want to use windings.
fixed splitscreen support when playing mvds. added mini-scoreboards to splitscreen.
editor/debugger now shows asm if there's no linenumber info. also, pressing f1 for help shows the shortcuts.
Added support for .framegroups files for psk(psa) and iqm formats.
True support for ezquake's colour codes. Mutually exclusive with background colours.
path command output slightly more readable.
added support for digest_hex (MD4, SHA1, CRC16).
skingroups now colourmap correctly.
Fix terrain colour hints, and litdata from the wrong bsp.
fix ftp dual-homed issue. support epsv command, and enable ipv6 (eprt still not supported).
remove d3d11 compilation from the makefile. the required headers are not provided by mingw, and are not available to the build bot, so don't bother.
fix v *= v.x and similar opcodes.
fteqcc: fixed support for áéíóú type chars in names. utf-8 files now properly supported (even with the utf-8 bom/identifier). utf-16 also supported.
fteqcc: fixed '#if 1 == 3 && 4' parsing.
fteqcc: -Werror acts on the warning, rather than as a separate error. Line numbers are thus more readable.
fteqcc: copyright message now includes compile date instead.
fteqccgui: the treeview control is now coloured depending on whether there were warnings/errors in the last compile.
fteqccgui: the output window is now focused and scrolls down as compilation progresses.
pr_dumpplatform command dumps out some pragmas to convert more serious warnings to errors. This is to avoid the infamous 'fteqcc sucks cos my code sucks' issue.
rewrote prespawn/modelist/soundlist code. server tracks progress now.
------------------------------------------------------------------------
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@4167 fc73d0e0-1445-4013-8a0c-d673dee63da5
2013-03-12 22:29:40 +00:00
}
}
t - > numvert + = lngsteps * latsteps ;
t - > numidx = cl_numstrisidx - t - > firstidx ;
cl_numstrisvert + = lngsteps * latsteps ;
}
2018-04-27 16:40:50 +00:00
void CLQ1_AddOrientedSphere ( shader_t * shader , float radius , float * matrix , float r , float g , float b , float a )
{
CLQ1_AddOrientedHalfSphere ( shader , radius , 0 , matrix , r , g , b , a ) ;
CLQ1_AddOrientedHalfSphere ( shader , - radius , 0 , matrix , r , g , b , a ) ;
}
------------------------------------------------------------------------
r4169 | acceptthis | 2013-01-17 08:55:12 +0000 (Thu, 17 Jan 2013) | 31 lines
removed MAX_VISEDICTS limit.
PEXT2_REPLACEMENTDELTAS tweaked, now has 4 million entity limit. still not enabled by default.
TE_BEAM now maps to a separate TEQW_BEAM to avoid conflicts with QW.
added android multitouch emulation for windows/rawinput (in_simulatemultitouch).
split topcolor/bottomcolor from scoreboard, for dp's colormap|1024 feature.
now using utf-8 for windows consoles.
qcc warnings/errors now give clickable console links for quick+easy editing.
disabled menutint when the currently active item changes contrast or gamma (for OneManClan).
Added support for drawfont/drawfontscale.
tweaked the qcvm a little to reduce the number of pointers.
.doll file loading. still experimental and will likely crash. requires csqc active, even if its a dummy progs. this will be fixed in time. Still other things that need cleaning up.
windows: gl_font "?" shows the standard windows font-selection dialog, and can be used to select windows fonts. not all work. and you probably don't want to use windings.
fixed splitscreen support when playing mvds. added mini-scoreboards to splitscreen.
editor/debugger now shows asm if there's no linenumber info. also, pressing f1 for help shows the shortcuts.
Added support for .framegroups files for psk(psa) and iqm formats.
True support for ezquake's colour codes. Mutually exclusive with background colours.
path command output slightly more readable.
added support for digest_hex (MD4, SHA1, CRC16).
skingroups now colourmap correctly.
Fix terrain colour hints, and litdata from the wrong bsp.
fix ftp dual-homed issue. support epsv command, and enable ipv6 (eprt still not supported).
remove d3d11 compilation from the makefile. the required headers are not provided by mingw, and are not available to the build bot, so don't bother.
fix v *= v.x and similar opcodes.
fteqcc: fixed support for áéíóú type chars in names. utf-8 files now properly supported (even with the utf-8 bom/identifier). utf-16 also supported.
fteqcc: fixed '#if 1 == 3 && 4' parsing.
fteqcc: -Werror acts on the warning, rather than as a separate error. Line numbers are thus more readable.
fteqcc: copyright message now includes compile date instead.
fteqccgui: the treeview control is now coloured depending on whether there were warnings/errors in the last compile.
fteqccgui: the output window is now focused and scrolls down as compilation progresses.
pr_dumpplatform command dumps out some pragmas to convert more serious warnings to errors. This is to avoid the infamous 'fteqcc sucks cos my code sucks' issue.
rewrote prespawn/modelist/soundlist code. server tracks progress now.
------------------------------------------------------------------------
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@4167 fc73d0e0-1445-4013-8a0c-d673dee63da5
2013-03-12 22:29:40 +00:00
void CLQ1_AddOrientedCylinder ( shader_t * shader , float radius , float height , qboolean capsule , float * matrix , float r , float g , float b , float a )
{
int sides = 16 ;
2012-02-12 05:18:31 +00:00
int v ;
scenetris_t * t ;
------------------------------------------------------------------------
r4169 | acceptthis | 2013-01-17 08:55:12 +0000 (Thu, 17 Jan 2013) | 31 lines
removed MAX_VISEDICTS limit.
PEXT2_REPLACEMENTDELTAS tweaked, now has 4 million entity limit. still not enabled by default.
TE_BEAM now maps to a separate TEQW_BEAM to avoid conflicts with QW.
added android multitouch emulation for windows/rawinput (in_simulatemultitouch).
split topcolor/bottomcolor from scoreboard, for dp's colormap|1024 feature.
now using utf-8 for windows consoles.
qcc warnings/errors now give clickable console links for quick+easy editing.
disabled menutint when the currently active item changes contrast or gamma (for OneManClan).
Added support for drawfont/drawfontscale.
tweaked the qcvm a little to reduce the number of pointers.
.doll file loading. still experimental and will likely crash. requires csqc active, even if its a dummy progs. this will be fixed in time. Still other things that need cleaning up.
windows: gl_font "?" shows the standard windows font-selection dialog, and can be used to select windows fonts. not all work. and you probably don't want to use windings.
fixed splitscreen support when playing mvds. added mini-scoreboards to splitscreen.
editor/debugger now shows asm if there's no linenumber info. also, pressing f1 for help shows the shortcuts.
Added support for .framegroups files for psk(psa) and iqm formats.
True support for ezquake's colour codes. Mutually exclusive with background colours.
path command output slightly more readable.
added support for digest_hex (MD4, SHA1, CRC16).
skingroups now colourmap correctly.
Fix terrain colour hints, and litdata from the wrong bsp.
fix ftp dual-homed issue. support epsv command, and enable ipv6 (eprt still not supported).
remove d3d11 compilation from the makefile. the required headers are not provided by mingw, and are not available to the build bot, so don't bother.
fix v *= v.x and similar opcodes.
fteqcc: fixed support for áéíóú type chars in names. utf-8 files now properly supported (even with the utf-8 bom/identifier). utf-16 also supported.
fteqcc: fixed '#if 1 == 3 && 4' parsing.
fteqcc: -Werror acts on the warning, rather than as a separate error. Line numbers are thus more readable.
fteqcc: copyright message now includes compile date instead.
fteqccgui: the treeview control is now coloured depending on whether there were warnings/errors in the last compile.
fteqccgui: the output window is now focused and scrolls down as compilation progresses.
pr_dumpplatform command dumps out some pragmas to convert more serious warnings to errors. This is to avoid the infamous 'fteqcc sucks cos my code sucks' issue.
rewrote prespawn/modelist/soundlist code. server tracks progress now.
------------------------------------------------------------------------
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@4167 fc73d0e0-1445-4013-8a0c-d673dee63da5
2013-03-12 22:29:40 +00:00
vec3_t corner ;
int flags = BEF_NODLIGHT | BEF_NOSHADOWS ;
if ( ! r & & ! g & & ! b )
return ;
radius * = 0.5 ;
height * = 0.5 ;
if ( capsule )
height - = radius ;
if ( height > 0 )
{
/*reuse the previous trigroup if its the same shader*/
if ( cl_numstris & & cl_stris [ cl_numstris - 1 ] . shader = = shader & & cl_stris [ cl_numstris - 1 ] . flags = = flags )
t = & cl_stris [ cl_numstris - 1 ] ;
else
{
if ( cl_numstris = = cl_maxstris )
{
cl_maxstris + = 8 ;
cl_stris = BZ_Realloc ( cl_stris , sizeof ( * cl_stris ) * cl_maxstris ) ;
}
t = & cl_stris [ cl_numstris + + ] ;
t - > shader = shader ;
t - > numidx = 0 ;
t - > numvert = 0 ;
t - > firstidx = cl_numstrisidx ;
t - > firstvert = cl_numstrisvert ;
t - > flags = flags ;
}
if ( cl_numstrisvert + sides * 2 > cl_maxstrisvert )
2019-02-19 06:49:03 +00:00
cl_stris_ExpandVerts ( cl_numstrisvert + sides * 2 ) ;
------------------------------------------------------------------------
r4169 | acceptthis | 2013-01-17 08:55:12 +0000 (Thu, 17 Jan 2013) | 31 lines
removed MAX_VISEDICTS limit.
PEXT2_REPLACEMENTDELTAS tweaked, now has 4 million entity limit. still not enabled by default.
TE_BEAM now maps to a separate TEQW_BEAM to avoid conflicts with QW.
added android multitouch emulation for windows/rawinput (in_simulatemultitouch).
split topcolor/bottomcolor from scoreboard, for dp's colormap|1024 feature.
now using utf-8 for windows consoles.
qcc warnings/errors now give clickable console links for quick+easy editing.
disabled menutint when the currently active item changes contrast or gamma (for OneManClan).
Added support for drawfont/drawfontscale.
tweaked the qcvm a little to reduce the number of pointers.
.doll file loading. still experimental and will likely crash. requires csqc active, even if its a dummy progs. this will be fixed in time. Still other things that need cleaning up.
windows: gl_font "?" shows the standard windows font-selection dialog, and can be used to select windows fonts. not all work. and you probably don't want to use windings.
fixed splitscreen support when playing mvds. added mini-scoreboards to splitscreen.
editor/debugger now shows asm if there's no linenumber info. also, pressing f1 for help shows the shortcuts.
Added support for .framegroups files for psk(psa) and iqm formats.
True support for ezquake's colour codes. Mutually exclusive with background colours.
path command output slightly more readable.
added support for digest_hex (MD4, SHA1, CRC16).
skingroups now colourmap correctly.
Fix terrain colour hints, and litdata from the wrong bsp.
fix ftp dual-homed issue. support epsv command, and enable ipv6 (eprt still not supported).
remove d3d11 compilation from the makefile. the required headers are not provided by mingw, and are not available to the build bot, so don't bother.
fix v *= v.x and similar opcodes.
fteqcc: fixed support for áéíóú type chars in names. utf-8 files now properly supported (even with the utf-8 bom/identifier). utf-16 also supported.
fteqcc: fixed '#if 1 == 3 && 4' parsing.
fteqcc: -Werror acts on the warning, rather than as a separate error. Line numbers are thus more readable.
fteqcc: copyright message now includes compile date instead.
fteqccgui: the treeview control is now coloured depending on whether there were warnings/errors in the last compile.
fteqccgui: the output window is now focused and scrolls down as compilation progresses.
pr_dumpplatform command dumps out some pragmas to convert more serious warnings to errors. This is to avoid the infamous 'fteqcc sucks cos my code sucks' issue.
rewrote prespawn/modelist/soundlist code. server tracks progress now.
------------------------------------------------------------------------
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@4167 fc73d0e0-1445-4013-8a0c-d673dee63da5
2013-03-12 22:29:40 +00:00
if ( cl_maxstrisidx < cl_numstrisidx + sides * 6 )
{
cl_maxstrisidx = cl_numstrisidx + sides * 6 + 64 ;
cl_strisidx = BZ_Realloc ( cl_strisidx , sizeof ( * cl_strisidx ) * cl_maxstrisidx ) ;
}
for ( v = 0 ; v < sides * 2 ; v + + )
{
corner [ 0 ] = sin ( ( v > > 1 ) * 2 * M_PI / sides ) * radius ;
corner [ 1 ] = cos ( ( v > > 1 ) * 2 * M_PI / sides ) * radius ;
corner [ 2 ] = ( v & 1 ) ? height : - height ;
Matrix3x4_RM_Transform3 ( matrix , corner , cl_strisvertv [ cl_numstrisvert + v ] ) ;
cl_strisvertt [ cl_numstrisvert + v ] [ 0 ] = 0 ;
cl_strisvertt [ cl_numstrisvert + v ] [ 1 ] = 0 ;
cl_strisvertc [ cl_numstrisvert + v ] [ 0 ] = r ;
cl_strisvertc [ cl_numstrisvert + v ] [ 1 ] = g ;
cl_strisvertc [ cl_numstrisvert + v ] [ 2 ] = b ;
cl_strisvertc [ cl_numstrisvert + v ] [ 3 ] = a ;
}
for ( v = 0 ; v < sides - 1 ; v + + )
{
2018-04-27 16:40:50 +00:00
cl_strisidx [ cl_numstrisidx + + ] = cl_numstrisvert - t - > firstvert + 2 + v * 2 ;
cl_strisidx [ cl_numstrisidx + + ] = cl_numstrisvert - t - > firstvert + 1 + v * 2 ;
cl_strisidx [ cl_numstrisidx + + ] = cl_numstrisvert - t - > firstvert + 0 + v * 2 ;
cl_strisidx [ cl_numstrisidx + + ] = cl_numstrisvert - t - > firstvert + 3 + v * 2 ;
cl_strisidx [ cl_numstrisidx + + ] = cl_numstrisvert - t - > firstvert + 1 + v * 2 ;
cl_strisidx [ cl_numstrisidx + + ] = cl_numstrisvert - t - > firstvert + 2 + v * 2 ;
------------------------------------------------------------------------
r4169 | acceptthis | 2013-01-17 08:55:12 +0000 (Thu, 17 Jan 2013) | 31 lines
removed MAX_VISEDICTS limit.
PEXT2_REPLACEMENTDELTAS tweaked, now has 4 million entity limit. still not enabled by default.
TE_BEAM now maps to a separate TEQW_BEAM to avoid conflicts with QW.
added android multitouch emulation for windows/rawinput (in_simulatemultitouch).
split topcolor/bottomcolor from scoreboard, for dp's colormap|1024 feature.
now using utf-8 for windows consoles.
qcc warnings/errors now give clickable console links for quick+easy editing.
disabled menutint when the currently active item changes contrast or gamma (for OneManClan).
Added support for drawfont/drawfontscale.
tweaked the qcvm a little to reduce the number of pointers.
.doll file loading. still experimental and will likely crash. requires csqc active, even if its a dummy progs. this will be fixed in time. Still other things that need cleaning up.
windows: gl_font "?" shows the standard windows font-selection dialog, and can be used to select windows fonts. not all work. and you probably don't want to use windings.
fixed splitscreen support when playing mvds. added mini-scoreboards to splitscreen.
editor/debugger now shows asm if there's no linenumber info. also, pressing f1 for help shows the shortcuts.
Added support for .framegroups files for psk(psa) and iqm formats.
True support for ezquake's colour codes. Mutually exclusive with background colours.
path command output slightly more readable.
added support for digest_hex (MD4, SHA1, CRC16).
skingroups now colourmap correctly.
Fix terrain colour hints, and litdata from the wrong bsp.
fix ftp dual-homed issue. support epsv command, and enable ipv6 (eprt still not supported).
remove d3d11 compilation from the makefile. the required headers are not provided by mingw, and are not available to the build bot, so don't bother.
fix v *= v.x and similar opcodes.
fteqcc: fixed support for áéíóú type chars in names. utf-8 files now properly supported (even with the utf-8 bom/identifier). utf-16 also supported.
fteqcc: fixed '#if 1 == 3 && 4' parsing.
fteqcc: -Werror acts on the warning, rather than as a separate error. Line numbers are thus more readable.
fteqcc: copyright message now includes compile date instead.
fteqccgui: the treeview control is now coloured depending on whether there were warnings/errors in the last compile.
fteqccgui: the output window is now focused and scrolls down as compilation progresses.
pr_dumpplatform command dumps out some pragmas to convert more serious warnings to errors. This is to avoid the infamous 'fteqcc sucks cos my code sucks' issue.
rewrote prespawn/modelist/soundlist code. server tracks progress now.
------------------------------------------------------------------------
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@4167 fc73d0e0-1445-4013-8a0c-d673dee63da5
2013-03-12 22:29:40 +00:00
}
2018-04-27 16:40:50 +00:00
cl_strisidx [ cl_numstrisidx + + ] = cl_numstrisvert - t - > firstvert + 0 ;
cl_strisidx [ cl_numstrisidx + + ] = cl_numstrisvert - t - > firstvert + 1 + v * 2 ;
cl_strisidx [ cl_numstrisidx + + ] = cl_numstrisvert - t - > firstvert + 0 + v * 2 ;
cl_strisidx [ cl_numstrisidx + + ] = cl_numstrisvert - t - > firstvert + 1 ;
cl_strisidx [ cl_numstrisidx + + ] = cl_numstrisvert - t - > firstvert + 1 + v * 2 ;
cl_strisidx [ cl_numstrisidx + + ] = cl_numstrisvert - t - > firstvert + 0 ;
------------------------------------------------------------------------
r4169 | acceptthis | 2013-01-17 08:55:12 +0000 (Thu, 17 Jan 2013) | 31 lines
removed MAX_VISEDICTS limit.
PEXT2_REPLACEMENTDELTAS tweaked, now has 4 million entity limit. still not enabled by default.
TE_BEAM now maps to a separate TEQW_BEAM to avoid conflicts with QW.
added android multitouch emulation for windows/rawinput (in_simulatemultitouch).
split topcolor/bottomcolor from scoreboard, for dp's colormap|1024 feature.
now using utf-8 for windows consoles.
qcc warnings/errors now give clickable console links for quick+easy editing.
disabled menutint when the currently active item changes contrast or gamma (for OneManClan).
Added support for drawfont/drawfontscale.
tweaked the qcvm a little to reduce the number of pointers.
.doll file loading. still experimental and will likely crash. requires csqc active, even if its a dummy progs. this will be fixed in time. Still other things that need cleaning up.
windows: gl_font "?" shows the standard windows font-selection dialog, and can be used to select windows fonts. not all work. and you probably don't want to use windings.
fixed splitscreen support when playing mvds. added mini-scoreboards to splitscreen.
editor/debugger now shows asm if there's no linenumber info. also, pressing f1 for help shows the shortcuts.
Added support for .framegroups files for psk(psa) and iqm formats.
True support for ezquake's colour codes. Mutually exclusive with background colours.
path command output slightly more readable.
added support for digest_hex (MD4, SHA1, CRC16).
skingroups now colourmap correctly.
Fix terrain colour hints, and litdata from the wrong bsp.
fix ftp dual-homed issue. support epsv command, and enable ipv6 (eprt still not supported).
remove d3d11 compilation from the makefile. the required headers are not provided by mingw, and are not available to the build bot, so don't bother.
fix v *= v.x and similar opcodes.
fteqcc: fixed support for áéíóú type chars in names. utf-8 files now properly supported (even with the utf-8 bom/identifier). utf-16 also supported.
fteqcc: fixed '#if 1 == 3 && 4' parsing.
fteqcc: -Werror acts on the warning, rather than as a separate error. Line numbers are thus more readable.
fteqcc: copyright message now includes compile date instead.
fteqccgui: the treeview control is now coloured depending on whether there were warnings/errors in the last compile.
fteqccgui: the output window is now focused and scrolls down as compilation progresses.
pr_dumpplatform command dumps out some pragmas to convert more serious warnings to errors. This is to avoid the infamous 'fteqcc sucks cos my code sucks' issue.
rewrote prespawn/modelist/soundlist code. server tracks progress now.
------------------------------------------------------------------------
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@4167 fc73d0e0-1445-4013-8a0c-d673dee63da5
2013-03-12 22:29:40 +00:00
if ( ! capsule )
{
for ( v = 4 ; v < sides * 2 ; v + = 2 )
{
2018-04-27 16:40:50 +00:00
cl_strisidx [ cl_numstrisidx + + ] = cl_numstrisvert - t - > firstvert + v ;
cl_strisidx [ cl_numstrisidx + + ] = cl_numstrisvert - t - > firstvert + ( v - 2 ) ;
cl_strisidx [ cl_numstrisidx + + ] = cl_numstrisvert - t - > firstvert + 0 ;
------------------------------------------------------------------------
r4169 | acceptthis | 2013-01-17 08:55:12 +0000 (Thu, 17 Jan 2013) | 31 lines
removed MAX_VISEDICTS limit.
PEXT2_REPLACEMENTDELTAS tweaked, now has 4 million entity limit. still not enabled by default.
TE_BEAM now maps to a separate TEQW_BEAM to avoid conflicts with QW.
added android multitouch emulation for windows/rawinput (in_simulatemultitouch).
split topcolor/bottomcolor from scoreboard, for dp's colormap|1024 feature.
now using utf-8 for windows consoles.
qcc warnings/errors now give clickable console links for quick+easy editing.
disabled menutint when the currently active item changes contrast or gamma (for OneManClan).
Added support for drawfont/drawfontscale.
tweaked the qcvm a little to reduce the number of pointers.
.doll file loading. still experimental and will likely crash. requires csqc active, even if its a dummy progs. this will be fixed in time. Still other things that need cleaning up.
windows: gl_font "?" shows the standard windows font-selection dialog, and can be used to select windows fonts. not all work. and you probably don't want to use windings.
fixed splitscreen support when playing mvds. added mini-scoreboards to splitscreen.
editor/debugger now shows asm if there's no linenumber info. also, pressing f1 for help shows the shortcuts.
Added support for .framegroups files for psk(psa) and iqm formats.
True support for ezquake's colour codes. Mutually exclusive with background colours.
path command output slightly more readable.
added support for digest_hex (MD4, SHA1, CRC16).
skingroups now colourmap correctly.
Fix terrain colour hints, and litdata from the wrong bsp.
fix ftp dual-homed issue. support epsv command, and enable ipv6 (eprt still not supported).
remove d3d11 compilation from the makefile. the required headers are not provided by mingw, and are not available to the build bot, so don't bother.
fix v *= v.x and similar opcodes.
fteqcc: fixed support for áéíóú type chars in names. utf-8 files now properly supported (even with the utf-8 bom/identifier). utf-16 also supported.
fteqcc: fixed '#if 1 == 3 && 4' parsing.
fteqcc: -Werror acts on the warning, rather than as a separate error. Line numbers are thus more readable.
fteqcc: copyright message now includes compile date instead.
fteqccgui: the treeview control is now coloured depending on whether there were warnings/errors in the last compile.
fteqccgui: the output window is now focused and scrolls down as compilation progresses.
pr_dumpplatform command dumps out some pragmas to convert more serious warnings to errors. This is to avoid the infamous 'fteqcc sucks cos my code sucks' issue.
rewrote prespawn/modelist/soundlist code. server tracks progress now.
------------------------------------------------------------------------
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@4167 fc73d0e0-1445-4013-8a0c-d673dee63da5
2013-03-12 22:29:40 +00:00
2018-04-27 16:40:50 +00:00
cl_strisidx [ cl_numstrisidx + + ] = cl_numstrisvert - t - > firstvert + 1 ;
cl_strisidx [ cl_numstrisidx + + ] = cl_numstrisvert - t - > firstvert + ( v - 2 ) + 1 ;
cl_strisidx [ cl_numstrisidx + + ] = cl_numstrisvert - t - > firstvert + v + 1 ;
------------------------------------------------------------------------
r4169 | acceptthis | 2013-01-17 08:55:12 +0000 (Thu, 17 Jan 2013) | 31 lines
removed MAX_VISEDICTS limit.
PEXT2_REPLACEMENTDELTAS tweaked, now has 4 million entity limit. still not enabled by default.
TE_BEAM now maps to a separate TEQW_BEAM to avoid conflicts with QW.
added android multitouch emulation for windows/rawinput (in_simulatemultitouch).
split topcolor/bottomcolor from scoreboard, for dp's colormap|1024 feature.
now using utf-8 for windows consoles.
qcc warnings/errors now give clickable console links for quick+easy editing.
disabled menutint when the currently active item changes contrast or gamma (for OneManClan).
Added support for drawfont/drawfontscale.
tweaked the qcvm a little to reduce the number of pointers.
.doll file loading. still experimental and will likely crash. requires csqc active, even if its a dummy progs. this will be fixed in time. Still other things that need cleaning up.
windows: gl_font "?" shows the standard windows font-selection dialog, and can be used to select windows fonts. not all work. and you probably don't want to use windings.
fixed splitscreen support when playing mvds. added mini-scoreboards to splitscreen.
editor/debugger now shows asm if there's no linenumber info. also, pressing f1 for help shows the shortcuts.
Added support for .framegroups files for psk(psa) and iqm formats.
True support for ezquake's colour codes. Mutually exclusive with background colours.
path command output slightly more readable.
added support for digest_hex (MD4, SHA1, CRC16).
skingroups now colourmap correctly.
Fix terrain colour hints, and litdata from the wrong bsp.
fix ftp dual-homed issue. support epsv command, and enable ipv6 (eprt still not supported).
remove d3d11 compilation from the makefile. the required headers are not provided by mingw, and are not available to the build bot, so don't bother.
fix v *= v.x and similar opcodes.
fteqcc: fixed support for áéíóú type chars in names. utf-8 files now properly supported (even with the utf-8 bom/identifier). utf-16 also supported.
fteqcc: fixed '#if 1 == 3 && 4' parsing.
fteqcc: -Werror acts on the warning, rather than as a separate error. Line numbers are thus more readable.
fteqcc: copyright message now includes compile date instead.
fteqccgui: the treeview control is now coloured depending on whether there were warnings/errors in the last compile.
fteqccgui: the output window is now focused and scrolls down as compilation progresses.
pr_dumpplatform command dumps out some pragmas to convert more serious warnings to errors. This is to avoid the infamous 'fteqcc sucks cos my code sucks' issue.
rewrote prespawn/modelist/soundlist code. server tracks progress now.
------------------------------------------------------------------------
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@4167 fc73d0e0-1445-4013-8a0c-d673dee63da5
2013-03-12 22:29:40 +00:00
}
}
t - > numvert + = sides * 2 ;
t - > numidx = cl_numstrisidx - t - > firstidx ;
cl_numstrisvert + = sides * 2 ;
}
if ( capsule )
{
CLQ1_AddOrientedHalfSphere ( shader , radius , height , matrix , r , g , b , a ) ;
CLQ1_AddOrientedHalfSphere ( shader , - radius , - height , matrix , r , g , b , a ) ;
}
}
void CLQ1_DrawLine ( shader_t * shader , vec3_t v1 , vec3_t v2 , float r , float g , float b , float a )
{
scenetris_t * t ;
int flags = BEF_NODLIGHT | BEF_NOSHADOWS | BEF_LINES ;
if ( cl_numstris & & cl_stris [ cl_numstris - 1 ] . shader = = shader & & cl_stris [ cl_numstris - 1 ] . flags = = flags )
t = & cl_stris [ cl_numstris - 1 ] ;
else
{
if ( cl_numstris = = cl_maxstris )
{
cl_maxstris + = 8 ;
cl_stris = BZ_Realloc ( cl_stris , sizeof ( * cl_stris ) * cl_maxstris ) ;
}
t = & cl_stris [ cl_numstris + + ] ;
t - > shader = shader ;
t - > numidx = 0 ;
t - > numvert = 0 ;
t - > firstidx = cl_numstrisidx ;
t - > firstvert = cl_numstrisvert ;
t - > flags = flags ;
}
if ( cl_numstrisvert + 2 > cl_maxstrisvert )
2019-02-19 06:49:03 +00:00
cl_stris_ExpandVerts ( cl_numstrisvert + 2 ) ;
------------------------------------------------------------------------
r4169 | acceptthis | 2013-01-17 08:55:12 +0000 (Thu, 17 Jan 2013) | 31 lines
removed MAX_VISEDICTS limit.
PEXT2_REPLACEMENTDELTAS tweaked, now has 4 million entity limit. still not enabled by default.
TE_BEAM now maps to a separate TEQW_BEAM to avoid conflicts with QW.
added android multitouch emulation for windows/rawinput (in_simulatemultitouch).
split topcolor/bottomcolor from scoreboard, for dp's colormap|1024 feature.
now using utf-8 for windows consoles.
qcc warnings/errors now give clickable console links for quick+easy editing.
disabled menutint when the currently active item changes contrast or gamma (for OneManClan).
Added support for drawfont/drawfontscale.
tweaked the qcvm a little to reduce the number of pointers.
.doll file loading. still experimental and will likely crash. requires csqc active, even if its a dummy progs. this will be fixed in time. Still other things that need cleaning up.
windows: gl_font "?" shows the standard windows font-selection dialog, and can be used to select windows fonts. not all work. and you probably don't want to use windings.
fixed splitscreen support when playing mvds. added mini-scoreboards to splitscreen.
editor/debugger now shows asm if there's no linenumber info. also, pressing f1 for help shows the shortcuts.
Added support for .framegroups files for psk(psa) and iqm formats.
True support for ezquake's colour codes. Mutually exclusive with background colours.
path command output slightly more readable.
added support for digest_hex (MD4, SHA1, CRC16).
skingroups now colourmap correctly.
Fix terrain colour hints, and litdata from the wrong bsp.
fix ftp dual-homed issue. support epsv command, and enable ipv6 (eprt still not supported).
remove d3d11 compilation from the makefile. the required headers are not provided by mingw, and are not available to the build bot, so don't bother.
fix v *= v.x and similar opcodes.
fteqcc: fixed support for áéíóú type chars in names. utf-8 files now properly supported (even with the utf-8 bom/identifier). utf-16 also supported.
fteqcc: fixed '#if 1 == 3 && 4' parsing.
fteqcc: -Werror acts on the warning, rather than as a separate error. Line numbers are thus more readable.
fteqcc: copyright message now includes compile date instead.
fteqccgui: the treeview control is now coloured depending on whether there were warnings/errors in the last compile.
fteqccgui: the output window is now focused and scrolls down as compilation progresses.
pr_dumpplatform command dumps out some pragmas to convert more serious warnings to errors. This is to avoid the infamous 'fteqcc sucks cos my code sucks' issue.
rewrote prespawn/modelist/soundlist code. server tracks progress now.
------------------------------------------------------------------------
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@4167 fc73d0e0-1445-4013-8a0c-d673dee63da5
2013-03-12 22:29:40 +00:00
if ( cl_maxstrisidx < cl_numstrisidx + 2 )
{
cl_maxstrisidx = cl_numstrisidx + 2 ;
cl_strisidx = BZ_Realloc ( cl_strisidx , sizeof ( * cl_strisidx ) * cl_maxstrisidx ) ;
}
VectorCopy ( v1 , cl_strisvertv [ cl_numstrisvert + 0 ] ) ;
cl_strisvertt [ cl_numstrisvert + 0 ] [ 0 ] = 0 ;
cl_strisvertt [ cl_numstrisvert + 0 ] [ 1 ] = 0 ;
cl_strisvertc [ cl_numstrisvert + 0 ] [ 0 ] = r ;
cl_strisvertc [ cl_numstrisvert + 0 ] [ 1 ] = g ;
cl_strisvertc [ cl_numstrisvert + 0 ] [ 2 ] = b ;
cl_strisvertc [ cl_numstrisvert + 0 ] [ 3 ] = a ;
VectorCopy ( v2 , cl_strisvertv [ cl_numstrisvert + 1 ] ) ;
cl_strisvertt [ cl_numstrisvert + 1 ] [ 0 ] = 0 ;
cl_strisvertt [ cl_numstrisvert + 1 ] [ 1 ] = 0 ;
cl_strisvertc [ cl_numstrisvert + 1 ] [ 0 ] = r ;
cl_strisvertc [ cl_numstrisvert + 1 ] [ 1 ] = g ;
cl_strisvertc [ cl_numstrisvert + 1 ] [ 2 ] = b ;
cl_strisvertc [ cl_numstrisvert + 1 ] [ 3 ] = a ;
cl_strisidx [ cl_numstrisidx + + ] = cl_numstrisvert - t - > firstvert + 0 ;
cl_strisidx [ cl_numstrisidx + + ] = cl_numstrisvert - t - > firstvert + 1 ;
t - > numvert + = 2 ;
t - > numidx = cl_numstrisidx - t - > firstidx ;
cl_numstrisvert + = 2 ;
}
2018-11-19 06:37:25 +00:00
void CLQ1_AddSpriteQuad ( shader_t * shader , vec3_t mid , float radius )
{
float r = 1 , g = 1 , b = 1 ;
scenetris_t * t ;
int flags = BEF_NODLIGHT | BEF_NOSHADOWS ;
if ( cl_numstris & & cl_stris [ cl_numstris - 1 ] . shader = = shader & & cl_stris [ cl_numstris - 1 ] . flags = = flags & & cl_stris [ cl_numstris - 1 ] . numvert + 4 < = MAX_INDICIES )
t = & cl_stris [ cl_numstris - 1 ] ;
else
{
if ( cl_numstris = = cl_maxstris )
{
cl_maxstris + = 8 ;
cl_stris = BZ_Realloc ( cl_stris , sizeof ( * cl_stris ) * cl_maxstris ) ;
}
t = & cl_stris [ cl_numstris + + ] ;
t - > shader = shader ;
t - > firstidx = cl_numstrisidx ;
t - > firstvert = cl_numstrisvert ;
t - > numvert = 0 ;
t - > numidx = 0 ;
t - > flags = flags ;
}
if ( cl_numstrisidx + 6 > cl_maxstrisidx )
{
cl_maxstrisidx = cl_numstrisidx + 6 + 64 ;
cl_strisidx = BZ_Realloc ( cl_strisidx , sizeof ( * cl_strisidx ) * cl_maxstrisidx ) ;
}
if ( cl_numstrisvert + 4 > cl_maxstrisvert )
2019-02-19 06:49:03 +00:00
cl_stris_ExpandVerts ( cl_maxstrisvert + 64 ) ;
2018-11-19 06:37:25 +00:00
{
VectorMA ( mid , radius , vright , cl_strisvertv [ cl_numstrisvert ] ) ;
VectorMA ( cl_strisvertv [ cl_numstrisvert ] , radius , vup , cl_strisvertv [ cl_numstrisvert ] ) ;
Vector4Set ( cl_strisvertc [ cl_numstrisvert ] , r , g , b , 0.2 ) ;
Vector2Set ( cl_strisvertt [ cl_numstrisvert ] , 1 , 1 ) ;
cl_numstrisvert + + ;
VectorMA ( mid , radius , vright , cl_strisvertv [ cl_numstrisvert ] ) ;
VectorMA ( cl_strisvertv [ cl_numstrisvert ] , - radius , vup , cl_strisvertv [ cl_numstrisvert ] ) ;
Vector4Set ( cl_strisvertc [ cl_numstrisvert ] , r , g , b , 0.2 ) ;
Vector2Set ( cl_strisvertt [ cl_numstrisvert ] , 1 , 0 ) ;
cl_numstrisvert + + ;
VectorMA ( mid , - radius , vright , cl_strisvertv [ cl_numstrisvert ] ) ;
VectorMA ( cl_strisvertv [ cl_numstrisvert ] , - radius , vup , cl_strisvertv [ cl_numstrisvert ] ) ;
Vector4Set ( cl_strisvertc [ cl_numstrisvert ] , r , g , b , 0.2 ) ;
Vector2Set ( cl_strisvertt [ cl_numstrisvert ] , 0 , 0 ) ;
cl_numstrisvert + + ;
VectorMA ( mid , - radius , vright , cl_strisvertv [ cl_numstrisvert ] ) ;
VectorMA ( cl_strisvertv [ cl_numstrisvert ] , radius , vup , cl_strisvertv [ cl_numstrisvert ] ) ;
Vector4Set ( cl_strisvertc [ cl_numstrisvert ] , r , g , b , 0.2 ) ;
Vector2Set ( cl_strisvertt [ cl_numstrisvert ] , 0 , 1 ) ;
cl_numstrisvert + + ;
}
/*build the triangles*/
cl_strisidx [ cl_numstrisidx + + ] = t - > numvert + 0 ;
cl_strisidx [ cl_numstrisidx + + ] = t - > numvert + 1 ;
cl_strisidx [ cl_numstrisidx + + ] = t - > numvert + 2 ;
cl_strisidx [ cl_numstrisidx + + ] = t - > numvert + 0 ;
cl_strisidx [ cl_numstrisidx + + ] = t - > numvert + 2 ;
cl_strisidx [ cl_numstrisidx + + ] = t - > numvert + 3 ;
t - > numidx = cl_numstrisidx - t - > firstidx ;
t - > numvert + = 4 ;
}
2014-02-14 13:19:00 +00:00
# include "shader.h"
2014-02-14 13:29:41 +00:00
void CL_DrawDebugPlane ( float * normal , float dist , float r , float g , float b , qboolean enqueue )
2014-02-14 13:19:00 +00:00
{
2018-11-19 06:37:25 +00:00
const float radius = 8192 ; //infinite is quite small nowadays.
2014-02-14 13:19:00 +00:00
scenetris_t * t ;
if ( ! enqueue )
cl_numstris = 0 ;
if ( cl_numstris = = cl_maxstris )
{
cl_maxstris + = 8 ;
cl_stris = BZ_Realloc ( cl_stris , sizeof ( * cl_stris ) * cl_maxstris ) ;
}
t = & cl_stris [ cl_numstris + + ] ;
t - > shader = R_RegisterShader ( " testplane " , SUF_NONE , " { \n { \n map $whiteimage \n rgbgen vertex \n alphagen vertex \n blendfunc add \n nodepth \n } \n } \n " ) ;
t - > firstidx = cl_numstrisidx ;
t - > firstvert = cl_numstrisvert ;
t - > numvert = 0 ;
t - > numidx = 0 ;
if ( cl_numstrisidx + 6 > cl_maxstrisidx )
{
cl_maxstrisidx = cl_numstrisidx + 6 + 64 ;
cl_strisidx = BZ_Realloc ( cl_strisidx , sizeof ( * cl_strisidx ) * cl_maxstrisidx ) ;
}
if ( cl_numstrisvert + 4 > cl_maxstrisvert )
2019-02-19 06:49:03 +00:00
cl_stris_ExpandVerts ( cl_maxstrisvert + 64 ) ;
2014-02-14 13:19:00 +00:00
{
vec3_t tmp = { 0 , 0.04 , 0.96 } ;
vec3_t right , forward ;
CrossProduct ( normal , tmp , right ) ;
VectorNormalize ( right ) ;
CrossProduct ( normal , right , forward ) ;
VectorNormalize ( forward ) ;
VectorScale ( normal , dist , cl_strisvertv [ cl_numstrisvert ] ) ;
2018-11-19 06:37:25 +00:00
VectorMA ( cl_strisvertv [ cl_numstrisvert ] , radius , right , cl_strisvertv [ cl_numstrisvert ] ) ;
VectorMA ( cl_strisvertv [ cl_numstrisvert ] , radius , forward , cl_strisvertv [ cl_numstrisvert ] ) ;
2014-02-14 13:19:00 +00:00
Vector4Set ( cl_strisvertc [ cl_numstrisvert ] , r , g , b , 0.2 ) ;
cl_numstrisvert + + ;
VectorScale ( normal , dist , cl_strisvertv [ cl_numstrisvert ] ) ;
2018-11-19 06:37:25 +00:00
VectorMA ( cl_strisvertv [ cl_numstrisvert ] , radius , right , cl_strisvertv [ cl_numstrisvert ] ) ;
VectorMA ( cl_strisvertv [ cl_numstrisvert ] , - radius , forward , cl_strisvertv [ cl_numstrisvert ] ) ;
2014-02-14 13:19:00 +00:00
Vector4Set ( cl_strisvertc [ cl_numstrisvert ] , r , g , b , 0.2 ) ;
cl_numstrisvert + + ;
VectorScale ( normal , dist , cl_strisvertv [ cl_numstrisvert ] ) ;
2018-11-19 06:37:25 +00:00
VectorMA ( cl_strisvertv [ cl_numstrisvert ] , - radius , right , cl_strisvertv [ cl_numstrisvert ] ) ;
VectorMA ( cl_strisvertv [ cl_numstrisvert ] , - radius , forward , cl_strisvertv [ cl_numstrisvert ] ) ;
2014-02-14 13:19:00 +00:00
Vector4Set ( cl_strisvertc [ cl_numstrisvert ] , r , g , b , 0.2 ) ;
cl_numstrisvert + + ;
VectorScale ( normal , dist , cl_strisvertv [ cl_numstrisvert ] ) ;
2018-11-19 06:37:25 +00:00
VectorMA ( cl_strisvertv [ cl_numstrisvert ] , - radius , right , cl_strisvertv [ cl_numstrisvert ] ) ;
VectorMA ( cl_strisvertv [ cl_numstrisvert ] , radius , forward , cl_strisvertv [ cl_numstrisvert ] ) ;
2014-02-14 13:19:00 +00:00
Vector4Set ( cl_strisvertc [ cl_numstrisvert ] , r , g , b , 0.2 ) ;
cl_numstrisvert + + ;
}
/*build the triangles*/
cl_strisidx [ cl_numstrisidx + + ] = t - > numvert + 0 ;
cl_strisidx [ cl_numstrisidx + + ] = t - > numvert + 1 ;
cl_strisidx [ cl_numstrisidx + + ] = t - > numvert + 2 ;
cl_strisidx [ cl_numstrisidx + + ] = t - > numvert + 0 ;
cl_strisidx [ cl_numstrisidx + + ] = t - > numvert + 2 ;
cl_strisidx [ cl_numstrisidx + + ] = t - > numvert + 3 ;
t - > numidx = cl_numstrisidx - t - > firstidx ;
t - > numvert + = 4 ;
if ( ! enqueue )
{
// int oldents = cl_numvisedicts;
// cl_numvisedicts = 0;
2019-07-02 04:12:20 +00:00
r_refdef . scenevis = NULL ;
2016-11-20 20:52:41 +00:00
BE_DrawWorld ( NULL ) ;
2014-02-14 13:19:00 +00:00
cl_numstris = 0 ;
// cl_numvisedicts = oldents;
}
}
------------------------------------------------------------------------
r4169 | acceptthis | 2013-01-17 08:55:12 +0000 (Thu, 17 Jan 2013) | 31 lines
removed MAX_VISEDICTS limit.
PEXT2_REPLACEMENTDELTAS tweaked, now has 4 million entity limit. still not enabled by default.
TE_BEAM now maps to a separate TEQW_BEAM to avoid conflicts with QW.
added android multitouch emulation for windows/rawinput (in_simulatemultitouch).
split topcolor/bottomcolor from scoreboard, for dp's colormap|1024 feature.
now using utf-8 for windows consoles.
qcc warnings/errors now give clickable console links for quick+easy editing.
disabled menutint when the currently active item changes contrast or gamma (for OneManClan).
Added support for drawfont/drawfontscale.
tweaked the qcvm a little to reduce the number of pointers.
.doll file loading. still experimental and will likely crash. requires csqc active, even if its a dummy progs. this will be fixed in time. Still other things that need cleaning up.
windows: gl_font "?" shows the standard windows font-selection dialog, and can be used to select windows fonts. not all work. and you probably don't want to use windings.
fixed splitscreen support when playing mvds. added mini-scoreboards to splitscreen.
editor/debugger now shows asm if there's no linenumber info. also, pressing f1 for help shows the shortcuts.
Added support for .framegroups files for psk(psa) and iqm formats.
True support for ezquake's colour codes. Mutually exclusive with background colours.
path command output slightly more readable.
added support for digest_hex (MD4, SHA1, CRC16).
skingroups now colourmap correctly.
Fix terrain colour hints, and litdata from the wrong bsp.
fix ftp dual-homed issue. support epsv command, and enable ipv6 (eprt still not supported).
remove d3d11 compilation from the makefile. the required headers are not provided by mingw, and are not available to the build bot, so don't bother.
fix v *= v.x and similar opcodes.
fteqcc: fixed support for áéíóú type chars in names. utf-8 files now properly supported (even with the utf-8 bom/identifier). utf-16 also supported.
fteqcc: fixed '#if 1 == 3 && 4' parsing.
fteqcc: -Werror acts on the warning, rather than as a separate error. Line numbers are thus more readable.
fteqcc: copyright message now includes compile date instead.
fteqccgui: the treeview control is now coloured depending on whether there were warnings/errors in the last compile.
fteqccgui: the output window is now focused and scrolls down as compilation progresses.
pr_dumpplatform command dumps out some pragmas to convert more serious warnings to errors. This is to avoid the infamous 'fteqcc sucks cos my code sucks' issue.
rewrote prespawn/modelist/soundlist code. server tracks progress now.
------------------------------------------------------------------------
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@4167 fc73d0e0-1445-4013-8a0c-d673dee63da5
2013-03-12 22:29:40 +00:00
void CLQ1_AddOrientedCube ( shader_t * shader , vec3_t mins , vec3_t maxs , float * matrix , float r , float g , float b , float a )
{
int v ;
scenetris_t * t ;
vec3_t corner ;
int flags = BEF_NODLIGHT | BEF_NOSHADOWS ;
2012-02-12 05:18:31 +00:00
if ( ! r & & ! g & & ! b )
return ;
/*reuse the previous trigroup if its the same shader*/
------------------------------------------------------------------------
r4169 | acceptthis | 2013-01-17 08:55:12 +0000 (Thu, 17 Jan 2013) | 31 lines
removed MAX_VISEDICTS limit.
PEXT2_REPLACEMENTDELTAS tweaked, now has 4 million entity limit. still not enabled by default.
TE_BEAM now maps to a separate TEQW_BEAM to avoid conflicts with QW.
added android multitouch emulation for windows/rawinput (in_simulatemultitouch).
split topcolor/bottomcolor from scoreboard, for dp's colormap|1024 feature.
now using utf-8 for windows consoles.
qcc warnings/errors now give clickable console links for quick+easy editing.
disabled menutint when the currently active item changes contrast or gamma (for OneManClan).
Added support for drawfont/drawfontscale.
tweaked the qcvm a little to reduce the number of pointers.
.doll file loading. still experimental and will likely crash. requires csqc active, even if its a dummy progs. this will be fixed in time. Still other things that need cleaning up.
windows: gl_font "?" shows the standard windows font-selection dialog, and can be used to select windows fonts. not all work. and you probably don't want to use windings.
fixed splitscreen support when playing mvds. added mini-scoreboards to splitscreen.
editor/debugger now shows asm if there's no linenumber info. also, pressing f1 for help shows the shortcuts.
Added support for .framegroups files for psk(psa) and iqm formats.
True support for ezquake's colour codes. Mutually exclusive with background colours.
path command output slightly more readable.
added support for digest_hex (MD4, SHA1, CRC16).
skingroups now colourmap correctly.
Fix terrain colour hints, and litdata from the wrong bsp.
fix ftp dual-homed issue. support epsv command, and enable ipv6 (eprt still not supported).
remove d3d11 compilation from the makefile. the required headers are not provided by mingw, and are not available to the build bot, so don't bother.
fix v *= v.x and similar opcodes.
fteqcc: fixed support for áéíóú type chars in names. utf-8 files now properly supported (even with the utf-8 bom/identifier). utf-16 also supported.
fteqcc: fixed '#if 1 == 3 && 4' parsing.
fteqcc: -Werror acts on the warning, rather than as a separate error. Line numbers are thus more readable.
fteqcc: copyright message now includes compile date instead.
fteqccgui: the treeview control is now coloured depending on whether there were warnings/errors in the last compile.
fteqccgui: the output window is now focused and scrolls down as compilation progresses.
pr_dumpplatform command dumps out some pragmas to convert more serious warnings to errors. This is to avoid the infamous 'fteqcc sucks cos my code sucks' issue.
rewrote prespawn/modelist/soundlist code. server tracks progress now.
------------------------------------------------------------------------
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@4167 fc73d0e0-1445-4013-8a0c-d673dee63da5
2013-03-12 22:29:40 +00:00
if ( cl_numstris & & cl_stris [ cl_numstris - 1 ] . shader = = shader & & cl_stris [ cl_numstris - 1 ] . flags = = flags & & cl_stris [ cl_numstris - 1 ] . numvert + 8 < = MAX_INDICIES )
2012-02-12 05:18:31 +00:00
t = & cl_stris [ cl_numstris - 1 ] ;
else
{
if ( cl_numstris = = cl_maxstris )
{
cl_maxstris + = 8 ;
cl_stris = BZ_Realloc ( cl_stris , sizeof ( * cl_stris ) * cl_maxstris ) ;
}
t = & cl_stris [ cl_numstris + + ] ;
t - > shader = shader ;
t - > numidx = 0 ;
t - > numvert = 0 ;
t - > firstidx = cl_numstrisidx ;
t - > firstvert = cl_numstrisvert ;
------------------------------------------------------------------------
r4169 | acceptthis | 2013-01-17 08:55:12 +0000 (Thu, 17 Jan 2013) | 31 lines
removed MAX_VISEDICTS limit.
PEXT2_REPLACEMENTDELTAS tweaked, now has 4 million entity limit. still not enabled by default.
TE_BEAM now maps to a separate TEQW_BEAM to avoid conflicts with QW.
added android multitouch emulation for windows/rawinput (in_simulatemultitouch).
split topcolor/bottomcolor from scoreboard, for dp's colormap|1024 feature.
now using utf-8 for windows consoles.
qcc warnings/errors now give clickable console links for quick+easy editing.
disabled menutint when the currently active item changes contrast or gamma (for OneManClan).
Added support for drawfont/drawfontscale.
tweaked the qcvm a little to reduce the number of pointers.
.doll file loading. still experimental and will likely crash. requires csqc active, even if its a dummy progs. this will be fixed in time. Still other things that need cleaning up.
windows: gl_font "?" shows the standard windows font-selection dialog, and can be used to select windows fonts. not all work. and you probably don't want to use windings.
fixed splitscreen support when playing mvds. added mini-scoreboards to splitscreen.
editor/debugger now shows asm if there's no linenumber info. also, pressing f1 for help shows the shortcuts.
Added support for .framegroups files for psk(psa) and iqm formats.
True support for ezquake's colour codes. Mutually exclusive with background colours.
path command output slightly more readable.
added support for digest_hex (MD4, SHA1, CRC16).
skingroups now colourmap correctly.
Fix terrain colour hints, and litdata from the wrong bsp.
fix ftp dual-homed issue. support epsv command, and enable ipv6 (eprt still not supported).
remove d3d11 compilation from the makefile. the required headers are not provided by mingw, and are not available to the build bot, so don't bother.
fix v *= v.x and similar opcodes.
fteqcc: fixed support for áéíóú type chars in names. utf-8 files now properly supported (even with the utf-8 bom/identifier). utf-16 also supported.
fteqcc: fixed '#if 1 == 3 && 4' parsing.
fteqcc: -Werror acts on the warning, rather than as a separate error. Line numbers are thus more readable.
fteqcc: copyright message now includes compile date instead.
fteqccgui: the treeview control is now coloured depending on whether there were warnings/errors in the last compile.
fteqccgui: the output window is now focused and scrolls down as compilation progresses.
pr_dumpplatform command dumps out some pragmas to convert more serious warnings to errors. This is to avoid the infamous 'fteqcc sucks cos my code sucks' issue.
rewrote prespawn/modelist/soundlist code. server tracks progress now.
------------------------------------------------------------------------
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@4167 fc73d0e0-1445-4013-8a0c-d673dee63da5
2013-03-12 22:29:40 +00:00
t - > flags = flags ;
2012-02-12 05:18:31 +00:00
}
if ( cl_numstrisvert + 8 > cl_maxstrisvert )
2019-02-19 06:49:03 +00:00
cl_stris_ExpandVerts ( cl_numstrisvert + 8 + 1024 ) ;
2012-02-12 05:18:31 +00:00
if ( cl_maxstrisidx < cl_numstrisidx + 6 * 6 )
{
------------------------------------------------------------------------
r4169 | acceptthis | 2013-01-17 08:55:12 +0000 (Thu, 17 Jan 2013) | 31 lines
removed MAX_VISEDICTS limit.
PEXT2_REPLACEMENTDELTAS tweaked, now has 4 million entity limit. still not enabled by default.
TE_BEAM now maps to a separate TEQW_BEAM to avoid conflicts with QW.
added android multitouch emulation for windows/rawinput (in_simulatemultitouch).
split topcolor/bottomcolor from scoreboard, for dp's colormap|1024 feature.
now using utf-8 for windows consoles.
qcc warnings/errors now give clickable console links for quick+easy editing.
disabled menutint when the currently active item changes contrast or gamma (for OneManClan).
Added support for drawfont/drawfontscale.
tweaked the qcvm a little to reduce the number of pointers.
.doll file loading. still experimental and will likely crash. requires csqc active, even if its a dummy progs. this will be fixed in time. Still other things that need cleaning up.
windows: gl_font "?" shows the standard windows font-selection dialog, and can be used to select windows fonts. not all work. and you probably don't want to use windings.
fixed splitscreen support when playing mvds. added mini-scoreboards to splitscreen.
editor/debugger now shows asm if there's no linenumber info. also, pressing f1 for help shows the shortcuts.
Added support for .framegroups files for psk(psa) and iqm formats.
True support for ezquake's colour codes. Mutually exclusive with background colours.
path command output slightly more readable.
added support for digest_hex (MD4, SHA1, CRC16).
skingroups now colourmap correctly.
Fix terrain colour hints, and litdata from the wrong bsp.
fix ftp dual-homed issue. support epsv command, and enable ipv6 (eprt still not supported).
remove d3d11 compilation from the makefile. the required headers are not provided by mingw, and are not available to the build bot, so don't bother.
fix v *= v.x and similar opcodes.
fteqcc: fixed support for áéíóú type chars in names. utf-8 files now properly supported (even with the utf-8 bom/identifier). utf-16 also supported.
fteqcc: fixed '#if 1 == 3 && 4' parsing.
fteqcc: -Werror acts on the warning, rather than as a separate error. Line numbers are thus more readable.
fteqcc: copyright message now includes compile date instead.
fteqccgui: the treeview control is now coloured depending on whether there were warnings/errors in the last compile.
fteqccgui: the output window is now focused and scrolls down as compilation progresses.
pr_dumpplatform command dumps out some pragmas to convert more serious warnings to errors. This is to avoid the infamous 'fteqcc sucks cos my code sucks' issue.
rewrote prespawn/modelist/soundlist code. server tracks progress now.
------------------------------------------------------------------------
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@4167 fc73d0e0-1445-4013-8a0c-d673dee63da5
2013-03-12 22:29:40 +00:00
cl_maxstrisidx = cl_numstrisidx + 6 * 6 + 1024 ;
2012-02-12 05:18:31 +00:00
cl_strisidx = BZ_Realloc ( cl_strisidx , sizeof ( * cl_strisidx ) * cl_maxstrisidx ) ;
}
for ( v = 0 ; v < 8 ; v + + )
{
------------------------------------------------------------------------
r4169 | acceptthis | 2013-01-17 08:55:12 +0000 (Thu, 17 Jan 2013) | 31 lines
removed MAX_VISEDICTS limit.
PEXT2_REPLACEMENTDELTAS tweaked, now has 4 million entity limit. still not enabled by default.
TE_BEAM now maps to a separate TEQW_BEAM to avoid conflicts with QW.
added android multitouch emulation for windows/rawinput (in_simulatemultitouch).
split topcolor/bottomcolor from scoreboard, for dp's colormap|1024 feature.
now using utf-8 for windows consoles.
qcc warnings/errors now give clickable console links for quick+easy editing.
disabled menutint when the currently active item changes contrast or gamma (for OneManClan).
Added support for drawfont/drawfontscale.
tweaked the qcvm a little to reduce the number of pointers.
.doll file loading. still experimental and will likely crash. requires csqc active, even if its a dummy progs. this will be fixed in time. Still other things that need cleaning up.
windows: gl_font "?" shows the standard windows font-selection dialog, and can be used to select windows fonts. not all work. and you probably don't want to use windings.
fixed splitscreen support when playing mvds. added mini-scoreboards to splitscreen.
editor/debugger now shows asm if there's no linenumber info. also, pressing f1 for help shows the shortcuts.
Added support for .framegroups files for psk(psa) and iqm formats.
True support for ezquake's colour codes. Mutually exclusive with background colours.
path command output slightly more readable.
added support for digest_hex (MD4, SHA1, CRC16).
skingroups now colourmap correctly.
Fix terrain colour hints, and litdata from the wrong bsp.
fix ftp dual-homed issue. support epsv command, and enable ipv6 (eprt still not supported).
remove d3d11 compilation from the makefile. the required headers are not provided by mingw, and are not available to the build bot, so don't bother.
fix v *= v.x and similar opcodes.
fteqcc: fixed support for áéíóú type chars in names. utf-8 files now properly supported (even with the utf-8 bom/identifier). utf-16 also supported.
fteqcc: fixed '#if 1 == 3 && 4' parsing.
fteqcc: -Werror acts on the warning, rather than as a separate error. Line numbers are thus more readable.
fteqcc: copyright message now includes compile date instead.
fteqccgui: the treeview control is now coloured depending on whether there were warnings/errors in the last compile.
fteqccgui: the output window is now focused and scrolls down as compilation progresses.
pr_dumpplatform command dumps out some pragmas to convert more serious warnings to errors. This is to avoid the infamous 'fteqcc sucks cos my code sucks' issue.
rewrote prespawn/modelist/soundlist code. server tracks progress now.
------------------------------------------------------------------------
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@4167 fc73d0e0-1445-4013-8a0c-d673dee63da5
2013-03-12 22:29:40 +00:00
corner [ 0 ] = ( v & 1 ) ? mins [ 0 ] : maxs [ 0 ] ;
corner [ 1 ] = ( v & 2 ) ? mins [ 1 ] : maxs [ 1 ] ;
corner [ 2 ] = ( v & 4 ) ? mins [ 2 ] : maxs [ 2 ] ;
if ( matrix )
Matrix3x4_RM_Transform3 ( matrix , corner , cl_strisvertv [ cl_numstrisvert + v ] ) ;
else
VectorCopy ( corner , cl_strisvertv [ cl_numstrisvert + v ] ) ;
2012-02-12 05:18:31 +00:00
cl_strisvertt [ cl_numstrisvert + v ] [ 0 ] = 0 ;
cl_strisvertt [ cl_numstrisvert + v ] [ 1 ] = 0 ;
cl_strisvertc [ cl_numstrisvert + v ] [ 0 ] = r ;
cl_strisvertc [ cl_numstrisvert + v ] [ 1 ] = g ;
cl_strisvertc [ cl_numstrisvert + v ] [ 2 ] = b ;
cl_strisvertc [ cl_numstrisvert + v ] [ 3 ] = a ;
}
/*top*/
------------------------------------------------------------------------
r4169 | acceptthis | 2013-01-17 08:55:12 +0000 (Thu, 17 Jan 2013) | 31 lines
removed MAX_VISEDICTS limit.
PEXT2_REPLACEMENTDELTAS tweaked, now has 4 million entity limit. still not enabled by default.
TE_BEAM now maps to a separate TEQW_BEAM to avoid conflicts with QW.
added android multitouch emulation for windows/rawinput (in_simulatemultitouch).
split topcolor/bottomcolor from scoreboard, for dp's colormap|1024 feature.
now using utf-8 for windows consoles.
qcc warnings/errors now give clickable console links for quick+easy editing.
disabled menutint when the currently active item changes contrast or gamma (for OneManClan).
Added support for drawfont/drawfontscale.
tweaked the qcvm a little to reduce the number of pointers.
.doll file loading. still experimental and will likely crash. requires csqc active, even if its a dummy progs. this will be fixed in time. Still other things that need cleaning up.
windows: gl_font "?" shows the standard windows font-selection dialog, and can be used to select windows fonts. not all work. and you probably don't want to use windings.
fixed splitscreen support when playing mvds. added mini-scoreboards to splitscreen.
editor/debugger now shows asm if there's no linenumber info. also, pressing f1 for help shows the shortcuts.
Added support for .framegroups files for psk(psa) and iqm formats.
True support for ezquake's colour codes. Mutually exclusive with background colours.
path command output slightly more readable.
added support for digest_hex (MD4, SHA1, CRC16).
skingroups now colourmap correctly.
Fix terrain colour hints, and litdata from the wrong bsp.
fix ftp dual-homed issue. support epsv command, and enable ipv6 (eprt still not supported).
remove d3d11 compilation from the makefile. the required headers are not provided by mingw, and are not available to the build bot, so don't bother.
fix v *= v.x and similar opcodes.
fteqcc: fixed support for áéíóú type chars in names. utf-8 files now properly supported (even with the utf-8 bom/identifier). utf-16 also supported.
fteqcc: fixed '#if 1 == 3 && 4' parsing.
fteqcc: -Werror acts on the warning, rather than as a separate error. Line numbers are thus more readable.
fteqcc: copyright message now includes compile date instead.
fteqccgui: the treeview control is now coloured depending on whether there were warnings/errors in the last compile.
fteqccgui: the output window is now focused and scrolls down as compilation progresses.
pr_dumpplatform command dumps out some pragmas to convert more serious warnings to errors. This is to avoid the infamous 'fteqcc sucks cos my code sucks' issue.
rewrote prespawn/modelist/soundlist code. server tracks progress now.
------------------------------------------------------------------------
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@4167 fc73d0e0-1445-4013-8a0c-d673dee63da5
2013-03-12 22:29:40 +00:00
cl_strisidx [ cl_numstrisidx + + ] = cl_numstrisvert + 2 - t - > firstvert ;
cl_strisidx [ cl_numstrisidx + + ] = cl_numstrisvert + 1 - t - > firstvert ;
cl_strisidx [ cl_numstrisidx + + ] = cl_numstrisvert + 0 - t - > firstvert ;
cl_strisidx [ cl_numstrisidx + + ] = cl_numstrisvert + 3 - t - > firstvert ;
cl_strisidx [ cl_numstrisidx + + ] = cl_numstrisvert + 1 - t - > firstvert ;
cl_strisidx [ cl_numstrisidx + + ] = cl_numstrisvert + 2 - t - > firstvert ;
2012-02-12 05:18:31 +00:00
/*bottom*/
------------------------------------------------------------------------
r4169 | acceptthis | 2013-01-17 08:55:12 +0000 (Thu, 17 Jan 2013) | 31 lines
removed MAX_VISEDICTS limit.
PEXT2_REPLACEMENTDELTAS tweaked, now has 4 million entity limit. still not enabled by default.
TE_BEAM now maps to a separate TEQW_BEAM to avoid conflicts with QW.
added android multitouch emulation for windows/rawinput (in_simulatemultitouch).
split topcolor/bottomcolor from scoreboard, for dp's colormap|1024 feature.
now using utf-8 for windows consoles.
qcc warnings/errors now give clickable console links for quick+easy editing.
disabled menutint when the currently active item changes contrast or gamma (for OneManClan).
Added support for drawfont/drawfontscale.
tweaked the qcvm a little to reduce the number of pointers.
.doll file loading. still experimental and will likely crash. requires csqc active, even if its a dummy progs. this will be fixed in time. Still other things that need cleaning up.
windows: gl_font "?" shows the standard windows font-selection dialog, and can be used to select windows fonts. not all work. and you probably don't want to use windings.
fixed splitscreen support when playing mvds. added mini-scoreboards to splitscreen.
editor/debugger now shows asm if there's no linenumber info. also, pressing f1 for help shows the shortcuts.
Added support for .framegroups files for psk(psa) and iqm formats.
True support for ezquake's colour codes. Mutually exclusive with background colours.
path command output slightly more readable.
added support for digest_hex (MD4, SHA1, CRC16).
skingroups now colourmap correctly.
Fix terrain colour hints, and litdata from the wrong bsp.
fix ftp dual-homed issue. support epsv command, and enable ipv6 (eprt still not supported).
remove d3d11 compilation from the makefile. the required headers are not provided by mingw, and are not available to the build bot, so don't bother.
fix v *= v.x and similar opcodes.
fteqcc: fixed support for áéíóú type chars in names. utf-8 files now properly supported (even with the utf-8 bom/identifier). utf-16 also supported.
fteqcc: fixed '#if 1 == 3 && 4' parsing.
fteqcc: -Werror acts on the warning, rather than as a separate error. Line numbers are thus more readable.
fteqcc: copyright message now includes compile date instead.
fteqccgui: the treeview control is now coloured depending on whether there were warnings/errors in the last compile.
fteqccgui: the output window is now focused and scrolls down as compilation progresses.
pr_dumpplatform command dumps out some pragmas to convert more serious warnings to errors. This is to avoid the infamous 'fteqcc sucks cos my code sucks' issue.
rewrote prespawn/modelist/soundlist code. server tracks progress now.
------------------------------------------------------------------------
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@4167 fc73d0e0-1445-4013-8a0c-d673dee63da5
2013-03-12 22:29:40 +00:00
cl_strisidx [ cl_numstrisidx + + ] = cl_numstrisvert + 4 - t - > firstvert ;
cl_strisidx [ cl_numstrisidx + + ] = cl_numstrisvert + 5 - t - > firstvert ;
cl_strisidx [ cl_numstrisidx + + ] = cl_numstrisvert + 6 - t - > firstvert ;
cl_strisidx [ cl_numstrisidx + + ] = cl_numstrisvert + 6 - t - > firstvert ;
cl_strisidx [ cl_numstrisidx + + ] = cl_numstrisvert + 5 - t - > firstvert ;
cl_strisidx [ cl_numstrisidx + + ] = cl_numstrisvert + 7 - t - > firstvert ;
2012-02-12 05:18:31 +00:00
/*'left'*/
------------------------------------------------------------------------
r4169 | acceptthis | 2013-01-17 08:55:12 +0000 (Thu, 17 Jan 2013) | 31 lines
removed MAX_VISEDICTS limit.
PEXT2_REPLACEMENTDELTAS tweaked, now has 4 million entity limit. still not enabled by default.
TE_BEAM now maps to a separate TEQW_BEAM to avoid conflicts with QW.
added android multitouch emulation for windows/rawinput (in_simulatemultitouch).
split topcolor/bottomcolor from scoreboard, for dp's colormap|1024 feature.
now using utf-8 for windows consoles.
qcc warnings/errors now give clickable console links for quick+easy editing.
disabled menutint when the currently active item changes contrast or gamma (for OneManClan).
Added support for drawfont/drawfontscale.
tweaked the qcvm a little to reduce the number of pointers.
.doll file loading. still experimental and will likely crash. requires csqc active, even if its a dummy progs. this will be fixed in time. Still other things that need cleaning up.
windows: gl_font "?" shows the standard windows font-selection dialog, and can be used to select windows fonts. not all work. and you probably don't want to use windings.
fixed splitscreen support when playing mvds. added mini-scoreboards to splitscreen.
editor/debugger now shows asm if there's no linenumber info. also, pressing f1 for help shows the shortcuts.
Added support for .framegroups files for psk(psa) and iqm formats.
True support for ezquake's colour codes. Mutually exclusive with background colours.
path command output slightly more readable.
added support for digest_hex (MD4, SHA1, CRC16).
skingroups now colourmap correctly.
Fix terrain colour hints, and litdata from the wrong bsp.
fix ftp dual-homed issue. support epsv command, and enable ipv6 (eprt still not supported).
remove d3d11 compilation from the makefile. the required headers are not provided by mingw, and are not available to the build bot, so don't bother.
fix v *= v.x and similar opcodes.
fteqcc: fixed support for áéíóú type chars in names. utf-8 files now properly supported (even with the utf-8 bom/identifier). utf-16 also supported.
fteqcc: fixed '#if 1 == 3 && 4' parsing.
fteqcc: -Werror acts on the warning, rather than as a separate error. Line numbers are thus more readable.
fteqcc: copyright message now includes compile date instead.
fteqccgui: the treeview control is now coloured depending on whether there were warnings/errors in the last compile.
fteqccgui: the output window is now focused and scrolls down as compilation progresses.
pr_dumpplatform command dumps out some pragmas to convert more serious warnings to errors. This is to avoid the infamous 'fteqcc sucks cos my code sucks' issue.
rewrote prespawn/modelist/soundlist code. server tracks progress now.
------------------------------------------------------------------------
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@4167 fc73d0e0-1445-4013-8a0c-d673dee63da5
2013-03-12 22:29:40 +00:00
cl_strisidx [ cl_numstrisidx + + ] = cl_numstrisvert + 5 - t - > firstvert ;
cl_strisidx [ cl_numstrisidx + + ] = cl_numstrisvert + 4 - t - > firstvert ;
cl_strisidx [ cl_numstrisidx + + ] = cl_numstrisvert + 0 - t - > firstvert ;
cl_strisidx [ cl_numstrisidx + + ] = cl_numstrisvert + 1 - t - > firstvert ;
cl_strisidx [ cl_numstrisidx + + ] = cl_numstrisvert + 5 - t - > firstvert ;
cl_strisidx [ cl_numstrisidx + + ] = cl_numstrisvert + 0 - t - > firstvert ;
2012-02-12 05:18:31 +00:00
/*right*/
------------------------------------------------------------------------
r4169 | acceptthis | 2013-01-17 08:55:12 +0000 (Thu, 17 Jan 2013) | 31 lines
removed MAX_VISEDICTS limit.
PEXT2_REPLACEMENTDELTAS tweaked, now has 4 million entity limit. still not enabled by default.
TE_BEAM now maps to a separate TEQW_BEAM to avoid conflicts with QW.
added android multitouch emulation for windows/rawinput (in_simulatemultitouch).
split topcolor/bottomcolor from scoreboard, for dp's colormap|1024 feature.
now using utf-8 for windows consoles.
qcc warnings/errors now give clickable console links for quick+easy editing.
disabled menutint when the currently active item changes contrast or gamma (for OneManClan).
Added support for drawfont/drawfontscale.
tweaked the qcvm a little to reduce the number of pointers.
.doll file loading. still experimental and will likely crash. requires csqc active, even if its a dummy progs. this will be fixed in time. Still other things that need cleaning up.
windows: gl_font "?" shows the standard windows font-selection dialog, and can be used to select windows fonts. not all work. and you probably don't want to use windings.
fixed splitscreen support when playing mvds. added mini-scoreboards to splitscreen.
editor/debugger now shows asm if there's no linenumber info. also, pressing f1 for help shows the shortcuts.
Added support for .framegroups files for psk(psa) and iqm formats.
True support for ezquake's colour codes. Mutually exclusive with background colours.
path command output slightly more readable.
added support for digest_hex (MD4, SHA1, CRC16).
skingroups now colourmap correctly.
Fix terrain colour hints, and litdata from the wrong bsp.
fix ftp dual-homed issue. support epsv command, and enable ipv6 (eprt still not supported).
remove d3d11 compilation from the makefile. the required headers are not provided by mingw, and are not available to the build bot, so don't bother.
fix v *= v.x and similar opcodes.
fteqcc: fixed support for áéíóú type chars in names. utf-8 files now properly supported (even with the utf-8 bom/identifier). utf-16 also supported.
fteqcc: fixed '#if 1 == 3 && 4' parsing.
fteqcc: -Werror acts on the warning, rather than as a separate error. Line numbers are thus more readable.
fteqcc: copyright message now includes compile date instead.
fteqccgui: the treeview control is now coloured depending on whether there were warnings/errors in the last compile.
fteqccgui: the output window is now focused and scrolls down as compilation progresses.
pr_dumpplatform command dumps out some pragmas to convert more serious warnings to errors. This is to avoid the infamous 'fteqcc sucks cos my code sucks' issue.
rewrote prespawn/modelist/soundlist code. server tracks progress now.
------------------------------------------------------------------------
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@4167 fc73d0e0-1445-4013-8a0c-d673dee63da5
2013-03-12 22:29:40 +00:00
cl_strisidx [ cl_numstrisidx + + ] = cl_numstrisvert + 2 - t - > firstvert ;
cl_strisidx [ cl_numstrisidx + + ] = cl_numstrisvert + 6 - t - > firstvert ;
cl_strisidx [ cl_numstrisidx + + ] = cl_numstrisvert + 7 - t - > firstvert ;
cl_strisidx [ cl_numstrisidx + + ] = cl_numstrisvert + 2 - t - > firstvert ;
cl_strisidx [ cl_numstrisidx + + ] = cl_numstrisvert + 7 - t - > firstvert ;
cl_strisidx [ cl_numstrisidx + + ] = cl_numstrisvert + 3 - t - > firstvert ;
2012-02-12 05:18:31 +00:00
/*urm, the other way*/
------------------------------------------------------------------------
r4169 | acceptthis | 2013-01-17 08:55:12 +0000 (Thu, 17 Jan 2013) | 31 lines
removed MAX_VISEDICTS limit.
PEXT2_REPLACEMENTDELTAS tweaked, now has 4 million entity limit. still not enabled by default.
TE_BEAM now maps to a separate TEQW_BEAM to avoid conflicts with QW.
added android multitouch emulation for windows/rawinput (in_simulatemultitouch).
split topcolor/bottomcolor from scoreboard, for dp's colormap|1024 feature.
now using utf-8 for windows consoles.
qcc warnings/errors now give clickable console links for quick+easy editing.
disabled menutint when the currently active item changes contrast or gamma (for OneManClan).
Added support for drawfont/drawfontscale.
tweaked the qcvm a little to reduce the number of pointers.
.doll file loading. still experimental and will likely crash. requires csqc active, even if its a dummy progs. this will be fixed in time. Still other things that need cleaning up.
windows: gl_font "?" shows the standard windows font-selection dialog, and can be used to select windows fonts. not all work. and you probably don't want to use windings.
fixed splitscreen support when playing mvds. added mini-scoreboards to splitscreen.
editor/debugger now shows asm if there's no linenumber info. also, pressing f1 for help shows the shortcuts.
Added support for .framegroups files for psk(psa) and iqm formats.
True support for ezquake's colour codes. Mutually exclusive with background colours.
path command output slightly more readable.
added support for digest_hex (MD4, SHA1, CRC16).
skingroups now colourmap correctly.
Fix terrain colour hints, and litdata from the wrong bsp.
fix ftp dual-homed issue. support epsv command, and enable ipv6 (eprt still not supported).
remove d3d11 compilation from the makefile. the required headers are not provided by mingw, and are not available to the build bot, so don't bother.
fix v *= v.x and similar opcodes.
fteqcc: fixed support for áéíóú type chars in names. utf-8 files now properly supported (even with the utf-8 bom/identifier). utf-16 also supported.
fteqcc: fixed '#if 1 == 3 && 4' parsing.
fteqcc: -Werror acts on the warning, rather than as a separate error. Line numbers are thus more readable.
fteqcc: copyright message now includes compile date instead.
fteqccgui: the treeview control is now coloured depending on whether there were warnings/errors in the last compile.
fteqccgui: the output window is now focused and scrolls down as compilation progresses.
pr_dumpplatform command dumps out some pragmas to convert more serious warnings to errors. This is to avoid the infamous 'fteqcc sucks cos my code sucks' issue.
rewrote prespawn/modelist/soundlist code. server tracks progress now.
------------------------------------------------------------------------
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@4167 fc73d0e0-1445-4013-8a0c-d673dee63da5
2013-03-12 22:29:40 +00:00
cl_strisidx [ cl_numstrisidx + + ] = cl_numstrisvert + 2 - t - > firstvert ;
cl_strisidx [ cl_numstrisidx + + ] = cl_numstrisvert + 4 - t - > firstvert ;
cl_strisidx [ cl_numstrisidx + + ] = cl_numstrisvert + 6 - t - > firstvert ;
cl_strisidx [ cl_numstrisidx + + ] = cl_numstrisvert + 4 - t - > firstvert ;
cl_strisidx [ cl_numstrisidx + + ] = cl_numstrisvert + 2 - t - > firstvert ;
cl_strisidx [ cl_numstrisidx + + ] = cl_numstrisvert + 0 - t - > firstvert ;
2012-02-12 05:18:31 +00:00
/*and its oposite*/
------------------------------------------------------------------------
r4169 | acceptthis | 2013-01-17 08:55:12 +0000 (Thu, 17 Jan 2013) | 31 lines
removed MAX_VISEDICTS limit.
PEXT2_REPLACEMENTDELTAS tweaked, now has 4 million entity limit. still not enabled by default.
TE_BEAM now maps to a separate TEQW_BEAM to avoid conflicts with QW.
added android multitouch emulation for windows/rawinput (in_simulatemultitouch).
split topcolor/bottomcolor from scoreboard, for dp's colormap|1024 feature.
now using utf-8 for windows consoles.
qcc warnings/errors now give clickable console links for quick+easy editing.
disabled menutint when the currently active item changes contrast or gamma (for OneManClan).
Added support for drawfont/drawfontscale.
tweaked the qcvm a little to reduce the number of pointers.
.doll file loading. still experimental and will likely crash. requires csqc active, even if its a dummy progs. this will be fixed in time. Still other things that need cleaning up.
windows: gl_font "?" shows the standard windows font-selection dialog, and can be used to select windows fonts. not all work. and you probably don't want to use windings.
fixed splitscreen support when playing mvds. added mini-scoreboards to splitscreen.
editor/debugger now shows asm if there's no linenumber info. also, pressing f1 for help shows the shortcuts.
Added support for .framegroups files for psk(psa) and iqm formats.
True support for ezquake's colour codes. Mutually exclusive with background colours.
path command output slightly more readable.
added support for digest_hex (MD4, SHA1, CRC16).
skingroups now colourmap correctly.
Fix terrain colour hints, and litdata from the wrong bsp.
fix ftp dual-homed issue. support epsv command, and enable ipv6 (eprt still not supported).
remove d3d11 compilation from the makefile. the required headers are not provided by mingw, and are not available to the build bot, so don't bother.
fix v *= v.x and similar opcodes.
fteqcc: fixed support for áéíóú type chars in names. utf-8 files now properly supported (even with the utf-8 bom/identifier). utf-16 also supported.
fteqcc: fixed '#if 1 == 3 && 4' parsing.
fteqcc: -Werror acts on the warning, rather than as a separate error. Line numbers are thus more readable.
fteqcc: copyright message now includes compile date instead.
fteqccgui: the treeview control is now coloured depending on whether there were warnings/errors in the last compile.
fteqccgui: the output window is now focused and scrolls down as compilation progresses.
pr_dumpplatform command dumps out some pragmas to convert more serious warnings to errors. This is to avoid the infamous 'fteqcc sucks cos my code sucks' issue.
rewrote prespawn/modelist/soundlist code. server tracks progress now.
------------------------------------------------------------------------
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@4167 fc73d0e0-1445-4013-8a0c-d673dee63da5
2013-03-12 22:29:40 +00:00
cl_strisidx [ cl_numstrisidx + + ] = cl_numstrisvert + 7 - t - > firstvert ;
cl_strisidx [ cl_numstrisidx + + ] = cl_numstrisvert + 5 - t - > firstvert ;
cl_strisidx [ cl_numstrisidx + + ] = cl_numstrisvert + 3 - t - > firstvert ;
cl_strisidx [ cl_numstrisidx + + ] = cl_numstrisvert + 1 - t - > firstvert ;
cl_strisidx [ cl_numstrisidx + + ] = cl_numstrisvert + 3 - t - > firstvert ;
cl_strisidx [ cl_numstrisidx + + ] = cl_numstrisvert + 5 - t - > firstvert ;
2012-02-12 05:18:31 +00:00
t - > numvert + = 8 ;
t - > numidx = cl_numstrisidx - t - > firstidx ;
cl_numstrisvert + = 8 ;
}
# include "pr_common.h"
void CLQ1_AddVisibleBBoxes ( void )
{
world_t * w ;
wedict_t * e ;
int i ;
shader_t * s ;
vec3_t min , max , size ;
switch ( r_showbboxes . ival & 3 )
{
default :
return ;
# ifndef CLIENTONLY
case 1 :
w = & sv . world ;
break ;
# endif
# ifdef CSQC_DAT
case 2 :
2016-02-15 06:01:17 +00:00
{
extern world_t csqc_world ;
w = & csqc_world ;
}
2012-07-05 19:42:36 +00:00
break ;
2012-02-12 05:18:31 +00:00
# endif
2012-07-05 19:42:36 +00:00
case 3 :
{
2013-03-12 22:53:23 +00:00
inframe_t * frame ;
2012-07-05 19:42:36 +00:00
packet_entities_t * pak ;
entity_state_t * state ;
model_t * mod ;
2013-08-21 07:14:39 +00:00
s = R_RegisterShader ( " bboxshader " , SUF_NONE ,
2012-07-05 19:42:36 +00:00
" { \n "
2013-08-21 07:14:39 +00:00
" polygonoffset \n "
" { \n "
" map $whiteimage \n "
" blendfunc add \n "
" rgbgen vertex \n "
" alphagen vertex \n "
" } \n "
2012-07-05 19:42:36 +00:00
" } \n " ) ;
2013-03-12 22:53:23 +00:00
frame = & cl . inframes [ cl . parsecount & UPDATE_MASK ] ;
2012-07-05 19:42:36 +00:00
pak = & frame - > packet_entities ;
for ( i = 0 ; i < pak - > num_entities ; i + + )
{
state = & pak - > entities [ i ] ;
2016-07-12 00:40:13 +00:00
if ( state - > solidsize = = ES_SOLID_NOT & & ! state - > skinnum )
2012-07-05 19:42:36 +00:00
continue ;
2016-07-12 00:40:13 +00:00
if ( state - > solidsize = = ES_SOLID_BSP )
2012-07-05 19:42:36 +00:00
{ /*bsp model size*/
if ( state - > modelindex < = 0 )
continue ;
if ( ! cl . model_precache [ state - > modelindex ] )
continue ;
/*this makes non-inline bsp objects non-solid for prediction*/
2013-03-12 22:53:23 +00:00
if ( ( cls . fteprotocolextensions2 & PEXT2_REPLACEMENTDELTAS ) | | ( ( * cl . model_precache [ state - > modelindex ] - > name = = ' * ' | | cl . model_precache [ state - > modelindex ] - > numsubmodels ) & & cl . model_precache [ state - > modelindex ] - > hulls [ 1 ] . firstclipnode ) )
2012-07-05 19:42:36 +00:00
{
mod = cl . model_precache [ state - > modelindex ] ;
VectorAdd ( state - > origin , mod - > mins , min ) ;
VectorAdd ( state - > origin , mod - > maxs , max ) ;
------------------------------------------------------------------------
r4169 | acceptthis | 2013-01-17 08:55:12 +0000 (Thu, 17 Jan 2013) | 31 lines
removed MAX_VISEDICTS limit.
PEXT2_REPLACEMENTDELTAS tweaked, now has 4 million entity limit. still not enabled by default.
TE_BEAM now maps to a separate TEQW_BEAM to avoid conflicts with QW.
added android multitouch emulation for windows/rawinput (in_simulatemultitouch).
split topcolor/bottomcolor from scoreboard, for dp's colormap|1024 feature.
now using utf-8 for windows consoles.
qcc warnings/errors now give clickable console links for quick+easy editing.
disabled menutint when the currently active item changes contrast or gamma (for OneManClan).
Added support for drawfont/drawfontscale.
tweaked the qcvm a little to reduce the number of pointers.
.doll file loading. still experimental and will likely crash. requires csqc active, even if its a dummy progs. this will be fixed in time. Still other things that need cleaning up.
windows: gl_font "?" shows the standard windows font-selection dialog, and can be used to select windows fonts. not all work. and you probably don't want to use windings.
fixed splitscreen support when playing mvds. added mini-scoreboards to splitscreen.
editor/debugger now shows asm if there's no linenumber info. also, pressing f1 for help shows the shortcuts.
Added support for .framegroups files for psk(psa) and iqm formats.
True support for ezquake's colour codes. Mutually exclusive with background colours.
path command output slightly more readable.
added support for digest_hex (MD4, SHA1, CRC16).
skingroups now colourmap correctly.
Fix terrain colour hints, and litdata from the wrong bsp.
fix ftp dual-homed issue. support epsv command, and enable ipv6 (eprt still not supported).
remove d3d11 compilation from the makefile. the required headers are not provided by mingw, and are not available to the build bot, so don't bother.
fix v *= v.x and similar opcodes.
fteqcc: fixed support for áéíóú type chars in names. utf-8 files now properly supported (even with the utf-8 bom/identifier). utf-16 also supported.
fteqcc: fixed '#if 1 == 3 && 4' parsing.
fteqcc: -Werror acts on the warning, rather than as a separate error. Line numbers are thus more readable.
fteqcc: copyright message now includes compile date instead.
fteqccgui: the treeview control is now coloured depending on whether there were warnings/errors in the last compile.
fteqccgui: the output window is now focused and scrolls down as compilation progresses.
pr_dumpplatform command dumps out some pragmas to convert more serious warnings to errors. This is to avoid the infamous 'fteqcc sucks cos my code sucks' issue.
rewrote prespawn/modelist/soundlist code. server tracks progress now.
------------------------------------------------------------------------
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@4167 fc73d0e0-1445-4013-8a0c-d673dee63da5
2013-03-12 22:29:40 +00:00
CLQ1_AddOrientedCube ( s , min , max , NULL , 0.1 , 0 , 0 , 1 ) ;
2012-07-05 19:42:36 +00:00
}
}
else
{
/*don't bother with angles*/
2016-07-12 00:40:13 +00:00
COM_DecodeSize ( state - > solidsize , min , max ) ;
2012-07-05 19:42:36 +00:00
VectorAdd ( state - > origin , min , min ) ;
VectorAdd ( state - > origin , max , max ) ;
------------------------------------------------------------------------
r4169 | acceptthis | 2013-01-17 08:55:12 +0000 (Thu, 17 Jan 2013) | 31 lines
removed MAX_VISEDICTS limit.
PEXT2_REPLACEMENTDELTAS tweaked, now has 4 million entity limit. still not enabled by default.
TE_BEAM now maps to a separate TEQW_BEAM to avoid conflicts with QW.
added android multitouch emulation for windows/rawinput (in_simulatemultitouch).
split topcolor/bottomcolor from scoreboard, for dp's colormap|1024 feature.
now using utf-8 for windows consoles.
qcc warnings/errors now give clickable console links for quick+easy editing.
disabled menutint when the currently active item changes contrast or gamma (for OneManClan).
Added support for drawfont/drawfontscale.
tweaked the qcvm a little to reduce the number of pointers.
.doll file loading. still experimental and will likely crash. requires csqc active, even if its a dummy progs. this will be fixed in time. Still other things that need cleaning up.
windows: gl_font "?" shows the standard windows font-selection dialog, and can be used to select windows fonts. not all work. and you probably don't want to use windings.
fixed splitscreen support when playing mvds. added mini-scoreboards to splitscreen.
editor/debugger now shows asm if there's no linenumber info. also, pressing f1 for help shows the shortcuts.
Added support for .framegroups files for psk(psa) and iqm formats.
True support for ezquake's colour codes. Mutually exclusive with background colours.
path command output slightly more readable.
added support for digest_hex (MD4, SHA1, CRC16).
skingroups now colourmap correctly.
Fix terrain colour hints, and litdata from the wrong bsp.
fix ftp dual-homed issue. support epsv command, and enable ipv6 (eprt still not supported).
remove d3d11 compilation from the makefile. the required headers are not provided by mingw, and are not available to the build bot, so don't bother.
fix v *= v.x and similar opcodes.
fteqcc: fixed support for áéíóú type chars in names. utf-8 files now properly supported (even with the utf-8 bom/identifier). utf-16 also supported.
fteqcc: fixed '#if 1 == 3 && 4' parsing.
fteqcc: -Werror acts on the warning, rather than as a separate error. Line numbers are thus more readable.
fteqcc: copyright message now includes compile date instead.
fteqccgui: the treeview control is now coloured depending on whether there were warnings/errors in the last compile.
fteqccgui: the output window is now focused and scrolls down as compilation progresses.
pr_dumpplatform command dumps out some pragmas to convert more serious warnings to errors. This is to avoid the infamous 'fteqcc sucks cos my code sucks' issue.
rewrote prespawn/modelist/soundlist code. server tracks progress now.
------------------------------------------------------------------------
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@4167 fc73d0e0-1445-4013-8a0c-d673dee63da5
2013-03-12 22:29:40 +00:00
CLQ1_AddOrientedCube ( s , min , max , NULL , 0.1 , 0 , 0 , 1 ) ;
2013-09-06 22:57:44 +00:00
2016-07-12 00:40:13 +00:00
COM_DecodeSize ( state - > solidsize , min , max ) ;
2013-09-06 22:57:44 +00:00
VectorAdd ( state - > u . q1 . predorg , min , min ) ;
VectorAdd ( state - > u . q1 . predorg , max , max ) ;
CLQ1_AddOrientedCube ( s , min , max , NULL , 0 , 0 , 0.1 , 1 ) ;
2012-07-05 19:42:36 +00:00
}
}
}
return ;
2012-02-12 05:18:31 +00:00
}
if ( ! w - > progs )
return ;
2013-08-21 07:14:39 +00:00
s = R_RegisterShader ( " bboxshader " , SUF_NONE ,
2012-02-12 05:18:31 +00:00
" { \n "
2013-08-21 07:14:39 +00:00
" polygonoffset \n "
" { \n "
" map $whiteimage \n "
" blendfunc add \n "
" rgbgen vertex \n "
" alphagen vertex \n "
" } \n "
2012-02-12 05:18:31 +00:00
" } \n " ) ;
for ( i = 1 ; i < w - > num_edicts ; i + + )
{
2018-04-06 17:21:15 +00:00
e = WEDICT_NUM_PB ( w - > progs , i ) ;
2016-07-21 19:27:59 +00:00
if ( ED_ISFREE ( e ) )
2012-02-12 05:18:31 +00:00
continue ;
if ( r_showbboxes . ival & 4 )
{
2012-07-05 19:42:36 +00:00
//shows the hulls instead
2012-02-12 05:18:31 +00:00
/*mins is easy*/
VectorAdd ( e - > v - > origin , e - > v - > mins , min ) ;
/*maxs is weeeeird*/
VectorSubtract ( e - > v - > maxs , e - > v - > mins , size ) ;
if ( size [ 0 ] < 3 )
VectorCopy ( min , max ) ;
else if ( size [ 0 ] < = 32 )
{
max [ 0 ] = min [ 0 ] + 32 ;
max [ 1 ] = min [ 1 ] + 32 ;
max [ 2 ] = min [ 2 ] + 56 ;
}
else
{
max [ 0 ] = min [ 0 ] + 64 ;
max [ 1 ] = min [ 1 ] + 64 ;
max [ 2 ] = min [ 2 ] + 88 ;
}
}
else
{
2014-09-17 03:04:08 +00:00
if ( e - > v - > solid = = SOLID_BSP )
{
VectorCopy ( e - > v - > absmin , min ) ;
VectorCopy ( e - > v - > absmax , max ) ;
}
else
{
VectorAdd ( e - > v - > origin , e - > v - > mins , min ) ;
VectorAdd ( e - > v - > origin , e - > v - > maxs , max ) ;
}
}
if ( e - > xv - > geomtype = = GEOMTYPE_CAPSULE )
{
float rad = ( ( e - > v - > maxs [ 0 ] - e - > v - > mins [ 0 ] ) + ( e - > v - > maxs [ 1 ] - e - > v - > mins [ 1 ] ) ) / 4.0 ;
float height = ( e - > v - > maxs [ 2 ] - e - > v - > mins [ 2 ] ) / 2 ;
float matrix [ 12 ] = { 1 , 0 , 0 , 0 , 0 , 1 , 0 , 0 , 0 , 0 , 1 , 0 } ;
matrix [ 3 ] = e - > v - > origin [ 0 ] ;
matrix [ 7 ] = e - > v - > origin [ 1 ] ;
matrix [ 11 ] = e - > v - > origin [ 2 ] + ( e - > v - > maxs [ 2 ] - height ) ;
CLQ1_AddOrientedCylinder ( s , rad * 2 , height * 2 , true , matrix , ( e - > v - > solid | | e - > v - > movetype ) ? 0.1 : 0 , ( e - > v - > movetype = = MOVETYPE_STEP | | e - > v - > movetype = = MOVETYPE_TOSS | | e - > v - > movetype = = MOVETYPE_BOUNCE ) ? 0.1 : 0 , ( ( int ) e - > v - > flags & ( FL_ONGROUND | ( ( e - > v - > movetype = = MOVETYPE_STEP ) ? FL_FLY : 0 ) ) ) ? 0.1 : 0 , 1 ) ;
2012-02-12 05:18:31 +00:00
}
2014-09-17 03:04:08 +00:00
else
2015-06-22 11:49:15 +00:00
{
if ( ! e - > v - > solid & & ! e - > v - > movetype )
{
vec3_t ep = { 1 , 1 , 1 } ;
VectorAdd ( max , ep , max ) ;
VectorSubtract ( min , ep , min ) ;
CLQ1_AddOrientedCube ( s , min , max , NULL , 0 , 0.1 , 0 , 1 ) ;
}
else
CLQ1_AddOrientedCube ( s , min , max , NULL , ( e - > v - > solid | | e - > v - > movetype ) ? 0.1 : 0 , ( e - > v - > movetype = = MOVETYPE_STEP | | e - > v - > movetype = = MOVETYPE_TOSS | | e - > v - > movetype = = MOVETYPE_BOUNCE ) ? 0.1 : 0 , ( ( int ) e - > v - > flags & ( FL_ONGROUND | ( ( e - > v - > movetype = = MOVETYPE_STEP ) ? FL_FLY : 0 ) ) ) ? 0.1 : 0 , 1 ) ;
}
------------------------------------------------------------------------
r4169 | acceptthis | 2013-01-17 08:55:12 +0000 (Thu, 17 Jan 2013) | 31 lines
removed MAX_VISEDICTS limit.
PEXT2_REPLACEMENTDELTAS tweaked, now has 4 million entity limit. still not enabled by default.
TE_BEAM now maps to a separate TEQW_BEAM to avoid conflicts with QW.
added android multitouch emulation for windows/rawinput (in_simulatemultitouch).
split topcolor/bottomcolor from scoreboard, for dp's colormap|1024 feature.
now using utf-8 for windows consoles.
qcc warnings/errors now give clickable console links for quick+easy editing.
disabled menutint when the currently active item changes contrast or gamma (for OneManClan).
Added support for drawfont/drawfontscale.
tweaked the qcvm a little to reduce the number of pointers.
.doll file loading. still experimental and will likely crash. requires csqc active, even if its a dummy progs. this will be fixed in time. Still other things that need cleaning up.
windows: gl_font "?" shows the standard windows font-selection dialog, and can be used to select windows fonts. not all work. and you probably don't want to use windings.
fixed splitscreen support when playing mvds. added mini-scoreboards to splitscreen.
editor/debugger now shows asm if there's no linenumber info. also, pressing f1 for help shows the shortcuts.
Added support for .framegroups files for psk(psa) and iqm formats.
True support for ezquake's colour codes. Mutually exclusive with background colours.
path command output slightly more readable.
added support for digest_hex (MD4, SHA1, CRC16).
skingroups now colourmap correctly.
Fix terrain colour hints, and litdata from the wrong bsp.
fix ftp dual-homed issue. support epsv command, and enable ipv6 (eprt still not supported).
remove d3d11 compilation from the makefile. the required headers are not provided by mingw, and are not available to the build bot, so don't bother.
fix v *= v.x and similar opcodes.
fteqcc: fixed support for áéíóú type chars in names. utf-8 files now properly supported (even with the utf-8 bom/identifier). utf-16 also supported.
fteqcc: fixed '#if 1 == 3 && 4' parsing.
fteqcc: -Werror acts on the warning, rather than as a separate error. Line numbers are thus more readable.
fteqcc: copyright message now includes compile date instead.
fteqccgui: the treeview control is now coloured depending on whether there were warnings/errors in the last compile.
fteqccgui: the output window is now focused and scrolls down as compilation progresses.
pr_dumpplatform command dumps out some pragmas to convert more serious warnings to errors. This is to avoid the infamous 'fteqcc sucks cos my code sucks' issue.
rewrote prespawn/modelist/soundlist code. server tracks progress now.
------------------------------------------------------------------------
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@4167 fc73d0e0-1445-4013-8a0c-d673dee63da5
2013-03-12 22:29:40 +00:00
}
}
2015-03-03 00:14:43 +00:00
typedef struct
{
scenetris_t * t ;
vec4_t rgbavalue ;
vec3_t axis [ 3 ] ;
float offset [ 3 ] ;
float scale [ 3 ] ;
} cl_adddecal_ctx_t ;
static void CL_AddDecal_Callback ( void * vctx , vec3_t * fte_restrict points , size_t numtris , shader_t * shader )
{
cl_adddecal_ctx_t * ctx = vctx ;
scenetris_t * t = ctx - > t ;
size_t numpoints = numtris * 3 ;
size_t v ;
if ( cl_numstrisvert + numpoints > cl_maxstrisvert )
2019-02-19 06:49:03 +00:00
cl_stris_ExpandVerts ( cl_numstrisvert + numpoints ) ;
2015-03-03 00:14:43 +00:00
if ( cl_maxstrisidx < cl_numstrisidx + numpoints )
{
cl_maxstrisidx = cl_numstrisidx + numpoints + 64 ;
cl_strisidx = BZ_Realloc ( cl_strisidx , sizeof ( * cl_strisidx ) * cl_maxstrisidx ) ;
}
for ( v = 0 ; v < numpoints ; v + + )
{
VectorCopy ( points [ v ] , cl_strisvertv [ cl_numstrisvert + v ] ) ;
2017-11-30 17:59:11 +00:00
cl_strisvertt [ cl_numstrisvert + v ] [ 0 ] = 1 + ( DotProduct ( points [ v ] , ctx - > axis [ 1 ] ) - ctx - > offset [ 1 ] ) * ctx - > scale [ 1 ] ;
2015-03-03 00:14:43 +00:00
cl_strisvertt [ cl_numstrisvert + v ] [ 1 ] = - ( DotProduct ( points [ v ] , ctx - > axis [ 2 ] ) - ctx - > offset [ 2 ] ) * ctx - > scale [ 2 ] ;
cl_strisvertc [ cl_numstrisvert + v ] [ 0 ] = ctx - > rgbavalue [ 0 ] ;
cl_strisvertc [ cl_numstrisvert + v ] [ 1 ] = ctx - > rgbavalue [ 1 ] ;
cl_strisvertc [ cl_numstrisvert + v ] [ 2 ] = ctx - > rgbavalue [ 2 ] ;
2018-11-19 06:37:25 +00:00
cl_strisvertc [ cl_numstrisvert + v ] [ 3 ] = ctx - > rgbavalue [ 3 ] * ( 1 - fabs ( DotProduct ( points [ v ] , ctx - > axis [ 0 ] ) - ctx - > offset [ 0 ] ) * ctx - > scale [ 0 ] ) ;
2015-03-03 00:14:43 +00:00
}
for ( v = 0 ; v < numpoints ; v + + )
{
cl_strisidx [ cl_numstrisidx + + ] = cl_numstrisvert + v - t - > firstvert ;
}
t - > numvert + = numpoints ;
t - > numidx + = numpoints ;
cl_numstrisvert + = numpoints ;
}
------------------------------------------------------------------------
r4169 | acceptthis | 2013-01-17 08:55:12 +0000 (Thu, 17 Jan 2013) | 31 lines
removed MAX_VISEDICTS limit.
PEXT2_REPLACEMENTDELTAS tweaked, now has 4 million entity limit. still not enabled by default.
TE_BEAM now maps to a separate TEQW_BEAM to avoid conflicts with QW.
added android multitouch emulation for windows/rawinput (in_simulatemultitouch).
split topcolor/bottomcolor from scoreboard, for dp's colormap|1024 feature.
now using utf-8 for windows consoles.
qcc warnings/errors now give clickable console links for quick+easy editing.
disabled menutint when the currently active item changes contrast or gamma (for OneManClan).
Added support for drawfont/drawfontscale.
tweaked the qcvm a little to reduce the number of pointers.
.doll file loading. still experimental and will likely crash. requires csqc active, even if its a dummy progs. this will be fixed in time. Still other things that need cleaning up.
windows: gl_font "?" shows the standard windows font-selection dialog, and can be used to select windows fonts. not all work. and you probably don't want to use windings.
fixed splitscreen support when playing mvds. added mini-scoreboards to splitscreen.
editor/debugger now shows asm if there's no linenumber info. also, pressing f1 for help shows the shortcuts.
Added support for .framegroups files for psk(psa) and iqm formats.
True support for ezquake's colour codes. Mutually exclusive with background colours.
path command output slightly more readable.
added support for digest_hex (MD4, SHA1, CRC16).
skingroups now colourmap correctly.
Fix terrain colour hints, and litdata from the wrong bsp.
fix ftp dual-homed issue. support epsv command, and enable ipv6 (eprt still not supported).
remove d3d11 compilation from the makefile. the required headers are not provided by mingw, and are not available to the build bot, so don't bother.
fix v *= v.x and similar opcodes.
fteqcc: fixed support for áéíóú type chars in names. utf-8 files now properly supported (even with the utf-8 bom/identifier). utf-16 also supported.
fteqcc: fixed '#if 1 == 3 && 4' parsing.
fteqcc: -Werror acts on the warning, rather than as a separate error. Line numbers are thus more readable.
fteqcc: copyright message now includes compile date instead.
fteqccgui: the treeview control is now coloured depending on whether there were warnings/errors in the last compile.
fteqccgui: the output window is now focused and scrolls down as compilation progresses.
pr_dumpplatform command dumps out some pragmas to convert more serious warnings to errors. This is to avoid the infamous 'fteqcc sucks cos my code sucks' issue.
rewrote prespawn/modelist/soundlist code. server tracks progress now.
------------------------------------------------------------------------
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@4167 fc73d0e0-1445-4013-8a0c-d673dee63da5
2013-03-12 22:29:40 +00:00
void CL_AddDecal ( shader_t * shader , vec3_t origin , vec3_t up , vec3_t side , vec3_t rgbvalue , float alphavalue )
{
scenetris_t * t ;
2018-11-19 06:37:25 +00:00
float l , s , radius , vradius ;
2015-03-03 00:14:43 +00:00
cl_adddecal_ctx_t ctx ;
------------------------------------------------------------------------
r4169 | acceptthis | 2013-01-17 08:55:12 +0000 (Thu, 17 Jan 2013) | 31 lines
removed MAX_VISEDICTS limit.
PEXT2_REPLACEMENTDELTAS tweaked, now has 4 million entity limit. still not enabled by default.
TE_BEAM now maps to a separate TEQW_BEAM to avoid conflicts with QW.
added android multitouch emulation for windows/rawinput (in_simulatemultitouch).
split topcolor/bottomcolor from scoreboard, for dp's colormap|1024 feature.
now using utf-8 for windows consoles.
qcc warnings/errors now give clickable console links for quick+easy editing.
disabled menutint when the currently active item changes contrast or gamma (for OneManClan).
Added support for drawfont/drawfontscale.
tweaked the qcvm a little to reduce the number of pointers.
.doll file loading. still experimental and will likely crash. requires csqc active, even if its a dummy progs. this will be fixed in time. Still other things that need cleaning up.
windows: gl_font "?" shows the standard windows font-selection dialog, and can be used to select windows fonts. not all work. and you probably don't want to use windings.
fixed splitscreen support when playing mvds. added mini-scoreboards to splitscreen.
editor/debugger now shows asm if there's no linenumber info. also, pressing f1 for help shows the shortcuts.
Added support for .framegroups files for psk(psa) and iqm formats.
True support for ezquake's colour codes. Mutually exclusive with background colours.
path command output slightly more readable.
added support for digest_hex (MD4, SHA1, CRC16).
skingroups now colourmap correctly.
Fix terrain colour hints, and litdata from the wrong bsp.
fix ftp dual-homed issue. support epsv command, and enable ipv6 (eprt still not supported).
remove d3d11 compilation from the makefile. the required headers are not provided by mingw, and are not available to the build bot, so don't bother.
fix v *= v.x and similar opcodes.
fteqcc: fixed support for áéíóú type chars in names. utf-8 files now properly supported (even with the utf-8 bom/identifier). utf-16 also supported.
fteqcc: fixed '#if 1 == 3 && 4' parsing.
fteqcc: -Werror acts on the warning, rather than as a separate error. Line numbers are thus more readable.
fteqcc: copyright message now includes compile date instead.
fteqccgui: the treeview control is now coloured depending on whether there were warnings/errors in the last compile.
fteqccgui: the output window is now focused and scrolls down as compilation progresses.
pr_dumpplatform command dumps out some pragmas to convert more serious warnings to errors. This is to avoid the infamous 'fteqcc sucks cos my code sucks' issue.
rewrote prespawn/modelist/soundlist code. server tracks progress now.
------------------------------------------------------------------------
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@4167 fc73d0e0-1445-4013-8a0c-d673dee63da5
2013-03-12 22:29:40 +00:00
2015-03-03 00:14:43 +00:00
VectorNegate ( up , ctx . axis [ 0 ] ) ;
VectorCopy ( side , ctx . axis [ 2 ] ) ;
------------------------------------------------------------------------
r4169 | acceptthis | 2013-01-17 08:55:12 +0000 (Thu, 17 Jan 2013) | 31 lines
removed MAX_VISEDICTS limit.
PEXT2_REPLACEMENTDELTAS tweaked, now has 4 million entity limit. still not enabled by default.
TE_BEAM now maps to a separate TEQW_BEAM to avoid conflicts with QW.
added android multitouch emulation for windows/rawinput (in_simulatemultitouch).
split topcolor/bottomcolor from scoreboard, for dp's colormap|1024 feature.
now using utf-8 for windows consoles.
qcc warnings/errors now give clickable console links for quick+easy editing.
disabled menutint when the currently active item changes contrast or gamma (for OneManClan).
Added support for drawfont/drawfontscale.
tweaked the qcvm a little to reduce the number of pointers.
.doll file loading. still experimental and will likely crash. requires csqc active, even if its a dummy progs. this will be fixed in time. Still other things that need cleaning up.
windows: gl_font "?" shows the standard windows font-selection dialog, and can be used to select windows fonts. not all work. and you probably don't want to use windings.
fixed splitscreen support when playing mvds. added mini-scoreboards to splitscreen.
editor/debugger now shows asm if there's no linenumber info. also, pressing f1 for help shows the shortcuts.
Added support for .framegroups files for psk(psa) and iqm formats.
True support for ezquake's colour codes. Mutually exclusive with background colours.
path command output slightly more readable.
added support for digest_hex (MD4, SHA1, CRC16).
skingroups now colourmap correctly.
Fix terrain colour hints, and litdata from the wrong bsp.
fix ftp dual-homed issue. support epsv command, and enable ipv6 (eprt still not supported).
remove d3d11 compilation from the makefile. the required headers are not provided by mingw, and are not available to the build bot, so don't bother.
fix v *= v.x and similar opcodes.
fteqcc: fixed support for áéíóú type chars in names. utf-8 files now properly supported (even with the utf-8 bom/identifier). utf-16 also supported.
fteqcc: fixed '#if 1 == 3 && 4' parsing.
fteqcc: -Werror acts on the warning, rather than as a separate error. Line numbers are thus more readable.
fteqcc: copyright message now includes compile date instead.
fteqccgui: the treeview control is now coloured depending on whether there were warnings/errors in the last compile.
fteqccgui: the output window is now focused and scrolls down as compilation progresses.
pr_dumpplatform command dumps out some pragmas to convert more serious warnings to errors. This is to avoid the infamous 'fteqcc sucks cos my code sucks' issue.
rewrote prespawn/modelist/soundlist code. server tracks progress now.
------------------------------------------------------------------------
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@4167 fc73d0e0-1445-4013-8a0c-d673dee63da5
2013-03-12 22:29:40 +00:00
2017-11-23 04:05:53 +00:00
s = DotProduct ( ctx . axis [ 2 ] , ctx . axis [ 2 ] ) ;
l = DotProduct ( ctx . axis [ 0 ] , ctx . axis [ 0 ] ) ;
2018-11-19 06:37:25 +00:00
vradius = 1 / sqrt ( l ) ;
2017-11-23 04:05:53 +00:00
radius = 1 / sqrt ( s ) ;
------------------------------------------------------------------------
r4169 | acceptthis | 2013-01-17 08:55:12 +0000 (Thu, 17 Jan 2013) | 31 lines
removed MAX_VISEDICTS limit.
PEXT2_REPLACEMENTDELTAS tweaked, now has 4 million entity limit. still not enabled by default.
TE_BEAM now maps to a separate TEQW_BEAM to avoid conflicts with QW.
added android multitouch emulation for windows/rawinput (in_simulatemultitouch).
split topcolor/bottomcolor from scoreboard, for dp's colormap|1024 feature.
now using utf-8 for windows consoles.
qcc warnings/errors now give clickable console links for quick+easy editing.
disabled menutint when the currently active item changes contrast or gamma (for OneManClan).
Added support for drawfont/drawfontscale.
tweaked the qcvm a little to reduce the number of pointers.
.doll file loading. still experimental and will likely crash. requires csqc active, even if its a dummy progs. this will be fixed in time. Still other things that need cleaning up.
windows: gl_font "?" shows the standard windows font-selection dialog, and can be used to select windows fonts. not all work. and you probably don't want to use windings.
fixed splitscreen support when playing mvds. added mini-scoreboards to splitscreen.
editor/debugger now shows asm if there's no linenumber info. also, pressing f1 for help shows the shortcuts.
Added support for .framegroups files for psk(psa) and iqm formats.
True support for ezquake's colour codes. Mutually exclusive with background colours.
path command output slightly more readable.
added support for digest_hex (MD4, SHA1, CRC16).
skingroups now colourmap correctly.
Fix terrain colour hints, and litdata from the wrong bsp.
fix ftp dual-homed issue. support epsv command, and enable ipv6 (eprt still not supported).
remove d3d11 compilation from the makefile. the required headers are not provided by mingw, and are not available to the build bot, so don't bother.
fix v *= v.x and similar opcodes.
fteqcc: fixed support for áéíóú type chars in names. utf-8 files now properly supported (even with the utf-8 bom/identifier). utf-16 also supported.
fteqcc: fixed '#if 1 == 3 && 4' parsing.
fteqcc: -Werror acts on the warning, rather than as a separate error. Line numbers are thus more readable.
fteqcc: copyright message now includes compile date instead.
fteqccgui: the treeview control is now coloured depending on whether there were warnings/errors in the last compile.
fteqccgui: the output window is now focused and scrolls down as compilation progresses.
pr_dumpplatform command dumps out some pragmas to convert more serious warnings to errors. This is to avoid the infamous 'fteqcc sucks cos my code sucks' issue.
rewrote prespawn/modelist/soundlist code. server tracks progress now.
------------------------------------------------------------------------
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@4167 fc73d0e0-1445-4013-8a0c-d673dee63da5
2013-03-12 22:29:40 +00:00
2018-11-19 06:37:25 +00:00
VectorScale ( ctx . axis [ 0 ] , vradius , ctx . axis [ 0 ] ) ;
2017-11-23 04:05:53 +00:00
VectorScale ( ctx . axis [ 2 ] , radius , ctx . axis [ 2 ] ) ;
------------------------------------------------------------------------
r4169 | acceptthis | 2013-01-17 08:55:12 +0000 (Thu, 17 Jan 2013) | 31 lines
removed MAX_VISEDICTS limit.
PEXT2_REPLACEMENTDELTAS tweaked, now has 4 million entity limit. still not enabled by default.
TE_BEAM now maps to a separate TEQW_BEAM to avoid conflicts with QW.
added android multitouch emulation for windows/rawinput (in_simulatemultitouch).
split topcolor/bottomcolor from scoreboard, for dp's colormap|1024 feature.
now using utf-8 for windows consoles.
qcc warnings/errors now give clickable console links for quick+easy editing.
disabled menutint when the currently active item changes contrast or gamma (for OneManClan).
Added support for drawfont/drawfontscale.
tweaked the qcvm a little to reduce the number of pointers.
.doll file loading. still experimental and will likely crash. requires csqc active, even if its a dummy progs. this will be fixed in time. Still other things that need cleaning up.
windows: gl_font "?" shows the standard windows font-selection dialog, and can be used to select windows fonts. not all work. and you probably don't want to use windings.
fixed splitscreen support when playing mvds. added mini-scoreboards to splitscreen.
editor/debugger now shows asm if there's no linenumber info. also, pressing f1 for help shows the shortcuts.
Added support for .framegroups files for psk(psa) and iqm formats.
True support for ezquake's colour codes. Mutually exclusive with background colours.
path command output slightly more readable.
added support for digest_hex (MD4, SHA1, CRC16).
skingroups now colourmap correctly.
Fix terrain colour hints, and litdata from the wrong bsp.
fix ftp dual-homed issue. support epsv command, and enable ipv6 (eprt still not supported).
remove d3d11 compilation from the makefile. the required headers are not provided by mingw, and are not available to the build bot, so don't bother.
fix v *= v.x and similar opcodes.
fteqcc: fixed support for áéíóú type chars in names. utf-8 files now properly supported (even with the utf-8 bom/identifier). utf-16 also supported.
fteqcc: fixed '#if 1 == 3 && 4' parsing.
fteqcc: -Werror acts on the warning, rather than as a separate error. Line numbers are thus more readable.
fteqcc: copyright message now includes compile date instead.
fteqccgui: the treeview control is now coloured depending on whether there were warnings/errors in the last compile.
fteqccgui: the output window is now focused and scrolls down as compilation progresses.
pr_dumpplatform command dumps out some pragmas to convert more serious warnings to errors. This is to avoid the infamous 'fteqcc sucks cos my code sucks' issue.
rewrote prespawn/modelist/soundlist code. server tracks progress now.
------------------------------------------------------------------------
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@4167 fc73d0e0-1445-4013-8a0c-d673dee63da5
2013-03-12 22:29:40 +00:00
2017-11-23 04:05:53 +00:00
CrossProduct ( ctx . axis [ 0 ] , ctx . axis [ 2 ] , ctx . axis [ 1 ] ) ;
------------------------------------------------------------------------
r4169 | acceptthis | 2013-01-17 08:55:12 +0000 (Thu, 17 Jan 2013) | 31 lines
removed MAX_VISEDICTS limit.
PEXT2_REPLACEMENTDELTAS tweaked, now has 4 million entity limit. still not enabled by default.
TE_BEAM now maps to a separate TEQW_BEAM to avoid conflicts with QW.
added android multitouch emulation for windows/rawinput (in_simulatemultitouch).
split topcolor/bottomcolor from scoreboard, for dp's colormap|1024 feature.
now using utf-8 for windows consoles.
qcc warnings/errors now give clickable console links for quick+easy editing.
disabled menutint when the currently active item changes contrast or gamma (for OneManClan).
Added support for drawfont/drawfontscale.
tweaked the qcvm a little to reduce the number of pointers.
.doll file loading. still experimental and will likely crash. requires csqc active, even if its a dummy progs. this will be fixed in time. Still other things that need cleaning up.
windows: gl_font "?" shows the standard windows font-selection dialog, and can be used to select windows fonts. not all work. and you probably don't want to use windings.
fixed splitscreen support when playing mvds. added mini-scoreboards to splitscreen.
editor/debugger now shows asm if there's no linenumber info. also, pressing f1 for help shows the shortcuts.
Added support for .framegroups files for psk(psa) and iqm formats.
True support for ezquake's colour codes. Mutually exclusive with background colours.
path command output slightly more readable.
added support for digest_hex (MD4, SHA1, CRC16).
skingroups now colourmap correctly.
Fix terrain colour hints, and litdata from the wrong bsp.
fix ftp dual-homed issue. support epsv command, and enable ipv6 (eprt still not supported).
remove d3d11 compilation from the makefile. the required headers are not provided by mingw, and are not available to the build bot, so don't bother.
fix v *= v.x and similar opcodes.
fteqcc: fixed support for áéíóú type chars in names. utf-8 files now properly supported (even with the utf-8 bom/identifier). utf-16 also supported.
fteqcc: fixed '#if 1 == 3 && 4' parsing.
fteqcc: -Werror acts on the warning, rather than as a separate error. Line numbers are thus more readable.
fteqcc: copyright message now includes compile date instead.
fteqccgui: the treeview control is now coloured depending on whether there were warnings/errors in the last compile.
fteqccgui: the output window is now focused and scrolls down as compilation progresses.
pr_dumpplatform command dumps out some pragmas to convert more serious warnings to errors. This is to avoid the infamous 'fteqcc sucks cos my code sucks' issue.
rewrote prespawn/modelist/soundlist code. server tracks progress now.
------------------------------------------------------------------------
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@4167 fc73d0e0-1445-4013-8a0c-d673dee63da5
2013-03-12 22:29:40 +00:00
2017-11-23 04:05:53 +00:00
ctx . offset [ 2 ] = DotProduct ( origin , ctx . axis [ 2 ] ) + 0.5 * radius ;
2018-11-19 06:37:25 +00:00
ctx . offset [ 1 ] = DotProduct ( origin , ctx . axis [ 1 ] ) + 0.5 * radius ;
2015-03-03 00:14:43 +00:00
ctx . offset [ 0 ] = DotProduct ( origin , ctx . axis [ 0 ] ) ;
------------------------------------------------------------------------
r4169 | acceptthis | 2013-01-17 08:55:12 +0000 (Thu, 17 Jan 2013) | 31 lines
removed MAX_VISEDICTS limit.
PEXT2_REPLACEMENTDELTAS tweaked, now has 4 million entity limit. still not enabled by default.
TE_BEAM now maps to a separate TEQW_BEAM to avoid conflicts with QW.
added android multitouch emulation for windows/rawinput (in_simulatemultitouch).
split topcolor/bottomcolor from scoreboard, for dp's colormap|1024 feature.
now using utf-8 for windows consoles.
qcc warnings/errors now give clickable console links for quick+easy editing.
disabled menutint when the currently active item changes contrast or gamma (for OneManClan).
Added support for drawfont/drawfontscale.
tweaked the qcvm a little to reduce the number of pointers.
.doll file loading. still experimental and will likely crash. requires csqc active, even if its a dummy progs. this will be fixed in time. Still other things that need cleaning up.
windows: gl_font "?" shows the standard windows font-selection dialog, and can be used to select windows fonts. not all work. and you probably don't want to use windings.
fixed splitscreen support when playing mvds. added mini-scoreboards to splitscreen.
editor/debugger now shows asm if there's no linenumber info. also, pressing f1 for help shows the shortcuts.
Added support for .framegroups files for psk(psa) and iqm formats.
True support for ezquake's colour codes. Mutually exclusive with background colours.
path command output slightly more readable.
added support for digest_hex (MD4, SHA1, CRC16).
skingroups now colourmap correctly.
Fix terrain colour hints, and litdata from the wrong bsp.
fix ftp dual-homed issue. support epsv command, and enable ipv6 (eprt still not supported).
remove d3d11 compilation from the makefile. the required headers are not provided by mingw, and are not available to the build bot, so don't bother.
fix v *= v.x and similar opcodes.
fteqcc: fixed support for áéíóú type chars in names. utf-8 files now properly supported (even with the utf-8 bom/identifier). utf-16 also supported.
fteqcc: fixed '#if 1 == 3 && 4' parsing.
fteqcc: -Werror acts on the warning, rather than as a separate error. Line numbers are thus more readable.
fteqcc: copyright message now includes compile date instead.
fteqccgui: the treeview control is now coloured depending on whether there were warnings/errors in the last compile.
fteqccgui: the output window is now focused and scrolls down as compilation progresses.
pr_dumpplatform command dumps out some pragmas to convert more serious warnings to errors. This is to avoid the infamous 'fteqcc sucks cos my code sucks' issue.
rewrote prespawn/modelist/soundlist code. server tracks progress now.
------------------------------------------------------------------------
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@4167 fc73d0e0-1445-4013-8a0c-d673dee63da5
2013-03-12 22:29:40 +00:00
2017-11-23 04:05:53 +00:00
ctx . scale [ 2 ] = 1 / radius ;
2018-11-19 06:37:25 +00:00
ctx . scale [ 1 ] = 1 / radius ;
ctx . scale [ 0 ] = 2 / vradius ;
if ( R2D_Flush )
R2D_Flush ( ) ;
------------------------------------------------------------------------
r4169 | acceptthis | 2013-01-17 08:55:12 +0000 (Thu, 17 Jan 2013) | 31 lines
removed MAX_VISEDICTS limit.
PEXT2_REPLACEMENTDELTAS tweaked, now has 4 million entity limit. still not enabled by default.
TE_BEAM now maps to a separate TEQW_BEAM to avoid conflicts with QW.
added android multitouch emulation for windows/rawinput (in_simulatemultitouch).
split topcolor/bottomcolor from scoreboard, for dp's colormap|1024 feature.
now using utf-8 for windows consoles.
qcc warnings/errors now give clickable console links for quick+easy editing.
disabled menutint when the currently active item changes contrast or gamma (for OneManClan).
Added support for drawfont/drawfontscale.
tweaked the qcvm a little to reduce the number of pointers.
.doll file loading. still experimental and will likely crash. requires csqc active, even if its a dummy progs. this will be fixed in time. Still other things that need cleaning up.
windows: gl_font "?" shows the standard windows font-selection dialog, and can be used to select windows fonts. not all work. and you probably don't want to use windings.
fixed splitscreen support when playing mvds. added mini-scoreboards to splitscreen.
editor/debugger now shows asm if there's no linenumber info. also, pressing f1 for help shows the shortcuts.
Added support for .framegroups files for psk(psa) and iqm formats.
True support for ezquake's colour codes. Mutually exclusive with background colours.
path command output slightly more readable.
added support for digest_hex (MD4, SHA1, CRC16).
skingroups now colourmap correctly.
Fix terrain colour hints, and litdata from the wrong bsp.
fix ftp dual-homed issue. support epsv command, and enable ipv6 (eprt still not supported).
remove d3d11 compilation from the makefile. the required headers are not provided by mingw, and are not available to the build bot, so don't bother.
fix v *= v.x and similar opcodes.
fteqcc: fixed support for áéíóú type chars in names. utf-8 files now properly supported (even with the utf-8 bom/identifier). utf-16 also supported.
fteqcc: fixed '#if 1 == 3 && 4' parsing.
fteqcc: -Werror acts on the warning, rather than as a separate error. Line numbers are thus more readable.
fteqcc: copyright message now includes compile date instead.
fteqccgui: the treeview control is now coloured depending on whether there were warnings/errors in the last compile.
fteqccgui: the output window is now focused and scrolls down as compilation progresses.
pr_dumpplatform command dumps out some pragmas to convert more serious warnings to errors. This is to avoid the infamous 'fteqcc sucks cos my code sucks' issue.
rewrote prespawn/modelist/soundlist code. server tracks progress now.
------------------------------------------------------------------------
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@4167 fc73d0e0-1445-4013-8a0c-d673dee63da5
2013-03-12 22:29:40 +00:00
/*reuse the previous trigroup if its the same shader*/
if ( cl_numstris & & cl_stris [ cl_numstris - 1 ] . shader = = shader & & cl_stris [ cl_numstris - 1 ] . flags = = ( BEF_NODLIGHT | BEF_NOSHADOWS ) )
t = & cl_stris [ cl_numstris - 1 ] ;
else
{
if ( cl_numstris = = cl_maxstris )
{
cl_maxstris + = 8 ;
cl_stris = BZ_Realloc ( cl_stris , sizeof ( * cl_stris ) * cl_maxstris ) ;
}
t = & cl_stris [ cl_numstris + + ] ;
t - > shader = shader ;
t - > numidx = 0 ;
t - > numvert = 0 ;
t - > flags = BEF_NODLIGHT | BEF_NOSHADOWS ;
t - > firstidx = cl_numstrisidx ;
t - > firstvert = cl_numstrisvert ;
}
2015-03-03 00:14:43 +00:00
ctx . t = t ;
VectorCopy ( rgbvalue , ctx . rgbavalue ) ;
ctx . rgbavalue [ 3 ] = alphavalue ;
2018-11-19 06:37:25 +00:00
Mod_ClipDecal ( cl . worldmodel , origin , ctx . axis [ 0 ] , ctx . axis [ 1 ] , ctx . axis [ 2 ] , max ( radius , vradius ) , 0 , 0 , CL_AddDecal_Callback , & ctx ) ;
------------------------------------------------------------------------
r4169 | acceptthis | 2013-01-17 08:55:12 +0000 (Thu, 17 Jan 2013) | 31 lines
removed MAX_VISEDICTS limit.
PEXT2_REPLACEMENTDELTAS tweaked, now has 4 million entity limit. still not enabled by default.
TE_BEAM now maps to a separate TEQW_BEAM to avoid conflicts with QW.
added android multitouch emulation for windows/rawinput (in_simulatemultitouch).
split topcolor/bottomcolor from scoreboard, for dp's colormap|1024 feature.
now using utf-8 for windows consoles.
qcc warnings/errors now give clickable console links for quick+easy editing.
disabled menutint when the currently active item changes contrast or gamma (for OneManClan).
Added support for drawfont/drawfontscale.
tweaked the qcvm a little to reduce the number of pointers.
.doll file loading. still experimental and will likely crash. requires csqc active, even if its a dummy progs. this will be fixed in time. Still other things that need cleaning up.
windows: gl_font "?" shows the standard windows font-selection dialog, and can be used to select windows fonts. not all work. and you probably don't want to use windings.
fixed splitscreen support when playing mvds. added mini-scoreboards to splitscreen.
editor/debugger now shows asm if there's no linenumber info. also, pressing f1 for help shows the shortcuts.
Added support for .framegroups files for psk(psa) and iqm formats.
True support for ezquake's colour codes. Mutually exclusive with background colours.
path command output slightly more readable.
added support for digest_hex (MD4, SHA1, CRC16).
skingroups now colourmap correctly.
Fix terrain colour hints, and litdata from the wrong bsp.
fix ftp dual-homed issue. support epsv command, and enable ipv6 (eprt still not supported).
remove d3d11 compilation from the makefile. the required headers are not provided by mingw, and are not available to the build bot, so don't bother.
fix v *= v.x and similar opcodes.
fteqcc: fixed support for áéíóú type chars in names. utf-8 files now properly supported (even with the utf-8 bom/identifier). utf-16 also supported.
fteqcc: fixed '#if 1 == 3 && 4' parsing.
fteqcc: -Werror acts on the warning, rather than as a separate error. Line numbers are thus more readable.
fteqcc: copyright message now includes compile date instead.
fteqccgui: the treeview control is now coloured depending on whether there were warnings/errors in the last compile.
fteqccgui: the output window is now focused and scrolls down as compilation progresses.
pr_dumpplatform command dumps out some pragmas to convert more serious warnings to errors. This is to avoid the infamous 'fteqcc sucks cos my code sucks' issue.
rewrote prespawn/modelist/soundlist code. server tracks progress now.
------------------------------------------------------------------------
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@4167 fc73d0e0-1445-4013-8a0c-d673dee63da5
2013-03-12 22:29:40 +00:00
2015-03-03 00:14:43 +00:00
if ( ! t - > numidx )
cl_numstris - - ;
2012-02-12 05:18:31 +00:00
}
2017-05-18 10:24:09 +00:00
void R_AddItemTimer ( vec3_t shadoworg , float yaw , float radius , float percent , vec3_t rgb )
Reworked client support for DPP5+. less code now, its much more graceful.
added waterfog command. waterfog overrides regular fog only when the view is in water.
fixed 64bit printf format specifiers. should work better on winxp64.
fixed some spec angle weirdness.
fixed viewsize 99.99 weirdness with ezhud.
fixed extra offset on the console (exhibited in 64bit builds, but not limited to).
fixed .avi playback, can now actually display frames again.
reimplemented line sparks.
fixed r_editlights_save flipping the light's pitch.
fixed issue with oggs failing to load.
fixed condump to cope with unicode properly.
made sv_bigcoords default except in quake. hexen2 kinda needs it for bsp angle precision.
fixed nq server to not stall weirdly on map changes.
fixed qwprogs svc_cdtrack not bugging out with nq clients on the server.
fixed restart command to load the last map run by the server, instead of start.bsp (when idle)
optimised d3d9 renderer a little. now uses less draw calls, especially with complex scenes. seems to get higher framerates than opengl now.
fixed d3d9 renderer to not bug out quite so much when run fullscreen (shader subsystem is now correctly initialised).
fixed a couple of bugs from font change. also now supports utf-8 in a few more places.
r_editlights_reload no longer generates rtlights inside the void. this resolves a few glitches (but should also help framerates a little).
fixed so corona-only lights won't generate shadowmaps and waste lots of time.
removed lots of #defines from qclib. I should never have made them in the first place, but I was lazy. obviously there's more left that I cba to remove yet.
fixed nested calls with variant-vectors. this fixes csaddon's light editor.
fixed qcc hc calling conventions using redundant stores.
disabled keywords can still be used by using __keyword instead.
fixed ftegccgui grep feature.
fixed motionless-dog qcc bug.
tweaked qcc warnings a little. -Wall is now a viable setting. you should be able to fix all those warnings.
fixed qw svc_intermission + dpp5+ clients bug.
fixed annoying spam about disconnecting in hexen2.
rewrote status command a little to cope with ipv6 addresses more gracefully
fixed significant stall when hibernating/debugging a server with a player sitting on it.
fixed truelightning.
fixed rocketlight overriding pflags.
fixed torches vanishing on vid_restart.
fixed issue with decal scaling.
fixed findentityfield builtin.
fixed fteqcc issue with ptr+1
fixed use of arrays inside class functions.
fixed/implemented fteqcc emulation of pointer opcodes.
added __inout keyword to fteqcc, so that it doesn't feel so horrendous.
fixed sizeof(*foo)
fixed *struct = struct;
fixed recursive structs.
fixed fteqcc warning report.
fixed sdl2 controller support, hopefully.
attempted to implement xinput, including per-player audio playback.
slightly fixed relaxed attitude to mouse focus when running fullscreen.
fixed weird warnings/errors with 'ent.arrayhead' terms. now generates sane errors.
implemented bindmaps (for csqc).
fixed crashing bug with eprint builtin.
implemented subset of music_playlist_* functionality. significant changes to music playback.
fixed some more dpcsqc compat.
fixed binds menu. now displays and accepts modifiers.
fixed issues with huge lightmaps.
fixed protocol determinism with dp clients connecting to fte servers. the initial getchallenge request now inhibits vanilla nq connection requests.
implemented support for 'dupe' userinfo key, allowing clients to request client->server packet duplication. should probably queue them tbh.
implemented sv_saveentfile command.
fixed resume after breaking inside a stepped-over function.
fixed erroneous footer after debugging.
(I wonder just how many things I broke with these fixes)
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@4946 fc73d0e0-1445-4013-8a0c-d673dee63da5
2015-07-26 10:56:18 +00:00
{
vec3_t eang ;
shader_t * s ;
scenetris_t * t ;
cl_adddecal_ctx_t ctx ;
// if (!r_shadows.value)
// return;
s = R_RegisterShader ( " timershader " , SUF_NONE ,
" { \n "
" polygonoffset \n "
2016-11-20 20:52:41 +00:00
" fte_program itemtimer \n "
Reworked client support for DPP5+. less code now, its much more graceful.
added waterfog command. waterfog overrides regular fog only when the view is in water.
fixed 64bit printf format specifiers. should work better on winxp64.
fixed some spec angle weirdness.
fixed viewsize 99.99 weirdness with ezhud.
fixed extra offset on the console (exhibited in 64bit builds, but not limited to).
fixed .avi playback, can now actually display frames again.
reimplemented line sparks.
fixed r_editlights_save flipping the light's pitch.
fixed issue with oggs failing to load.
fixed condump to cope with unicode properly.
made sv_bigcoords default except in quake. hexen2 kinda needs it for bsp angle precision.
fixed nq server to not stall weirdly on map changes.
fixed qwprogs svc_cdtrack not bugging out with nq clients on the server.
fixed restart command to load the last map run by the server, instead of start.bsp (when idle)
optimised d3d9 renderer a little. now uses less draw calls, especially with complex scenes. seems to get higher framerates than opengl now.
fixed d3d9 renderer to not bug out quite so much when run fullscreen (shader subsystem is now correctly initialised).
fixed a couple of bugs from font change. also now supports utf-8 in a few more places.
r_editlights_reload no longer generates rtlights inside the void. this resolves a few glitches (but should also help framerates a little).
fixed so corona-only lights won't generate shadowmaps and waste lots of time.
removed lots of #defines from qclib. I should never have made them in the first place, but I was lazy. obviously there's more left that I cba to remove yet.
fixed nested calls with variant-vectors. this fixes csaddon's light editor.
fixed qcc hc calling conventions using redundant stores.
disabled keywords can still be used by using __keyword instead.
fixed ftegccgui grep feature.
fixed motionless-dog qcc bug.
tweaked qcc warnings a little. -Wall is now a viable setting. you should be able to fix all those warnings.
fixed qw svc_intermission + dpp5+ clients bug.
fixed annoying spam about disconnecting in hexen2.
rewrote status command a little to cope with ipv6 addresses more gracefully
fixed significant stall when hibernating/debugging a server with a player sitting on it.
fixed truelightning.
fixed rocketlight overriding pflags.
fixed torches vanishing on vid_restart.
fixed issue with decal scaling.
fixed findentityfield builtin.
fixed fteqcc issue with ptr+1
fixed use of arrays inside class functions.
fixed/implemented fteqcc emulation of pointer opcodes.
added __inout keyword to fteqcc, so that it doesn't feel so horrendous.
fixed sizeof(*foo)
fixed *struct = struct;
fixed recursive structs.
fixed fteqcc warning report.
fixed sdl2 controller support, hopefully.
attempted to implement xinput, including per-player audio playback.
slightly fixed relaxed attitude to mouse focus when running fullscreen.
fixed weird warnings/errors with 'ent.arrayhead' terms. now generates sane errors.
implemented bindmaps (for csqc).
fixed crashing bug with eprint builtin.
implemented subset of music_playlist_* functionality. significant changes to music playback.
fixed some more dpcsqc compat.
fixed binds menu. now displays and accepts modifiers.
fixed issues with huge lightmaps.
fixed protocol determinism with dp clients connecting to fte servers. the initial getchallenge request now inhibits vanilla nq connection requests.
implemented support for 'dupe' userinfo key, allowing clients to request client->server packet duplication. should probably queue them tbh.
implemented sv_saveentfile command.
fixed resume after breaking inside a stepped-over function.
fixed erroneous footer after debugging.
(I wonder just how many things I broke with these fixes)
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@4946 fc73d0e0-1445-4013-8a0c-d673dee63da5
2015-07-26 10:56:18 +00:00
" { \n "
" map $diffuse \n "
" blendfunc src_alpha one \n "
" rgbgen vertex \n "
" alphagen vertex \n "
" } \n "
" } \n " ) ;
if ( ! s - > prog )
return ;
TEXASSIGN ( s - > defaulttextures - > base , balltexture ) ;
eang [ 0 ] = 0 ;
eang [ 1 ] = yaw ;
eang [ 2 ] = 0 ;
AngleVectors ( eang , ctx . axis [ 1 ] , ctx . axis [ 2 ] , ctx . axis [ 0 ] ) ;
VectorNegate ( ctx . axis [ 0 ] , ctx . axis [ 0 ] ) ;
ctx . offset [ 2 ] = DotProduct ( shadoworg , ctx . axis [ 2 ] ) + 0.5 * radius ;
ctx . offset [ 1 ] = DotProduct ( shadoworg , ctx . axis [ 1 ] ) + 0.5 * radius ;
ctx . offset [ 0 ] = DotProduct ( shadoworg , ctx . axis [ 0 ] ) ;
ctx . scale [ 1 ] = 1 / radius ;
ctx . scale [ 2 ] = 1 / radius ;
ctx . scale [ 0 ] = 0 ; //.5/radius;
2021-04-20 19:21:34 +00:00
if ( R2D_Flush )
R2D_Flush ( ) ;
Reworked client support for DPP5+. less code now, its much more graceful.
added waterfog command. waterfog overrides regular fog only when the view is in water.
fixed 64bit printf format specifiers. should work better on winxp64.
fixed some spec angle weirdness.
fixed viewsize 99.99 weirdness with ezhud.
fixed extra offset on the console (exhibited in 64bit builds, but not limited to).
fixed .avi playback, can now actually display frames again.
reimplemented line sparks.
fixed r_editlights_save flipping the light's pitch.
fixed issue with oggs failing to load.
fixed condump to cope with unicode properly.
made sv_bigcoords default except in quake. hexen2 kinda needs it for bsp angle precision.
fixed nq server to not stall weirdly on map changes.
fixed qwprogs svc_cdtrack not bugging out with nq clients on the server.
fixed restart command to load the last map run by the server, instead of start.bsp (when idle)
optimised d3d9 renderer a little. now uses less draw calls, especially with complex scenes. seems to get higher framerates than opengl now.
fixed d3d9 renderer to not bug out quite so much when run fullscreen (shader subsystem is now correctly initialised).
fixed a couple of bugs from font change. also now supports utf-8 in a few more places.
r_editlights_reload no longer generates rtlights inside the void. this resolves a few glitches (but should also help framerates a little).
fixed so corona-only lights won't generate shadowmaps and waste lots of time.
removed lots of #defines from qclib. I should never have made them in the first place, but I was lazy. obviously there's more left that I cba to remove yet.
fixed nested calls with variant-vectors. this fixes csaddon's light editor.
fixed qcc hc calling conventions using redundant stores.
disabled keywords can still be used by using __keyword instead.
fixed ftegccgui grep feature.
fixed motionless-dog qcc bug.
tweaked qcc warnings a little. -Wall is now a viable setting. you should be able to fix all those warnings.
fixed qw svc_intermission + dpp5+ clients bug.
fixed annoying spam about disconnecting in hexen2.
rewrote status command a little to cope with ipv6 addresses more gracefully
fixed significant stall when hibernating/debugging a server with a player sitting on it.
fixed truelightning.
fixed rocketlight overriding pflags.
fixed torches vanishing on vid_restart.
fixed issue with decal scaling.
fixed findentityfield builtin.
fixed fteqcc issue with ptr+1
fixed use of arrays inside class functions.
fixed/implemented fteqcc emulation of pointer opcodes.
added __inout keyword to fteqcc, so that it doesn't feel so horrendous.
fixed sizeof(*foo)
fixed *struct = struct;
fixed recursive structs.
fixed fteqcc warning report.
fixed sdl2 controller support, hopefully.
attempted to implement xinput, including per-player audio playback.
slightly fixed relaxed attitude to mouse focus when running fullscreen.
fixed weird warnings/errors with 'ent.arrayhead' terms. now generates sane errors.
implemented bindmaps (for csqc).
fixed crashing bug with eprint builtin.
implemented subset of music_playlist_* functionality. significant changes to music playback.
fixed some more dpcsqc compat.
fixed binds menu. now displays and accepts modifiers.
fixed issues with huge lightmaps.
fixed protocol determinism with dp clients connecting to fte servers. the initial getchallenge request now inhibits vanilla nq connection requests.
implemented support for 'dupe' userinfo key, allowing clients to request client->server packet duplication. should probably queue them tbh.
implemented sv_saveentfile command.
fixed resume after breaking inside a stepped-over function.
fixed erroneous footer after debugging.
(I wonder just how many things I broke with these fixes)
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@4946 fc73d0e0-1445-4013-8a0c-d673dee63da5
2015-07-26 10:56:18 +00:00
/*reuse the previous trigroup if its the same shader*/
if ( cl_numstris & & cl_stris [ cl_numstris - 1 ] . shader = = s & & cl_stris [ cl_numstris - 1 ] . flags = = ( BEF_NODLIGHT | BEF_NOSHADOWS ) )
t = & cl_stris [ cl_numstris - 1 ] ;
else
{
if ( cl_numstris = = cl_maxstris )
{
cl_maxstris + = 8 ;
cl_stris = BZ_Realloc ( cl_stris , sizeof ( * cl_stris ) * cl_maxstris ) ;
}
t = & cl_stris [ cl_numstris + + ] ;
t - > shader = s ;
t - > flags = BEF_NODLIGHT | BEF_NOSHADOWS ;
t - > numidx = 0 ;
t - > numvert = 0 ;
t - > firstidx = cl_numstrisidx ;
t - > firstvert = cl_numstrisvert ;
}
ctx . t = t ;
2017-05-18 10:24:09 +00:00
Vector4Set ( ctx . rgbavalue , rgb [ 0 ] , rgb [ 1 ] , rgb [ 2 ] , percent ) ;
2016-07-12 00:40:13 +00:00
Mod_ClipDecal ( cl . worldmodel , shadoworg , ctx . axis [ 0 ] , ctx . axis [ 1 ] , ctx . axis [ 2 ] , radius , 0 , 0 , CL_AddDecal_Callback , & ctx ) ;
Reworked client support for DPP5+. less code now, its much more graceful.
added waterfog command. waterfog overrides regular fog only when the view is in water.
fixed 64bit printf format specifiers. should work better on winxp64.
fixed some spec angle weirdness.
fixed viewsize 99.99 weirdness with ezhud.
fixed extra offset on the console (exhibited in 64bit builds, but not limited to).
fixed .avi playback, can now actually display frames again.
reimplemented line sparks.
fixed r_editlights_save flipping the light's pitch.
fixed issue with oggs failing to load.
fixed condump to cope with unicode properly.
made sv_bigcoords default except in quake. hexen2 kinda needs it for bsp angle precision.
fixed nq server to not stall weirdly on map changes.
fixed qwprogs svc_cdtrack not bugging out with nq clients on the server.
fixed restart command to load the last map run by the server, instead of start.bsp (when idle)
optimised d3d9 renderer a little. now uses less draw calls, especially with complex scenes. seems to get higher framerates than opengl now.
fixed d3d9 renderer to not bug out quite so much when run fullscreen (shader subsystem is now correctly initialised).
fixed a couple of bugs from font change. also now supports utf-8 in a few more places.
r_editlights_reload no longer generates rtlights inside the void. this resolves a few glitches (but should also help framerates a little).
fixed so corona-only lights won't generate shadowmaps and waste lots of time.
removed lots of #defines from qclib. I should never have made them in the first place, but I was lazy. obviously there's more left that I cba to remove yet.
fixed nested calls with variant-vectors. this fixes csaddon's light editor.
fixed qcc hc calling conventions using redundant stores.
disabled keywords can still be used by using __keyword instead.
fixed ftegccgui grep feature.
fixed motionless-dog qcc bug.
tweaked qcc warnings a little. -Wall is now a viable setting. you should be able to fix all those warnings.
fixed qw svc_intermission + dpp5+ clients bug.
fixed annoying spam about disconnecting in hexen2.
rewrote status command a little to cope with ipv6 addresses more gracefully
fixed significant stall when hibernating/debugging a server with a player sitting on it.
fixed truelightning.
fixed rocketlight overriding pflags.
fixed torches vanishing on vid_restart.
fixed issue with decal scaling.
fixed findentityfield builtin.
fixed fteqcc issue with ptr+1
fixed use of arrays inside class functions.
fixed/implemented fteqcc emulation of pointer opcodes.
added __inout keyword to fteqcc, so that it doesn't feel so horrendous.
fixed sizeof(*foo)
fixed *struct = struct;
fixed recursive structs.
fixed fteqcc warning report.
fixed sdl2 controller support, hopefully.
attempted to implement xinput, including per-player audio playback.
slightly fixed relaxed attitude to mouse focus when running fullscreen.
fixed weird warnings/errors with 'ent.arrayhead' terms. now generates sane errors.
implemented bindmaps (for csqc).
fixed crashing bug with eprint builtin.
implemented subset of music_playlist_* functionality. significant changes to music playback.
fixed some more dpcsqc compat.
fixed binds menu. now displays and accepts modifiers.
fixed issues with huge lightmaps.
fixed protocol determinism with dp clients connecting to fte servers. the initial getchallenge request now inhibits vanilla nq connection requests.
implemented support for 'dupe' userinfo key, allowing clients to request client->server packet duplication. should probably queue them tbh.
implemented sv_saveentfile command.
fixed resume after breaking inside a stepped-over function.
fixed erroneous footer after debugging.
(I wonder just how many things I broke with these fixes)
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@4946 fc73d0e0-1445-4013-8a0c-d673dee63da5
2015-07-26 10:56:18 +00:00
if ( ! t - > numidx )
cl_numstris - - ;
}
2011-04-30 17:21:10 +00:00
void CLQ1_AddShadow ( entity_t * ent )
{
float radius ;
vec3_t shadoworg ;
vec3_t eang ;
2015-03-03 00:14:43 +00:00
float tx , ty ;
2011-04-30 17:21:10 +00:00
shader_t * s ;
scenetris_t * t ;
2015-03-03 00:14:43 +00:00
cl_adddecal_ctx_t ctx ;
2011-04-30 17:21:10 +00:00
Too many changes, sorry.
Change revision displays, use the SVN commit date instead of using __DATE__ (when there's no local changes). This should allow reproducible builds.
Added s_al_disable cvar, to block openal and all the various problems people have had with it, without having to name an explicit fallback (which would vary by system).
Add mastervolume cvar (for ss).
Add r_shadows 2 (aka fake shadows - for ss).
Add scr_loadingscreen_aspect -1 setting, to disable levelshots entirely, also disables the progress bar (for ss).
Better support for some effectinfo hacks (for ss).
Added dpcompat_nocsqcwarnings (because of lazy+buggy mods like ss).
Rework the dpcsqc versions of project+unproject builtins for better compat (for ss).
Added dpcompat_csqcinputeventtypes to block unexpected csqc input events (for ss).
Better compat with DP's loadfont console command (for ss).
Added dpcompat_smallerfonts cvar to replicate a DP bug (for ss).
Detect dp's m_draw extension, to work around it (for ss).
Cvar dpcompat_ignoremodificationtimes added. A value of 0 favour the most recently modified file, 1 will use DP-like alphabetically sorted preferences (for ss).
loadfont builtin can now accept outline=1 in the sizes arg for slightly more readable fonts.
Fix bbox calcs for rotated entities, fix needed for r_ignorenetpvs 0.
Hackily parse emoji.json to provide :poop: etc suggestions.
Skip prediction entirely when there's no local entity info. This fixes stair-smoothing in xonotic.
screenshot_cubemap will now capture half-float images when saving to ktx or dds files.
Fix support for xcf files larger than 4gb, mostly to avoid compiler warnings.
Fixed size of gfx/loading.lmp when replacement textures are used.
Added mipmap support for rg8 and l8a8 textures.
r_hdr_framebuffer cvar updated to support format names instead of random negative numbers. Description updated to name some interesting ones.
Perform autoupdate _checks_ ONLY with explicit user confirmation (actual updating already needed user confirmation, but this extra step should reduce the chances of us getting wrongly accused of exfiltrating user data if we're run in a sandbox - we ONLY ever included the updating engine's version in the checks, though there's nothing we can do to avoid sending the user's router's IP).
Removed the 'summon satan all over your harddrive' quit message, in case paranoid security researchers are idiots and don't bother doing actual research.
Removed the triptohell.info and fte.triptohell.info certificates, they really need to stop being self-signed. The updates domain is still self-signed for autoupdates.
Video drivers are now able to report supported video resolutions, visible to menuqc. Currently only works with SDL2 builds.
Added setmousepos builtin. Should work with glx+win32 build.
VF_SKYROOM_CAMERA can now accept an extra two args, setviewprop(VF_SKYROOM_CAMERA, org, axis, degrees).
Removed v_skyroom_origin+v_skyroom_orientation cvars in favour just v_skyroom, which should make it behave more like the 'fog' command (used when csqc isn't overriding).
Added R_EndPolygonRibbon builtin to make it faster+easier to generate textured ribbon/cable/etc wide lines (for TW).
sdl: Fix up sys_sdl.c's file enumeration to support wildcards in directories.
edit command now displays end1.bin/end2.bin correctly, because we can.
Finally add support for f_modified - though ruleset_allow_larger_models and ruleset_allow_overlong_sounds generally make it redundant.
Fix threading race condition in sha1 lookups.
Updated f_ruleset to include the same extra flags reported by ezquake.
A mod's default.fmf file can now contain an eg 'mainconfig config.cfg' line (to explicitly set the main config saved with cfg_save_auto 1 etc).
fmf: basegame steam:GameName/GameDir can be used to try to load a mod directory from an installed steam game. The resulting gamedir will be read-only.
HOMEDIR CHANGE: use homedirs only if the basedir cannot be written or a homedir already exists, which should further reduce the probability of microsoft randomly uploading our data to their cloud (but mostly because its annoying to never know where your data is written).
Fixed buf_cvarlist, should work in xonotic now, and without segfaults.
Added an extra arg to URI_Get_Callback calls - the response size, also changed the tempstring to contain all bytes of the response, you need to be careful about nulls though.
Try to work around nvidia's forced-panning bug on x11 when changing video modes. This might screw with other programs.
sdl: support custom icons.
sdl: support choosing a specific display.
Added some documentation to menuqc builtins.
menusys: use outlines for slightly more readable fonts.
menusys: switch vid_width and vid_height combos into a single video mode combo to set both according to reported video modes.
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@5581 fc73d0e0-1445-4013-8a0c-d673dee63da5
2019-11-20 03:09:50 +00:00
if ( ! r_blobshadows | | ! ent - > model | | ( ent - > model - > type ! = mod_alias & & ent - > model - > type ! = mod_halflife ) )
2011-04-30 17:21:10 +00:00
return ;
2013-08-21 07:14:39 +00:00
s = R_RegisterShader ( " shadowshader " , SUF_NONE ,
2011-04-30 17:21:10 +00:00
" { \n "
2013-08-21 07:14:39 +00:00
" polygonoffset \n "
" { \n "
" map $diffuse \n "
" blendfunc blend \n "
" rgbgen vertex \n "
" alphagen vertex \n "
" } \n "
2011-04-30 17:21:10 +00:00
" } \n " ) ;
2015-05-03 19:57:46 +00:00
TEXASSIGN ( s - > defaulttextures - > base , balltexture ) ;
2011-04-30 17:21:10 +00:00
tx = ent - > model - > maxs [ 0 ] - ent - > model - > mins [ 0 ] ;
ty = ent - > model - > maxs [ 1 ] - ent - > model - > mins [ 1 ] ;
if ( tx > ty )
radius = tx ;
else
radius = ty ;
radius / = 2 ;
shadoworg [ 0 ] = ent - > origin [ 0 ] ;
shadoworg [ 1 ] = ent - > origin [ 1 ] ;
shadoworg [ 2 ] = ent - > origin [ 2 ] + ent - > model - > mins [ 2 ] ;
eang [ 0 ] = 0 ;
eang [ 1 ] = ent - > angles [ 1 ] ;
eang [ 2 ] = 0 ;
2015-03-03 00:14:43 +00:00
AngleVectors ( eang , ctx . axis [ 1 ] , ctx . axis [ 2 ] , ctx . axis [ 0 ] ) ;
VectorNegate ( ctx . axis [ 0 ] , ctx . axis [ 0 ] ) ;
2011-04-30 17:21:10 +00:00
2015-03-03 00:14:43 +00:00
ctx . offset [ 2 ] = DotProduct ( shadoworg , ctx . axis [ 2 ] ) + 0.5 * radius ;
ctx . offset [ 1 ] = DotProduct ( shadoworg , ctx . axis [ 1 ] ) + 0.5 * radius ;
ctx . offset [ 0 ] = DotProduct ( shadoworg , ctx . axis [ 0 ] ) ;
ctx . scale [ 1 ] = 1 / radius ;
ctx . scale [ 2 ] = 1 / radius ;
ctx . scale [ 0 ] = 0.5 / radius ;
2011-04-30 17:21:10 +00:00
2021-04-20 19:21:34 +00:00
if ( R2D_Flush )
R2D_Flush ( ) ;
2011-04-30 17:21:10 +00:00
/*reuse the previous trigroup if its the same shader*/
------------------------------------------------------------------------
r4169 | acceptthis | 2013-01-17 08:55:12 +0000 (Thu, 17 Jan 2013) | 31 lines
removed MAX_VISEDICTS limit.
PEXT2_REPLACEMENTDELTAS tweaked, now has 4 million entity limit. still not enabled by default.
TE_BEAM now maps to a separate TEQW_BEAM to avoid conflicts with QW.
added android multitouch emulation for windows/rawinput (in_simulatemultitouch).
split topcolor/bottomcolor from scoreboard, for dp's colormap|1024 feature.
now using utf-8 for windows consoles.
qcc warnings/errors now give clickable console links for quick+easy editing.
disabled menutint when the currently active item changes contrast or gamma (for OneManClan).
Added support for drawfont/drawfontscale.
tweaked the qcvm a little to reduce the number of pointers.
.doll file loading. still experimental and will likely crash. requires csqc active, even if its a dummy progs. this will be fixed in time. Still other things that need cleaning up.
windows: gl_font "?" shows the standard windows font-selection dialog, and can be used to select windows fonts. not all work. and you probably don't want to use windings.
fixed splitscreen support when playing mvds. added mini-scoreboards to splitscreen.
editor/debugger now shows asm if there's no linenumber info. also, pressing f1 for help shows the shortcuts.
Added support for .framegroups files for psk(psa) and iqm formats.
True support for ezquake's colour codes. Mutually exclusive with background colours.
path command output slightly more readable.
added support for digest_hex (MD4, SHA1, CRC16).
skingroups now colourmap correctly.
Fix terrain colour hints, and litdata from the wrong bsp.
fix ftp dual-homed issue. support epsv command, and enable ipv6 (eprt still not supported).
remove d3d11 compilation from the makefile. the required headers are not provided by mingw, and are not available to the build bot, so don't bother.
fix v *= v.x and similar opcodes.
fteqcc: fixed support for áéíóú type chars in names. utf-8 files now properly supported (even with the utf-8 bom/identifier). utf-16 also supported.
fteqcc: fixed '#if 1 == 3 && 4' parsing.
fteqcc: -Werror acts on the warning, rather than as a separate error. Line numbers are thus more readable.
fteqcc: copyright message now includes compile date instead.
fteqccgui: the treeview control is now coloured depending on whether there were warnings/errors in the last compile.
fteqccgui: the output window is now focused and scrolls down as compilation progresses.
pr_dumpplatform command dumps out some pragmas to convert more serious warnings to errors. This is to avoid the infamous 'fteqcc sucks cos my code sucks' issue.
rewrote prespawn/modelist/soundlist code. server tracks progress now.
------------------------------------------------------------------------
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@4167 fc73d0e0-1445-4013-8a0c-d673dee63da5
2013-03-12 22:29:40 +00:00
if ( cl_numstris & & cl_stris [ cl_numstris - 1 ] . shader = = s & & cl_stris [ cl_numstris - 1 ] . flags = = ( BEF_NODLIGHT | BEF_NOSHADOWS ) )
2011-04-30 17:21:10 +00:00
t = & cl_stris [ cl_numstris - 1 ] ;
else
{
if ( cl_numstris = = cl_maxstris )
{
cl_maxstris + = 8 ;
cl_stris = BZ_Realloc ( cl_stris , sizeof ( * cl_stris ) * cl_maxstris ) ;
}
t = & cl_stris [ cl_numstris + + ] ;
t - > shader = s ;
------------------------------------------------------------------------
r4169 | acceptthis | 2013-01-17 08:55:12 +0000 (Thu, 17 Jan 2013) | 31 lines
removed MAX_VISEDICTS limit.
PEXT2_REPLACEMENTDELTAS tweaked, now has 4 million entity limit. still not enabled by default.
TE_BEAM now maps to a separate TEQW_BEAM to avoid conflicts with QW.
added android multitouch emulation for windows/rawinput (in_simulatemultitouch).
split topcolor/bottomcolor from scoreboard, for dp's colormap|1024 feature.
now using utf-8 for windows consoles.
qcc warnings/errors now give clickable console links for quick+easy editing.
disabled menutint when the currently active item changes contrast or gamma (for OneManClan).
Added support for drawfont/drawfontscale.
tweaked the qcvm a little to reduce the number of pointers.
.doll file loading. still experimental and will likely crash. requires csqc active, even if its a dummy progs. this will be fixed in time. Still other things that need cleaning up.
windows: gl_font "?" shows the standard windows font-selection dialog, and can be used to select windows fonts. not all work. and you probably don't want to use windings.
fixed splitscreen support when playing mvds. added mini-scoreboards to splitscreen.
editor/debugger now shows asm if there's no linenumber info. also, pressing f1 for help shows the shortcuts.
Added support for .framegroups files for psk(psa) and iqm formats.
True support for ezquake's colour codes. Mutually exclusive with background colours.
path command output slightly more readable.
added support for digest_hex (MD4, SHA1, CRC16).
skingroups now colourmap correctly.
Fix terrain colour hints, and litdata from the wrong bsp.
fix ftp dual-homed issue. support epsv command, and enable ipv6 (eprt still not supported).
remove d3d11 compilation from the makefile. the required headers are not provided by mingw, and are not available to the build bot, so don't bother.
fix v *= v.x and similar opcodes.
fteqcc: fixed support for áéíóú type chars in names. utf-8 files now properly supported (even with the utf-8 bom/identifier). utf-16 also supported.
fteqcc: fixed '#if 1 == 3 && 4' parsing.
fteqcc: -Werror acts on the warning, rather than as a separate error. Line numbers are thus more readable.
fteqcc: copyright message now includes compile date instead.
fteqccgui: the treeview control is now coloured depending on whether there were warnings/errors in the last compile.
fteqccgui: the output window is now focused and scrolls down as compilation progresses.
pr_dumpplatform command dumps out some pragmas to convert more serious warnings to errors. This is to avoid the infamous 'fteqcc sucks cos my code sucks' issue.
rewrote prespawn/modelist/soundlist code. server tracks progress now.
------------------------------------------------------------------------
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@4167 fc73d0e0-1445-4013-8a0c-d673dee63da5
2013-03-12 22:29:40 +00:00
t - > flags = BEF_NODLIGHT | BEF_NOSHADOWS ;
2011-04-30 17:21:10 +00:00
t - > numidx = 0 ;
t - > numvert = 0 ;
t - > firstidx = cl_numstrisidx ;
t - > firstvert = cl_numstrisvert ;
}
2015-03-03 00:14:43 +00:00
ctx . t = t ;
Too many changes, sorry.
Change revision displays, use the SVN commit date instead of using __DATE__ (when there's no local changes). This should allow reproducible builds.
Added s_al_disable cvar, to block openal and all the various problems people have had with it, without having to name an explicit fallback (which would vary by system).
Add mastervolume cvar (for ss).
Add r_shadows 2 (aka fake shadows - for ss).
Add scr_loadingscreen_aspect -1 setting, to disable levelshots entirely, also disables the progress bar (for ss).
Better support for some effectinfo hacks (for ss).
Added dpcompat_nocsqcwarnings (because of lazy+buggy mods like ss).
Rework the dpcsqc versions of project+unproject builtins for better compat (for ss).
Added dpcompat_csqcinputeventtypes to block unexpected csqc input events (for ss).
Better compat with DP's loadfont console command (for ss).
Added dpcompat_smallerfonts cvar to replicate a DP bug (for ss).
Detect dp's m_draw extension, to work around it (for ss).
Cvar dpcompat_ignoremodificationtimes added. A value of 0 favour the most recently modified file, 1 will use DP-like alphabetically sorted preferences (for ss).
loadfont builtin can now accept outline=1 in the sizes arg for slightly more readable fonts.
Fix bbox calcs for rotated entities, fix needed for r_ignorenetpvs 0.
Hackily parse emoji.json to provide :poop: etc suggestions.
Skip prediction entirely when there's no local entity info. This fixes stair-smoothing in xonotic.
screenshot_cubemap will now capture half-float images when saving to ktx or dds files.
Fix support for xcf files larger than 4gb, mostly to avoid compiler warnings.
Fixed size of gfx/loading.lmp when replacement textures are used.
Added mipmap support for rg8 and l8a8 textures.
r_hdr_framebuffer cvar updated to support format names instead of random negative numbers. Description updated to name some interesting ones.
Perform autoupdate _checks_ ONLY with explicit user confirmation (actual updating already needed user confirmation, but this extra step should reduce the chances of us getting wrongly accused of exfiltrating user data if we're run in a sandbox - we ONLY ever included the updating engine's version in the checks, though there's nothing we can do to avoid sending the user's router's IP).
Removed the 'summon satan all over your harddrive' quit message, in case paranoid security researchers are idiots and don't bother doing actual research.
Removed the triptohell.info and fte.triptohell.info certificates, they really need to stop being self-signed. The updates domain is still self-signed for autoupdates.
Video drivers are now able to report supported video resolutions, visible to menuqc. Currently only works with SDL2 builds.
Added setmousepos builtin. Should work with glx+win32 build.
VF_SKYROOM_CAMERA can now accept an extra two args, setviewprop(VF_SKYROOM_CAMERA, org, axis, degrees).
Removed v_skyroom_origin+v_skyroom_orientation cvars in favour just v_skyroom, which should make it behave more like the 'fog' command (used when csqc isn't overriding).
Added R_EndPolygonRibbon builtin to make it faster+easier to generate textured ribbon/cable/etc wide lines (for TW).
sdl: Fix up sys_sdl.c's file enumeration to support wildcards in directories.
edit command now displays end1.bin/end2.bin correctly, because we can.
Finally add support for f_modified - though ruleset_allow_larger_models and ruleset_allow_overlong_sounds generally make it redundant.
Fix threading race condition in sha1 lookups.
Updated f_ruleset to include the same extra flags reported by ezquake.
A mod's default.fmf file can now contain an eg 'mainconfig config.cfg' line (to explicitly set the main config saved with cfg_save_auto 1 etc).
fmf: basegame steam:GameName/GameDir can be used to try to load a mod directory from an installed steam game. The resulting gamedir will be read-only.
HOMEDIR CHANGE: use homedirs only if the basedir cannot be written or a homedir already exists, which should further reduce the probability of microsoft randomly uploading our data to their cloud (but mostly because its annoying to never know where your data is written).
Fixed buf_cvarlist, should work in xonotic now, and without segfaults.
Added an extra arg to URI_Get_Callback calls - the response size, also changed the tempstring to contain all bytes of the response, you need to be careful about nulls though.
Try to work around nvidia's forced-panning bug on x11 when changing video modes. This might screw with other programs.
sdl: support custom icons.
sdl: support choosing a specific display.
Added some documentation to menuqc builtins.
menusys: use outlines for slightly more readable fonts.
menusys: switch vid_width and vid_height combos into a single video mode combo to set both according to reported video modes.
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@5581 fc73d0e0-1445-4013-8a0c-d673dee63da5
2019-11-20 03:09:50 +00:00
Vector4Set ( ctx . rgbavalue , 0 , 0 , 0 , r_blobshadows ) ;
2016-07-12 00:40:13 +00:00
Mod_ClipDecal ( cl . worldmodel , shadoworg , ctx . axis [ 0 ] , ctx . axis [ 1 ] , ctx . axis [ 2 ] , radius , 0 , 0 , CL_AddDecal_Callback , & ctx ) ;
2015-03-03 00:14:43 +00:00
if ( ! t - > numidx )
cl_numstris - - ;
2011-04-30 17:21:10 +00:00
}
2011-04-25 03:25:22 +00:00
void CLQ1_AddPowerupShell ( entity_t * ent , qboolean viewweap , unsigned int effects )
{
entity_t * shell ;
Reworked client support for DPP5+. less code now, its much more graceful.
added waterfog command. waterfog overrides regular fog only when the view is in water.
fixed 64bit printf format specifiers. should work better on winxp64.
fixed some spec angle weirdness.
fixed viewsize 99.99 weirdness with ezhud.
fixed extra offset on the console (exhibited in 64bit builds, but not limited to).
fixed .avi playback, can now actually display frames again.
reimplemented line sparks.
fixed r_editlights_save flipping the light's pitch.
fixed issue with oggs failing to load.
fixed condump to cope with unicode properly.
made sv_bigcoords default except in quake. hexen2 kinda needs it for bsp angle precision.
fixed nq server to not stall weirdly on map changes.
fixed qwprogs svc_cdtrack not bugging out with nq clients on the server.
fixed restart command to load the last map run by the server, instead of start.bsp (when idle)
optimised d3d9 renderer a little. now uses less draw calls, especially with complex scenes. seems to get higher framerates than opengl now.
fixed d3d9 renderer to not bug out quite so much when run fullscreen (shader subsystem is now correctly initialised).
fixed a couple of bugs from font change. also now supports utf-8 in a few more places.
r_editlights_reload no longer generates rtlights inside the void. this resolves a few glitches (but should also help framerates a little).
fixed so corona-only lights won't generate shadowmaps and waste lots of time.
removed lots of #defines from qclib. I should never have made them in the first place, but I was lazy. obviously there's more left that I cba to remove yet.
fixed nested calls with variant-vectors. this fixes csaddon's light editor.
fixed qcc hc calling conventions using redundant stores.
disabled keywords can still be used by using __keyword instead.
fixed ftegccgui grep feature.
fixed motionless-dog qcc bug.
tweaked qcc warnings a little. -Wall is now a viable setting. you should be able to fix all those warnings.
fixed qw svc_intermission + dpp5+ clients bug.
fixed annoying spam about disconnecting in hexen2.
rewrote status command a little to cope with ipv6 addresses more gracefully
fixed significant stall when hibernating/debugging a server with a player sitting on it.
fixed truelightning.
fixed rocketlight overriding pflags.
fixed torches vanishing on vid_restart.
fixed issue with decal scaling.
fixed findentityfield builtin.
fixed fteqcc issue with ptr+1
fixed use of arrays inside class functions.
fixed/implemented fteqcc emulation of pointer opcodes.
added __inout keyword to fteqcc, so that it doesn't feel so horrendous.
fixed sizeof(*foo)
fixed *struct = struct;
fixed recursive structs.
fixed fteqcc warning report.
fixed sdl2 controller support, hopefully.
attempted to implement xinput, including per-player audio playback.
slightly fixed relaxed attitude to mouse focus when running fullscreen.
fixed weird warnings/errors with 'ent.arrayhead' terms. now generates sane errors.
implemented bindmaps (for csqc).
fixed crashing bug with eprint builtin.
implemented subset of music_playlist_* functionality. significant changes to music playback.
fixed some more dpcsqc compat.
fixed binds menu. now displays and accepts modifiers.
fixed issues with huge lightmaps.
fixed protocol determinism with dp clients connecting to fte servers. the initial getchallenge request now inhibits vanilla nq connection requests.
implemented support for 'dupe' userinfo key, allowing clients to request client->server packet duplication. should probably queue them tbh.
implemented sv_saveentfile command.
fixed resume after breaking inside a stepped-over function.
fixed erroneous footer after debugging.
(I wonder just how many things I broke with these fixes)
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@4946 fc73d0e0-1445-4013-8a0c-d673dee63da5
2015-07-26 10:56:18 +00:00
if ( ! ( effects & ( EF_BLUE | EF_RED | EF_GREEN ) ) | | ! v_powerupshell . value | | ! ent )
2011-04-25 03:25:22 +00:00
return ;
------------------------------------------------------------------------
r4169 | acceptthis | 2013-01-17 08:55:12 +0000 (Thu, 17 Jan 2013) | 31 lines
removed MAX_VISEDICTS limit.
PEXT2_REPLACEMENTDELTAS tweaked, now has 4 million entity limit. still not enabled by default.
TE_BEAM now maps to a separate TEQW_BEAM to avoid conflicts with QW.
added android multitouch emulation for windows/rawinput (in_simulatemultitouch).
split topcolor/bottomcolor from scoreboard, for dp's colormap|1024 feature.
now using utf-8 for windows consoles.
qcc warnings/errors now give clickable console links for quick+easy editing.
disabled menutint when the currently active item changes contrast or gamma (for OneManClan).
Added support for drawfont/drawfontscale.
tweaked the qcvm a little to reduce the number of pointers.
.doll file loading. still experimental and will likely crash. requires csqc active, even if its a dummy progs. this will be fixed in time. Still other things that need cleaning up.
windows: gl_font "?" shows the standard windows font-selection dialog, and can be used to select windows fonts. not all work. and you probably don't want to use windings.
fixed splitscreen support when playing mvds. added mini-scoreboards to splitscreen.
editor/debugger now shows asm if there's no linenumber info. also, pressing f1 for help shows the shortcuts.
Added support for .framegroups files for psk(psa) and iqm formats.
True support for ezquake's colour codes. Mutually exclusive with background colours.
path command output slightly more readable.
added support for digest_hex (MD4, SHA1, CRC16).
skingroups now colourmap correctly.
Fix terrain colour hints, and litdata from the wrong bsp.
fix ftp dual-homed issue. support epsv command, and enable ipv6 (eprt still not supported).
remove d3d11 compilation from the makefile. the required headers are not provided by mingw, and are not available to the build bot, so don't bother.
fix v *= v.x and similar opcodes.
fteqcc: fixed support for áéíóú type chars in names. utf-8 files now properly supported (even with the utf-8 bom/identifier). utf-16 also supported.
fteqcc: fixed '#if 1 == 3 && 4' parsing.
fteqcc: -Werror acts on the warning, rather than as a separate error. Line numbers are thus more readable.
fteqcc: copyright message now includes compile date instead.
fteqccgui: the treeview control is now coloured depending on whether there were warnings/errors in the last compile.
fteqccgui: the output window is now focused and scrolls down as compilation progresses.
pr_dumpplatform command dumps out some pragmas to convert more serious warnings to errors. This is to avoid the infamous 'fteqcc sucks cos my code sucks' issue.
rewrote prespawn/modelist/soundlist code. server tracks progress now.
------------------------------------------------------------------------
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@4167 fc73d0e0-1445-4013-8a0c-d673dee63da5
2013-03-12 22:29:40 +00:00
if ( cl_numvisedicts = = cl_maxvisedicts )
2011-04-25 03:25:22 +00:00
return ; // object list is full
shell = & cl_visedicts [ cl_numvisedicts + + ] ;
* shell = * ent ;
/*view weapons are much closer to the screen, the scales don't work too well, so use a different shader with a smaller expansion*/
if ( viewweap )
{
2013-08-21 07:14:39 +00:00
shell - > forcedshader = R_RegisterShader ( " powerups/shellweapon " , SUF_NONE ,
2011-04-25 03:25:22 +00:00
" { \n "
" program defaultpowerupshell \n "
" sort additive \n "
" deformVertexes wave 100 sin 0.5 0 0 0 \n "
" noshadows \n "
" surfaceparm nodlight \n "
" { \n "
2011-10-27 15:46:36 +00:00
" map $whiteimage \n "
2011-04-25 03:25:22 +00:00
" rgbgen entity \n "
" alphagen entity \n "
" blendfunc src_alpha one \n "
" } \n "
" } \n "
) ;
}
else
{
2013-08-21 07:14:39 +00:00
shell - > forcedshader = R_RegisterShader ( " powerups/shell " , SUF_NONE ,
2011-04-25 03:25:22 +00:00
" { \n "
" program defaultpowerupshell \n "
" sort additive \n "
" deformVertexes wave 100 sin 3 0 0 0 \n "
" noshadows \n "
" surfaceparm nodlight \n "
" { \n "
2011-10-27 15:46:36 +00:00
" map $whiteimage \n "
2011-04-25 03:25:22 +00:00
" rgbgen entity \n "
" alphagen entity \n "
" blendfunc src_alpha one \n "
" } \n "
" } \n "
) ;
}
shell - > shaderRGBAf [ 0 ] * = ( effects & EF_RED ) ? 1 : 0 ;
added r_meshpitch cvar that allows for fixing the unfixable mesh pitch bug from vanilla... needs a better name... do note that this will break pretty much any mod, so this is really only for TCs designed to use it. Its likely that I missed places.
nqsv: added support for spectators with nq clients. the angles are a bit rough, but hey. need to do something about frags so nq clients know who's a spectator. use 'cmd observe' to get an nq client to spectate on an fte server (then attack/jump behave the same as in qw clients).
nqsv: rewrote EF_MUZZLEFLASH handling, so svc_muzzleflash is now translated properly to EF_MUZZLEFLASH, and vice versa. No more missing muzzleflashes!
added screenshot_cubemap, so you can actually pre-generate cubemaps with fte (which can be used for reflections or whatever).
misc fixes (server crash, a couple of other less important ones).
external files based on a model's name will now obey r_replacemodels properly, instead of needing to use foo.mdl_0.skin for foo.md3.
identify <playernum> should now use the correct masked ip, instead of abrubtly failing (reported by kt)
vid_toggle console command should now obey vid_width and vid_height when switching to fullscreen, but only if vid_fullscreen is actually set, which should make it seem better behaved (reported by kt).
qcc: cleaned up sym->symboldata[sym->ofs] to be more consistent at all stages.
qcc: typedef float vec4[4]; now works to define a float array with 4 elements (however, it will be passed by-value rather than by-reference).
qcc: cleaned up optional vs __out ordering issues.
qccgui: shift+f3 searches backwards
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@5064 fc73d0e0-1445-4013-8a0c-d673dee63da5
2017-02-27 09:34:35 +00:00
shell - > shaderRGBAf [ 1 ] * = ( effects & EF_GREEN ) ? 1 : 0 ;
2011-04-25 03:25:22 +00:00
shell - > shaderRGBAf [ 2 ] * = ( effects & EF_BLUE ) ? 1 : 0 ;
shell - > shaderRGBAf [ 3 ] * = v_powerupshell . value ;
/*let the shader do all the work*/
2014-03-31 17:06:41 +00:00
shell - > flags & = ~ RF_TRANSLUCENT | RF_ADDITIVE ;
2011-04-25 03:25:22 +00:00
}
2016-07-12 00:40:13 +00:00
static void CL_LerpNetFrameState ( framestate_t * fs , lerpents_t * le )
2009-07-18 20:46:42 +00:00
{
2016-07-12 00:40:13 +00:00
int fsanim ;
for ( fsanim = 0 ; fsanim < FS_COUNT ; fsanim + + )
{
fs - > g [ fsanim ] . frame [ 0 ] = le - > newframe [ fsanim ] ;
fs - > g [ fsanim ] . frame [ 1 ] = le - > oldframe [ fsanim ] ;
2009-07-18 20:46:42 +00:00
2016-07-12 00:40:13 +00:00
fs - > g [ fsanim ] . frametime [ 0 ] = cl . servertime - le - > newframestarttime [ fsanim ] ;
fs - > g [ fsanim ] . frametime [ 1 ] = cl . servertime - le - > oldframestarttime [ fsanim ] ;
2009-07-18 20:46:42 +00:00
2016-07-12 00:40:13 +00:00
fs - > g [ fsanim ] . lerpweight [ 0 ] = ( fs - > g [ fsanim ] . frametime [ 0 ] ) / le - > framelerpdeltatime [ fsanim ] ;
fs - > g [ fsanim ] . lerpweight [ 0 ] = bound ( 0 , fs - > g [ FS_REG ] . lerpweight [ 0 ] , 1 ) ;
fs - > g [ fsanim ] . lerpweight [ 1 ] = 1 - fs - > g [ fsanim ] . lerpweight [ 0 ] ;
}
fs - > g [ 0 ] . endbone = le - > basebone ;
2009-07-18 20:46:42 +00:00
}
2016-07-12 00:40:13 +00:00
static void CL_UpdateNetFrameLerpState ( qboolean force , int curframe , int curbaseframe , int curbasebone , lerpents_t * le )
2009-07-18 20:46:42 +00:00
{
2016-07-12 00:40:13 +00:00
int fst , frame ;
if ( curbasebone ! = le - > basebone )
{
//FIXME: we should be able to treat 0 and 255 specially by ignoring the change and locking the respective value to the other's value.
if ( ! curbasebone )
curbaseframe = curframe ;
else if ( curbasebone = = 255 )
curframe = curbaseframe ;
added r_meshpitch cvar that allows for fixing the unfixable mesh pitch bug from vanilla... needs a better name... do note that this will break pretty much any mod, so this is really only for TCs designed to use it. Its likely that I missed places.
nqsv: added support for spectators with nq clients. the angles are a bit rough, but hey. need to do something about frags so nq clients know who's a spectator. use 'cmd observe' to get an nq client to spectate on an fte server (then attack/jump behave the same as in qw clients).
nqsv: rewrote EF_MUZZLEFLASH handling, so svc_muzzleflash is now translated properly to EF_MUZZLEFLASH, and vice versa. No more missing muzzleflashes!
added screenshot_cubemap, so you can actually pre-generate cubemaps with fte (which can be used for reflections or whatever).
misc fixes (server crash, a couple of other less important ones).
external files based on a model's name will now obey r_replacemodels properly, instead of needing to use foo.mdl_0.skin for foo.md3.
identify <playernum> should now use the correct masked ip, instead of abrubtly failing (reported by kt)
vid_toggle console command should now obey vid_width and vid_height when switching to fullscreen, but only if vid_fullscreen is actually set, which should make it seem better behaved (reported by kt).
qcc: cleaned up sym->symboldata[sym->ofs] to be more consistent at all stages.
qcc: typedef float vec4[4]; now works to define a float array with 4 elements (however, it will be passed by-value rather than by-reference).
qcc: cleaned up optional vs __out ordering issues.
qccgui: shift+f3 searches backwards
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@5064 fc73d0e0-1445-4013-8a0c-d673dee63da5
2017-02-27 09:34:35 +00:00
le - > basebone = curbasebone ;
2016-07-12 00:40:13 +00:00
}
for ( fst = 0 ; fst < FS_COUNT ; fst + + )
{
added r_meshpitch cvar that allows for fixing the unfixable mesh pitch bug from vanilla... needs a better name... do note that this will break pretty much any mod, so this is really only for TCs designed to use it. Its likely that I missed places.
nqsv: added support for spectators with nq clients. the angles are a bit rough, but hey. need to do something about frags so nq clients know who's a spectator. use 'cmd observe' to get an nq client to spectate on an fte server (then attack/jump behave the same as in qw clients).
nqsv: rewrote EF_MUZZLEFLASH handling, so svc_muzzleflash is now translated properly to EF_MUZZLEFLASH, and vice versa. No more missing muzzleflashes!
added screenshot_cubemap, so you can actually pre-generate cubemaps with fte (which can be used for reflections or whatever).
misc fixes (server crash, a couple of other less important ones).
external files based on a model's name will now obey r_replacemodels properly, instead of needing to use foo.mdl_0.skin for foo.md3.
identify <playernum> should now use the correct masked ip, instead of abrubtly failing (reported by kt)
vid_toggle console command should now obey vid_width and vid_height when switching to fullscreen, but only if vid_fullscreen is actually set, which should make it seem better behaved (reported by kt).
qcc: cleaned up sym->symboldata[sym->ofs] to be more consistent at all stages.
qcc: typedef float vec4[4]; now works to define a float array with 4 elements (however, it will be passed by-value rather than by-reference).
qcc: cleaned up optional vs __out ordering issues.
qccgui: shift+f3 searches backwards
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@5064 fc73d0e0-1445-4013-8a0c-d673dee63da5
2017-02-27 09:34:35 +00:00
frame = ( fst = = FST_BASE ) ? curbaseframe : curframe ;
2016-07-12 00:40:13 +00:00
if ( force | | frame ! = le - > newframe [ fst ] )
2009-07-18 20:46:42 +00:00
{
2019-01-20 01:00:18 +00:00
le - > framelerpdeltatime [ fst ] = bound ( 0 , cl . servertime - le - > newframestarttime [ fst ] , cl_lerp_maxinterval . value ) ; //clamp to 10 tics per second
2016-07-12 00:40:13 +00:00
if ( ! force )
{
le - > oldframe [ fst ] = le - > newframe [ fst ] ;
le - > oldframestarttime [ fst ] = le - > newframestarttime [ fst ] ;
}
else
{
le - > oldframe [ fst ] = frame ;
le - > oldframestarttime [ fst ] = cl . servertime ;
}
le - > newframe [ fst ] = frame ;
le - > newframestarttime [ fst ] = cl . servertime ;
2017-01-13 00:39:50 +00:00
// if (force)
// {
// //if its new, we need to tweak the age of the animation. looping anims won't appear any different, while non-looping ones will clamp to the last pose of the animation when its new.
// le->oldframestarttime[fst] -= Mod_GetFrameDuration(le->model, 0, le->oldframe[fst]);
// le->newframestarttime[fst] -= Mod_GetFrameDuration(le->model, 0, le->newframe[fst]);
// }
2009-07-18 20:46:42 +00:00
}
}
}
2011-06-18 12:25:36 +00:00
void CL_ClearLerpEntsParticleState ( void )
{
int i ;
for ( i = 0 ; i < cl . maxlerpents ; i + + )
{
pe - > DelinkTrailstate ( & ( cl . lerpents [ i ] . trailstate ) ) ;
pe - > DelinkTrailstate ( & ( cl . lerpents [ i ] . emitstate ) ) ;
}
}
2019-07-02 04:12:20 +00:00
void CL_LinkStaticEntities ( void * pvs , int * areas )
2010-07-11 02:22:39 +00:00
{
int i ;
2016-10-22 07:06:51 +00:00
entity_t * ent ;
2010-07-11 02:22:39 +00:00
model_t * clmodel ;
2016-10-22 07:06:51 +00:00
static_entity_t * stat ;
2010-07-11 02:22:39 +00:00
extern cvar_t r_drawflame , gl_part_flame ;
2016-10-22 07:06:51 +00:00
vec3_t mins , maxs ;
2010-07-11 02:22:39 +00:00
2015-10-11 11:34:58 +00:00
if ( r_drawflame . ival < 0 | | r_drawentities . ival = = 0 )
Fixes, workarounds, and breakages. Hexen2 should work much better (-hexen2 says no mission pack, -portals says h2mp). Started working on splitting bigcoords per client, far too much work still to go on that. Removed gl_ztrick entirely. Enabled csprogs download by default. Added client support for fitzquake's 666 protocol, needs testing, some cleanup for dp protocols too, no server support, couldn't selectively enable it anyway. Now attempting to cache shadow meshes for explosions and stuff. Played with lightmaps a little, should potentially run a little faster on certain (intel?) cards. Tweeked npfte a little to try to avoid deadlocks and crashes. Fixed sky worldspawn parsing. Added h2mp's model format. Fixed baseline issue in q2 client, made servers generate q2 baselines. MOVETYPE_PUSH will not rotate extra if rotation is forced. Made status command show allowed client types. Changed lighting on weapons - should now be shaded.
git-svn-id: https://svn.code.sf.net/p/fteqw/code/branches/wip@3572 fc73d0e0-1445-4013-8a0c-d673dee63da5
2010-08-11 03:36:31 +00:00
return ;
2010-07-11 02:22:39 +00:00
if ( ! cl . worldmodel )
return ;
for ( i = 0 ; i < cl . num_statics ; i + + )
{
------------------------------------------------------------------------
r4169 | acceptthis | 2013-01-17 08:55:12 +0000 (Thu, 17 Jan 2013) | 31 lines
removed MAX_VISEDICTS limit.
PEXT2_REPLACEMENTDELTAS tweaked, now has 4 million entity limit. still not enabled by default.
TE_BEAM now maps to a separate TEQW_BEAM to avoid conflicts with QW.
added android multitouch emulation for windows/rawinput (in_simulatemultitouch).
split topcolor/bottomcolor from scoreboard, for dp's colormap|1024 feature.
now using utf-8 for windows consoles.
qcc warnings/errors now give clickable console links for quick+easy editing.
disabled menutint when the currently active item changes contrast or gamma (for OneManClan).
Added support for drawfont/drawfontscale.
tweaked the qcvm a little to reduce the number of pointers.
.doll file loading. still experimental and will likely crash. requires csqc active, even if its a dummy progs. this will be fixed in time. Still other things that need cleaning up.
windows: gl_font "?" shows the standard windows font-selection dialog, and can be used to select windows fonts. not all work. and you probably don't want to use windings.
fixed splitscreen support when playing mvds. added mini-scoreboards to splitscreen.
editor/debugger now shows asm if there's no linenumber info. also, pressing f1 for help shows the shortcuts.
Added support for .framegroups files for psk(psa) and iqm formats.
True support for ezquake's colour codes. Mutually exclusive with background colours.
path command output slightly more readable.
added support for digest_hex (MD4, SHA1, CRC16).
skingroups now colourmap correctly.
Fix terrain colour hints, and litdata from the wrong bsp.
fix ftp dual-homed issue. support epsv command, and enable ipv6 (eprt still not supported).
remove d3d11 compilation from the makefile. the required headers are not provided by mingw, and are not available to the build bot, so don't bother.
fix v *= v.x and similar opcodes.
fteqcc: fixed support for áéíóú type chars in names. utf-8 files now properly supported (even with the utf-8 bom/identifier). utf-16 also supported.
fteqcc: fixed '#if 1 == 3 && 4' parsing.
fteqcc: -Werror acts on the warning, rather than as a separate error. Line numbers are thus more readable.
fteqcc: copyright message now includes compile date instead.
fteqccgui: the treeview control is now coloured depending on whether there were warnings/errors in the last compile.
fteqccgui: the output window is now focused and scrolls down as compilation progresses.
pr_dumpplatform command dumps out some pragmas to convert more serious warnings to errors. This is to avoid the infamous 'fteqcc sucks cos my code sucks' issue.
rewrote prespawn/modelist/soundlist code. server tracks progress now.
------------------------------------------------------------------------
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@4167 fc73d0e0-1445-4013-8a0c-d673dee63da5
2013-03-12 22:29:40 +00:00
if ( cl_numvisedicts = = cl_maxvisedicts )
2020-04-19 01:23:32 +00:00
{
cl_expandvisents = true ;
2010-07-11 02:22:39 +00:00
break ;
2020-04-19 01:23:32 +00:00
}
2016-10-22 07:06:51 +00:00
stat = & cl_static_entities [ i ] ;
2010-07-11 02:22:39 +00:00
2016-10-22 07:06:51 +00:00
clmodel = stat - > ent . model ;
2010-07-11 02:22:39 +00:00
2016-10-22 07:06:51 +00:00
if ( ! clmodel )
{
if ( stat - > mdlidx < 0 )
{
if ( stat - > mdlidx > - MAX_CSMODELS )
clmodel = cl . model_csqcprecache [ - stat - > mdlidx ] ;
}
else
{
if ( stat - > mdlidx < MAX_PRECACHE_MODELS )
clmodel = cl . model_precache [ stat - > mdlidx ] ;
}
if ( ! clmodel | | clmodel - > loadstate = = MLS_LOADING )
continue ;
if ( ! cl . worldmodel | | cl . worldmodel - > loadstate ! = MLS_LOADED )
continue ;
stat - > ent . model = clmodel ;
//figure out the correct axis for the model
if ( clmodel & & clmodel - > type = = mod_alias & & ( cls . protocol = = CP_QUAKEWORLD | | cls . protocol = = CP_NETQUAKE ) )
2020-10-06 03:17:28 +00:00
{ //q2 is fixed, but q1 pitches the wrong way, and hexen2 rolls the wrong way too.
AngleVectorsMesh ( stat - > state . angles , stat - > ent . axis [ 0 ] , stat - > ent . axis [ 1 ] , stat - > ent . axis [ 2 ] ) ;
2016-10-22 07:06:51 +00:00
}
else
AngleVectors ( stat - > state . angles , stat - > ent . axis [ 0 ] , stat - > ent . axis [ 1 ] , stat - > ent . axis [ 2 ] ) ;
VectorInverse ( stat - > ent . axis [ 1 ] ) ;
if ( clmodel )
{
//FIXME: wait for model to load so we know the correct size?
/*FIXME: compensate for angle*/
VectorAdd ( stat - > state . origin , clmodel - > mins , mins ) ;
VectorAdd ( stat - > state . origin , clmodel - > maxs , maxs ) ;
}
else
{
VectorCopy ( stat - > state . origin , mins ) ;
VectorCopy ( stat - > state . origin , maxs ) ;
}
2019-04-07 16:41:09 +00:00
cl . worldmodel - > funcs . FindTouchedLeafs ( cl . worldmodel , & stat - > ent . pvscache , mins , maxs ) ;
2016-10-22 07:06:51 +00:00
}
2021-04-14 05:21:04 +00:00
else if ( clmodel - > loadstate ! = MLS_LOADED )
{
if ( clmodel - > loadstate = = MLS_NOTLOADED ) //flushed?
Mod_LoadModel ( clmodel , MLV_WARN ) ; //load it, but don't otherwise care for now.
continue ;
}
2010-07-11 02:22:39 +00:00
2012-11-27 03:23:19 +00:00
/*pvs test*/
2019-07-02 04:12:20 +00:00
if ( pvs & & ! cl . worldmodel - > funcs . EdictInFatPVS ( cl . worldmodel , & stat - > ent . pvscache , pvs , areas ) )
2010-07-11 02:22:39 +00:00
continue ;
2018-11-28 05:41:39 +00:00
2016-10-22 07:06:51 +00:00
// emit particles for statics (we don't need to cheat check statics)
if ( stat - > state . u . q1 . emiteffectnum )
P_EmitEffect ( stat - > ent . origin , stat - > ent . axis , MDLF_EMITFORWARDS , CL_TranslateParticleFromServer ( stat - > state . u . q1 . emiteffectnum ) , & ( stat - > emit ) ) ;
2018-11-28 05:41:39 +00:00
else if ( clmodel )
2010-07-11 02:22:39 +00:00
{
2018-11-28 05:41:39 +00:00
if ( clmodel - > particleeffect > = 0 & & gl_part_flame . ival )
P_EmitEffect ( stat - > ent . origin , stat - > ent . axis , clmodel - > engineflags , clmodel - > particleeffect , & stat - > emit ) ;
2016-10-22 07:06:51 +00:00
if ( ( ! r_drawflame . ival ) & & ( clmodel - > engineflags & MDLF_FLAME ) )
continue ;
2010-07-11 02:22:39 +00:00
}
2011-04-25 03:25:22 +00:00
2016-10-22 07:06:51 +00:00
//prepare to draw it
if ( ! clmodel | | clmodel - > loadstate ! = MLS_LOADED )
continue ;
ent = & cl_visedicts [ cl_numvisedicts + + ] ;
* ent = stat - > ent ;
ent - > framestate . g [ FS_REG ] . frametime [ 0 ] = cl . time ;
ent - > framestate . g [ FS_REG ] . frametime [ 1 ] = cl . time ;
2011-04-25 03:25:22 +00:00
// FIXME: no effects on static ents
// CLQ1_AddPowerupShell(ent, false, stat->effects);
2010-07-11 02:22:39 +00:00
}
}
2019-07-02 04:12:20 +00:00
//returns cos(angle)
static float CompareAngles ( const vec3_t angles1 , const vec3_t angles2 )
{
float angle ;
vec3_t dir1 , dir2 ;
angle = angles1 [ YAW ] * ( M_PI * 2 / 360 ) ;
dir1 [ 1 ] = sin ( angle ) ;
dir1 [ 0 ] = cos ( angle ) ;
if ( angles1 [ PITCH ] )
{
angle = angles1 [ PITCH ] * ( M_PI * 2 / 360 ) ;
dir1 [ 2 ] = - sin ( angle ) ;
angle = cos ( angle ) ;
dir1 [ 0 ] * = angle ;
dir1 [ 1 ] * = angle ;
}
else
dir1 [ 2 ] = 0 ;
angle = angles2 [ YAW ] * ( M_PI * 2 / 360 ) ;
dir2 [ 1 ] = sin ( angle ) ;
dir2 [ 0 ] = cos ( angle ) ;
if ( angles2 [ PITCH ] )
{
angle = angles2 [ PITCH ] * ( M_PI * 2 / 360 ) ;
dir2 [ 2 ] = - sin ( angle ) ;
angle = cos ( angle ) ;
dir2 [ 0 ] * = angle ;
dir2 [ 1 ] * = angle ;
}
else
dir2 [ 2 ] = 0 ;
return DotProduct ( dir1 , dir2 ) ;
}
2004-08-23 00:15:46 +00:00
/*
= = = = = = = = = = = = = = =
CL_LinkPacketEntities
= = = = = = = = = = = = = = =
*/
void R_FlameTrail ( vec3_t start , vec3_t end , float seperation ) ;
2005-11-26 03:02:55 +00:00
2010-03-14 14:35:56 +00:00
/*
Interpolates the two packets by the given time , writes its results into the lerpentities array .
*/
2013-07-26 17:19:06 +00:00
static void CL_TransitionPacketEntities ( int newsequence , packet_entities_t * newpack , packet_entities_t * oldpack , float frac , float servertime )
2005-11-26 03:02:55 +00:00
{
lerpents_t * le ;
entity_state_t * snew , * sold ;
2011-12-05 15:23:40 +00:00
int i ;
2005-11-26 03:02:55 +00:00
int oldpnum , newpnum ;
2013-09-06 22:57:44 +00:00
float * snew__origin ;
float * sold__origin ;
2019-07-02 04:12:20 +00:00
float cos_theta ;
2016-07-12 00:40:13 +00:00
int oldsequence ;
extern cvar_t r_nolerp ;
2005-11-26 03:02:55 +00:00
2015-03-03 07:54:10 +00:00
qboolean isnew ;
2005-11-26 03:02:55 +00:00
vec3_t move ;
float a1 , a2 ;
2020-09-29 07:09:01 +00:00
float maxdist = cl_lerp_maxdistance . value * cl_lerp_maxdistance . value ;
2005-11-26 03:02:55 +00:00
/*
seeing as how dropped packets cannot be filled in due to the reliable networking stuff ,
We can simply detect changes and lerp towards them
*/
//we have two index-sorted lists of entities
//we figure out which ones are new,
//we don't care about old, as our caller will use the lerpents array we fill, and the entity numbers from the 'new' packet.
2016-07-12 00:40:13 +00:00
oldsequence = cl . lerpentssequence ;
if ( ! oldsequence )
oldsequence = - 1 ; //something invalid, so everything is new
2012-02-17 01:35:22 +00:00
cl . lerpentssequence = newsequence ;
2016-07-12 00:40:13 +00:00
cl . packfrac = frac ;
cl . currentpacktime = servertime ;
cl . currentpackentities = newpack ;
cl . previouspackentities = oldpack ;
2005-11-26 03:02:55 +00:00
oldpnum = 0 ;
for ( newpnum = 0 ; newpnum < newpack - > num_entities ; newpnum + + )
{
snew = & newpack - > entities [ newpnum ] ;
sold = NULL ;
2014-08-15 02:20:41 +00:00
for ( ; oldpnum < oldpack - > num_entities ; )
2005-11-26 03:02:55 +00:00
{
2015-03-12 14:59:53 +00:00
sold = & oldpack - > entities [ oldpnum ] ;
2005-11-26 03:02:55 +00:00
if ( sold - > number > = snew - > number )
{
if ( sold - > number > snew - > number )
sold = NULL ; //woo, it's a new entity.
2015-03-12 14:59:53 +00:00
else
oldpnum + + ;
2005-11-26 03:02:55 +00:00
break ;
}
2015-03-12 14:59:53 +00:00
oldpnum + + ;
------------------------------------------------------------------------
r4169 | acceptthis | 2013-01-17 08:55:12 +0000 (Thu, 17 Jan 2013) | 31 lines
removed MAX_VISEDICTS limit.
PEXT2_REPLACEMENTDELTAS tweaked, now has 4 million entity limit. still not enabled by default.
TE_BEAM now maps to a separate TEQW_BEAM to avoid conflicts with QW.
added android multitouch emulation for windows/rawinput (in_simulatemultitouch).
split topcolor/bottomcolor from scoreboard, for dp's colormap|1024 feature.
now using utf-8 for windows consoles.
qcc warnings/errors now give clickable console links for quick+easy editing.
disabled menutint when the currently active item changes contrast or gamma (for OneManClan).
Added support for drawfont/drawfontscale.
tweaked the qcvm a little to reduce the number of pointers.
.doll file loading. still experimental and will likely crash. requires csqc active, even if its a dummy progs. this will be fixed in time. Still other things that need cleaning up.
windows: gl_font "?" shows the standard windows font-selection dialog, and can be used to select windows fonts. not all work. and you probably don't want to use windings.
fixed splitscreen support when playing mvds. added mini-scoreboards to splitscreen.
editor/debugger now shows asm if there's no linenumber info. also, pressing f1 for help shows the shortcuts.
Added support for .framegroups files for psk(psa) and iqm formats.
True support for ezquake's colour codes. Mutually exclusive with background colours.
path command output slightly more readable.
added support for digest_hex (MD4, SHA1, CRC16).
skingroups now colourmap correctly.
Fix terrain colour hints, and litdata from the wrong bsp.
fix ftp dual-homed issue. support epsv command, and enable ipv6 (eprt still not supported).
remove d3d11 compilation from the makefile. the required headers are not provided by mingw, and are not available to the build bot, so don't bother.
fix v *= v.x and similar opcodes.
fteqcc: fixed support for áéíóú type chars in names. utf-8 files now properly supported (even with the utf-8 bom/identifier). utf-16 also supported.
fteqcc: fixed '#if 1 == 3 && 4' parsing.
fteqcc: -Werror acts on the warning, rather than as a separate error. Line numbers are thus more readable.
fteqcc: copyright message now includes compile date instead.
fteqccgui: the treeview control is now coloured depending on whether there were warnings/errors in the last compile.
fteqccgui: the output window is now focused and scrolls down as compilation progresses.
pr_dumpplatform command dumps out some pragmas to convert more serious warnings to errors. This is to avoid the infamous 'fteqcc sucks cos my code sucks' issue.
rewrote prespawn/modelist/soundlist code. server tracks progress now.
------------------------------------------------------------------------
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@4167 fc73d0e0-1445-4013-8a0c-d673dee63da5
2013-03-12 22:29:40 +00:00
# ifdef RAGDOLL
2016-07-12 00:40:13 +00:00
//note: not entirely reliable
------------------------------------------------------------------------
r4169 | acceptthis | 2013-01-17 08:55:12 +0000 (Thu, 17 Jan 2013) | 31 lines
removed MAX_VISEDICTS limit.
PEXT2_REPLACEMENTDELTAS tweaked, now has 4 million entity limit. still not enabled by default.
TE_BEAM now maps to a separate TEQW_BEAM to avoid conflicts with QW.
added android multitouch emulation for windows/rawinput (in_simulatemultitouch).
split topcolor/bottomcolor from scoreboard, for dp's colormap|1024 feature.
now using utf-8 for windows consoles.
qcc warnings/errors now give clickable console links for quick+easy editing.
disabled menutint when the currently active item changes contrast or gamma (for OneManClan).
Added support for drawfont/drawfontscale.
tweaked the qcvm a little to reduce the number of pointers.
.doll file loading. still experimental and will likely crash. requires csqc active, even if its a dummy progs. this will be fixed in time. Still other things that need cleaning up.
windows: gl_font "?" shows the standard windows font-selection dialog, and can be used to select windows fonts. not all work. and you probably don't want to use windings.
fixed splitscreen support when playing mvds. added mini-scoreboards to splitscreen.
editor/debugger now shows asm if there's no linenumber info. also, pressing f1 for help shows the shortcuts.
Added support for .framegroups files for psk(psa) and iqm formats.
True support for ezquake's colour codes. Mutually exclusive with background colours.
path command output slightly more readable.
added support for digest_hex (MD4, SHA1, CRC16).
skingroups now colourmap correctly.
Fix terrain colour hints, and litdata from the wrong bsp.
fix ftp dual-homed issue. support epsv command, and enable ipv6 (eprt still not supported).
remove d3d11 compilation from the makefile. the required headers are not provided by mingw, and are not available to the build bot, so don't bother.
fix v *= v.x and similar opcodes.
fteqcc: fixed support for áéíóú type chars in names. utf-8 files now properly supported (even with the utf-8 bom/identifier). utf-16 also supported.
fteqcc: fixed '#if 1 == 3 && 4' parsing.
fteqcc: -Werror acts on the warning, rather than as a separate error. Line numbers are thus more readable.
fteqcc: copyright message now includes compile date instead.
fteqccgui: the treeview control is now coloured depending on whether there were warnings/errors in the last compile.
fteqccgui: the output window is now focused and scrolls down as compilation progresses.
pr_dumpplatform command dumps out some pragmas to convert more serious warnings to errors. This is to avoid the infamous 'fteqcc sucks cos my code sucks' issue.
rewrote prespawn/modelist/soundlist code. server tracks progress now.
------------------------------------------------------------------------
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@4167 fc73d0e0-1445-4013-8a0c-d673dee63da5
2013-03-12 22:29:40 +00:00
le = & cl . lerpents [ sold - > number ] ;
2014-04-12 03:30:27 +00:00
if ( sold - > number < cl . maxlerpents & & le - > skeletalobject )
------------------------------------------------------------------------
r4169 | acceptthis | 2013-01-17 08:55:12 +0000 (Thu, 17 Jan 2013) | 31 lines
removed MAX_VISEDICTS limit.
PEXT2_REPLACEMENTDELTAS tweaked, now has 4 million entity limit. still not enabled by default.
TE_BEAM now maps to a separate TEQW_BEAM to avoid conflicts with QW.
added android multitouch emulation for windows/rawinput (in_simulatemultitouch).
split topcolor/bottomcolor from scoreboard, for dp's colormap|1024 feature.
now using utf-8 for windows consoles.
qcc warnings/errors now give clickable console links for quick+easy editing.
disabled menutint when the currently active item changes contrast or gamma (for OneManClan).
Added support for drawfont/drawfontscale.
tweaked the qcvm a little to reduce the number of pointers.
.doll file loading. still experimental and will likely crash. requires csqc active, even if its a dummy progs. this will be fixed in time. Still other things that need cleaning up.
windows: gl_font "?" shows the standard windows font-selection dialog, and can be used to select windows fonts. not all work. and you probably don't want to use windings.
fixed splitscreen support when playing mvds. added mini-scoreboards to splitscreen.
editor/debugger now shows asm if there's no linenumber info. also, pressing f1 for help shows the shortcuts.
Added support for .framegroups files for psk(psa) and iqm formats.
True support for ezquake's colour codes. Mutually exclusive with background colours.
path command output slightly more readable.
added support for digest_hex (MD4, SHA1, CRC16).
skingroups now colourmap correctly.
Fix terrain colour hints, and litdata from the wrong bsp.
fix ftp dual-homed issue. support epsv command, and enable ipv6 (eprt still not supported).
remove d3d11 compilation from the makefile. the required headers are not provided by mingw, and are not available to the build bot, so don't bother.
fix v *= v.x and similar opcodes.
fteqcc: fixed support for áéíóú type chars in names. utf-8 files now properly supported (even with the utf-8 bom/identifier). utf-16 also supported.
fteqcc: fixed '#if 1 == 3 && 4' parsing.
fteqcc: -Werror acts on the warning, rather than as a separate error. Line numbers are thus more readable.
fteqcc: copyright message now includes compile date instead.
fteqccgui: the treeview control is now coloured depending on whether there were warnings/errors in the last compile.
fteqccgui: the output window is now focused and scrolls down as compilation progresses.
pr_dumpplatform command dumps out some pragmas to convert more serious warnings to errors. This is to avoid the infamous 'fteqcc sucks cos my code sucks' issue.
rewrote prespawn/modelist/soundlist code. server tracks progress now.
------------------------------------------------------------------------
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@4167 fc73d0e0-1445-4013-8a0c-d673dee63da5
2013-03-12 22:29:40 +00:00
rag_removedeltaent ( le ) ;
# endif
2005-11-26 03:02:55 +00:00
}
if ( snew - > number > = cl . maxlerpents )
{
2008-05-09 14:22:37 +00:00
int newmaxle = snew - > number + 16 ;
cl . lerpents = BZ_Realloc ( cl . lerpents , newmaxle * sizeof ( lerpents_t ) ) ;
memset ( cl . lerpents + cl . maxlerpents , 0 , sizeof ( lerpents_t ) * ( newmaxle - cl . maxlerpents ) ) ;
cl . maxlerpents = newmaxle ;
2005-11-26 03:02:55 +00:00
}
2015-03-03 07:54:10 +00:00
if ( ! sold )
{
isnew = true ;
sold = snew ; //don't crash if anything tries poking sold
}
else
isnew = false ;
2016-07-12 00:40:13 +00:00
le = & cl . lerpents [ snew - > number ] ;
if ( le - > sequence ! = oldsequence )
isnew = true ;
le - > sequence = newsequence ;
le - > entstate = snew ;
2013-09-06 22:57:44 +00:00
if ( snew - > u . q1 . pmovetype )
{
if ( ! cl . do_lerp_players )
{
entity_state_t * from ;
float age ;
packet_entities_t * latest ;
2015-03-03 07:54:10 +00:00
if ( isnew )
2013-09-06 22:57:44 +00:00
{
/*keep trails correct*/
le - > isnew = true ;
VectorCopy ( le - > origin , le - > lastorigin ) ;
}
2016-07-12 00:40:13 +00:00
CL_UpdateNetFrameLerpState ( sold = = snew , snew - > frame , snew - > baseframe , snew - > basebone , le ) ;
2013-09-06 22:57:44 +00:00
from = sold ; //eww
age = servertime - oldpack - > servertime ;
latest = & cl . inframes [ cl . validsequence & UPDATE_MASK ] . packet_entities ;
for ( i = 0 ; i < latest - > num_entities ; i + + )
{
if ( latest - > entities [ i ] . number = = snew - > number )
{
from = & latest - > entities [ i ] ;
//use realtime instead.
//also, use the sent timings instead of received as those are assumed to be more reliable
2015-06-28 03:43:10 +00:00
age = ( realtime - cl . outframes [ cl . ackedmovesequence & UPDATE_MASK ] . senttime ) - cls . latency * cl_predict_players_latency . value + cl_predict_players_nudge . value ;
2013-09-06 22:57:44 +00:00
break ;
}
}
if ( age > 1 )
age = 1 ;
2014-03-30 08:55:06 +00:00
if ( cl_predict_players . ival & & pmove . numphysent )
2013-09-06 22:57:44 +00:00
{
CL_PredictEntityMovement ( from , age ) ;
VectorCopy ( from - > u . q1 . predorg , le - > origin ) ;
}
else
VectorCopy ( from - > origin , le - > origin ) ;
VectorCopy ( from - > angles , le - > angles ) ;
continue ;
}
2015-01-21 18:18:37 +00:00
//FIXME: find a packet where this entity changed.
2013-09-06 22:57:44 +00:00
snew__origin = snew - > u . q1 . predorg ;
sold__origin = sold - > u . q1 . predorg ;
2019-07-02 04:12:20 +00:00
cos_theta = 1 ; //don't cut off lerping when the player spins too fast.
2013-09-06 22:57:44 +00:00
}
else
{
snew__origin = snew - > origin ;
sold__origin = sold - > origin ;
2019-07-02 04:12:20 +00:00
cos_theta = CompareAngles ( sold - > angles , snew - > angles ) ;
2013-09-06 22:57:44 +00:00
}
2019-07-02 04:12:20 +00:00
2013-09-06 22:57:44 +00:00
VectorSubtract ( snew__origin , sold__origin , move ) ;
2020-09-29 07:09:01 +00:00
if ( DotProduct ( move , move ) > maxdist | | cos_theta < 0.707 | | snew - > modelindex ! = sold - > modelindex | | ( ( sold - > effects ^ snew - > effects ) & EF_TELEPORT_BIT ) )
2005-11-26 03:02:55 +00:00
{
2015-03-03 07:54:10 +00:00
isnew = true ; //disable lerping (and indirectly trails)
2016-07-12 00:40:13 +00:00
// VectorClear(move);
2005-11-26 03:02:55 +00:00
}
2012-02-12 05:18:31 +00:00
VectorCopy ( le - > origin , le - > lastorigin ) ;
2015-03-03 07:54:10 +00:00
if ( isnew )
2005-11-26 03:02:55 +00:00
{
2016-07-12 00:40:13 +00:00
# ifdef RAGDOLL //make sure nothing gets stale
if ( le - > skeletalobject )
rag_removedeltaent ( le ) ;
# endif
le - > newsequence = snew - > sequence ;
2009-07-18 20:46:42 +00:00
//new this frame (or we noticed something changed significantly)
2013-09-06 22:57:44 +00:00
VectorCopy ( snew__origin , le - > origin ) ;
2009-07-18 20:46:42 +00:00
VectorCopy ( snew - > angles , le - > angles ) ;
2011-05-29 04:26:29 +00:00
2013-09-06 22:57:44 +00:00
VectorCopy ( snew__origin , le - > oldorigin ) ;
2010-07-12 22:46:37 +00:00
VectorCopy ( snew - > angles , le - > oldangle ) ;
2013-09-06 22:57:44 +00:00
VectorCopy ( snew__origin , le - > neworigin ) ;
2010-07-12 22:46:37 +00:00
VectorCopy ( snew - > angles , le - > newangle ) ;
2005-11-26 03:02:55 +00:00
2016-07-12 00:40:13 +00:00
le - > orglerpdeltatime = newpack - > servertime - oldpack - > servertime ;
2009-07-18 20:46:42 +00:00
le - > orglerpstarttime = oldpack - > servertime ;
2011-04-30 17:21:10 +00:00
le - > isnew = true ;
VectorCopy ( le - > origin , le - > lastorigin ) ;
2009-07-18 20:46:42 +00:00
}
2011-04-30 17:21:10 +00:00
else
2009-07-18 20:46:42 +00:00
{
2015-08-02 19:08:36 +00:00
if ( ( sold - > effects ^ snew - > effects ) & EF_RESTARTANIM_BIT )
isnew = true ;
2011-04-30 17:21:10 +00:00
if ( snew - > dpflags & RENDER_STEP )
{
float lfrac ;
//ignore the old packet entirely, except for maybe its time.
2013-09-06 22:57:44 +00:00
if ( ! VectorEquals ( le - > neworigin , snew__origin ) | | ! VectorEquals ( le - > newangle , snew - > angles ) )
2011-04-30 17:21:10 +00:00
{
2016-07-12 00:40:13 +00:00
le - > newsequence = snew - > sequence ;
2019-01-20 01:00:18 +00:00
le - > orglerpdeltatime = bound ( 0 , oldpack - > servertime - le - > orglerpstarttime , cl_lerp_maxinterval . value ) ; //clamp to 10 tics per second
2011-04-30 17:21:10 +00:00
le - > orglerpstarttime = oldpack - > servertime ;
2009-07-18 20:46:42 +00:00
2011-04-30 17:21:10 +00:00
VectorCopy ( le - > neworigin , le - > oldorigin ) ;
VectorCopy ( le - > newangle , le - > oldangle ) ;
2011-10-27 15:46:36 +00:00
2013-09-06 22:57:44 +00:00
VectorCopy ( snew__origin , le - > neworigin ) ;
2011-04-30 17:21:10 +00:00
VectorCopy ( snew - > angles , le - > newangle ) ;
}
2005-11-26 03:02:55 +00:00
2011-04-30 17:21:10 +00:00
lfrac = ( servertime - le - > orglerpstarttime ) / le - > orglerpdeltatime ;
lfrac = bound ( 0 , lfrac , 1 ) ;
2016-07-12 00:40:13 +00:00
if ( r_nolerp . ival )
2018-01-05 16:14:33 +00:00
{
2016-07-12 00:40:13 +00:00
lfrac = 1 ;
2018-01-05 16:14:33 +00:00
isnew = true ;
}
2011-04-30 17:21:10 +00:00
for ( i = 0 ; i < 3 ; i + + )
2009-07-18 20:46:42 +00:00
{
2011-04-30 17:21:10 +00:00
le - > origin [ i ] = le - > oldorigin [ i ] + lfrac * ( le - > neworigin [ i ] - le - > oldorigin [ i ] ) ;
2011-12-05 15:23:40 +00:00
a1 = le - > oldangle [ i ] ;
a2 = le - > newangle [ i ] ;
if ( a1 - a2 > 180 )
a1 - = 360 ;
if ( a1 - a2 < - 180 )
a1 + = 360 ;
le - > angles [ i ] = a1 + lfrac * ( a2 - a1 ) ;
2009-07-18 20:46:42 +00:00
}
}
2011-04-30 17:21:10 +00:00
else
2009-07-18 20:46:42 +00:00
{
2016-07-12 00:40:13 +00:00
float lfrac ;
if ( le - > newsequence ! = snew - > sequence )
{
le - > newsequence = snew - > sequence ;
VectorCopy ( le - > neworigin , le - > oldorigin ) ;
VectorCopy ( le - > newangle , le - > oldangle ) ;
VectorCopy ( snew__origin , le - > neworigin ) ;
VectorCopy ( snew - > angles , le - > newangle ) ;
//fixme: should be oldservertime
2019-03-12 05:04:27 +00:00
le - > orglerpdeltatime = bound ( 0.001 , servertime - le - > orglerpstarttime , cl_lerp_maxinterval . value ) ;
2016-07-12 00:40:13 +00:00
le - > orglerpstarttime = servertime ;
}
lfrac = ( servertime - le - > orglerpstarttime ) / le - > orglerpdeltatime ;
lfrac = bound ( 0 , lfrac , 1 ) ;
2011-04-30 17:21:10 +00:00
//lerp based purely on the packet times,
for ( i = 0 ; i < 3 ; i + + )
2009-07-18 20:46:42 +00:00
{
2016-07-12 00:40:13 +00:00
le - > origin [ i ] = le - > oldorigin [ i ] + lfrac * ( le - > neworigin [ i ] - le - > oldorigin [ i ] ) ;
2011-04-30 17:21:10 +00:00
2016-07-12 00:40:13 +00:00
a1 = le - > oldangle [ i ] ;
a2 = le - > newangle [ i ] ;
2011-12-05 15:23:40 +00:00
if ( a1 - a2 > 180 )
a1 - = 360 ;
if ( a1 - a2 < - 180 )
a1 + = 360 ;
2016-07-12 00:40:13 +00:00
le - > angles [ i ] = a1 + lfrac * ( a2 - a1 ) ;
2009-07-18 20:46:42 +00:00
}
}
2005-11-26 03:02:55 +00:00
}
2009-07-18 20:46:42 +00:00
2016-07-12 00:40:13 +00:00
# ifdef RAGDOLL //this preprocessor is misnamed, but oh well
if ( snew - > bonecount )
{
void * newbones = GetBoneSpace ( newpack , snew - > boneoffset ) ;
if ( sold & & snew - > bonecount = = sold - > bonecount )
rag_lerpdeltaent ( le , snew - > bonecount , newbones , r_nolerp . ival ? 1 : frac , GetBoneSpace ( oldpack , sold - > boneoffset ) ) ;
else
rag_lerpdeltaent ( le , snew - > bonecount , newbones , 1 , newbones ) ;
}
# endif
CL_UpdateNetFrameLerpState ( isnew , snew - > frame , snew - > baseframe , snew - > basebone , le ) ;
2005-11-26 03:02:55 +00:00
}
}
2010-03-14 14:35:56 +00:00
static qboolean CL_ChooseInterpolationFrames ( int * newf , int * oldf , float servertime )
2005-11-26 03:02:55 +00:00
{
2010-03-14 14:35:56 +00:00
int i ;
float newtime = 0 ;
* oldf = - 1 ;
* newf = - 1 ;
2005-11-26 03:02:55 +00:00
//choose the two packets.
//we should be picking the packet just after the server time, and the one just before
for ( i = cls . netchan . incoming_sequence ; i > = cls . netchan . incoming_sequence - UPDATE_MASK ; i - - )
{
2013-09-06 22:57:44 +00:00
if ( cl . inframes [ i & UPDATE_MASK ] . frameid ! = i | | cl . inframes [ i & UPDATE_MASK ] . invalid )
2005-11-26 03:02:55 +00:00
continue ; //packetloss/choke, it's really only a problem for the oldframe, but...
2013-03-12 22:53:23 +00:00
if ( cl . inframes [ i & UPDATE_MASK ] . packet_entities . servertime > = servertime )
2005-11-26 03:02:55 +00:00
{
2013-03-12 22:53:23 +00:00
if ( cl . inframes [ i & UPDATE_MASK ] . packet_entities . servertime )
2005-11-26 03:02:55 +00:00
{
2013-03-12 22:53:23 +00:00
if ( ! newtime | | newtime ! = cl . inframes [ i & UPDATE_MASK ] . packet_entities . servertime ) //if it's a duplicate, pick the latest (so just-shot rockets are still present)
2010-03-14 14:35:56 +00:00
{
2013-03-12 22:53:23 +00:00
newtime = cl . inframes [ i & UPDATE_MASK ] . packet_entities . servertime ;
2010-03-14 14:35:56 +00:00
* newf = i ;
}
2005-11-26 03:02:55 +00:00
}
}
2010-03-14 14:35:56 +00:00
else if ( newtime )
2005-11-26 03:02:55 +00:00
{
2013-03-12 22:53:23 +00:00
if ( cl . inframes [ i & UPDATE_MASK ] . packet_entities . servertime ! = newtime )
2005-11-26 03:02:55 +00:00
{ //it does actually lerp, and isn't an identical frame.
2010-03-14 14:35:56 +00:00
* oldf = i ;
2005-11-26 03:02:55 +00:00
break ;
}
}
}
2010-03-14 14:35:56 +00:00
if ( * newf = = - 1 )
2005-11-26 03:02:55 +00:00
{
2010-03-14 14:35:56 +00:00
/*
This can happen if the client ' s predicted time is greater than the most recently received packet .
This should of course not happen . . .
*/
2014-03-30 08:55:06 +00:00
// Con_DPrintf("Warning: No lerp-to frame packet\n");
2010-03-14 14:35:56 +00:00
/*just grab the most recent frame that is valid*/
for ( i = cls . netchan . incoming_sequence ; i > = cls . netchan . incoming_sequence - UPDATE_MASK ; i - - )
{
2013-09-06 22:57:44 +00:00
if ( cl . inframes [ i & UPDATE_MASK ] . frameid ! = i | | cl . inframes [ i & UPDATE_MASK ] . invalid )
2010-03-14 14:35:56 +00:00
continue ; //packetloss/choke, it's really only a problem for the oldframe, but...
* oldf = * newf = i ;
return true ;
}
return false ;
2005-11-26 03:02:55 +00:00
}
2010-03-14 14:35:56 +00:00
else if ( * oldf = = - 1 ) //can happen at map start, and really laggy games, but really shouldn't in a normal game
2005-11-26 03:02:55 +00:00
{
2010-03-14 14:35:56 +00:00
* oldf = * newf ;
}
return true ;
}
2008-12-03 02:42:05 +00:00
qboolean CL_MayLerp ( void )
{
//force lerping when playing low-framerate demos.
if ( cls . demoplayback = = DPB_MVD | | cls . demoplayback = = DPB_EZTV )
return true ;
# ifdef NQPROT
if ( cls . demoplayback = = DPB_NETQUAKE )
return true ;
if ( cls . protocol = = CP_NETQUAKE ) //this includes DP protocols.
2010-07-11 02:22:39 +00:00
return ! cl_nolerp_netquake . ival ;
2008-12-03 02:42:05 +00:00
# endif
2013-03-12 22:53:23 +00:00
if ( cl_nolerp . ival = = 2 & & ! cls . deathmatch )
2010-07-11 02:22:39 +00:00
return true ;
return ! cl_nolerp . ival ;
2008-12-03 02:42:05 +00:00
}
2011-12-05 15:23:40 +00:00
/*fills in cl.lerpents and cl.currentpackentities*/
void CL_TransitionEntities ( void )
{
packet_entities_t * packnew , * packold ;
2017-02-21 21:18:48 +00:00
int newf , newff , oldf , i ;
2011-12-05 15:23:40 +00:00
qboolean nolerp ;
2013-07-26 17:19:06 +00:00
float servertime , frac ;
2011-12-05 15:23:40 +00:00
if ( cls . protocol = = CP_QUAKEWORLD & & ( cls . demoplayback = = DPB_MVD | | cls . demoplayback = = DPB_EZTV ) )
{
nolerp = false ;
}
else
{
nolerp = ! CL_MayLerp ( ) & & cls . demoplayback ! = DPB_MVD & & cls . demoplayback ! = DPB_EZTV ;
}
2018-05-06 16:09:07 +00:00
if ( cl . demonudge < 0 )
2019-09-10 15:40:04 +00:00
{ //demo playback allows nudging to earlier frames, generally only when paused though...
2018-05-06 16:09:07 +00:00
servertime = cl . inframes [ ( cls . netchan . incoming_sequence + cl . demonudge ) & UPDATE_MASK ] . packet_entities . servertime ;
nolerp = true ;
}
else if ( nolerp )
2019-09-10 15:40:04 +00:00
{
//force our emulated time to as late as we can, if we're not using interpolation, which has the effect of disabling all interpolation
2013-03-12 22:53:23 +00:00
servertime = cl . inframes [ cls . netchan . incoming_sequence & UPDATE_MASK ] . packet_entities . servertime ;
2019-09-10 15:40:04 +00:00
}
2011-12-05 15:23:40 +00:00
else
2019-09-10 15:40:04 +00:00
{
//otherwise go for the latest frame we can.
2011-12-05 15:23:40 +00:00
servertime = cl . servertime ;
2019-09-10 15:40:04 +00:00
}
2011-12-05 15:23:40 +00:00
// servertime -= 0.1;
/*make sure we have some info for it, on failure keep the info from the last frame (its possible that the frame data can be changed by a network packet, but mneh, but chances are if there's no info then there are NO packets at all)*/
if ( ! CL_ChooseInterpolationFrames ( & newf , & oldf , servertime ) )
return ;
2011-12-23 14:36:25 +00:00
newff = newf ;
2011-12-05 15:23:40 +00:00
newf & = UPDATE_MASK ;
oldf & = UPDATE_MASK ;
/*transition the ents and stuff*/
2013-03-12 22:53:23 +00:00
packnew = & cl . inframes [ newf ] . packet_entities ;
packold = & cl . inframes [ oldf ] . packet_entities ;
2013-07-26 17:19:06 +00:00
if ( packnew - > servertime = = packold - > servertime )
2019-09-10 15:40:04 +00:00
frac = 1 ; //lerp totally into the new (avoid any division-by-0 issues here)
2013-07-26 17:19:06 +00:00
else
frac = ( servertime - packold - > servertime ) / ( packnew - > servertime - packold - > servertime ) ;
2012-01-28 10:30:44 +00:00
2014-03-30 08:55:06 +00:00
// if (!cl.paused)
2020-04-29 10:43:22 +00:00
// Con_DPrintf("%f %s%f^7 %f (%f) (%i) %f %s%f^7 %f\n", packold->servertime, (servertime<packold->servertime||packnew->servertime<servertime)?"^1":"",servertime, packnew->servertime, frac, newff, cl.oldgametime, (servertime<cl.oldgametime||cl.gametime<servertime)?"^3":"", servertime, cl.gametime);
2013-03-12 22:35:33 +00:00
2013-07-26 17:19:06 +00:00
CL_TransitionPacketEntities ( newff , packnew , packold , frac , servertime ) ;
2011-12-05 15:23:40 +00:00
2017-02-21 21:18:48 +00:00
for ( i = 0 ; i < cl . splitclients ; i + + )
{
VectorInterpolate ( packold - > punchangle [ i ] , frac , packnew - > punchangle [ i ] , cl . playerview [ i ] . punchangle_sv ) ;
VectorInterpolate ( packold - > punchorigin [ i ] , frac , packnew - > punchorigin [ i ] , cl . playerview [ i ] . punchorigin ) ;
}
2011-12-05 15:23:40 +00:00
/*and transition players too*/
{
float frac , a1 , a2 ;
2011-12-23 03:12:29 +00:00
int i , p ;
2011-12-05 15:23:40 +00:00
vec3_t move ;
lerpents_t * le ;
player_state_t * pnew , * pold ;
2013-07-26 17:19:06 +00:00
if ( ! cl . do_lerp_players )
2011-12-23 14:36:25 +00:00
{
newf = newff = oldf = cl . parsecount ;
newf & = UPDATE_MASK ;
oldf & = UPDATE_MASK ;
}
2011-12-05 15:23:40 +00:00
if ( packnew - > servertime = = packold - > servertime )
frac = 1 ; //lerp totally into the new
else
frac = ( servertime - packold - > servertime ) / ( packnew - > servertime - packold - > servertime ) ;
2013-03-12 22:53:23 +00:00
pnew = & cl . inframes [ newf ] . playerstate [ 0 ] ;
pold = & cl . inframes [ oldf ] . playerstate [ 0 ] ;
2011-12-23 03:12:29 +00:00
for ( p = 0 ; p < cl . allocated_client_slots ; p + + , pnew + + , pold + + )
2011-12-05 15:23:40 +00:00
{
2011-12-23 14:36:25 +00:00
if ( pnew - > messagenum ! = newff )
2012-02-12 05:18:31 +00:00
{
2011-12-23 03:12:29 +00:00
continue ;
2012-02-12 05:18:31 +00:00
}
2011-12-05 15:23:40 +00:00
le = & cl . lerpplayers [ p ] ;
2011-12-23 14:36:25 +00:00
VectorSubtract ( pnew - > predorigin , pold - > predorigin , move ) ;
2011-12-05 15:23:40 +00:00
2011-12-23 03:12:29 +00:00
if ( DotProduct ( move , move ) > 120 * 120 )
frac = 1 ;
2011-12-05 15:23:40 +00:00
//lerp based purely on the packet times,
for ( i = 0 ; i < 3 ; i + + )
{
2011-12-23 14:36:25 +00:00
le - > origin [ i ] = pold - > predorigin [ i ] + frac * ( move [ i ] ) ;
2011-12-05 15:23:40 +00:00
a1 = SHORT2ANGLE ( pold - > command . angles [ i ] ) ;
a2 = SHORT2ANGLE ( pnew - > command . angles [ i ] ) ;
if ( a1 - a2 > 180 )
a1 - = 360 ;
if ( a1 - a2 < - 180 )
a1 + = 360 ;
le - > angles [ i ] = a1 + frac * ( a2 - a1 ) ;
}
le - > orglerpdeltatime = 0.1 ;
le - > orglerpstarttime = packold - > servertime ;
}
}
}
2005-11-26 03:02:55 +00:00
void CL_LinkPacketEntities ( void )
{
2014-10-05 20:04:11 +00:00
extern cvar_t gl_part_flame ;
2005-11-26 03:02:55 +00:00
entity_t * ent ;
packet_entities_t * pack ;
entity_state_t * state ;
lerpents_t * le ;
2013-03-12 22:36:18 +00:00
model_t * model , * model2 ;
2005-11-26 03:02:55 +00:00
vec3_t old_origin ;
float autorotate ;
int i ;
2005-11-30 01:20:53 +00:00
int newpnum ;
2005-11-26 03:02:55 +00:00
//, spnum;
dlight_t * dl ;
vec3_t angles ;
2011-04-20 03:38:59 +00:00
static int flickertime ;
static int flicker ;
2014-10-05 20:04:11 +00:00
int trailef , trailidx ;
2013-03-12 22:44:00 +00:00
int modelflags ;
2015-08-07 17:49:49 +00:00
struct itemtimer_s * timer , * * timerlink ;
2019-02-16 19:09:07 +00:00
float timestep = cl . time - cl . lastlinktime ;
2019-07-02 04:12:20 +00:00
extern cvar_t r_ignoreentpvs ;
vec3_t absmin , absmax ;
2019-02-16 19:09:07 +00:00
cl . lastlinktime = cl . time ;
timestep = bound ( 0 , timestep , 0.1 ) ;
2005-11-26 03:02:55 +00:00
2011-12-05 15:23:40 +00:00
pack = cl . currentpackentities ;
2005-11-26 03:02:55 +00:00
if ( ! pack )
return ;
2011-12-05 15:23:40 +00:00
i = cl . currentpacktime * 20 ;
2011-04-20 03:38:59 +00:00
if ( flickertime ! = i )
2011-10-27 15:46:36 +00:00
{
flickertime = i ;
2011-04-20 03:38:59 +00:00
flicker = rand ( ) ;
2011-10-27 15:46:36 +00:00
}
2011-04-20 03:38:59 +00:00
2011-12-05 15:23:40 +00:00
autorotate = anglemod ( 100 * cl . currentpacktime ) ;
2005-11-26 03:02:55 +00:00
2009-04-02 22:25:54 +00:00
# ifdef CSQC_DAT
2011-12-05 15:23:40 +00:00
CSQC_DeltaStart ( cl . currentpacktime ) ;
2009-04-02 22:25:54 +00:00
# endif
2009-04-01 22:03:56 +00:00
2015-08-07 17:49:49 +00:00
for ( timerlink = & cl . itemtimers ; ( timer = * timerlink ) ; )
{
if ( cl . time > timer - > end )
{
* timerlink = timer - > next ;
Z_Free ( timer ) ;
}
else
{
timerlink = & ( * timerlink ) - > next ;
2015-10-27 15:20:15 +00:00
if ( timer - > entnum )
{
if ( timer - > entnum > = cl . maxlerpents )
continue ;
le = & cl . lerpents [ timer - > entnum ] ;
if ( le - > sequence ! = cl . lerpentssequence )
continue ;
2017-05-28 15:42:32 +00:00
// VectorCopy(le->origin, timer->origin);
2015-10-27 15:20:15 +00:00
}
2017-05-18 10:24:09 +00:00
R_AddItemTimer ( timer - > origin , cl . time * 90 + timer - > origin [ 0 ] + timer - > origin [ 1 ] + timer - > origin [ 2 ] , timer - > radius , ( cl . time - timer - > start ) / timer - > duration , timer - > rgb ) ;
2015-08-07 17:49:49 +00:00
}
}
2005-11-26 03:02:55 +00:00
for ( newpnum = 0 ; newpnum < pack - > num_entities ; newpnum + + )
{
state = & pack - > entities [ newpnum ] ;
2015-08-07 17:49:49 +00:00
# ifdef CSQC_DAT
if ( CSQC_DeltaUpdate ( state ) )
continue ;
# endif
2005-11-26 03:02:55 +00:00
------------------------------------------------------------------------
r4169 | acceptthis | 2013-01-17 08:55:12 +0000 (Thu, 17 Jan 2013) | 31 lines
removed MAX_VISEDICTS limit.
PEXT2_REPLACEMENTDELTAS tweaked, now has 4 million entity limit. still not enabled by default.
TE_BEAM now maps to a separate TEQW_BEAM to avoid conflicts with QW.
added android multitouch emulation for windows/rawinput (in_simulatemultitouch).
split topcolor/bottomcolor from scoreboard, for dp's colormap|1024 feature.
now using utf-8 for windows consoles.
qcc warnings/errors now give clickable console links for quick+easy editing.
disabled menutint when the currently active item changes contrast or gamma (for OneManClan).
Added support for drawfont/drawfontscale.
tweaked the qcvm a little to reduce the number of pointers.
.doll file loading. still experimental and will likely crash. requires csqc active, even if its a dummy progs. this will be fixed in time. Still other things that need cleaning up.
windows: gl_font "?" shows the standard windows font-selection dialog, and can be used to select windows fonts. not all work. and you probably don't want to use windings.
fixed splitscreen support when playing mvds. added mini-scoreboards to splitscreen.
editor/debugger now shows asm if there's no linenumber info. also, pressing f1 for help shows the shortcuts.
Added support for .framegroups files for psk(psa) and iqm formats.
True support for ezquake's colour codes. Mutually exclusive with background colours.
path command output slightly more readable.
added support for digest_hex (MD4, SHA1, CRC16).
skingroups now colourmap correctly.
Fix terrain colour hints, and litdata from the wrong bsp.
fix ftp dual-homed issue. support epsv command, and enable ipv6 (eprt still not supported).
remove d3d11 compilation from the makefile. the required headers are not provided by mingw, and are not available to the build bot, so don't bother.
fix v *= v.x and similar opcodes.
fteqcc: fixed support for áéíóú type chars in names. utf-8 files now properly supported (even with the utf-8 bom/identifier). utf-16 also supported.
fteqcc: fixed '#if 1 == 3 && 4' parsing.
fteqcc: -Werror acts on the warning, rather than as a separate error. Line numbers are thus more readable.
fteqcc: copyright message now includes compile date instead.
fteqccgui: the treeview control is now coloured depending on whether there were warnings/errors in the last compile.
fteqccgui: the output window is now focused and scrolls down as compilation progresses.
pr_dumpplatform command dumps out some pragmas to convert more serious warnings to errors. This is to avoid the infamous 'fteqcc sucks cos my code sucks' issue.
rewrote prespawn/modelist/soundlist code. server tracks progress now.
------------------------------------------------------------------------
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@4167 fc73d0e0-1445-4013-8a0c-d673dee63da5
2013-03-12 22:29:40 +00:00
if ( cl_numvisedicts = = cl_maxvisedicts )
2005-11-26 03:02:55 +00:00
break ;
2009-04-01 22:03:56 +00:00
2015-08-07 17:49:49 +00:00
if ( state - > number > = cl . maxlerpents )
2009-04-01 22:03:56 +00:00
continue ;
2015-08-07 17:49:49 +00:00
le = & cl . lerpents [ state - > number ] ;
2009-04-01 22:03:56 +00:00
2005-11-26 03:02:55 +00:00
ent = & cl_visedicts [ cl_numvisedicts ] ;
2019-04-07 16:41:09 +00:00
2014-01-16 06:47:33 +00:00
ent - > rtype = RT_MODEL ;
------------------------------------------------------------------------
r4169 | acceptthis | 2013-01-17 08:55:12 +0000 (Thu, 17 Jan 2013) | 31 lines
removed MAX_VISEDICTS limit.
PEXT2_REPLACEMENTDELTAS tweaked, now has 4 million entity limit. still not enabled by default.
TE_BEAM now maps to a separate TEQW_BEAM to avoid conflicts with QW.
added android multitouch emulation for windows/rawinput (in_simulatemultitouch).
split topcolor/bottomcolor from scoreboard, for dp's colormap|1024 feature.
now using utf-8 for windows consoles.
qcc warnings/errors now give clickable console links for quick+easy editing.
disabled menutint when the currently active item changes contrast or gamma (for OneManClan).
Added support for drawfont/drawfontscale.
tweaked the qcvm a little to reduce the number of pointers.
.doll file loading. still experimental and will likely crash. requires csqc active, even if its a dummy progs. this will be fixed in time. Still other things that need cleaning up.
windows: gl_font "?" shows the standard windows font-selection dialog, and can be used to select windows fonts. not all work. and you probably don't want to use windings.
fixed splitscreen support when playing mvds. added mini-scoreboards to splitscreen.
editor/debugger now shows asm if there's no linenumber info. also, pressing f1 for help shows the shortcuts.
Added support for .framegroups files for psk(psa) and iqm formats.
True support for ezquake's colour codes. Mutually exclusive with background colours.
path command output slightly more readable.
added support for digest_hex (MD4, SHA1, CRC16).
skingroups now colourmap correctly.
Fix terrain colour hints, and litdata from the wrong bsp.
fix ftp dual-homed issue. support epsv command, and enable ipv6 (eprt still not supported).
remove d3d11 compilation from the makefile. the required headers are not provided by mingw, and are not available to the build bot, so don't bother.
fix v *= v.x and similar opcodes.
fteqcc: fixed support for áéíóú type chars in names. utf-8 files now properly supported (even with the utf-8 bom/identifier). utf-16 also supported.
fteqcc: fixed '#if 1 == 3 && 4' parsing.
fteqcc: -Werror acts on the warning, rather than as a separate error. Line numbers are thus more readable.
fteqcc: copyright message now includes compile date instead.
fteqccgui: the treeview control is now coloured depending on whether there were warnings/errors in the last compile.
fteqccgui: the output window is now focused and scrolls down as compilation progresses.
pr_dumpplatform command dumps out some pragmas to convert more serious warnings to errors. This is to avoid the infamous 'fteqcc sucks cos my code sucks' issue.
rewrote prespawn/modelist/soundlist code. server tracks progress now.
------------------------------------------------------------------------
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@4167 fc73d0e0-1445-4013-8a0c-d673dee63da5
2013-03-12 22:29:40 +00:00
ent - > playerindex = - 1 ;
2014-03-30 08:55:06 +00:00
ent - > customskin = 0 ;
------------------------------------------------------------------------
r4169 | acceptthis | 2013-01-17 08:55:12 +0000 (Thu, 17 Jan 2013) | 31 lines
removed MAX_VISEDICTS limit.
PEXT2_REPLACEMENTDELTAS tweaked, now has 4 million entity limit. still not enabled by default.
TE_BEAM now maps to a separate TEQW_BEAM to avoid conflicts with QW.
added android multitouch emulation for windows/rawinput (in_simulatemultitouch).
split topcolor/bottomcolor from scoreboard, for dp's colormap|1024 feature.
now using utf-8 for windows consoles.
qcc warnings/errors now give clickable console links for quick+easy editing.
disabled menutint when the currently active item changes contrast or gamma (for OneManClan).
Added support for drawfont/drawfontscale.
tweaked the qcvm a little to reduce the number of pointers.
.doll file loading. still experimental and will likely crash. requires csqc active, even if its a dummy progs. this will be fixed in time. Still other things that need cleaning up.
windows: gl_font "?" shows the standard windows font-selection dialog, and can be used to select windows fonts. not all work. and you probably don't want to use windings.
fixed splitscreen support when playing mvds. added mini-scoreboards to splitscreen.
editor/debugger now shows asm if there's no linenumber info. also, pressing f1 for help shows the shortcuts.
Added support for .framegroups files for psk(psa) and iqm formats.
True support for ezquake's colour codes. Mutually exclusive with background colours.
path command output slightly more readable.
added support for digest_hex (MD4, SHA1, CRC16).
skingroups now colourmap correctly.
Fix terrain colour hints, and litdata from the wrong bsp.
fix ftp dual-homed issue. support epsv command, and enable ipv6 (eprt still not supported).
remove d3d11 compilation from the makefile. the required headers are not provided by mingw, and are not available to the build bot, so don't bother.
fix v *= v.x and similar opcodes.
fteqcc: fixed support for áéíóú type chars in names. utf-8 files now properly supported (even with the utf-8 bom/identifier). utf-16 also supported.
fteqcc: fixed '#if 1 == 3 && 4' parsing.
fteqcc: -Werror acts on the warning, rather than as a separate error. Line numbers are thus more readable.
fteqcc: copyright message now includes compile date instead.
fteqccgui: the treeview control is now coloured depending on whether there were warnings/errors in the last compile.
fteqccgui: the output window is now focused and scrolls down as compilation progresses.
pr_dumpplatform command dumps out some pragmas to convert more serious warnings to errors. This is to avoid the infamous 'fteqcc sucks cos my code sucks' issue.
rewrote prespawn/modelist/soundlist code. server tracks progress now.
------------------------------------------------------------------------
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@4167 fc73d0e0-1445-4013-8a0c-d673dee63da5
2013-03-12 22:29:40 +00:00
ent - > topcolour = TOP_DEFAULT ;
ent - > bottomcolour = BOTTOM_DEFAULT ;
2014-09-17 03:04:08 +00:00
# ifdef HEXEN2
------------------------------------------------------------------------
r4169 | acceptthis | 2013-01-17 08:55:12 +0000 (Thu, 17 Jan 2013) | 31 lines
removed MAX_VISEDICTS limit.
PEXT2_REPLACEMENTDELTAS tweaked, now has 4 million entity limit. still not enabled by default.
TE_BEAM now maps to a separate TEQW_BEAM to avoid conflicts with QW.
added android multitouch emulation for windows/rawinput (in_simulatemultitouch).
split topcolor/bottomcolor from scoreboard, for dp's colormap|1024 feature.
now using utf-8 for windows consoles.
qcc warnings/errors now give clickable console links for quick+easy editing.
disabled menutint when the currently active item changes contrast or gamma (for OneManClan).
Added support for drawfont/drawfontscale.
tweaked the qcvm a little to reduce the number of pointers.
.doll file loading. still experimental and will likely crash. requires csqc active, even if its a dummy progs. this will be fixed in time. Still other things that need cleaning up.
windows: gl_font "?" shows the standard windows font-selection dialog, and can be used to select windows fonts. not all work. and you probably don't want to use windings.
fixed splitscreen support when playing mvds. added mini-scoreboards to splitscreen.
editor/debugger now shows asm if there's no linenumber info. also, pressing f1 for help shows the shortcuts.
Added support for .framegroups files for psk(psa) and iqm formats.
True support for ezquake's colour codes. Mutually exclusive with background colours.
path command output slightly more readable.
added support for digest_hex (MD4, SHA1, CRC16).
skingroups now colourmap correctly.
Fix terrain colour hints, and litdata from the wrong bsp.
fix ftp dual-homed issue. support epsv command, and enable ipv6 (eprt still not supported).
remove d3d11 compilation from the makefile. the required headers are not provided by mingw, and are not available to the build bot, so don't bother.
fix v *= v.x and similar opcodes.
fteqcc: fixed support for áéíóú type chars in names. utf-8 files now properly supported (even with the utf-8 bom/identifier). utf-16 also supported.
fteqcc: fixed '#if 1 == 3 && 4' parsing.
fteqcc: -Werror acts on the warning, rather than as a separate error. Line numbers are thus more readable.
fteqcc: copyright message now includes compile date instead.
fteqccgui: the treeview control is now coloured depending on whether there were warnings/errors in the last compile.
fteqccgui: the output window is now focused and scrolls down as compilation progresses.
pr_dumpplatform command dumps out some pragmas to convert more serious warnings to errors. This is to avoid the infamous 'fteqcc sucks cos my code sucks' issue.
rewrote prespawn/modelist/soundlist code. server tracks progress now.
------------------------------------------------------------------------
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@4167 fc73d0e0-1445-4013-8a0c-d673dee63da5
2013-03-12 22:29:40 +00:00
ent - > h2playerclass = 0 ;
2014-09-17 03:04:08 +00:00
# endif
2011-04-30 17:21:10 +00:00
ent - > light_known = 0 ;
2005-11-26 03:02:55 +00:00
ent - > forcedshader = NULL ;
2015-09-07 14:34:39 +00:00
ent - > shaderTime = 0 ;
2005-11-26 03:02:55 +00:00
2008-12-23 02:55:20 +00:00
memset ( & ent - > framestate , 0 , sizeof ( ent - > framestate ) ) ;
2009-03-03 01:52:30 +00:00
VectorCopy ( le - > origin , ent - > origin ) ;
2005-11-26 03:02:55 +00:00
2009-11-04 21:16:50 +00:00
//bots or powerup glows. items always glow, bots can be disabled
if ( state - > modelindex ! = cl_playerindex | | r_powerupglow . ival )
Reworked client support for DPP5+. less code now, its much more graceful.
added waterfog command. waterfog overrides regular fog only when the view is in water.
fixed 64bit printf format specifiers. should work better on winxp64.
fixed some spec angle weirdness.
fixed viewsize 99.99 weirdness with ezhud.
fixed extra offset on the console (exhibited in 64bit builds, but not limited to).
fixed .avi playback, can now actually display frames again.
reimplemented line sparks.
fixed r_editlights_save flipping the light's pitch.
fixed issue with oggs failing to load.
fixed condump to cope with unicode properly.
made sv_bigcoords default except in quake. hexen2 kinda needs it for bsp angle precision.
fixed nq server to not stall weirdly on map changes.
fixed qwprogs svc_cdtrack not bugging out with nq clients on the server.
fixed restart command to load the last map run by the server, instead of start.bsp (when idle)
optimised d3d9 renderer a little. now uses less draw calls, especially with complex scenes. seems to get higher framerates than opengl now.
fixed d3d9 renderer to not bug out quite so much when run fullscreen (shader subsystem is now correctly initialised).
fixed a couple of bugs from font change. also now supports utf-8 in a few more places.
r_editlights_reload no longer generates rtlights inside the void. this resolves a few glitches (but should also help framerates a little).
fixed so corona-only lights won't generate shadowmaps and waste lots of time.
removed lots of #defines from qclib. I should never have made them in the first place, but I was lazy. obviously there's more left that I cba to remove yet.
fixed nested calls with variant-vectors. this fixes csaddon's light editor.
fixed qcc hc calling conventions using redundant stores.
disabled keywords can still be used by using __keyword instead.
fixed ftegccgui grep feature.
fixed motionless-dog qcc bug.
tweaked qcc warnings a little. -Wall is now a viable setting. you should be able to fix all those warnings.
fixed qw svc_intermission + dpp5+ clients bug.
fixed annoying spam about disconnecting in hexen2.
rewrote status command a little to cope with ipv6 addresses more gracefully
fixed significant stall when hibernating/debugging a server with a player sitting on it.
fixed truelightning.
fixed rocketlight overriding pflags.
fixed torches vanishing on vid_restart.
fixed issue with decal scaling.
fixed findentityfield builtin.
fixed fteqcc issue with ptr+1
fixed use of arrays inside class functions.
fixed/implemented fteqcc emulation of pointer opcodes.
added __inout keyword to fteqcc, so that it doesn't feel so horrendous.
fixed sizeof(*foo)
fixed *struct = struct;
fixed recursive structs.
fixed fteqcc warning report.
fixed sdl2 controller support, hopefully.
attempted to implement xinput, including per-player audio playback.
slightly fixed relaxed attitude to mouse focus when running fullscreen.
fixed weird warnings/errors with 'ent.arrayhead' terms. now generates sane errors.
implemented bindmaps (for csqc).
fixed crashing bug with eprint builtin.
implemented subset of music_playlist_* functionality. significant changes to music playback.
fixed some more dpcsqc compat.
fixed binds menu. now displays and accepts modifiers.
fixed issues with huge lightmaps.
fixed protocol determinism with dp clients connecting to fte servers. the initial getchallenge request now inhibits vanilla nq connection requests.
implemented support for 'dupe' userinfo key, allowing clients to request client->server packet duplication. should probably queue them tbh.
implemented sv_saveentfile command.
fixed resume after breaking inside a stepped-over function.
fixed erroneous footer after debugging.
(I wonder just how many things I broke with these fixes)
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@4946 fc73d0e0-1445-4013-8a0c-d673dee63da5
2015-07-26 10:56:18 +00:00
if ( state - > effects & ( EF_GREEN | EF_BLUE | EF_RED | EF_BRIGHTLIGHT | EF_DIMLIGHT ) )
2005-11-26 03:02:55 +00:00
{
2009-11-04 21:16:50 +00:00
vec3_t colour ;
float radius ;
colour [ 0 ] = 0 ;
colour [ 1 ] = 0 ;
colour [ 2 ] = 0 ;
radius = 0 ;
if ( state - > effects & EF_BRIGHTLIGHT )
{
2020-09-29 07:09:01 +00:00
radius = max ( radius , r_brightlight_colour . vec4 [ 3 ] ) ;
VectorAdd ( colour , r_brightlight_colour . vec4 , colour ) ;
2009-11-04 21:16:50 +00:00
}
if ( state - > effects & EF_DIMLIGHT )
{
2019-09-04 07:59:40 +00:00
radius = max ( radius , r_dimlight_colour . vec4 [ 3 ] ) ;
VectorAdd ( colour , r_dimlight_colour . vec4 , colour ) ;
2009-11-04 21:16:50 +00:00
}
if ( state - > effects & EF_BLUE )
{
2020-09-29 07:09:01 +00:00
radius = max ( radius , r_bluelight_colour . vec4 [ 3 ] ) ;
VectorAdd ( colour , r_bluelight_colour . vec4 , colour ) ;
2009-11-04 21:16:50 +00:00
}
if ( state - > effects & EF_RED )
{
2020-09-29 07:09:01 +00:00
radius = max ( radius , r_redlight_colour . vec4 [ 3 ] ) ;
VectorAdd ( colour , r_redlight_colour . vec4 , colour ) ;
2009-11-04 21:16:50 +00:00
}
Reworked client support for DPP5+. less code now, its much more graceful.
added waterfog command. waterfog overrides regular fog only when the view is in water.
fixed 64bit printf format specifiers. should work better on winxp64.
fixed some spec angle weirdness.
fixed viewsize 99.99 weirdness with ezhud.
fixed extra offset on the console (exhibited in 64bit builds, but not limited to).
fixed .avi playback, can now actually display frames again.
reimplemented line sparks.
fixed r_editlights_save flipping the light's pitch.
fixed issue with oggs failing to load.
fixed condump to cope with unicode properly.
made sv_bigcoords default except in quake. hexen2 kinda needs it for bsp angle precision.
fixed nq server to not stall weirdly on map changes.
fixed qwprogs svc_cdtrack not bugging out with nq clients on the server.
fixed restart command to load the last map run by the server, instead of start.bsp (when idle)
optimised d3d9 renderer a little. now uses less draw calls, especially with complex scenes. seems to get higher framerates than opengl now.
fixed d3d9 renderer to not bug out quite so much when run fullscreen (shader subsystem is now correctly initialised).
fixed a couple of bugs from font change. also now supports utf-8 in a few more places.
r_editlights_reload no longer generates rtlights inside the void. this resolves a few glitches (but should also help framerates a little).
fixed so corona-only lights won't generate shadowmaps and waste lots of time.
removed lots of #defines from qclib. I should never have made them in the first place, but I was lazy. obviously there's more left that I cba to remove yet.
fixed nested calls with variant-vectors. this fixes csaddon's light editor.
fixed qcc hc calling conventions using redundant stores.
disabled keywords can still be used by using __keyword instead.
fixed ftegccgui grep feature.
fixed motionless-dog qcc bug.
tweaked qcc warnings a little. -Wall is now a viable setting. you should be able to fix all those warnings.
fixed qw svc_intermission + dpp5+ clients bug.
fixed annoying spam about disconnecting in hexen2.
rewrote status command a little to cope with ipv6 addresses more gracefully
fixed significant stall when hibernating/debugging a server with a player sitting on it.
fixed truelightning.
fixed rocketlight overriding pflags.
fixed torches vanishing on vid_restart.
fixed issue with decal scaling.
fixed findentityfield builtin.
fixed fteqcc issue with ptr+1
fixed use of arrays inside class functions.
fixed/implemented fteqcc emulation of pointer opcodes.
added __inout keyword to fteqcc, so that it doesn't feel so horrendous.
fixed sizeof(*foo)
fixed *struct = struct;
fixed recursive structs.
fixed fteqcc warning report.
fixed sdl2 controller support, hopefully.
attempted to implement xinput, including per-player audio playback.
slightly fixed relaxed attitude to mouse focus when running fullscreen.
fixed weird warnings/errors with 'ent.arrayhead' terms. now generates sane errors.
implemented bindmaps (for csqc).
fixed crashing bug with eprint builtin.
implemented subset of music_playlist_* functionality. significant changes to music playback.
fixed some more dpcsqc compat.
fixed binds menu. now displays and accepts modifiers.
fixed issues with huge lightmaps.
fixed protocol determinism with dp clients connecting to fte servers. the initial getchallenge request now inhibits vanilla nq connection requests.
implemented support for 'dupe' userinfo key, allowing clients to request client->server packet duplication. should probably queue them tbh.
implemented sv_saveentfile command.
fixed resume after breaking inside a stepped-over function.
fixed erroneous footer after debugging.
(I wonder just how many things I broke with these fixes)
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@4946 fc73d0e0-1445-4013-8a0c-d673dee63da5
2015-07-26 10:56:18 +00:00
if ( state - > effects & EF_GREEN )
{
2020-09-29 07:09:01 +00:00
radius = max ( radius , r_greenlight_colour . vec4 [ 3 ] ) ;
VectorAdd ( colour , r_greenlight_colour . vec4 , colour ) ;
Reworked client support for DPP5+. less code now, its much more graceful.
added waterfog command. waterfog overrides regular fog only when the view is in water.
fixed 64bit printf format specifiers. should work better on winxp64.
fixed some spec angle weirdness.
fixed viewsize 99.99 weirdness with ezhud.
fixed extra offset on the console (exhibited in 64bit builds, but not limited to).
fixed .avi playback, can now actually display frames again.
reimplemented line sparks.
fixed r_editlights_save flipping the light's pitch.
fixed issue with oggs failing to load.
fixed condump to cope with unicode properly.
made sv_bigcoords default except in quake. hexen2 kinda needs it for bsp angle precision.
fixed nq server to not stall weirdly on map changes.
fixed qwprogs svc_cdtrack not bugging out with nq clients on the server.
fixed restart command to load the last map run by the server, instead of start.bsp (when idle)
optimised d3d9 renderer a little. now uses less draw calls, especially with complex scenes. seems to get higher framerates than opengl now.
fixed d3d9 renderer to not bug out quite so much when run fullscreen (shader subsystem is now correctly initialised).
fixed a couple of bugs from font change. also now supports utf-8 in a few more places.
r_editlights_reload no longer generates rtlights inside the void. this resolves a few glitches (but should also help framerates a little).
fixed so corona-only lights won't generate shadowmaps and waste lots of time.
removed lots of #defines from qclib. I should never have made them in the first place, but I was lazy. obviously there's more left that I cba to remove yet.
fixed nested calls with variant-vectors. this fixes csaddon's light editor.
fixed qcc hc calling conventions using redundant stores.
disabled keywords can still be used by using __keyword instead.
fixed ftegccgui grep feature.
fixed motionless-dog qcc bug.
tweaked qcc warnings a little. -Wall is now a viable setting. you should be able to fix all those warnings.
fixed qw svc_intermission + dpp5+ clients bug.
fixed annoying spam about disconnecting in hexen2.
rewrote status command a little to cope with ipv6 addresses more gracefully
fixed significant stall when hibernating/debugging a server with a player sitting on it.
fixed truelightning.
fixed rocketlight overriding pflags.
fixed torches vanishing on vid_restart.
fixed issue with decal scaling.
fixed findentityfield builtin.
fixed fteqcc issue with ptr+1
fixed use of arrays inside class functions.
fixed/implemented fteqcc emulation of pointer opcodes.
added __inout keyword to fteqcc, so that it doesn't feel so horrendous.
fixed sizeof(*foo)
fixed *struct = struct;
fixed recursive structs.
fixed fteqcc warning report.
fixed sdl2 controller support, hopefully.
attempted to implement xinput, including per-player audio playback.
slightly fixed relaxed attitude to mouse focus when running fullscreen.
fixed weird warnings/errors with 'ent.arrayhead' terms. now generates sane errors.
implemented bindmaps (for csqc).
fixed crashing bug with eprint builtin.
implemented subset of music_playlist_* functionality. significant changes to music playback.
fixed some more dpcsqc compat.
fixed binds menu. now displays and accepts modifiers.
fixed issues with huge lightmaps.
fixed protocol determinism with dp clients connecting to fte servers. the initial getchallenge request now inhibits vanilla nq connection requests.
implemented support for 'dupe' userinfo key, allowing clients to request client->server packet duplication. should probably queue them tbh.
implemented sv_saveentfile command.
fixed resume after breaking inside a stepped-over function.
fixed erroneous footer after debugging.
(I wonder just how many things I broke with these fixes)
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@4946 fc73d0e0-1445-4013-8a0c-d673dee63da5
2015-07-26 10:56:18 +00:00
}
2009-11-04 21:16:50 +00:00
if ( radius )
{
2011-04-20 03:38:59 +00:00
radius + = r_lightflicker . value ? ( ( flicker + state - > number ) & 31 ) : 0 ;
2013-03-12 22:53:23 +00:00
CL_NewDlight ( state - > number , ent - > origin , radius , 0.1 , colour [ 0 ] , colour [ 1 ] , colour [ 2 ] ) ;
2009-11-04 21:16:50 +00:00
}
2005-11-26 03:02:55 +00:00
}
2019-01-29 07:18:07 +00:00
if ( ( state - > lightpflags & ( PFLAGS_FULLDYNAMIC | PFLAGS_CORONA ) ) & & ( ( state - > lightpflags & PFLAGS_FULLDYNAMIC ) | | state - > light [ 3 ] ) )
2010-08-28 17:14:38 +00:00
{
vec3_t colour ;
2010-10-02 02:25:39 +00:00
if ( ! state - > light [ 0 ] & & ! state - > light [ 1 ] & & ! state - > light [ 2 ] )
2010-08-28 17:14:38 +00:00
{
colour [ 0 ] = colour [ 1 ] = colour [ 2 ] = 1 ;
}
else
{
colour [ 0 ] = state - > light [ 0 ] / 1024.0f ;
colour [ 1 ] = state - > light [ 1 ] / 1024.0f ;
colour [ 2 ] = state - > light [ 2 ] / 1024.0f ;
}
2013-03-12 22:53:23 +00:00
dl = CL_NewDlight ( state - > number , ent - > origin , state - > light [ 3 ] ? state - > light [ 3 ] : 350 , 0.1 , colour [ 0 ] , colour [ 1 ] , colour [ 2 ] ) ;
2014-04-12 03:30:27 +00:00
if ( ! ( state - > lightpflags & PFLAGS_FULLDYNAMIC ) ) //corona-only lights shouldn't do much else.
2014-04-03 02:16:21 +00:00
{
dl - > flags & = ~ ( LFLAG_LIGHTMAP | LFLAG_FLASHBLEND ) ;
2014-04-03 02:39:51 +00:00
# ifdef RTLIGHTS
2014-04-03 02:16:21 +00:00
/*make sure there's no rtlight*/
memset ( dl - > lightcolourscales , 0 , sizeof ( dl - > lightcolourscales ) ) ;
2014-04-03 02:39:51 +00:00
# endif
2014-04-03 02:16:21 +00:00
}
2012-01-01 02:26:42 +00:00
dl - > corona = ( state - > lightpflags & PFLAGS_CORONA ) ? 1 : 0 ;
dl - > coronascale = 0.25 ;
2013-10-29 17:38:22 +00:00
dl - > style = state - > lightstyle ;
2012-01-01 02:26:42 +00:00
dl - > flags & = ~ LFLAG_FLASHBLEND ;
dl - > flags | = ( state - > lightpflags & PFLAGS_NOSHADOW ) ? LFLAG_NOSHADOWS : 0 ;
2014-10-05 20:04:11 +00:00
# ifdef RTLIGHTS
2012-01-01 02:26:42 +00:00
if ( state - > skinnum )
{
2014-10-05 20:04:11 +00:00
VectorCopy ( le - > angles , angles ) ;
//if (model && model->type == mod_alias)
2020-10-06 03:17:28 +00:00
AngleVectorsMesh ( angles , dl - > axis [ 0 ] , dl - > axis [ 1 ] , dl - > axis [ 2 ] ) ; //pflags matches alias models.
//else
// AngleVectors(angles, dl->axis[0], dl->axis[1], dl->axis[2]);
2012-01-01 02:26:42 +00:00
VectorInverse ( dl - > axis [ 1 ] ) ;
2014-10-05 20:04:11 +00:00
R_LoadNumberedLightTexture ( dl , state - > skinnum ) ;
2012-01-01 02:26:42 +00:00
}
2014-10-05 20:04:11 +00:00
# endif
2010-08-28 17:14:38 +00:00
}
2005-11-26 03:02:55 +00:00
// if set to invisible, skip
2020-04-19 01:23:32 +00:00
if ( state - > modelindex < 1 | | ( state - > effects & NQEF_NODRAW ) )
2005-11-26 03:02:55 +00:00
{
2017-06-21 01:24:25 +00:00
if ( state - > tagindex = = 0xffff )
{
if ( state - > tagentity )
{
ent - > rtype = RT_PORTALCAMERA ;
ent - > keynum = state - > tagentity ;
}
else
{
ent - > rtype = RT_PORTALSURFACE ;
VectorCopy ( ent - > origin , ent - > oldorigin ) ;
}
}
else
continue ;
model = NULL ;
2013-03-12 22:44:00 +00:00
modelflags = state - > effects > > 24 ;
2017-06-21 01:24:25 +00:00
}
2013-03-12 22:44:00 +00:00
else
2017-06-21 01:24:25 +00:00
{
if ( CL_FilterModelindex ( state - > modelindex , state - > frame ) )
continue ;
model = cl . model_precache [ state - > modelindex ] ;
if ( ! model )
{
Con_DPrintf ( " Bad modelindex (%i) \n " , state - > modelindex ) ;
continue ;
}
//DP extension. .modelflags (which is sent in the high parts of effects) allows to specify exactly the q1-compatible flags.
//the extra bit allows for setting to 0.
//note that hexen2 has additional flags which cannot be expressed.
if ( state - > effects & 0xff800000 )
modelflags = state - > effects > > 24 ;
else
modelflags = model - > flags ;
}
2005-11-26 03:02:55 +00:00
2019-04-16 22:40:05 +00:00
# ifdef HAVE_LEGACY
2016-07-12 00:40:13 +00:00
if ( cl . model_precache_vwep [ 0 ] & & state - > modelindex2 < MAX_VWEP_MODELS )
2013-03-12 22:36:18 +00:00
{
2016-07-12 00:40:13 +00:00
if ( state - > modelindex = = cl_playerindex & & cl . model_precache_vwep [ 0 ] - > loadstate = = MLS_LOADED & &
cl . model_precache_vwep [ state - > modelindex2 ] & & cl . model_precache_vwep [ state - > modelindex2 ] - > loadstate = = MLS_LOADED )
2013-03-12 22:36:18 +00:00
{
model = cl . model_precache_vwep [ 0 ] ;
model2 = cl . model_precache_vwep [ state - > modelindex2 ] ;
}
else
model2 = NULL ;
}
2018-09-01 04:18:08 +00:00
else
# endif
if ( state - > modelindex2 & & state - > modelindex2 < MAX_PRECACHE_MODELS )
2013-03-12 22:36:18 +00:00
model2 = cl . model_precache [ state - > modelindex2 ] ;
else
model2 = NULL ;
2019-07-02 04:12:20 +00:00
if ( r_ignoreentpvs . ival | | ! model )
{
ent - > pvscache . num_leafs = 0 ;
# if defined(Q2BSPS) || defined(Q3BSPS) || defined(TERRAIN)
ent - > pvscache . areanum = 0 ;
ent - > pvscache . areanum2 = 0 ;
ent - > pvscache . headnode = 0 ;
# endif
}
else
{
/*bsp model size*/
Too many changes, sorry.
Change revision displays, use the SVN commit date instead of using __DATE__ (when there's no local changes). This should allow reproducible builds.
Added s_al_disable cvar, to block openal and all the various problems people have had with it, without having to name an explicit fallback (which would vary by system).
Add mastervolume cvar (for ss).
Add r_shadows 2 (aka fake shadows - for ss).
Add scr_loadingscreen_aspect -1 setting, to disable levelshots entirely, also disables the progress bar (for ss).
Better support for some effectinfo hacks (for ss).
Added dpcompat_nocsqcwarnings (because of lazy+buggy mods like ss).
Rework the dpcsqc versions of project+unproject builtins for better compat (for ss).
Added dpcompat_csqcinputeventtypes to block unexpected csqc input events (for ss).
Better compat with DP's loadfont console command (for ss).
Added dpcompat_smallerfonts cvar to replicate a DP bug (for ss).
Detect dp's m_draw extension, to work around it (for ss).
Cvar dpcompat_ignoremodificationtimes added. A value of 0 favour the most recently modified file, 1 will use DP-like alphabetically sorted preferences (for ss).
loadfont builtin can now accept outline=1 in the sizes arg for slightly more readable fonts.
Fix bbox calcs for rotated entities, fix needed for r_ignorenetpvs 0.
Hackily parse emoji.json to provide :poop: etc suggestions.
Skip prediction entirely when there's no local entity info. This fixes stair-smoothing in xonotic.
screenshot_cubemap will now capture half-float images when saving to ktx or dds files.
Fix support for xcf files larger than 4gb, mostly to avoid compiler warnings.
Fixed size of gfx/loading.lmp when replacement textures are used.
Added mipmap support for rg8 and l8a8 textures.
r_hdr_framebuffer cvar updated to support format names instead of random negative numbers. Description updated to name some interesting ones.
Perform autoupdate _checks_ ONLY with explicit user confirmation (actual updating already needed user confirmation, but this extra step should reduce the chances of us getting wrongly accused of exfiltrating user data if we're run in a sandbox - we ONLY ever included the updating engine's version in the checks, though there's nothing we can do to avoid sending the user's router's IP).
Removed the 'summon satan all over your harddrive' quit message, in case paranoid security researchers are idiots and don't bother doing actual research.
Removed the triptohell.info and fte.triptohell.info certificates, they really need to stop being self-signed. The updates domain is still self-signed for autoupdates.
Video drivers are now able to report supported video resolutions, visible to menuqc. Currently only works with SDL2 builds.
Added setmousepos builtin. Should work with glx+win32 build.
VF_SKYROOM_CAMERA can now accept an extra two args, setviewprop(VF_SKYROOM_CAMERA, org, axis, degrees).
Removed v_skyroom_origin+v_skyroom_orientation cvars in favour just v_skyroom, which should make it behave more like the 'fog' command (used when csqc isn't overriding).
Added R_EndPolygonRibbon builtin to make it faster+easier to generate textured ribbon/cable/etc wide lines (for TW).
sdl: Fix up sys_sdl.c's file enumeration to support wildcards in directories.
edit command now displays end1.bin/end2.bin correctly, because we can.
Finally add support for f_modified - though ruleset_allow_larger_models and ruleset_allow_overlong_sounds generally make it redundant.
Fix threading race condition in sha1 lookups.
Updated f_ruleset to include the same extra flags reported by ezquake.
A mod's default.fmf file can now contain an eg 'mainconfig config.cfg' line (to explicitly set the main config saved with cfg_save_auto 1 etc).
fmf: basegame steam:GameName/GameDir can be used to try to load a mod directory from an installed steam game. The resulting gamedir will be read-only.
HOMEDIR CHANGE: use homedirs only if the basedir cannot be written or a homedir already exists, which should further reduce the probability of microsoft randomly uploading our data to their cloud (but mostly because its annoying to never know where your data is written).
Fixed buf_cvarlist, should work in xonotic now, and without segfaults.
Added an extra arg to URI_Get_Callback calls - the response size, also changed the tempstring to contain all bytes of the response, you need to be careful about nulls though.
Try to work around nvidia's forced-panning bug on x11 when changing video modes. This might screw with other programs.
sdl: support custom icons.
sdl: support choosing a specific display.
Added some documentation to menuqc builtins.
menusys: use outlines for slightly more readable fonts.
menusys: switch vid_width and vid_height combos into a single video mode combo to set both according to reported video modes.
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@5581 fc73d0e0-1445-4013-8a0c-d673dee63da5
2019-11-20 03:09:50 +00:00
if ( model - > type = = mod_brush & & ( state - > angles [ 0 ] | | state - > angles [ 1 ] | | state - > angles [ 2 ] ) )
{
int i ;
float v ;
float max ;
//q2 method, works best with origin brushes.
max = 0 ;
for ( i = 0 ; i < 3 ; i + + )
{
v = fabs ( model - > mins [ i ] ) ;
if ( v > max )
max = v ;
v = fabs ( model - > maxs [ i ] ) ;
if ( v > max )
max = v ;
}
for ( i = 0 ; i < 3 ; i + + )
{
absmin [ i ] = ent - > origin [ i ] - max ;
absmax [ i ] = ent - > origin [ i ] + max ;
}
}
else
{
VectorAdd ( model - > mins , ent - > origin , absmin ) ;
VectorAdd ( model - > maxs , ent - > origin , absmax ) ;
}
2019-07-02 04:12:20 +00:00
cl . worldmodel - > funcs . FindTouchedLeafs ( cl . worldmodel , & ent - > pvscache , absmin , absmax ) ;
}
2005-11-26 03:02:55 +00:00
cl_numvisedicts + + ;
ent - > forcedshader = NULL ;
ent - > keynum = state - > number ;
2013-12-12 12:39:34 +00:00
if ( cl_r2g . value & & state - > modelindex = = cl_rocketindex & & cl_rocketindex ! = - 1 & & cl_grenadeindex ! = - 1 )
model = cl . model_precache [ cl_grenadeindex ] ;
ent - > model = model ;
2005-11-26 03:02:55 +00:00
------------------------------------------------------------------------
r4169 | acceptthis | 2013-01-17 08:55:12 +0000 (Thu, 17 Jan 2013) | 31 lines
removed MAX_VISEDICTS limit.
PEXT2_REPLACEMENTDELTAS tweaked, now has 4 million entity limit. still not enabled by default.
TE_BEAM now maps to a separate TEQW_BEAM to avoid conflicts with QW.
added android multitouch emulation for windows/rawinput (in_simulatemultitouch).
split topcolor/bottomcolor from scoreboard, for dp's colormap|1024 feature.
now using utf-8 for windows consoles.
qcc warnings/errors now give clickable console links for quick+easy editing.
disabled menutint when the currently active item changes contrast or gamma (for OneManClan).
Added support for drawfont/drawfontscale.
tweaked the qcvm a little to reduce the number of pointers.
.doll file loading. still experimental and will likely crash. requires csqc active, even if its a dummy progs. this will be fixed in time. Still other things that need cleaning up.
windows: gl_font "?" shows the standard windows font-selection dialog, and can be used to select windows fonts. not all work. and you probably don't want to use windings.
fixed splitscreen support when playing mvds. added mini-scoreboards to splitscreen.
editor/debugger now shows asm if there's no linenumber info. also, pressing f1 for help shows the shortcuts.
Added support for .framegroups files for psk(psa) and iqm formats.
True support for ezquake's colour codes. Mutually exclusive with background colours.
path command output slightly more readable.
added support for digest_hex (MD4, SHA1, CRC16).
skingroups now colourmap correctly.
Fix terrain colour hints, and litdata from the wrong bsp.
fix ftp dual-homed issue. support epsv command, and enable ipv6 (eprt still not supported).
remove d3d11 compilation from the makefile. the required headers are not provided by mingw, and are not available to the build bot, so don't bother.
fix v *= v.x and similar opcodes.
fteqcc: fixed support for áéíóú type chars in names. utf-8 files now properly supported (even with the utf-8 bom/identifier). utf-16 also supported.
fteqcc: fixed '#if 1 == 3 && 4' parsing.
fteqcc: -Werror acts on the warning, rather than as a separate error. Line numbers are thus more readable.
fteqcc: copyright message now includes compile date instead.
fteqccgui: the treeview control is now coloured depending on whether there were warnings/errors in the last compile.
fteqccgui: the output window is now focused and scrolls down as compilation progresses.
pr_dumpplatform command dumps out some pragmas to convert more serious warnings to errors. This is to avoid the infamous 'fteqcc sucks cos my code sucks' issue.
rewrote prespawn/modelist/soundlist code. server tracks progress now.
------------------------------------------------------------------------
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@4167 fc73d0e0-1445-4013-8a0c-d673dee63da5
2013-03-12 22:29:40 +00:00
ent - > flags = 0 ;
2013-06-23 02:17:02 +00:00
if ( ( state - > dpflags & RENDER_EXTERIORMODEL ) | | r_refdef . playerview - > viewentity = = state - > number )
2014-03-31 17:06:41 +00:00
ent - > flags | = RF_EXTERNALMODEL ;
2016-07-12 00:40:13 +00:00
if ( state - > dpflags & RENDER_VIEWMODEL )
{
ent - > flags | = RF_WEAPONMODEL | Q2RF_MINLIGHT | RF_DEPTHHACK ;
if ( state - > effects & DPEF_NOGUNBOB )
ent - > flags | = RF_WEAPONMODELNOBOB ;
}
2009-11-04 21:16:50 +00:00
if ( state - > effects & NQEF_ADDITIVE )
2014-03-31 17:06:41 +00:00
ent - > flags | = RF_ADDITIVE ;
2005-11-26 03:02:55 +00:00
if ( state - > effects & EF_NODEPTHTEST )
ent - > flags | = RF_NODEPTHTEST ;
2016-01-18 05:22:07 +00:00
if ( state - > effects & EF_NOSHADOW )
2011-10-27 15:46:36 +00:00
ent - > flags | = RF_NOSHADOW ;
2016-12-09 09:09:12 +00:00
if ( state - > trans < 0xfe )
{
ent - > shaderRGBAf [ 3 ] = state - > trans / ( float ) 0xfe ;
2014-03-31 17:06:41 +00:00
ent - > flags | = RF_TRANSLUCENT ;
2016-12-09 09:09:12 +00:00
}
else
ent - > shaderRGBAf [ 3 ] = 1 ;
2005-11-26 03:02:55 +00:00
2012-05-14 01:41:08 +00:00
/* if (le->origin[2] < r_refdef.waterheight != le->lastorigin[2] < r_refdef.waterheight)
{
P_RunParticleEffectTypeString ( le - > origin , NULL , 1 , " te_watertransition " ) ;
}
*/
2005-11-26 03:02:55 +00:00
// set colormap
------------------------------------------------------------------------
r4169 | acceptthis | 2013-01-17 08:55:12 +0000 (Thu, 17 Jan 2013) | 31 lines
removed MAX_VISEDICTS limit.
PEXT2_REPLACEMENTDELTAS tweaked, now has 4 million entity limit. still not enabled by default.
TE_BEAM now maps to a separate TEQW_BEAM to avoid conflicts with QW.
added android multitouch emulation for windows/rawinput (in_simulatemultitouch).
split topcolor/bottomcolor from scoreboard, for dp's colormap|1024 feature.
now using utf-8 for windows consoles.
qcc warnings/errors now give clickable console links for quick+easy editing.
disabled menutint when the currently active item changes contrast or gamma (for OneManClan).
Added support for drawfont/drawfontscale.
tweaked the qcvm a little to reduce the number of pointers.
.doll file loading. still experimental and will likely crash. requires csqc active, even if its a dummy progs. this will be fixed in time. Still other things that need cleaning up.
windows: gl_font "?" shows the standard windows font-selection dialog, and can be used to select windows fonts. not all work. and you probably don't want to use windings.
fixed splitscreen support when playing mvds. added mini-scoreboards to splitscreen.
editor/debugger now shows asm if there's no linenumber info. also, pressing f1 for help shows the shortcuts.
Added support for .framegroups files for psk(psa) and iqm formats.
True support for ezquake's colour codes. Mutually exclusive with background colours.
path command output slightly more readable.
added support for digest_hex (MD4, SHA1, CRC16).
skingroups now colourmap correctly.
Fix terrain colour hints, and litdata from the wrong bsp.
fix ftp dual-homed issue. support epsv command, and enable ipv6 (eprt still not supported).
remove d3d11 compilation from the makefile. the required headers are not provided by mingw, and are not available to the build bot, so don't bother.
fix v *= v.x and similar opcodes.
fteqcc: fixed support for áéíóú type chars in names. utf-8 files now properly supported (even with the utf-8 bom/identifier). utf-16 also supported.
fteqcc: fixed '#if 1 == 3 && 4' parsing.
fteqcc: -Werror acts on the warning, rather than as a separate error. Line numbers are thus more readable.
fteqcc: copyright message now includes compile date instead.
fteqccgui: the treeview control is now coloured depending on whether there were warnings/errors in the last compile.
fteqccgui: the output window is now focused and scrolls down as compilation progresses.
pr_dumpplatform command dumps out some pragmas to convert more serious warnings to errors. This is to avoid the infamous 'fteqcc sucks cos my code sucks' issue.
rewrote prespawn/modelist/soundlist code. server tracks progress now.
------------------------------------------------------------------------
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@4167 fc73d0e0-1445-4013-8a0c-d673dee63da5
2013-03-12 22:29:40 +00:00
if ( state - > dpflags & RENDER_COLORMAPPED )
2005-11-26 03:02:55 +00:00
{
------------------------------------------------------------------------
r4169 | acceptthis | 2013-01-17 08:55:12 +0000 (Thu, 17 Jan 2013) | 31 lines
removed MAX_VISEDICTS limit.
PEXT2_REPLACEMENTDELTAS tweaked, now has 4 million entity limit. still not enabled by default.
TE_BEAM now maps to a separate TEQW_BEAM to avoid conflicts with QW.
added android multitouch emulation for windows/rawinput (in_simulatemultitouch).
split topcolor/bottomcolor from scoreboard, for dp's colormap|1024 feature.
now using utf-8 for windows consoles.
qcc warnings/errors now give clickable console links for quick+easy editing.
disabled menutint when the currently active item changes contrast or gamma (for OneManClan).
Added support for drawfont/drawfontscale.
tweaked the qcvm a little to reduce the number of pointers.
.doll file loading. still experimental and will likely crash. requires csqc active, even if its a dummy progs. this will be fixed in time. Still other things that need cleaning up.
windows: gl_font "?" shows the standard windows font-selection dialog, and can be used to select windows fonts. not all work. and you probably don't want to use windings.
fixed splitscreen support when playing mvds. added mini-scoreboards to splitscreen.
editor/debugger now shows asm if there's no linenumber info. also, pressing f1 for help shows the shortcuts.
Added support for .framegroups files for psk(psa) and iqm formats.
True support for ezquake's colour codes. Mutually exclusive with background colours.
path command output slightly more readable.
added support for digest_hex (MD4, SHA1, CRC16).
skingroups now colourmap correctly.
Fix terrain colour hints, and litdata from the wrong bsp.
fix ftp dual-homed issue. support epsv command, and enable ipv6 (eprt still not supported).
remove d3d11 compilation from the makefile. the required headers are not provided by mingw, and are not available to the build bot, so don't bother.
fix v *= v.x and similar opcodes.
fteqcc: fixed support for áéíóú type chars in names. utf-8 files now properly supported (even with the utf-8 bom/identifier). utf-16 also supported.
fteqcc: fixed '#if 1 == 3 && 4' parsing.
fteqcc: -Werror acts on the warning, rather than as a separate error. Line numbers are thus more readable.
fteqcc: copyright message now includes compile date instead.
fteqccgui: the treeview control is now coloured depending on whether there were warnings/errors in the last compile.
fteqccgui: the output window is now focused and scrolls down as compilation progresses.
pr_dumpplatform command dumps out some pragmas to convert more serious warnings to errors. This is to avoid the infamous 'fteqcc sucks cos my code sucks' issue.
rewrote prespawn/modelist/soundlist code. server tracks progress now.
------------------------------------------------------------------------
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@4167 fc73d0e0-1445-4013-8a0c-d673dee63da5
2013-03-12 22:29:40 +00:00
ent - > topcolour = ( state - > colormap > > 4 ) & 0xf ;
ent - > bottomcolour = ( state - > colormap > > 0 ) & 0xf ;
2005-11-26 03:02:55 +00:00
}
2013-12-02 14:30:30 +00:00
else if ( state - > colormap > 0 & & state - > colormap < = cl . allocated_client_slots )
2005-11-26 03:02:55 +00:00
{
2013-03-12 22:35:33 +00:00
ent - > playerindex = state - > colormap - 1 ;
2014-10-11 22:16:40 +00:00
# ifdef HEXEN2
2014-10-11 19:39:45 +00:00
ent - > h2playerclass = cl . players [ ent - > playerindex ] . h2playerclass ;
2014-10-11 22:16:40 +00:00
# endif
2018-03-04 14:41:16 +00:00
ent - > topcolour = cl . players [ ent - > playerindex ] . dtopcolor ;
ent - > bottomcolour = cl . players [ ent - > playerindex ] . dbottomcolor ;
2005-11-26 03:02:55 +00:00
}
// set skin
ent - > skinnum = state - > skinnum ;
2017-02-19 00:15:42 +00:00
# ifdef HEXEN2
2005-11-26 03:02:55 +00:00
ent - > abslight = state - > abslight ;
ent - > drawflags = state - > hexen2flags ;
2017-02-19 00:15:42 +00:00
# endif
2005-11-26 03:02:55 +00:00
2016-07-12 00:40:13 +00:00
CL_LerpNetFrameState ( & ent - > framestate , le ) ;
2005-11-26 03:02:55 +00:00
# ifdef PEXT_SCALE
//set scale
ent - > scale = state - > scale / 16.0 ;
# endif
2015-04-14 23:12:17 +00:00
if ( state - > colormod [ 0 ] = = 32 & & state - > colormod [ 1 ] = = 32 & & state - > colormod [ 2 ] = = 32 )
ent - > shaderRGBAf [ 0 ] = ent - > shaderRGBAf [ 1 ] = ent - > shaderRGBAf [ 2 ] = 1 ;
else
{
ent - > flags | = RF_FORCECOLOURMOD ;
ent - > shaderRGBAf [ 0 ] = ( state - > colormod [ 0 ] * 8.0f ) / 256 ;
ent - > shaderRGBAf [ 1 ] = ( state - > colormod [ 1 ] * 8.0f ) / 256 ;
ent - > shaderRGBAf [ 2 ] = ( state - > colormod [ 2 ] * 8.0f ) / 256 ;
}
2018-12-06 07:11:04 +00:00
if ( state - > colormod [ 0 ] = = 32 & & state - > colormod [ 1 ] = = 32 & & state - > colormod [ 2 ] = = 32 )
VectorSet ( ent - > glowmod , 1 , 1 , 1 ) ;
else
VectorScale ( state - > glowmod , 1 / 255.0 , ent - > glowmod ) ;
2012-02-12 05:18:31 +00:00
2005-11-26 03:02:55 +00:00
# ifdef PEXT_FATNESS
//set trans
2009-07-05 18:45:53 +00:00
ent - > fatness = state - > fatness / 16.0 ;
2005-11-26 03:02:55 +00:00
# endif
2015-08-10 18:28:23 +00:00
//swap items with sprites if desired.
if ( gl_simpleitems . ival & & ent - > skinnum > = 0 & & ent - > skinnum < countof ( model - > simpleskin ) & & model )
{
if ( ! model - > simpleskin [ ent - > skinnum ] )
{
char basename [ 64 ] , name [ MAX_QPATH ] ;
COM_FileBase ( model - > name , basename , sizeof ( basename ) ) ;
if ( ! strncmp ( model - > name , " maps/ " , 5 ) )
Q_snprintfz ( name , sizeof ( name ) , " textures/bmodels/simple_%s_%i.tga " , basename , ent - > skinnum ) ;
else
Q_snprintfz ( name , sizeof ( name ) , " textures/models/simple_%s_%i.tga " , basename , ent - > skinnum ) ;
2019-05-23 15:11:32 +00:00
model - > simpleskin [ ent - > skinnum ] = R_RegisterShader ( name , 0 , va ( " { \n nomipmaps \n program defaultsprite#MASK=0.5 \n surfaceparm noshadows \n surfaceparm nodlight \n sort seethrough \n { \n map \" %s \" \n alphafunc ge128 \n } \n } \n " , name ) ) ;
2015-08-10 18:28:23 +00:00
}
VectorCopy ( le - > angles , angles ) ;
if ( R_GetShaderSizes ( model - > simpleskin [ ent - > skinnum ] , NULL , NULL , false ) > 0 )
{
float tr [ 2 ] ;
ent - > forcedshader = model - > simpleskin [ ent - > skinnum ] ;
ent - > rtype = RT_SPRITE ;
ent - > scale * = 16 ;
tr [ 0 ] = sin ( le - > angles [ 1 ] * M_PI / 180.0 ) ;
tr [ 1 ] = cos ( le - > angles [ 1 ] * M_PI / 180.0 ) ;
ent - > origin [ 1 ] + = tr [ 0 ] * ( model - > maxs [ 0 ] + model - > mins [ 0 ] ) * 0.5 + tr [ 1 ] * ( model - > maxs [ 1 ] + model - > mins [ 1 ] ) * 0.5 ;
ent - > origin [ 0 ] + = tr [ 1 ] * ( model - > maxs [ 1 ] + model - > mins [ 1 ] ) * 0.5 - tr [ 0 ] * ( model - > maxs [ 0 ] + model - > mins [ 0 ] ) * 0.5 ;
ent - > origin [ 2 ] + = model - > mins [ 2 ] ;
ent - > origin [ 2 ] + = ent - > scale ;
if ( cl_item_bobbing . value )
ent - > origin [ 2 ] + = 5 + sin ( cl . time * 3 + ( ent - > origin [ 0 ] + ent - > origin [ 1 ] ) / 8 ) * 5.5 ; //don't let it into the ground
}
else if ( modelflags & MF_ROTATE )
{ //surely there's a more sane way to handle this.
angles [ 0 ] = 0 ;
angles [ 1 ] = autorotate ;
angles [ 2 ] = 0 ;
if ( cl_item_bobbing . value )
ent - > origin [ 2 ] + = 5 + sin ( cl . time * 3 + ( state - > origin [ 0 ] + state - > origin [ 1 ] ) / 8 ) * 5.5 ; //don't let it into the ground
}
}
// rotate pickup objects locally
else if ( modelflags & MF_ROTATE )
2005-11-26 03:02:55 +00:00
{
angles [ 0 ] = 0 ;
angles [ 1 ] = autorotate ;
angles [ 2 ] = 0 ;
if ( cl_item_bobbing . value )
2011-04-30 17:21:10 +00:00
ent - > origin [ 2 ] + = 5 + sin ( cl . time * 3 + ( state - > origin [ 0 ] + state - > origin [ 1 ] ) / 8 ) * 5.5 ; //don't let it into the ground
2005-11-26 03:02:55 +00:00
}
else
{
for ( i = 0 ; i < 3 ; i + + )
{
angles [ i ] = le - > angles [ i ] ;
}
}
2015-01-12 12:28:13 +00:00
VectorCopy ( angles , ent - > angles ) ;
2021-04-14 05:21:04 +00:00
if ( model - > type = = mod_alias )
AngleVectorsMesh ( angles , ent - > axis [ 0 ] , ent - > axis [ 1 ] , ent - > axis [ 2 ] ) ;
else
AngleVectors ( angles , ent - > axis [ 0 ] , ent - > axis [ 1 ] , ent - > axis [ 2 ] ) ;
2005-11-26 03:02:55 +00:00
VectorInverse ( ent - > axis [ 1 ] ) ;
2012-02-12 05:18:31 +00:00
/*if this entity is in a player's slot...*/
2011-04-25 03:25:22 +00:00
if ( ent - > keynum < = cl . allocated_client_slots )
2009-04-01 22:03:56 +00:00
{
2013-06-23 02:17:02 +00:00
if ( ! cl . playerview [ 0 ] . nolocalplayer )
2009-04-01 22:03:56 +00:00
ent - > keynum + = MAX_EDICTS ;
}
2005-11-26 03:02:55 +00:00
2017-06-21 01:24:25 +00:00
if ( state - > tagindex = = 0xffff )
{
if ( state - > tagentity )
{
ent - > rtype = RT_PORTALCAMERA ;
ent - > keynum = state - > tagentity ;
}
else
{
ent - > rtype = RT_PORTALSURFACE ;
VectorCopy ( ent - > origin , ent - > oldorigin ) ;
}
}
else if ( state - > tagentity )
2005-11-26 03:02:55 +00:00
{ //ent is attached to a tag, rotate this ent accordingly.
CL_RotateAroundTag ( ent , state - > number , state - > tagentity , state - > tagindex ) ;
}
2014-08-03 14:47:47 +00:00
# ifdef RAGDOLL
2016-07-12 00:40:13 +00:00
if ( model & & ( model - > dollinfo | | le - > skeletalobject ) )
2017-01-13 00:39:50 +00:00
rag_updatedeltaent ( & csqc_world , ent , le ) ;
2015-02-02 08:01:53 +00:00
# endif
2014-08-03 14:47:47 +00:00
ent - > framestate . g [ FS_REG ] . frame [ 0 ] & = ~ 0x8000 ;
ent - > framestate . g [ FS_REG ] . frame [ 1 ] & = ~ 0x8000 ;
2011-04-30 17:21:10 +00:00
CLQ1_AddShadow ( ent ) ;
2011-04-25 03:25:22 +00:00
CLQ1_AddPowerupShell ( ent , false , state - > effects ) ;
2012-07-21 04:43:31 +00:00
if ( r_torch . ival & & ent - > keynum < = cl . allocated_client_slots )
{
dlight_t * dl ;
dl = CL_NewDlight ( ent - > keynum , ent - > origin , 300 , r_torch . ival , 0.9 , 0.9 , 0.6 ) ;
dl - > flags | = LFLAG_SHADOWMAP | LFLAG_FLASHBLEND ;
dl - > fov = 90 ;
angles [ 0 ] * = 3 ;
// angles[1] += sin(realtime)*8;
// angles[0] += cos(realtime*1.13)*5;
AngleVectors ( angles , dl - > axis [ 0 ] , dl - > axis [ 1 ] , dl - > axis [ 2 ] ) ;
2012-08-04 01:35:52 +00:00
VectorMA ( dl - > origin , 16 , dl - > axis [ 0 ] , dl - > origin ) ;
2012-07-21 04:43:31 +00:00
}
2013-03-12 22:36:18 +00:00
if ( model2 )
CL_AddVWeapModel ( ent , model2 ) ;
2015-03-03 07:54:10 +00:00
//figure out which trail this entity is using
2017-06-21 01:24:25 +00:00
if ( model )
{
trailef = model - > particletrail ;
trailidx = model - > traildefaultindex ;
}
else
{
trailef = P_INVALID ;
trailidx = P_INVALID ;
}
2021-05-09 13:00:43 +00:00
if ( ( state - > effects & EF_HASPARTICLETRAIL ) | | modelflags )
2015-03-03 07:54:10 +00:00
P_DefaultTrail ( state - > effects , modelflags , & trailef , & trailidx ) ;
if ( state - > u . q1 . traileffectnum )
trailef = CL_TranslateParticleFromServer ( state - > u . q1 . traileffectnum ) ;
2016-10-22 07:06:51 +00:00
if ( state - > u . q1 . emiteffectnum )
P_EmitEffect ( ent - > origin , ent - > axis , MDLF_EMITFORWARDS , CL_TranslateParticleFromServer ( state - > u . q1 . emiteffectnum ) , & ( le - > emitstate ) ) ;
2017-06-21 01:24:25 +00:00
else if ( model & & model - > particleeffect ! = P_INVALID & & cls . allow_anyparticles & & gl_part_flame . ival )
2016-10-22 07:06:51 +00:00
P_EmitEffect ( ent - > origin , ent - > axis , model - > engineflags , model - > particleeffect , & ( le - > emitstate ) ) ;
2005-11-26 03:02:55 +00:00
// add automatic particle trails
2015-03-03 07:54:10 +00:00
if ( ! model | | ( ! ( modelflags & ~ MF_ROTATE ) & & trailef < 0 ) )
2005-11-26 03:02:55 +00:00
continue ;
2013-03-12 22:44:00 +00:00
if ( ! cls . allow_anyparticles & & ! ( modelflags & ~ MF_ROTATE ) )
2005-11-26 03:02:55 +00:00
continue ;
2011-04-30 17:21:10 +00:00
if ( le - > isnew )
2005-11-26 03:02:55 +00:00
{
2011-12-05 15:23:40 +00:00
le - > isnew = false ;
2008-11-09 22:29:28 +00:00
pe - > DelinkTrailstate ( & ( cl . lerpents [ state - > number ] . trailstate ) ) ;
pe - > DelinkTrailstate ( & ( cl . lerpents [ state - > number ] . emitstate ) ) ;
2005-11-26 03:02:55 +00:00
continue ; // not in last message
}
2011-04-30 17:21:10 +00:00
VectorCopy ( le - > lastorigin , old_origin ) ;
2005-11-26 03:02:55 +00:00
for ( i = 0 ; i < 3 ; i + + )
2005-11-26 23:23:03 +00:00
{
2016-07-12 00:40:13 +00:00
if ( fabs ( old_origin [ i ] - ent - > origin [ i ] ) > 128 )
2005-11-26 03:02:55 +00:00
{ // no trail if too far
VectorCopy ( ent - > origin , old_origin ) ;
break ;
}
2005-11-26 23:23:03 +00:00
}
2005-11-26 03:02:55 +00:00
2014-10-05 20:04:11 +00:00
//and emit it
2016-07-12 00:40:13 +00:00
// if (lasttime != cl.currentpacktime)
{
2019-01-29 07:18:07 +00:00
if ( trailef = = P_INVALID | | pe - > ParticleTrail ( old_origin , ent - > origin , trailef , timestep , ent - > keynum , ent - > axis , & ( le - > trailstate ) ) )
2016-07-12 00:40:13 +00:00
if ( model - > traildefaultindex > = 0 )
2019-01-29 07:18:07 +00:00
pe - > ParticleTrailIndex ( old_origin , ent - > origin , P_INVALID , timestep , trailidx , 0 , & ( le - > trailstate ) ) ;
2016-07-12 00:40:13 +00:00
//dlights are not so customisable.
if ( r_rocketlight . value & & ( modelflags & MF_ROCKET ) & & ! ( state - > lightpflags & ( PFLAGS_FULLDYNAMIC | PFLAGS_CORONA ) ) )
{
float rad = 0 ;
2019-09-04 07:59:40 +00:00
extern cvar_t r_rocketlight_colour ;
rad = r_rocketlight_colour . vec4 [ 3 ] ;
2016-07-12 00:40:13 +00:00
rad + = r_lightflicker . value ? ( ( flicker + state - > number ) & 31 ) : 0 ;
dl = CL_AllocDlight ( state - > number ) ;
memcpy ( dl - > axis , ent - > axis , sizeof ( dl - > axis ) ) ;
VectorCopy ( ent - > origin , dl - > origin ) ;
dl - > die = ( float ) cl . time ;
if ( modelflags & MF_ROCKET )
dl - > origin [ 2 ] + = 1 ; // is this even necessary
dl - > radius = rad * r_rocketlight . value ;
2019-09-04 07:59:40 +00:00
VectorCopy ( r_rocketlight_colour . vec4 , dl - > color ) ;
2016-07-12 00:40:13 +00:00
}
2005-11-26 03:02:55 +00:00
}
}
2009-04-02 22:25:54 +00:00
# ifdef CSQC_DAT
2009-04-06 00:34:32 +00:00
CSQC_DeltaEnd ( ) ;
2009-04-02 22:25:54 +00:00
# endif
2012-02-12 05:18:31 +00:00
CLQ1_AddVisibleBBoxes ( ) ;
2018-11-19 06:37:25 +00:00
# ifdef RTLIGHTS
R_EditLights_DrawLights ( ) ;
# endif
2005-11-26 03:02:55 +00:00
}
2004-08-23 00:15:46 +00:00
/*
= = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = =
PROJECTILE PARSING / LINKING
= = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = =
*/
typedef struct
{
int modelindex ;
vec3_t origin ;
vec3_t angles ;
} projectile_t ;
# define MAX_PROJECTILES 32
projectile_t cl_projectiles [ MAX_PROJECTILES ] ;
int cl_num_projectiles ;
extern int cl_spikeindex ;
void CL_ClearProjectiles ( void )
{
cl_num_projectiles = 0 ;
}
/*
= = = = = = = = = = = = = = = = = = = = =
CL_ParseProjectiles
Nails are passed as efficient temporary entities
= = = = = = = = = = = = = = = = = = = = =
*/
2004-12-08 04:14:52 +00:00
void CL_ParseProjectiles ( int modelindex , qboolean nails2 )
2004-08-23 00:15:46 +00:00
{
int i , c , j ;
qbyte bits [ 6 ] ;
projectile_t * pr ;
c = MSG_ReadByte ( ) ;
for ( i = 0 ; i < c ; i + + )
{
2004-12-08 04:14:52 +00:00
if ( nails2 )
MSG_ReadByte ( ) ;
2004-08-23 00:15:46 +00:00
for ( j = 0 ; j < 6 ; j + + )
bits [ j ] = MSG_ReadByte ( ) ;
if ( cl_num_projectiles = = MAX_PROJECTILES )
continue ;
pr = & cl_projectiles [ cl_num_projectiles ] ;
cl_num_projectiles + + ;
pr - > modelindex = modelindex ;
pr - > origin [ 0 ] = ( ( bits [ 0 ] + ( ( bits [ 1 ] & 15 ) < < 8 ) ) < < 1 ) - 4096 ;
pr - > origin [ 1 ] = ( ( ( bits [ 1 ] > > 4 ) + ( bits [ 2 ] < < 4 ) ) < < 1 ) - 4096 ;
pr - > origin [ 2 ] = ( ( bits [ 3 ] + ( ( bits [ 4 ] & 15 ) < < 8 ) ) < < 1 ) - 4096 ;
2009-11-04 21:16:50 +00:00
pr - > angles [ 0 ] = 360 * ( ( ( int ) bits [ 4 ] > > 4 ) / 16.0f + 1 / 32.0f ) ;
2004-12-24 08:45:56 +00:00
pr - > angles [ 1 ] = 360 * ( int ) bits [ 5 ] / 256.0f ;
2004-08-23 00:15:46 +00:00
}
}
/*
= = = = = = = = = = = = =
CL_LinkProjectiles
= = = = = = = = = = = = =
*/
void CL_LinkProjectiles ( void )
{
int i ;
projectile_t * pr ;
entity_t * ent ;
for ( i = 0 , pr = cl_projectiles ; i < cl_num_projectiles ; i + + , pr + + )
{
2014-10-20 03:14:00 +00:00
if ( pr - > modelindex < 1 )
continue ;
2004-08-23 00:15:46 +00:00
// grab an entity to fill in
------------------------------------------------------------------------
r4169 | acceptthis | 2013-01-17 08:55:12 +0000 (Thu, 17 Jan 2013) | 31 lines
removed MAX_VISEDICTS limit.
PEXT2_REPLACEMENTDELTAS tweaked, now has 4 million entity limit. still not enabled by default.
TE_BEAM now maps to a separate TEQW_BEAM to avoid conflicts with QW.
added android multitouch emulation for windows/rawinput (in_simulatemultitouch).
split topcolor/bottomcolor from scoreboard, for dp's colormap|1024 feature.
now using utf-8 for windows consoles.
qcc warnings/errors now give clickable console links for quick+easy editing.
disabled menutint when the currently active item changes contrast or gamma (for OneManClan).
Added support for drawfont/drawfontscale.
tweaked the qcvm a little to reduce the number of pointers.
.doll file loading. still experimental and will likely crash. requires csqc active, even if its a dummy progs. this will be fixed in time. Still other things that need cleaning up.
windows: gl_font "?" shows the standard windows font-selection dialog, and can be used to select windows fonts. not all work. and you probably don't want to use windings.
fixed splitscreen support when playing mvds. added mini-scoreboards to splitscreen.
editor/debugger now shows asm if there's no linenumber info. also, pressing f1 for help shows the shortcuts.
Added support for .framegroups files for psk(psa) and iqm formats.
True support for ezquake's colour codes. Mutually exclusive with background colours.
path command output slightly more readable.
added support for digest_hex (MD4, SHA1, CRC16).
skingroups now colourmap correctly.
Fix terrain colour hints, and litdata from the wrong bsp.
fix ftp dual-homed issue. support epsv command, and enable ipv6 (eprt still not supported).
remove d3d11 compilation from the makefile. the required headers are not provided by mingw, and are not available to the build bot, so don't bother.
fix v *= v.x and similar opcodes.
fteqcc: fixed support for áéíóú type chars in names. utf-8 files now properly supported (even with the utf-8 bom/identifier). utf-16 also supported.
fteqcc: fixed '#if 1 == 3 && 4' parsing.
fteqcc: -Werror acts on the warning, rather than as a separate error. Line numbers are thus more readable.
fteqcc: copyright message now includes compile date instead.
fteqccgui: the treeview control is now coloured depending on whether there were warnings/errors in the last compile.
fteqccgui: the output window is now focused and scrolls down as compilation progresses.
pr_dumpplatform command dumps out some pragmas to convert more serious warnings to errors. This is to avoid the infamous 'fteqcc sucks cos my code sucks' issue.
rewrote prespawn/modelist/soundlist code. server tracks progress now.
------------------------------------------------------------------------
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@4167 fc73d0e0-1445-4013-8a0c-d673dee63da5
2013-03-12 22:29:40 +00:00
if ( cl_numvisedicts = = cl_maxvisedicts )
2004-08-23 00:15:46 +00:00
break ; // object list is full
ent = & cl_visedicts [ cl_numvisedicts ] ;
cl_numvisedicts + + ;
2014-10-20 03:14:00 +00:00
memset ( ent , 0 , sizeof ( * ent ) ) ;
2004-08-23 00:15:46 +00:00
ent - > model = cl . model_precache [ pr - > modelindex ] ;
------------------------------------------------------------------------
r4169 | acceptthis | 2013-01-17 08:55:12 +0000 (Thu, 17 Jan 2013) | 31 lines
removed MAX_VISEDICTS limit.
PEXT2_REPLACEMENTDELTAS tweaked, now has 4 million entity limit. still not enabled by default.
TE_BEAM now maps to a separate TEQW_BEAM to avoid conflicts with QW.
added android multitouch emulation for windows/rawinput (in_simulatemultitouch).
split topcolor/bottomcolor from scoreboard, for dp's colormap|1024 feature.
now using utf-8 for windows consoles.
qcc warnings/errors now give clickable console links for quick+easy editing.
disabled menutint when the currently active item changes contrast or gamma (for OneManClan).
Added support for drawfont/drawfontscale.
tweaked the qcvm a little to reduce the number of pointers.
.doll file loading. still experimental and will likely crash. requires csqc active, even if its a dummy progs. this will be fixed in time. Still other things that need cleaning up.
windows: gl_font "?" shows the standard windows font-selection dialog, and can be used to select windows fonts. not all work. and you probably don't want to use windings.
fixed splitscreen support when playing mvds. added mini-scoreboards to splitscreen.
editor/debugger now shows asm if there's no linenumber info. also, pressing f1 for help shows the shortcuts.
Added support for .framegroups files for psk(psa) and iqm formats.
True support for ezquake's colour codes. Mutually exclusive with background colours.
path command output slightly more readable.
added support for digest_hex (MD4, SHA1, CRC16).
skingroups now colourmap correctly.
Fix terrain colour hints, and litdata from the wrong bsp.
fix ftp dual-homed issue. support epsv command, and enable ipv6 (eprt still not supported).
remove d3d11 compilation from the makefile. the required headers are not provided by mingw, and are not available to the build bot, so don't bother.
fix v *= v.x and similar opcodes.
fteqcc: fixed support for áéíóú type chars in names. utf-8 files now properly supported (even with the utf-8 bom/identifier). utf-16 also supported.
fteqcc: fixed '#if 1 == 3 && 4' parsing.
fteqcc: -Werror acts on the warning, rather than as a separate error. Line numbers are thus more readable.
fteqcc: copyright message now includes compile date instead.
fteqccgui: the treeview control is now coloured depending on whether there were warnings/errors in the last compile.
fteqccgui: the output window is now focused and scrolls down as compilation progresses.
pr_dumpplatform command dumps out some pragmas to convert more serious warnings to errors. This is to avoid the infamous 'fteqcc sucks cos my code sucks' issue.
rewrote prespawn/modelist/soundlist code. server tracks progress now.
------------------------------------------------------------------------
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@4167 fc73d0e0-1445-4013-8a0c-d673dee63da5
2013-03-12 22:29:40 +00:00
ent - > playerindex = - 1 ;
ent - > topcolour = TOP_DEFAULT ;
ent - > bottomcolour = BOTTOM_DEFAULT ;
2015-09-01 04:45:15 +00:00
ent - > framestate . g [ FS_REG ] . lerpweight [ 0 ] = 1 ;
2014-10-20 03:14:00 +00:00
2004-08-23 00:15:46 +00:00
# ifdef PEXT_SCALE
ent - > scale = 1 ;
# endif
2006-02-27 00:42:25 +00:00
ent - > shaderRGBAf [ 0 ] = 1 ;
ent - > shaderRGBAf [ 1 ] = 1 ;
ent - > shaderRGBAf [ 2 ] = 1 ;
ent - > shaderRGBAf [ 3 ] = 1 ;
2011-05-29 04:26:29 +00:00
2004-08-23 00:15:46 +00:00
VectorCopy ( pr - > origin , ent - > origin ) ;
VectorCopy ( pr - > angles , ent - > angles ) ;
2004-12-24 08:45:56 +00:00
2020-10-06 03:17:28 +00:00
AngleVectorsMesh ( ent - > angles , ent - > axis [ 0 ] , ent - > axis [ 1 ] , ent - > axis [ 2 ] ) ;
2004-12-24 08:45:56 +00:00
VectorInverse ( ent - > axis [ 1 ] ) ;
2004-08-23 00:15:46 +00:00
}
}
//========================================
2005-01-17 17:40:37 +00:00
extern int cl_spikeindex , cl_playerindex , cl_flagindex , cl_rocketindex , cl_grenadeindex ;
2004-08-23 00:15:46 +00:00
entity_t * CL_NewTempEntity ( void ) ;
static int MVD_TranslateFlags ( int src )
{
int dst = 0 ;
if ( src & DF_EFFECTS )
dst | = PF_EFFECTS ;
if ( src & DF_SKINNUM )
dst | = PF_SKINNUM ;
if ( src & DF_DEAD )
dst | = PF_DEAD ;
if ( src & DF_GIB )
dst | = PF_GIB ;
if ( src & DF_WEAPONFRAME )
dst | = PF_WEAPONFRAME ;
if ( src & DF_MODEL )
dst | = PF_MODEL ;
return dst ;
}
/*
= = = = = = = = = = = = = = = = = = =
CL_ParsePlayerinfo
= = = = = = = = = = = = = = = = = = =
*/
2005-04-26 16:04:12 +00:00
extern int parsecountmod , oldparsecountmod ;
2004-08-23 00:15:46 +00:00
extern double parsecounttime ;
int lastplayerinfo ;
2012-01-24 04:24:14 +00:00
void CL_ParseClientdata ( void ) ;
void CL_MVDUpdateSpectator ( void )
{
CL_ParseClientdata ( ) ;
}
2017-12-28 16:24:50 +00:00
void CLQW_ParsePlayerinfo ( void )
2004-08-23 00:15:46 +00:00
{
2015-06-05 09:04:05 +00:00
float msec ;
2004-08-23 00:15:46 +00:00
unsigned int flags ;
player_info_t * info ;
2005-04-26 16:04:12 +00:00
player_state_t * state , * oldstate ;
2004-08-23 00:15:46 +00:00
int num ;
int i ;
2006-06-02 17:42:36 +00:00
int newf ;
2012-01-24 04:24:14 +00:00
vec3_t org , dist ;
2004-08-23 00:15:46 +00:00
lastplayerinfo = num = MSG_ReadByte ( ) ;
if ( num > = MAX_CLIENTS )
Host_EndGame ( " CL_ParsePlayerinfo: bad num " ) ;
info = & cl . players [ num ] ;
2013-03-12 22:53:23 +00:00
oldstate = & cl . inframes [ oldparsecountmod ] . playerstate [ num ] ;
state = & cl . inframes [ parsecountmod ] . playerstate [ num ] ;
2004-08-23 00:15:46 +00:00
2008-01-09 00:52:31 +00:00
if ( cls . demoplayback = = DPB_MVD | | cls . demoplayback = = DPB_EZTV )
2004-08-23 00:15:46 +00:00
{
2020-02-11 18:06:10 +00:00
player_state_t dummy ;
2004-08-23 00:15:46 +00:00
if ( ! cl . parsecount | | info - > prevcount > cl . parsecount | | cl . parsecount - info - > prevcount > = UPDATE_BACKUP - 1 )
{
memset ( & dummy , 0 , sizeof ( dummy ) ) ;
2020-02-11 18:06:10 +00:00
oldstate = & dummy ;
2004-08-23 00:15:46 +00:00
}
else
{
2020-02-11 18:06:10 +00:00
oldstate = & cl . inframes [ info - > prevcount & UPDATE_MASK ] . playerstate [ num ] ;
2004-08-23 00:15:46 +00:00
}
2020-02-11 18:06:10 +00:00
memcpy ( state , oldstate , sizeof ( player_state_t ) ) ;
2004-08-27 00:37:05 +00:00
info - > prevcount = cl . parsecount ;
2004-08-23 00:15:46 +00:00
2015-09-01 04:45:15 +00:00
# ifdef QUAKESTATS
2005-11-30 01:20:53 +00:00
if ( cls . findtrack & & info - > stats [ STAT_HEALTH ] > 0 )
2015-06-22 11:49:15 +00:00
{ //FIXME: is this still needed with the autotrack stuff?
2013-06-23 02:17:02 +00:00
Cam_Lock ( & cl . playerview [ 0 ] , num ) ;
2004-08-23 00:15:46 +00:00
cls . findtrack = false ;
}
2015-09-01 04:45:15 +00:00
# endif
2005-11-30 01:20:53 +00:00
2004-08-23 00:15:46 +00:00
flags = MSG_ReadShort ( ) ;
state - > flags = MVD_TranslateFlags ( flags ) ;
state - > messagenum = cl . parsecount ;
state - > command . msec = 0 ;
state - > frame = MSG_ReadByte ( ) ;
state - > state_time = parsecounttime ;
state - > command . msec = 0 ;
for ( i = 0 ; i < 3 ; i + + )
{
2014-12-02 02:00:41 +00:00
if ( flags & ( DF_ORIGINX < < i ) )
2019-03-23 07:06:37 +00:00
{
if ( cls . ezprotocolextensions1 & EZPEXT1_FLOATENTCOORDS )
state - > origin [ i ] = MSG_ReadCoordFloat ( ) ;
else
state - > origin [ i ] = MSG_ReadCoord ( ) ;
}
2004-08-23 00:15:46 +00:00
}
2020-02-11 18:06:10 +00:00
VectorSubtract ( state - > origin , oldstate - > origin , dist ) ;
2013-03-12 22:53:23 +00:00
VectorScale ( dist , 1 / ( cl . inframes [ parsecountmod ] . packet_entities . servertime - cl . inframes [ oldparsecountmod ] . packet_entities . servertime ) , state - > velocity ) ;
2012-01-24 04:24:14 +00:00
VectorCopy ( state - > origin , state - > predorigin ) ;
2004-08-23 00:15:46 +00:00
for ( i = 0 ; i < 3 ; i + + )
{
2014-12-02 02:00:41 +00:00
if ( flags & ( DF_ANGLEX < < i ) )
2004-08-27 00:37:05 +00:00
{
state - > command . angles [ i ] = MSG_ReadShort ( ) ;
}
state - > viewangles [ i ] = state - > command . angles [ i ] * ( 360.0 / 65536 ) ;
2004-08-23 00:15:46 +00:00
}
if ( flags & DF_MODEL )
state - > modelindex = MSG_ReadByte ( ) ;
if ( flags & DF_SKINNUM )
state - > skinnum = MSG_ReadByte ( ) ;
if ( flags & DF_EFFECTS )
state - > effects = MSG_ReadByte ( ) ;
if ( flags & DF_WEAPONFRAME )
state - > weaponframe = MSG_ReadByte ( ) ;
2012-02-12 05:18:31 +00:00
VectorSet ( state - > szmins , - 16 , - 16 , - 24 ) ;
VectorSet ( state - > szmaxs , 16 , 16 , 32 ) ;
2010-11-20 22:01:16 +00:00
state - > scale = 1 ;
2006-02-27 00:42:25 +00:00
state - > alpha = 255 ;
2004-08-23 00:15:46 +00:00
state - > fatness = 0 ;
2006-03-06 18:53:09 +00:00
state - > colourmod [ 0 ] = 32 ;
state - > colourmod [ 1 ] = 32 ;
state - > colourmod [ 2 ] = 32 ;
2012-07-05 19:42:36 +00:00
state - > gravitydir [ 0 ] = 0 ;
state - > gravitydir [ 1 ] = 0 ;
state - > gravitydir [ 2 ] = - 1 ;
2004-08-27 00:37:05 +00:00
state - > pm_type = PM_NORMAL ;
2020-04-19 01:23:32 +00:00
# ifdef QUAKESTATS
2005-04-26 16:04:12 +00:00
TP_ParsePlayerInfo ( oldstate , state , info ) ;
2005-06-07 04:40:16 +00:00
2012-11-27 03:23:19 +00:00
//can't CL_SetStatInt as we don't know if its actually us or not
2012-02-14 15:50:34 +00:00
cl . players [ num ] . stats [ STAT_WEAPONFRAME ] = state - > weaponframe ;
cl . players [ num ] . statsf [ STAT_WEAPONFRAME ] = state - > weaponframe ;
for ( i = 0 ; i < cl . splitclients ; i + + )
{
2013-06-23 02:17:02 +00:00
playerview_t * pv = & cl . playerview [ i ] ;
if ( pv - > cam_spec_track = = num )
2012-02-14 15:50:34 +00:00
{
2013-06-23 02:17:02 +00:00
pv - > stats [ STAT_WEAPONFRAME ] = state - > weaponframe ;
pv - > statsf [ STAT_WEAPONFRAME ] = state - > weaponframe ;
2012-02-14 15:50:34 +00:00
}
}
2015-09-01 04:45:15 +00:00
# endif
2012-02-14 15:50:34 +00:00
2013-06-23 02:17:02 +00:00
//add a new splitscreen autotrack view if we can
------------------------------------------------------------------------
r4169 | acceptthis | 2013-01-17 08:55:12 +0000 (Thu, 17 Jan 2013) | 31 lines
removed MAX_VISEDICTS limit.
PEXT2_REPLACEMENTDELTAS tweaked, now has 4 million entity limit. still not enabled by default.
TE_BEAM now maps to a separate TEQW_BEAM to avoid conflicts with QW.
added android multitouch emulation for windows/rawinput (in_simulatemultitouch).
split topcolor/bottomcolor from scoreboard, for dp's colormap|1024 feature.
now using utf-8 for windows consoles.
qcc warnings/errors now give clickable console links for quick+easy editing.
disabled menutint when the currently active item changes contrast or gamma (for OneManClan).
Added support for drawfont/drawfontscale.
tweaked the qcvm a little to reduce the number of pointers.
.doll file loading. still experimental and will likely crash. requires csqc active, even if its a dummy progs. this will be fixed in time. Still other things that need cleaning up.
windows: gl_font "?" shows the standard windows font-selection dialog, and can be used to select windows fonts. not all work. and you probably don't want to use windings.
fixed splitscreen support when playing mvds. added mini-scoreboards to splitscreen.
editor/debugger now shows asm if there's no linenumber info. also, pressing f1 for help shows the shortcuts.
Added support for .framegroups files for psk(psa) and iqm formats.
True support for ezquake's colour codes. Mutually exclusive with background colours.
path command output slightly more readable.
added support for digest_hex (MD4, SHA1, CRC16).
skingroups now colourmap correctly.
Fix terrain colour hints, and litdata from the wrong bsp.
fix ftp dual-homed issue. support epsv command, and enable ipv6 (eprt still not supported).
remove d3d11 compilation from the makefile. the required headers are not provided by mingw, and are not available to the build bot, so don't bother.
fix v *= v.x and similar opcodes.
fteqcc: fixed support for áéíóú type chars in names. utf-8 files now properly supported (even with the utf-8 bom/identifier). utf-16 also supported.
fteqcc: fixed '#if 1 == 3 && 4' parsing.
fteqcc: -Werror acts on the warning, rather than as a separate error. Line numbers are thus more readable.
fteqcc: copyright message now includes compile date instead.
fteqccgui: the treeview control is now coloured depending on whether there were warnings/errors in the last compile.
fteqccgui: the output window is now focused and scrolls down as compilation progresses.
pr_dumpplatform command dumps out some pragmas to convert more serious warnings to errors. This is to avoid the infamous 'fteqcc sucks cos my code sucks' issue.
rewrote prespawn/modelist/soundlist code. server tracks progress now.
------------------------------------------------------------------------
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@4167 fc73d0e0-1445-4013-8a0c-d673dee63da5
2013-03-12 22:29:40 +00:00
if ( cl . splitclients < MAX_SPLITS & & ! cl . players [ num ] . spectator )
2005-06-07 04:40:16 +00:00
{
extern cvar_t cl_splitscreen ;
if ( cl . splitclients < cl_splitscreen . value + 1 )
{
for ( i = 0 ; i < cl . splitclients ; i + + )
2013-06-23 02:17:02 +00:00
{
playerview_t * pv = & cl . playerview [ i ] ;
2015-06-22 11:49:15 +00:00
if ( pv - > cam_state ! = CAM_FREECAM & & pv - > cam_spec_track = = num )
2005-06-07 04:40:16 +00:00
return ;
2013-06-23 02:17:02 +00:00
}
2005-06-07 04:40:16 +00:00
if ( i = = cl . splitclients )
{
2013-06-23 02:17:02 +00:00
playerview_t * pv = & cl . playerview [ cl . splitclients + + ] ;
Cam_Lock ( pv , num ) ;
2005-06-07 04:40:16 +00:00
}
}
}
2004-08-23 00:15:46 +00:00
return ;
}
2009-05-30 23:48:18 +00:00
flags = ( unsigned short ) MSG_ReadShort ( ) ;
2004-08-23 00:15:46 +00:00
2009-05-30 23:48:18 +00:00
if ( cls . fteprotocolextensions & ( PEXT_HULLSIZE | PEXT_TRANS | PEXT_SCALE | PEXT_FATNESS ) )
2019-03-01 22:39:30 +00:00
{
2004-08-23 00:15:46 +00:00
if ( flags & PF_EXTRA_PFS )
flags | = MSG_ReadByte ( ) < < 16 ;
2019-03-01 22:39:30 +00:00
}
else
flags = ( flags & 0x3fff ) | ( ( flags & 0xc000 ) < < 8 ) ;
2004-08-23 00:15:46 +00:00
2009-05-30 23:48:18 +00:00
state - > flags = flags ;
2004-08-23 00:15:46 +00:00
state - > messagenum = cl . parsecount ;
2017-12-28 16:24:50 +00:00
if ( cls . ezprotocolextensions1 & EZPEXT1_FLOATENTCOORDS )
{
org [ 0 ] = MSG_ReadCoordFloat ( ) ;
org [ 1 ] = MSG_ReadCoordFloat ( ) ;
org [ 2 ] = MSG_ReadCoordFloat ( ) ;
}
else
{
org [ 0 ] = MSG_ReadCoord ( ) ;
org [ 1 ] = MSG_ReadCoord ( ) ;
org [ 2 ] = MSG_ReadCoord ( ) ;
}
2004-09-07 18:22:30 +00:00
VectorCopy ( org , state - > origin ) ;
2004-08-23 00:15:46 +00:00
2006-06-02 17:42:36 +00:00
newf = MSG_ReadByte ( ) ;
if ( state - > frame ! = newf )
2004-08-23 00:15:46 +00:00
{
// state->lerpstarttime = realtime;
2006-06-02 17:42:36 +00:00
state - > frame = newf ;
2004-08-23 00:15:46 +00:00
}
// the other player's last move was likely some time
// before the packet was sent out, so accurately track
// the exact time it was valid at
if ( flags & PF_MSEC )
{
2015-06-05 09:04:05 +00:00
extern cvar_t cl_demospeed ;
2004-08-23 00:15:46 +00:00
msec = MSG_ReadByte ( ) ;
2015-06-05 09:04:05 +00:00
if ( cls . demoplayback )
state - > state_time = parsecounttime - msec * 0.001 * cl_demospeed . value ;
else
state - > state_time = parsecounttime - msec * 0.001 ;
2004-08-23 00:15:46 +00:00
}
else
2011-12-23 14:36:25 +00:00
{
msec = 0 ;
2004-08-23 00:15:46 +00:00
state - > state_time = parsecounttime ;
2011-12-23 14:36:25 +00:00
}
2004-08-23 00:15:46 +00:00
if ( flags & PF_COMMAND )
{
2021-04-14 05:21:04 +00:00
MSGQW_ReadDeltaUsercmd ( & nullcmd , & state - > command , cl . protocol_qw ) ;
2004-08-23 00:15:46 +00:00
state - > viewangles [ 0 ] = state - > command . angles [ 0 ] * ( 360.0 / 65536 ) ;
state - > viewangles [ 1 ] = state - > command . angles [ 1 ] * ( 360.0 / 65536 ) ;
state - > viewangles [ 2 ] = state - > command . angles [ 2 ] * ( 360.0 / 65536 ) ;
2009-07-06 01:20:20 +00:00
if ( ! ( cls . z_ext & Z_EXT_VWEP ) )
state - > command . impulse = 0 ;
2004-08-23 00:15:46 +00:00
}
for ( i = 0 ; i < 3 ; i + + )
{
if ( flags & ( PF_VELOCITY1 < < i ) )
state - > velocity [ i ] = MSG_ReadShort ( ) ;
else
state - > velocity [ i ] = 0 ;
}
if ( flags & PF_MODEL )
state - > modelindex = MSG_ReadByte ( ) ;
else
state - > modelindex = cl_playerindex ;
if ( flags & PF_SKINNUM )
{
state - > skinnum = MSG_ReadByte ( ) ;
if ( state - > skinnum & ( 1 < < 7 ) & & ( flags & PF_MODEL ) )
{
state - > modelindex + = 256 ;
state - > skinnum - = ( 1 < < 7 ) ;
}
}
else
state - > skinnum = 0 ;
if ( flags & PF_EFFECTS )
state - > effects = MSG_ReadByte ( ) ;
else
state - > effects = 0 ;
if ( flags & PF_WEAPONFRAME )
state - > weaponframe = MSG_ReadByte ( ) ;
else
state - > weaponframe = 0 ;
2012-02-12 05:18:31 +00:00
VectorSet ( state - > szmins , - 16 , - 16 , - 24 ) ;
VectorSet ( state - > szmaxs , 16 , 16 , 32 ) ;
2010-08-12 09:04:05 +00:00
state - > scale = 1 ;
2006-02-27 00:42:25 +00:00
state - > alpha = 255 ;
2004-08-23 00:15:46 +00:00
state - > fatness = 0 ;
2012-07-05 19:42:36 +00:00
state - > gravitydir [ 0 ] = 0 ;
state - > gravitydir [ 1 ] = 0 ;
state - > gravitydir [ 2 ] = - 1 ;
2004-08-23 00:15:46 +00:00
# ifdef PEXT_SCALE
2019-03-01 22:39:30 +00:00
if ( ( flags & PF_SCALE ) & & ( cls . fteprotocolextensions & PEXT_SCALE ) )
2019-09-04 07:59:40 +00:00
state - > scale = MSG_ReadByte ( ) / 50.0 ;
2004-08-23 00:15:46 +00:00
# endif
# ifdef PEXT_TRANS
2019-03-01 22:39:30 +00:00
if ( ( flags & PF_TRANS ) & & ( cls . fteprotocolextensions & PEXT_TRANS ) )
2006-02-27 00:42:25 +00:00
state - > alpha = MSG_ReadByte ( ) ;
2004-08-23 00:15:46 +00:00
# endif
# ifdef PEXT_FATNESS
2019-03-01 22:39:30 +00:00
if ( ( flags & PF_FATNESS ) & & ( cls . fteprotocolextensions & PEXT_FATNESS ) )
2019-09-04 07:59:40 +00:00
state - > fatness = MSG_ReadChar ( ) ;
2004-08-23 00:15:46 +00:00
# endif
# ifdef PEXT_HULLSIZE
2012-02-12 05:18:31 +00:00
if ( ( cls . fteprotocolextensions & PEXT_HULLSIZE ) & & ( flags & PF_HULLSIZE_Z ) )
2005-07-01 19:23:00 +00:00
{
2012-02-12 05:18:31 +00:00
int num ;
num = MSG_ReadByte ( ) ;
2012-02-27 12:23:15 +00:00
if ( ! cl . worldmodel | | cl . worldmodel - > fromgame ! = fg_quake )
2012-02-12 05:18:31 +00:00
{
VectorScale ( state - > szmins , num / 56.0f , state - > szmins ) ;
VectorScale ( state - > szmaxs , num / 56.0f , state - > szmaxs ) ;
}
else
{
VectorCopy ( cl . worldmodel - > hulls [ num & ( MAX_MAP_HULLSM - 1 ) ] . clip_mins , state - > szmins ) ;
VectorCopy ( cl . worldmodel - > hulls [ num & ( MAX_MAP_HULLSM - 1 ) ] . clip_maxs , state - > szmaxs ) ;
}
if ( num & 128 )
{ //this hack is for hexen2.
state - > szmaxs [ 2 ] - = state - > szmins [ 2 ] ;
state - > szmins [ 2 ] = 0 ;
}
2005-07-01 19:23:00 +00:00
}
2004-08-23 00:15:46 +00:00
//should be passed to player move func.
# endif
2019-03-01 22:39:30 +00:00
if ( cls . z_ext & Z_EXT_PF_ONGROUND )
state - > onground = ! ! ( flags & PF_ONGROUND ) ;
else
state - > onground = false ;
2004-08-23 00:15:46 +00:00
2019-03-01 22:39:30 +00:00
if ( ( cls . fteprotocolextensions & PEXT_COLOURMOD ) & & ( flags & PF_COLOURMOD ) )
2006-02-27 00:42:25 +00:00
{
state - > colourmod [ 0 ] = MSG_ReadByte ( ) ;
state - > colourmod [ 1 ] = MSG_ReadByte ( ) ;
state - > colourmod [ 2 ] = MSG_ReadByte ( ) ;
}
else
{
state - > colourmod [ 0 ] = 32 ;
state - > colourmod [ 1 ] = 32 ;
state - > colourmod [ 2 ] = 32 ;
}
2019-03-01 22:39:30 +00:00
//if we have no solidity info, guess.
if ( ! ( cls . z_ext & Z_EXT_PF_SOLID ) )
{
if ( cl . players [ num ] . spectator | | state - > flags & PF_DEAD )
state - > flags & = ~ PF_SOLID ;
else
state - > flags | = PF_SOLID ;
}
2005-07-01 19:23:00 +00:00
if ( cls . z_ext & Z_EXT_PM_TYPE )
{
int pm_code ;
2004-08-23 00:15:46 +00:00
pm_code = ( flags & PF_PMC_MASK ) > > PF_PMC_SHIFT ;
if ( pm_code = = PMC_NORMAL | | pm_code = = PMC_NORMAL_JUMP_HELD )
{
if ( flags & PF_DEAD )
state - > pm_type = PM_DEAD ;
else
{
state - > pm_type = PM_NORMAL ;
state - > jump_held = ( pm_code = = PMC_NORMAL_JUMP_HELD ) ;
}
}
else if ( pm_code = = PMC_OLD_SPECTATOR )
state - > pm_type = PM_OLD_SPECTATOR ;
else
{
if ( cls . z_ext & Z_EXT_PM_TYPE_NEW )
{
if ( pm_code = = PMC_SPECTATOR )
state - > pm_type = PM_SPECTATOR ;
else if ( pm_code = = PMC_FLY )
state - > pm_type = PM_FLY ;
else if ( pm_code = = PMC_NONE )
state - > pm_type = PM_NONE ;
else if ( pm_code = = PMC_FREEZE )
state - > pm_type = PM_FREEZE ;
2012-02-15 13:53:30 +00:00
else if ( pm_code = = PMC_WALLWALK )
state - > pm_type = PM_WALLWALK ;
2004-08-23 00:15:46 +00:00
else {
// future extension?
goto guess_pm_type ;
}
}
else
{
// future extension?
goto guess_pm_type ;
}
}
}
else
{
guess_pm_type :
if ( cl . players [ num ] . spectator )
state - > pm_type = PM_OLD_SPECTATOR ;
else if ( flags & PF_DEAD )
state - > pm_type = PM_DEAD ;
else
state - > pm_type = PM_NORMAL ;
}
2020-04-19 01:23:32 +00:00
# ifdef QUAKESTATS
2005-07-16 00:53:08 +00:00
TP_ParsePlayerInfo ( oldstate , state , info ) ;
2011-12-05 15:23:40 +00:00
2012-11-27 03:23:19 +00:00
//can't CL_SetStatInt as we don't know if its actually us or not
2012-02-14 15:50:34 +00:00
for ( i = 0 ; i < cl . splitclients ; i + + )
{
2013-06-23 02:17:02 +00:00
playerview_t * pv = & cl . playerview [ i ] ;
2017-05-28 15:42:32 +00:00
if ( ( pv - > spectator ? pv - > cam_spec_track : pv - > playernum ) = = num )
2012-02-14 15:50:34 +00:00
{
2013-06-23 02:17:02 +00:00
pv - > stats [ STAT_WEAPONFRAME ] = state - > weaponframe ;
pv - > statsf [ STAT_WEAPONFRAME ] = state - > weaponframe ;
2012-02-14 15:50:34 +00:00
}
}
2015-09-01 04:45:15 +00:00
# endif
2012-02-14 15:50:34 +00:00
2015-03-03 00:14:43 +00:00
if ( cl . worldmodel & & cl . do_lerp_players & & cl_predict_players . ival )
2011-12-05 15:23:40 +00:00
{
player_state_t exact ;
2015-06-28 03:43:10 +00:00
msec - = 1000 * ( cls . latency * cl_predict_players_latency . value - cl_predict_players_nudge . value ) ;
2011-12-23 14:36:25 +00:00
// msec = 1000*((realtime - cls.latency + 0.02) - state->state_time);
2011-12-05 15:23:40 +00:00
// predict players movement
2015-06-28 03:43:10 +00:00
state - > command . msec = bound ( 0 , msec , 255 ) ;
2011-12-05 15:23:40 +00:00
2015-03-03 00:14:43 +00:00
//FIXME: flag these and do the pred elsewhere.
2011-12-05 15:23:40 +00:00
CL_SetSolidEntities ( ) ;
2012-02-12 05:18:31 +00:00
CL_SetSolidPlayers ( ) ;
2012-04-24 07:59:11 +00:00
CL_PredictUsercmd ( 0 , num + 1 , state , & exact , & state - > command ) ; //uses player 0's maxspeed/grav...
2011-12-05 15:23:40 +00:00
VectorCopy ( exact . origin , state - > predorigin ) ;
}
else
VectorCopy ( state - > origin , state - > predorigin ) ;
2004-08-23 00:15:46 +00:00
}
------------------------------------------------------------------------
r4169 | acceptthis | 2013-01-17 08:55:12 +0000 (Thu, 17 Jan 2013) | 31 lines
removed MAX_VISEDICTS limit.
PEXT2_REPLACEMENTDELTAS tweaked, now has 4 million entity limit. still not enabled by default.
TE_BEAM now maps to a separate TEQW_BEAM to avoid conflicts with QW.
added android multitouch emulation for windows/rawinput (in_simulatemultitouch).
split topcolor/bottomcolor from scoreboard, for dp's colormap|1024 feature.
now using utf-8 for windows consoles.
qcc warnings/errors now give clickable console links for quick+easy editing.
disabled menutint when the currently active item changes contrast or gamma (for OneManClan).
Added support for drawfont/drawfontscale.
tweaked the qcvm a little to reduce the number of pointers.
.doll file loading. still experimental and will likely crash. requires csqc active, even if its a dummy progs. this will be fixed in time. Still other things that need cleaning up.
windows: gl_font "?" shows the standard windows font-selection dialog, and can be used to select windows fonts. not all work. and you probably don't want to use windings.
fixed splitscreen support when playing mvds. added mini-scoreboards to splitscreen.
editor/debugger now shows asm if there's no linenumber info. also, pressing f1 for help shows the shortcuts.
Added support for .framegroups files for psk(psa) and iqm formats.
True support for ezquake's colour codes. Mutually exclusive with background colours.
path command output slightly more readable.
added support for digest_hex (MD4, SHA1, CRC16).
skingroups now colourmap correctly.
Fix terrain colour hints, and litdata from the wrong bsp.
fix ftp dual-homed issue. support epsv command, and enable ipv6 (eprt still not supported).
remove d3d11 compilation from the makefile. the required headers are not provided by mingw, and are not available to the build bot, so don't bother.
fix v *= v.x and similar opcodes.
fteqcc: fixed support for áéíóú type chars in names. utf-8 files now properly supported (even with the utf-8 bom/identifier). utf-16 also supported.
fteqcc: fixed '#if 1 == 3 && 4' parsing.
fteqcc: -Werror acts on the warning, rather than as a separate error. Line numbers are thus more readable.
fteqcc: copyright message now includes compile date instead.
fteqccgui: the treeview control is now coloured depending on whether there were warnings/errors in the last compile.
fteqccgui: the output window is now focused and scrolls down as compilation progresses.
pr_dumpplatform command dumps out some pragmas to convert more serious warnings to errors. This is to avoid the infamous 'fteqcc sucks cos my code sucks' issue.
rewrote prespawn/modelist/soundlist code. server tracks progress now.
------------------------------------------------------------------------
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@4167 fc73d0e0-1445-4013-8a0c-d673dee63da5
2013-03-12 22:29:40 +00:00
/*
2004-08-23 00:15:46 +00:00
void CL_ParseClientPersist ( void )
{
player_info_t * info ;
int flags ;
flags = MSG_ReadShort ( ) ;
info = & cl . players [ lastplayerinfo ] ;
if ( flags & 1 )
info - > vweapindex = MSG_ReadShort ( ) ;
}
------------------------------------------------------------------------
r4169 | acceptthis | 2013-01-17 08:55:12 +0000 (Thu, 17 Jan 2013) | 31 lines
removed MAX_VISEDICTS limit.
PEXT2_REPLACEMENTDELTAS tweaked, now has 4 million entity limit. still not enabled by default.
TE_BEAM now maps to a separate TEQW_BEAM to avoid conflicts with QW.
added android multitouch emulation for windows/rawinput (in_simulatemultitouch).
split topcolor/bottomcolor from scoreboard, for dp's colormap|1024 feature.
now using utf-8 for windows consoles.
qcc warnings/errors now give clickable console links for quick+easy editing.
disabled menutint when the currently active item changes contrast or gamma (for OneManClan).
Added support for drawfont/drawfontscale.
tweaked the qcvm a little to reduce the number of pointers.
.doll file loading. still experimental and will likely crash. requires csqc active, even if its a dummy progs. this will be fixed in time. Still other things that need cleaning up.
windows: gl_font "?" shows the standard windows font-selection dialog, and can be used to select windows fonts. not all work. and you probably don't want to use windings.
fixed splitscreen support when playing mvds. added mini-scoreboards to splitscreen.
editor/debugger now shows asm if there's no linenumber info. also, pressing f1 for help shows the shortcuts.
Added support for .framegroups files for psk(psa) and iqm formats.
True support for ezquake's colour codes. Mutually exclusive with background colours.
path command output slightly more readable.
added support for digest_hex (MD4, SHA1, CRC16).
skingroups now colourmap correctly.
Fix terrain colour hints, and litdata from the wrong bsp.
fix ftp dual-homed issue. support epsv command, and enable ipv6 (eprt still not supported).
remove d3d11 compilation from the makefile. the required headers are not provided by mingw, and are not available to the build bot, so don't bother.
fix v *= v.x and similar opcodes.
fteqcc: fixed support for áéíóú type chars in names. utf-8 files now properly supported (even with the utf-8 bom/identifier). utf-16 also supported.
fteqcc: fixed '#if 1 == 3 && 4' parsing.
fteqcc: -Werror acts on the warning, rather than as a separate error. Line numbers are thus more readable.
fteqcc: copyright message now includes compile date instead.
fteqccgui: the treeview control is now coloured depending on whether there were warnings/errors in the last compile.
fteqccgui: the output window is now focused and scrolls down as compilation progresses.
pr_dumpplatform command dumps out some pragmas to convert more serious warnings to errors. This is to avoid the infamous 'fteqcc sucks cos my code sucks' issue.
rewrote prespawn/modelist/soundlist code. server tracks progress now.
------------------------------------------------------------------------
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@4167 fc73d0e0-1445-4013-8a0c-d673dee63da5
2013-03-12 22:29:40 +00:00
*/
2004-08-23 00:15:46 +00:00
/*
= = = = = = = = = = = = = = = =
CL_AddFlagModels
Called when the CTF flags are set
= = = = = = = = = = = = = = = =
*/
void CL_AddFlagModels ( entity_t * ent , int team )
{
int i ;
float f ;
vec3_t v_forward , v_right , v_up ;
entity_t * newent ;
2004-11-17 17:55:19 +00:00
vec3_t angles ;
2009-02-03 00:08:32 +00:00
float offs = 0 ;
2004-08-23 00:15:46 +00:00
if ( cl_flagindex = = - 1 )
return ;
2015-02-02 08:01:53 +00:00
for ( i = 0 ; i < FRAME_BLENDS ; i + + )
2008-12-23 02:55:20 +00:00
{
2015-02-02 08:01:53 +00:00
if ( ! ent - > framestate . g [ FS_REG ] . lerpweight [ i ] )
continue ;
2008-12-23 02:55:20 +00:00
f = 14 ;
if ( ent - > framestate . g [ FS_REG ] . frame [ i ] > = 29 & & ent - > framestate . g [ FS_REG ] . frame [ i ] < = 40 ) {
if ( ent - > framestate . g [ FS_REG ] . frame [ i ] > = 29 & & ent - > framestate . g [ FS_REG ] . frame [ i ] < = 34 ) { //axpain
if ( ent - > framestate . g [ FS_REG ] . frame [ i ] = = 29 ) f = f + 2 ;
else if ( ent - > framestate . g [ FS_REG ] . frame [ i ] = = 30 ) f = f + 8 ;
else if ( ent - > framestate . g [ FS_REG ] . frame [ i ] = = 31 ) f = f + 12 ;
else if ( ent - > framestate . g [ FS_REG ] . frame [ i ] = = 32 ) f = f + 11 ;
else if ( ent - > framestate . g [ FS_REG ] . frame [ i ] = = 33 ) f = f + 10 ;
else if ( ent - > framestate . g [ FS_REG ] . frame [ i ] = = 34 ) f = f + 4 ;
} else if ( ent - > framestate . g [ FS_REG ] . frame [ i ] > = 35 & & ent - > framestate . g [ FS_REG ] . frame [ i ] < = 40 ) { // pain
if ( ent - > framestate . g [ FS_REG ] . frame [ i ] = = 35 ) f = f + 2 ;
else if ( ent - > framestate . g [ FS_REG ] . frame [ i ] = = 36 ) f = f + 10 ;
else if ( ent - > framestate . g [ FS_REG ] . frame [ i ] = = 37 ) f = f + 10 ;
else if ( ent - > framestate . g [ FS_REG ] . frame [ i ] = = 38 ) f = f + 8 ;
else if ( ent - > framestate . g [ FS_REG ] . frame [ i ] = = 39 ) f = f + 4 ;
else if ( ent - > framestate . g [ FS_REG ] . frame [ i ] = = 40 ) f = f + 2 ;
}
} else if ( ent - > framestate . g [ FS_REG ] . frame [ i ] > = 103 & & ent - > framestate . g [ FS_REG ] . frame [ i ] < = 118 ) {
if ( ent - > framestate . g [ FS_REG ] . frame [ i ] > = 103 & & ent - > framestate . g [ FS_REG ] . frame [ i ] < = 104 ) f = f + 6 ; //nailattack
else if ( ent - > framestate . g [ FS_REG ] . frame [ i ] > = 105 & & ent - > framestate . g [ FS_REG ] . frame [ i ] < = 106 ) f = f + 6 ; //light
else if ( ent - > framestate . g [ FS_REG ] . frame [ i ] > = 107 & & ent - > framestate . g [ FS_REG ] . frame [ i ] < = 112 ) f = f + 7 ; //rocketattack
else if ( ent - > framestate . g [ FS_REG ] . frame [ i ] > = 112 & & ent - > framestate . g [ FS_REG ] . frame [ i ] < = 118 ) f = f + 7 ; //shotattack
}
2015-02-02 08:01:53 +00:00
offs + = f * ent - > framestate . g [ FS_REG ] . lerpweight [ i ] ;
2004-08-23 00:15:46 +00:00
}
newent = CL_NewTempEntity ( ) ;
newent - > model = cl . model_precache [ cl_flagindex ] ;
newent - > skinnum = team ;
2013-06-23 02:17:02 +00:00
newent - > keynum = ent - > keynum ;
newent - > flags | = ent - > flags ;
2004-08-23 00:15:46 +00:00
AngleVectors ( ent - > angles , v_forward , v_right , v_up ) ;
v_forward [ 2 ] = - v_forward [ 2 ] ; // reverse z component
for ( i = 0 ; i < 3 ; i + + )
2008-12-23 02:55:20 +00:00
newent - > origin [ i ] = ent - > origin [ i ] - offs * v_forward [ i ] + 22 * v_right [ i ] ;
2004-08-23 00:15:46 +00:00
newent - > origin [ 2 ] - = 16 ;
2009-03-03 01:52:30 +00:00
VectorCopy ( ent - > angles , newent - > angles ) ;
2004-08-23 00:15:46 +00:00
newent - > angles [ 2 ] - = 45 ;
2004-11-17 17:55:19 +00:00
VectorCopy ( newent - > angles , angles ) ;
2020-10-06 03:17:28 +00:00
AngleVectorsMesh ( angles , newent - > axis [ 0 ] , newent - > axis [ 1 ] , newent - > axis [ 2 ] ) ;
2004-11-17 17:55:19 +00:00
VectorInverse ( newent - > axis [ 1 ] ) ;
2004-08-23 00:15:46 +00:00
}
2009-07-06 01:20:20 +00:00
void CL_AddVWeapModel ( entity_t * player , model_t * model )
2004-08-23 00:15:46 +00:00
{
entity_t * newent ;
2015-02-02 08:01:53 +00:00
// vec3_t angles;
Fixes, workarounds, and breakages. Hexen2 should work much better (-hexen2 says no mission pack, -portals says h2mp). Started working on splitting bigcoords per client, far too much work still to go on that. Removed gl_ztrick entirely. Enabled csprogs download by default. Added client support for fitzquake's 666 protocol, needs testing, some cleanup for dp protocols too, no server support, couldn't selectively enable it anyway. Now attempting to cache shadow meshes for explosions and stuff. Played with lightmaps a little, should potentially run a little faster on certain (intel?) cards. Tweeked npfte a little to try to avoid deadlocks and crashes. Fixed sky worldspawn parsing. Added h2mp's model format. Fixed baseline issue in q2 client, made servers generate q2 baselines. MOVETYPE_PUSH will not rotate extra if rotation is forced. Made status command show allowed client types. Changed lighting on weapons - should now be shaded.
git-svn-id: https://svn.code.sf.net/p/fteqw/code/branches/wip@3572 fc73d0e0-1445-4013-8a0c-d673dee63da5
2010-08-11 03:36:31 +00:00
if ( ! model )
return ;
2004-08-23 00:15:46 +00:00
newent = CL_NewTempEntity ( ) ;
2009-07-19 15:08:30 +00:00
newent - > keynum = player - > keynum ;
2013-06-23 02:17:02 +00:00
newent - > flags | = player - > flags ;
2009-07-19 15:08:30 +00:00
2004-08-23 00:15:46 +00:00
VectorCopy ( player - > origin , newent - > origin ) ;
VectorCopy ( player - > angles , newent - > angles ) ;
newent - > skinnum = player - > skinnum ;
2009-07-06 01:20:20 +00:00
newent - > model = model ;
2008-12-23 02:55:20 +00:00
newent - > framestate = player - > framestate ;
2004-11-17 17:55:19 +00:00
2015-02-02 08:01:53 +00:00
AngleVectors ( newent - > angles , newent - > axis [ 0 ] , newent - > axis [ 1 ] , newent - > axis [ 2 ] ) ;
2004-11-17 17:55:19 +00:00
VectorInverse ( newent - > axis [ 1 ] ) ;
2004-08-23 00:15:46 +00:00
}
/*
= = = = = = = = = = = = =
CL_LinkPlayers
Create visible entities in the correct position
for all current players
= = = = = = = = = = = = =
*/
2009-07-17 22:28:16 +00:00
vec3_t nametagorg [ MAX_CLIENTS ] ;
qboolean nametagseen [ MAX_CLIENTS ] ;
2004-08-23 00:15:46 +00:00
void CL_LinkPlayers ( void )
{
int pnum ;
int j ;
player_info_t * info ;
player_state_t * state ;
player_state_t exact ;
double playertime ;
entity_t * ent ;
2015-06-05 09:04:05 +00:00
float msec ;
inframe_t * frame ;
2004-08-23 00:15:46 +00:00
int oldphysent ;
2004-11-17 17:55:19 +00:00
vec3_t angles ;
2010-03-14 14:35:56 +00:00
qboolean predictplayers ;
2010-08-14 00:15:07 +00:00
model_t * model ;
2011-04-20 03:38:59 +00:00
static int flickertime ;
static int flicker ;
2012-04-24 07:59:11 +00:00
float predictmsmult = 1000 * cl_predict_players_frac . value ;
2019-04-16 22:40:05 +00:00
# ifdef HAVE_LEGACY
2013-03-12 22:36:18 +00:00
int modelindex2 ;
2018-09-01 04:18:08 +00:00
# endif
2015-06-05 09:04:05 +00:00
extern cvar_t cl_demospeed ;
2018-05-06 16:09:07 +00:00
int displayseq ;
2004-08-23 00:15:46 +00:00
2014-10-05 20:04:11 +00:00
if ( ! cl . worldmodel | | cl . worldmodel - > loadstate ! = MLS_LOADED )
2009-04-01 22:03:56 +00:00
return ;
2014-01-13 02:42:25 +00:00
if ( cl . paused )
predictmsmult = 0 ;
2015-06-05 09:04:05 +00:00
if ( cls . demoplayback )
predictmsmult * = cl_demospeed . value ;
2014-01-13 02:42:25 +00:00
2015-06-28 03:43:10 +00:00
playertime = realtime - cls . latency * cl_predict_players_latency . value + cl_predict_players_nudge . value ;
2004-08-23 00:15:46 +00:00
if ( playertime > realtime )
playertime = realtime ;
2018-05-06 16:09:07 +00:00
if ( cl . demonudge < 0 )
displayseq = cl . lerpentssequence ;
else
displayseq = cl . validsequence ;
frame = & cl . inframes [ displayseq & UPDATE_MASK ] ;
2004-08-23 00:15:46 +00:00
2011-06-15 23:01:07 +00:00
predictplayers = cl_predict_players . ival ;
2010-03-14 14:35:56 +00:00
if ( cls . demoplayback = = DPB_MVD | | cls . demoplayback = = DPB_EZTV )
predictplayers = false ;
2013-10-29 17:38:22 +00:00
for ( j = 0 , info = cl . players , state = frame - > playerstate ; j < cl . allocated_client_slots
2004-08-23 00:15:46 +00:00
; j + + , info + + , state + + )
{
2009-07-17 22:28:16 +00:00
nametagseen [ j ] = false ;
2018-05-06 16:09:07 +00:00
if ( state - > messagenum ! = displayseq )
2009-04-01 22:03:56 +00:00
{
2009-04-02 22:25:54 +00:00
# ifdef CSQC_DAT
2009-04-06 00:34:32 +00:00
CSQC_DeltaPlayer ( j , NULL ) ;
2009-04-02 22:25:54 +00:00
# endif
2004-08-23 00:15:46 +00:00
continue ; // not present this frame
2009-04-01 22:03:56 +00:00
}
2016-07-12 00:40:13 +00:00
CL_UpdateNetFrameLerpState ( false , state - > frame , 0 , 0 , & cl . lerpplayers [ j ] ) ;
2015-06-30 14:05:45 +00:00
cl . lerpplayers [ j ] . sequence = cl . lerpentssequence ;
2011-05-20 04:10:46 +00:00
2009-04-02 22:25:54 +00:00
# ifdef CSQC_DAT
2009-04-06 00:34:32 +00:00
if ( CSQC_DeltaPlayer ( j , state ) )
2009-04-01 22:03:56 +00:00
continue ;
2009-04-02 22:25:54 +00:00
# endif
2004-08-23 00:15:46 +00:00
2020-10-26 06:30:35 +00:00
if ( info - > spectator | | state - > modelindex > = countof ( cl . model_precache ) )
2009-11-04 21:16:50 +00:00
continue ;
2010-08-14 00:15:07 +00:00
//the extra modelindex check is to stop lame mods from using vweps with rings
2019-04-16 22:40:05 +00:00
# ifdef HAVE_LEGACY
2013-03-12 22:36:18 +00:00
if ( state - > command . impulse & & cl . model_precache_vwep [ 0 ] & & cl . model_precache_vwep [ 0 ] - > type ! = mod_dummy & & state - > modelindex = = cl_playerindex )
{
2010-08-14 00:15:07 +00:00
model = cl . model_precache_vwep [ 0 ] ;
2013-03-12 22:36:18 +00:00
modelindex2 = state - > command . impulse ;
}
2010-08-14 00:15:07 +00:00
else
2018-09-01 04:18:08 +00:00
# endif
2013-03-12 22:36:18 +00:00
{
2010-08-14 00:15:07 +00:00
model = cl . model_precache [ state - > modelindex ] ;
2019-04-16 22:40:05 +00:00
# ifdef HAVE_LEGACY
2013-03-12 22:36:18 +00:00
modelindex2 = 0 ;
2018-09-01 04:18:08 +00:00
# endif
2013-03-12 22:36:18 +00:00
}
2010-08-14 00:15:07 +00:00
2004-08-23 00:15:46 +00:00
// spawn light flashes, even ones coming from invisible objects
2013-06-23 02:17:02 +00:00
if ( r_powerupglow . value & & ! ( r_powerupglow . value = = 2 & & j = = cl . playerview [ 0 ] . playernum )
2020-09-29 07:09:01 +00:00
& & ( state - > effects & ( EF_BLUE | EF_RED | EF_GREEN | EF_BRIGHTLIGHT | EF_DIMLIGHT ) ) )
2004-08-23 00:15:46 +00:00
{
2009-07-05 18:45:53 +00:00
vec3_t colour ;
float radius ;
colour [ 0 ] = 0 ;
colour [ 1 ] = 0 ;
colour [ 2 ] = 0 ;
radius = 0 ;
2008-01-24 01:24:10 +00:00
2009-07-05 18:45:53 +00:00
if ( state - > effects & EF_BRIGHTLIGHT )
{
2020-09-29 07:09:01 +00:00
radius = max ( radius , r_brightlight_colour . vec4 [ 3 ] ) ;
VectorAdd ( colour , r_brightlight_colour . vec4 , colour ) ;
2009-07-05 18:45:53 +00:00
}
if ( state - > effects & EF_DIMLIGHT )
{
2020-09-29 07:09:01 +00:00
radius = max ( radius , r_dimlight_colour . vec4 [ 3 ] ) ;
VectorAdd ( colour , r_dimlight_colour . vec4 , colour ) ;
2009-07-05 18:45:53 +00:00
}
if ( state - > effects & EF_BLUE )
{
2020-09-29 07:09:01 +00:00
radius = max ( radius , r_bluelight_colour . vec4 [ 3 ] ) ;
VectorAdd ( colour , r_bluelight_colour . vec4 , colour ) ;
2009-07-05 18:45:53 +00:00
}
if ( state - > effects & EF_RED )
{
2020-09-29 07:09:01 +00:00
radius = max ( radius , r_redlight_colour . vec4 [ 3 ] ) ;
VectorAdd ( colour , r_redlight_colour . vec4 , colour ) ;
}
if ( state - > effects & EF_GREEN )
{
radius = max ( radius , r_greenlight_colour . vec4 [ 3 ] ) ;
VectorAdd ( colour , r_greenlight_colour . vec4 , colour ) ;
2009-07-05 18:45:53 +00:00
}
if ( radius )
{
2010-08-14 00:15:07 +00:00
vec3_t org ;
VectorCopy ( state - > origin , org ) ;
2012-11-27 03:23:19 +00:00
//make the light appear at the predicted position rather than anywhere else.
2010-08-14 00:15:07 +00:00
for ( pnum = 0 ; pnum < cl . splitclients ; pnum + + )
2013-06-23 02:17:02 +00:00
if ( cl . playerview [ pnum ] . playernum = = j )
2012-07-05 19:42:36 +00:00
VectorCopy ( cl . playerview [ pnum ] . simorg , org ) ;
2010-08-16 02:03:02 +00:00
if ( model )
{
2010-08-28 17:14:38 +00:00
org [ 2 ] + = model - > mins [ 2 ] ;
org [ 2 ] + = 32 ;
2010-08-16 02:03:02 +00:00
}
2011-04-20 03:38:59 +00:00
if ( r_lightflicker . value )
{
pnum = realtime * 20 ;
if ( flickertime ! = pnum )
{
flickertime = pnum ;
flicker = rand ( ) ;
}
radius + = ( flicker + j ) & 31 ;
}
2011-12-27 08:35:19 +00:00
CL_NewDlight ( j + 1 , org , radius , 0.1 , colour [ 0 ] , colour [ 1 ] , colour [ 2 ] ) - > flags & = ~ LFLAG_FLASHBLEND ;
2009-07-05 18:45:53 +00:00
}
2004-08-23 00:15:46 +00:00
}
2004-12-08 04:14:52 +00:00
if ( state - > modelindex < 1 )
2004-08-23 00:15:46 +00:00
continue ;
2005-01-18 20:15:20 +00:00
if ( CL_FilterModelindex ( state - > modelindex , state - > frame ) )
continue ;
2004-08-23 00:15:46 +00:00
/*
if ( ! Cam_DrawPlayer ( j ) )
continue ;
*/
// grab an entity to fill in
------------------------------------------------------------------------
r4169 | acceptthis | 2013-01-17 08:55:12 +0000 (Thu, 17 Jan 2013) | 31 lines
removed MAX_VISEDICTS limit.
PEXT2_REPLACEMENTDELTAS tweaked, now has 4 million entity limit. still not enabled by default.
TE_BEAM now maps to a separate TEQW_BEAM to avoid conflicts with QW.
added android multitouch emulation for windows/rawinput (in_simulatemultitouch).
split topcolor/bottomcolor from scoreboard, for dp's colormap|1024 feature.
now using utf-8 for windows consoles.
qcc warnings/errors now give clickable console links for quick+easy editing.
disabled menutint when the currently active item changes contrast or gamma (for OneManClan).
Added support for drawfont/drawfontscale.
tweaked the qcvm a little to reduce the number of pointers.
.doll file loading. still experimental and will likely crash. requires csqc active, even if its a dummy progs. this will be fixed in time. Still other things that need cleaning up.
windows: gl_font "?" shows the standard windows font-selection dialog, and can be used to select windows fonts. not all work. and you probably don't want to use windings.
fixed splitscreen support when playing mvds. added mini-scoreboards to splitscreen.
editor/debugger now shows asm if there's no linenumber info. also, pressing f1 for help shows the shortcuts.
Added support for .framegroups files for psk(psa) and iqm formats.
True support for ezquake's colour codes. Mutually exclusive with background colours.
path command output slightly more readable.
added support for digest_hex (MD4, SHA1, CRC16).
skingroups now colourmap correctly.
Fix terrain colour hints, and litdata from the wrong bsp.
fix ftp dual-homed issue. support epsv command, and enable ipv6 (eprt still not supported).
remove d3d11 compilation from the makefile. the required headers are not provided by mingw, and are not available to the build bot, so don't bother.
fix v *= v.x and similar opcodes.
fteqcc: fixed support for áéíóú type chars in names. utf-8 files now properly supported (even with the utf-8 bom/identifier). utf-16 also supported.
fteqcc: fixed '#if 1 == 3 && 4' parsing.
fteqcc: -Werror acts on the warning, rather than as a separate error. Line numbers are thus more readable.
fteqcc: copyright message now includes compile date instead.
fteqccgui: the treeview control is now coloured depending on whether there were warnings/errors in the last compile.
fteqccgui: the output window is now focused and scrolls down as compilation progresses.
pr_dumpplatform command dumps out some pragmas to convert more serious warnings to errors. This is to avoid the infamous 'fteqcc sucks cos my code sucks' issue.
rewrote prespawn/modelist/soundlist code. server tracks progress now.
------------------------------------------------------------------------
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@4167 fc73d0e0-1445-4013-8a0c-d673dee63da5
2013-03-12 22:29:40 +00:00
if ( cl_numvisedicts = = cl_maxvisedicts )
2004-08-23 00:15:46 +00:00
break ; // object list is full
ent = & cl_visedicts [ cl_numvisedicts ] ;
cl_numvisedicts + + ;
2014-10-20 03:14:00 +00:00
memset ( ent , 0 , sizeof ( * ent ) ) ;
2004-08-23 00:15:46 +00:00
ent - > keynum = j + 1 ;
2010-08-14 00:15:07 +00:00
ent - > model = model ;
2005-10-01 15:44:36 +00:00
2005-02-06 02:47:36 +00:00
ent - > skinnum = state - > skinnum ;
2004-08-23 00:15:46 +00:00
2016-07-12 00:40:13 +00:00
CL_LerpNetFrameState ( & ent - > framestate , & cl . lerpplayers [ j ] ) ;
2004-08-23 00:15:46 +00:00
------------------------------------------------------------------------
r4169 | acceptthis | 2013-01-17 08:55:12 +0000 (Thu, 17 Jan 2013) | 31 lines
removed MAX_VISEDICTS limit.
PEXT2_REPLACEMENTDELTAS tweaked, now has 4 million entity limit. still not enabled by default.
TE_BEAM now maps to a separate TEQW_BEAM to avoid conflicts with QW.
added android multitouch emulation for windows/rawinput (in_simulatemultitouch).
split topcolor/bottomcolor from scoreboard, for dp's colormap|1024 feature.
now using utf-8 for windows consoles.
qcc warnings/errors now give clickable console links for quick+easy editing.
disabled menutint when the currently active item changes contrast or gamma (for OneManClan).
Added support for drawfont/drawfontscale.
tweaked the qcvm a little to reduce the number of pointers.
.doll file loading. still experimental and will likely crash. requires csqc active, even if its a dummy progs. this will be fixed in time. Still other things that need cleaning up.
windows: gl_font "?" shows the standard windows font-selection dialog, and can be used to select windows fonts. not all work. and you probably don't want to use windings.
fixed splitscreen support when playing mvds. added mini-scoreboards to splitscreen.
editor/debugger now shows asm if there's no linenumber info. also, pressing f1 for help shows the shortcuts.
Added support for .framegroups files for psk(psa) and iqm formats.
True support for ezquake's colour codes. Mutually exclusive with background colours.
path command output slightly more readable.
added support for digest_hex (MD4, SHA1, CRC16).
skingroups now colourmap correctly.
Fix terrain colour hints, and litdata from the wrong bsp.
fix ftp dual-homed issue. support epsv command, and enable ipv6 (eprt still not supported).
remove d3d11 compilation from the makefile. the required headers are not provided by mingw, and are not available to the build bot, so don't bother.
fix v *= v.x and similar opcodes.
fteqcc: fixed support for áéíóú type chars in names. utf-8 files now properly supported (even with the utf-8 bom/identifier). utf-16 also supported.
fteqcc: fixed '#if 1 == 3 && 4' parsing.
fteqcc: -Werror acts on the warning, rather than as a separate error. Line numbers are thus more readable.
fteqcc: copyright message now includes compile date instead.
fteqccgui: the treeview control is now coloured depending on whether there were warnings/errors in the last compile.
fteqccgui: the output window is now focused and scrolls down as compilation progresses.
pr_dumpplatform command dumps out some pragmas to convert more serious warnings to errors. This is to avoid the infamous 'fteqcc sucks cos my code sucks' issue.
rewrote prespawn/modelist/soundlist code. server tracks progress now.
------------------------------------------------------------------------
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@4167 fc73d0e0-1445-4013-8a0c-d673dee63da5
2013-03-12 22:29:40 +00:00
// set colormap
ent - > playerindex = j ;
2018-03-04 14:41:16 +00:00
ent - > topcolour = info - > dtopcolor ;
ent - > bottomcolour = info - > dbottomcolor ;
2014-09-17 03:04:08 +00:00
# ifdef HEXEN2
------------------------------------------------------------------------
r4169 | acceptthis | 2013-01-17 08:55:12 +0000 (Thu, 17 Jan 2013) | 31 lines
removed MAX_VISEDICTS limit.
PEXT2_REPLACEMENTDELTAS tweaked, now has 4 million entity limit. still not enabled by default.
TE_BEAM now maps to a separate TEQW_BEAM to avoid conflicts with QW.
added android multitouch emulation for windows/rawinput (in_simulatemultitouch).
split topcolor/bottomcolor from scoreboard, for dp's colormap|1024 feature.
now using utf-8 for windows consoles.
qcc warnings/errors now give clickable console links for quick+easy editing.
disabled menutint when the currently active item changes contrast or gamma (for OneManClan).
Added support for drawfont/drawfontscale.
tweaked the qcvm a little to reduce the number of pointers.
.doll file loading. still experimental and will likely crash. requires csqc active, even if its a dummy progs. this will be fixed in time. Still other things that need cleaning up.
windows: gl_font "?" shows the standard windows font-selection dialog, and can be used to select windows fonts. not all work. and you probably don't want to use windings.
fixed splitscreen support when playing mvds. added mini-scoreboards to splitscreen.
editor/debugger now shows asm if there's no linenumber info. also, pressing f1 for help shows the shortcuts.
Added support for .framegroups files for psk(psa) and iqm formats.
True support for ezquake's colour codes. Mutually exclusive with background colours.
path command output slightly more readable.
added support for digest_hex (MD4, SHA1, CRC16).
skingroups now colourmap correctly.
Fix terrain colour hints, and litdata from the wrong bsp.
fix ftp dual-homed issue. support epsv command, and enable ipv6 (eprt still not supported).
remove d3d11 compilation from the makefile. the required headers are not provided by mingw, and are not available to the build bot, so don't bother.
fix v *= v.x and similar opcodes.
fteqcc: fixed support for áéíóú type chars in names. utf-8 files now properly supported (even with the utf-8 bom/identifier). utf-16 also supported.
fteqcc: fixed '#if 1 == 3 && 4' parsing.
fteqcc: -Werror acts on the warning, rather than as a separate error. Line numbers are thus more readable.
fteqcc: copyright message now includes compile date instead.
fteqccgui: the treeview control is now coloured depending on whether there were warnings/errors in the last compile.
fteqccgui: the output window is now focused and scrolls down as compilation progresses.
pr_dumpplatform command dumps out some pragmas to convert more serious warnings to errors. This is to avoid the infamous 'fteqcc sucks cos my code sucks' issue.
rewrote prespawn/modelist/soundlist code. server tracks progress now.
------------------------------------------------------------------------
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@4167 fc73d0e0-1445-4013-8a0c-d673dee63da5
2013-03-12 22:29:40 +00:00
ent - > h2playerclass = info - > h2playerclass ;
2014-09-17 03:04:08 +00:00
# endif
2004-08-23 00:15:46 +00:00
# ifdef PEXT_SCALE
2010-08-12 09:04:05 +00:00
ent - > scale = state - > scale ;
2004-08-23 00:15:46 +00:00
# endif
2020-01-20 17:58:45 +00:00
ent - > glowmod [ 0 ] = ent - > glowmod [ 1 ] = ent - > glowmod [ 2 ] = 1 ;
2011-04-23 20:37:20 +00:00
ent - > shaderRGBAf [ 0 ] = state - > colourmod [ 0 ] / 32.0f ;
ent - > shaderRGBAf [ 1 ] = state - > colourmod [ 1 ] / 32.0f ;
ent - > shaderRGBAf [ 2 ] = state - > colourmod [ 2 ] / 32.0f ;
ent - > shaderRGBAf [ 3 ] = state - > alpha / 255.0f ;
if ( state - > alpha ! = 255 )
2014-03-31 17:06:41 +00:00
ent - > flags | = RF_TRANSLUCENT ;
2006-02-27 00:42:25 +00:00
2012-01-28 10:30:44 +00:00
ent - > fatness = state - > fatness ;
2004-08-23 00:15:46 +00:00
//
// angles
//
2004-11-17 17:55:19 +00:00
angles [ PITCH ] = - state - > viewangles [ PITCH ] / 3 ;
angles [ YAW ] = state - > viewangles [ YAW ] ;
angles [ ROLL ] = 0 ;
angles [ ROLL ] = V_CalcRoll ( angles , state - > velocity ) * 4 ;
2004-08-23 00:15:46 +00:00
2015-06-22 11:49:15 +00:00
if ( j + 1 = = r_refdef . playerview - > viewentity | | ( r_refdef . playerview - > cam_state = = CAM_EYECAM & & r_refdef . playerview - > cam_spec_track = = j ) )
2014-03-31 17:06:41 +00:00
ent - > flags | = RF_EXTERNALMODEL ;
2004-08-23 00:15:46 +00:00
// the player object gets added with flags | 2
for ( pnum = 0 ; pnum < cl . splitclients ; pnum + + )
{
2013-06-23 02:17:02 +00:00
playerview_t * pv = & cl . playerview [ pnum ] ;
if ( j = = pv - > playernum )
2004-08-23 00:15:46 +00:00
{
2005-06-14 04:52:10 +00:00
/* if (cl.spectator)
2004-08-23 00:15:46 +00:00
{
cl_numvisedicts - - ;
continue ;
}
2013-06-23 02:17:02 +00:00
*/ angles [ 0 ] = - 1 * pv - > viewangles [ 0 ] / 3 ;
angles [ 1 ] = pv - > viewangles [ 1 ] ;
angles [ 2 ] = pv - > viewangles [ 2 ] ;
ent - > origin [ 0 ] = pv - > simorg [ 0 ] ;
ent - > origin [ 1 ] = pv - > simorg [ 1 ] ;
ent - > origin [ 2 ] = pv - > simorg [ 2 ] + pv - > crouch ;
2004-08-23 00:15:46 +00:00
}
}
2015-02-02 08:01:53 +00:00
if ( model & & model - > type = = mod_alias )
2020-10-06 03:17:28 +00:00
{
added r_meshpitch cvar that allows for fixing the unfixable mesh pitch bug from vanilla... needs a better name... do note that this will break pretty much any mod, so this is really only for TCs designed to use it. Its likely that I missed places.
nqsv: added support for spectators with nq clients. the angles are a bit rough, but hey. need to do something about frags so nq clients know who's a spectator. use 'cmd observe' to get an nq client to spectate on an fte server (then attack/jump behave the same as in qw clients).
nqsv: rewrote EF_MUZZLEFLASH handling, so svc_muzzleflash is now translated properly to EF_MUZZLEFLASH, and vice versa. No more missing muzzleflashes!
added screenshot_cubemap, so you can actually pre-generate cubemaps with fte (which can be used for reflections or whatever).
misc fixes (server crash, a couple of other less important ones).
external files based on a model's name will now obey r_replacemodels properly, instead of needing to use foo.mdl_0.skin for foo.md3.
identify <playernum> should now use the correct masked ip, instead of abrubtly failing (reported by kt)
vid_toggle console command should now obey vid_width and vid_height when switching to fullscreen, but only if vid_fullscreen is actually set, which should make it seem better behaved (reported by kt).
qcc: cleaned up sym->symboldata[sym->ofs] to be more consistent at all stages.
qcc: typedef float vec4[4]; now works to define a float array with 4 elements (however, it will be passed by-value rather than by-reference).
qcc: cleaned up optional vs __out ordering issues.
qccgui: shift+f3 searches backwards
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@5064 fc73d0e0-1445-4013-8a0c-d673dee63da5
2017-02-27 09:34:35 +00:00
angles [ 0 ] * = r_meshpitch . value ; //carmack screwed up when he added alias models - they pitch the wrong way.
2020-10-06 03:17:28 +00:00
angles [ 2 ] * = r_meshroll . value ; //hexen2 screwed it up even more - they roll the wrong way.
}
2004-11-17 17:55:19 +00:00
VectorCopy ( angles , ent - > angles ) ;
AngleVectors ( angles , ent - > axis [ 0 ] , ent - > axis [ 1 ] , ent - > axis [ 2 ] ) ;
VectorInverse ( ent - > axis [ 1 ] ) ;
2004-08-23 00:15:46 +00:00
// only predict half the move to minimize overruns
2012-04-24 07:59:11 +00:00
msec = predictmsmult * ( playertime - state - > state_time ) ;
2005-10-01 03:09:17 +00:00
2006-01-28 02:35:40 +00:00
if ( pnum < cl . splitclients )
2005-10-01 03:09:17 +00:00
{ //this is a local player
2004-08-23 00:15:46 +00:00
}
2013-07-26 17:19:06 +00:00
else if ( cl . do_lerp_players )
2011-12-05 15:23:40 +00:00
{
lerpents_t * le = & cl . lerpplayers [ j ] ;
VectorCopy ( le - > origin , ent - > origin ) ;
VectorCopy ( le - > angles , ent - > angles ) ;
ent - > angles [ 0 ] / = 3 ;
AngleVectors ( ent - > angles , ent - > axis [ 0 ] , ent - > axis [ 1 ] , ent - > axis [ 2 ] ) ;
VectorInverse ( ent - > axis [ 1 ] ) ;
}
2010-03-14 14:35:56 +00:00
else if ( msec < = 0 | | ( ! predictplayers ) )
2004-08-23 00:15:46 +00:00
{
VectorCopy ( state - > origin , ent - > origin ) ;
//Con_DPrintf ("nopredict\n");
}
else
{
// predict players movement
2012-04-24 07:59:11 +00:00
if ( msec > 250 )
msec = 250 ;
2004-08-23 00:15:46 +00:00
state - > command . msec = msec ;
//Con_DPrintf ("predict: %i\n", msec);
oldphysent = pmove . numphysent ;
2012-02-12 05:18:31 +00:00
CL_SetSolidPlayers ( ) ;
2012-04-24 07:59:11 +00:00
CL_PredictUsercmd ( 0 , j + 1 , state , & exact , & state - > command ) ; //uses player 0's maxspeed/grav...
2004-08-23 00:15:46 +00:00
pmove . numphysent = oldphysent ;
VectorCopy ( exact . origin , ent - > origin ) ;
}
2009-07-17 22:28:16 +00:00
VectorCopy ( ent - > origin , nametagorg [ j ] ) ;
nametagseen [ j ] = true ;
2005-04-16 16:21:27 +00:00
if ( state - > effects & QWEF_FLAG1 )
2004-08-23 00:15:46 +00:00
CL_AddFlagModels ( ent , 0 ) ;
2005-04-16 16:21:27 +00:00
else if ( state - > effects & QWEF_FLAG2 )
2004-08-23 00:15:46 +00:00
CL_AddFlagModels ( ent , 1 ) ;
2019-04-16 22:40:05 +00:00
# ifdef HAVE_LEGACY
2013-03-12 22:36:18 +00:00
if ( modelindex2 )
CL_AddVWeapModel ( ent , cl . model_precache_vwep [ modelindex2 ] ) ;
2018-09-01 04:18:08 +00:00
# endif
2004-08-23 00:15:46 +00:00
2011-04-30 17:21:10 +00:00
CLQ1_AddShadow ( ent ) ;
2011-04-25 03:25:22 +00:00
CLQ1_AddPowerupShell ( ent , false , state - > effects ) ;
2013-09-06 22:57:44 +00:00
if ( ( r_showbboxes . ival & 3 ) = = 3 )
{
vec3_t min , max ;
shader_t * s = R_RegisterShader ( " bboxshader " , SUF_NONE , NULL ) ;
if ( s )
{
2014-01-13 02:42:25 +00:00
VectorAdd ( state - > origin , pmove . player_mins , min ) ;
VectorAdd ( state - > origin , pmove . player_maxs , max ) ;
2013-09-06 22:57:44 +00:00
CLQ1_AddOrientedCube ( s , min , max , NULL , 0.1 , 0 , 0 , 1 ) ;
2014-01-13 02:42:25 +00:00
VectorAdd ( ent - > origin , pmove . player_mins , min ) ;
VectorAdd ( ent - > origin , pmove . player_maxs , max ) ;
2013-09-06 22:57:44 +00:00
CLQ1_AddOrientedCube ( s , min , max , NULL , 0 , 0 , 0.1 , 1 ) ;
}
}
2009-11-04 21:16:50 +00:00
if ( r_torch . ival )
{
dlight_t * dl ;
2011-12-27 08:35:19 +00:00
dl = CL_NewDlight ( j + 1 , ent - > origin , 300 , r_torch . ival , 0.5 , 0.5 , 0.2 ) ;
2011-07-30 14:14:56 +00:00
dl - > flags | = LFLAG_SHADOWMAP | LFLAG_FLASHBLEND ;
2009-11-04 21:16:50 +00:00
dl - > fov = 60 ;
angles [ 0 ] * = 3 ;
angles [ 1 ] + = sin ( realtime ) * 8 ;
angles [ 0 ] + = cos ( realtime * 1.13 ) * 5 ;
AngleVectors ( angles , dl - > axis [ 0 ] , dl - > axis [ 1 ] , dl - > axis [ 2 ] ) ;
}
2004-08-23 00:15:46 +00:00
}
}
2005-02-12 18:56:04 +00:00
void CL_LinkViewModel ( void )
{
2015-09-01 04:45:15 +00:00
# ifdef QUAKESTATS
2018-12-06 04:55:35 +00:00
extern cvar_t r_viewpreselgun ;
2005-02-12 18:56:04 +00:00
entity_t ent ;
2011-04-25 03:25:22 +00:00
unsigned int plnum ;
added r_meshpitch cvar that allows for fixing the unfixable mesh pitch bug from vanilla... needs a better name... do note that this will break pretty much any mod, so this is really only for TCs designed to use it. Its likely that I missed places.
nqsv: added support for spectators with nq clients. the angles are a bit rough, but hey. need to do something about frags so nq clients know who's a spectator. use 'cmd observe' to get an nq client to spectate on an fte server (then attack/jump behave the same as in qw clients).
nqsv: rewrote EF_MUZZLEFLASH handling, so svc_muzzleflash is now translated properly to EF_MUZZLEFLASH, and vice versa. No more missing muzzleflashes!
added screenshot_cubemap, so you can actually pre-generate cubemaps with fte (which can be used for reflections or whatever).
misc fixes (server crash, a couple of other less important ones).
external files based on a model's name will now obey r_replacemodels properly, instead of needing to use foo.mdl_0.skin for foo.md3.
identify <playernum> should now use the correct masked ip, instead of abrubtly failing (reported by kt)
vid_toggle console command should now obey vid_width and vid_height when switching to fullscreen, but only if vid_fullscreen is actually set, which should make it seem better behaved (reported by kt).
qcc: cleaned up sym->symboldata[sym->ofs] to be more consistent at all stages.
qcc: typedef float vec4[4]; now works to define a float array with 4 elements (however, it will be passed by-value rather than by-reference).
qcc: cleaned up optional vs __out ordering issues.
qccgui: shift+f3 searches backwards
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@5064 fc73d0e0-1445-4013-8a0c-d673dee63da5
2017-02-27 09:34:35 +00:00
unsigned int playereffects ;
2006-02-27 00:42:25 +00:00
float alpha ;
2013-06-23 02:17:02 +00:00
playerview_t * pv = r_refdef . playerview ;
2018-12-06 04:55:35 +00:00
const char * preselectedmodelname ;
2005-02-12 18:56:04 +00:00
2006-05-17 23:01:06 +00:00
extern cvar_t cl_gunx , cl_guny , cl_gunz ;
2006-05-17 23:16:26 +00:00
extern cvar_t cl_gunanglex , cl_gunangley , cl_gunanglez ;
2006-05-17 23:01:06 +00:00
2013-06-23 02:17:02 +00:00
if ( r_drawviewmodel . value < = 0 | | ! Cam_DrawViewModel ( r_refdef . playerview ) )
2005-02-12 18:56:04 +00:00
return ;
# ifdef Q2CLIENT
2005-05-26 12:55:34 +00:00
if ( cls . protocol = = CP_QUAKE2 )
2016-01-18 05:22:07 +00:00
{
V_ClearEntity ( & ent ) ;
ent . model = pv - > vm . oldmodel ;
ent . framestate . g [ FS_REG ] . frame [ 0 ] = pv - > vm . prevframe ;
ent . framestate . g [ FS_REG ] . frame [ 1 ] = pv - > vm . oldframe ;
ent . framestate . g [ FS_REG ] . frametime [ 0 ] = pv - > vm . lerptime ;
ent . framestate . g [ FS_REG ] . frametime [ 1 ] = pv - > vm . oldlerptime ;
ent . framestate . g [ FS_REG ] . lerpweight [ 0 ] = 1 - cl . lerpfrac ;
ent . framestate . g [ FS_REG ] . lerpweight [ 1 ] = cl . lerpfrac ;
ent . flags | = RF_WEAPONMODEL | RF_DEPTHHACK | RF_NOSHADOW ;
V_AddEntity ( & ent ) ;
2005-02-12 18:56:04 +00:00
return ;
2016-01-18 05:22:07 +00:00
}
2005-02-12 18:56:04 +00:00
# endif
2009-11-04 21:16:50 +00:00
if ( ! r_drawentities . ival )
2005-02-12 18:56:04 +00:00
return ;
2013-06-23 02:17:02 +00:00
if ( ( r_refdef . playerview - > stats [ STAT_ITEMS ] & IT_INVISIBILITY ) & & r_drawviewmodelinvis . value < = 0 )
2005-02-12 18:56:04 +00:00
return ;
2013-06-23 02:17:02 +00:00
if ( r_refdef . playerview - > stats [ STAT_HEALTH ] < = 0 )
2005-02-12 18:56:04 +00:00
return ;
2015-09-01 04:45:15 +00:00
if ( cl . intermissionmode ! = IM_NONE )
2013-10-08 14:28:11 +00:00
return ;
2015-03-03 00:14:43 +00:00
if ( pv - > stats [ STAT_WEAPONMODELI ] < = 0 | | pv - > stats [ STAT_WEAPONMODELI ] > = MAX_PRECACHE_MODELS )
2013-10-08 14:28:11 +00:00
return ;
2005-02-12 18:56:04 +00:00
if ( r_drawviewmodel . value > 0 & & r_drawviewmodel . value < 1 )
2006-02-27 00:42:25 +00:00
alpha = r_drawviewmodel . value ;
2005-02-12 18:56:04 +00:00
else
2006-02-27 00:42:25 +00:00
alpha = 1 ;
2005-02-12 18:56:04 +00:00
2016-01-18 05:22:07 +00:00
if ( ( pv - > stats [ STAT_ITEMS ] & IT_INVISIBILITY )
2006-01-09 01:49:06 +00:00
& & r_drawviewmodelinvis . value > 0
& & r_drawviewmodelinvis . value < 1 )
2006-02-27 00:42:25 +00:00
alpha * = r_drawviewmodelinvis . value ;
2015-08-20 03:17:47 +00:00
//FIXME: scale alpha by the player's alpha too
2011-04-25 03:25:22 +00:00
if ( alpha < = 0 )
return ;
------------------------------------------------------------------------
r4169 | acceptthis | 2013-01-17 08:55:12 +0000 (Thu, 17 Jan 2013) | 31 lines
removed MAX_VISEDICTS limit.
PEXT2_REPLACEMENTDELTAS tweaked, now has 4 million entity limit. still not enabled by default.
TE_BEAM now maps to a separate TEQW_BEAM to avoid conflicts with QW.
added android multitouch emulation for windows/rawinput (in_simulatemultitouch).
split topcolor/bottomcolor from scoreboard, for dp's colormap|1024 feature.
now using utf-8 for windows consoles.
qcc warnings/errors now give clickable console links for quick+easy editing.
disabled menutint when the currently active item changes contrast or gamma (for OneManClan).
Added support for drawfont/drawfontscale.
tweaked the qcvm a little to reduce the number of pointers.
.doll file loading. still experimental and will likely crash. requires csqc active, even if its a dummy progs. this will be fixed in time. Still other things that need cleaning up.
windows: gl_font "?" shows the standard windows font-selection dialog, and can be used to select windows fonts. not all work. and you probably don't want to use windings.
fixed splitscreen support when playing mvds. added mini-scoreboards to splitscreen.
editor/debugger now shows asm if there's no linenumber info. also, pressing f1 for help shows the shortcuts.
Added support for .framegroups files for psk(psa) and iqm formats.
True support for ezquake's colour codes. Mutually exclusive with background colours.
path command output slightly more readable.
added support for digest_hex (MD4, SHA1, CRC16).
skingroups now colourmap correctly.
Fix terrain colour hints, and litdata from the wrong bsp.
fix ftp dual-homed issue. support epsv command, and enable ipv6 (eprt still not supported).
remove d3d11 compilation from the makefile. the required headers are not provided by mingw, and are not available to the build bot, so don't bother.
fix v *= v.x and similar opcodes.
fteqcc: fixed support for áéíóú type chars in names. utf-8 files now properly supported (even with the utf-8 bom/identifier). utf-16 also supported.
fteqcc: fixed '#if 1 == 3 && 4' parsing.
fteqcc: -Werror acts on the warning, rather than as a separate error. Line numbers are thus more readable.
fteqcc: copyright message now includes compile date instead.
fteqccgui: the treeview control is now coloured depending on whether there were warnings/errors in the last compile.
fteqccgui: the output window is now focused and scrolls down as compilation progresses.
pr_dumpplatform command dumps out some pragmas to convert more serious warnings to errors. This is to avoid the infamous 'fteqcc sucks cos my code sucks' issue.
rewrote prespawn/modelist/soundlist code. server tracks progress now.
------------------------------------------------------------------------
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@4167 fc73d0e0-1445-4013-8a0c-d673dee63da5
2013-03-12 22:29:40 +00:00
V_ClearEntity ( & ent ) ;
2011-04-25 03:25:22 +00:00
2006-05-19 21:00:55 +00:00
# ifdef PEXT_SCALE
ent . scale = 1 ;
# endif
2006-05-17 23:01:06 +00:00
ent . origin [ 0 ] = cl_gunz . value ;
ent . origin [ 1 ] = - cl_gunx . value ;
ent . origin [ 2 ] = - cl_guny . value ;
2006-05-17 23:16:26 +00:00
ent . angles [ 0 ] = cl_gunanglex . value ;
ent . angles [ 1 ] = cl_gunangley . value ;
ent . angles [ 2 ] = cl_gunanglez . value ;
2020-01-20 17:58:45 +00:00
ent . glowmod [ 0 ] = ent . glowmod [ 1 ] = ent . glowmod [ 2 ] = 1 ;
ent . shaderRGBAf [ 0 ] = ent . shaderRGBAf [ 1 ] = ent . shaderRGBAf [ 2 ] = 1 ;
2006-02-27 00:42:25 +00:00
ent . shaderRGBAf [ 3 ] = alpha ;
2011-04-25 03:25:22 +00:00
if ( alpha ! = 1 )
{
2014-03-31 17:06:41 +00:00
ent . flags | = RF_TRANSLUCENT ;
2011-04-25 03:25:22 +00:00
}
2006-01-09 01:49:06 +00:00
2018-12-06 04:55:35 +00:00
preselectedmodelname = r_viewpreselgun . ival ? IN_GetPreselectedViewmodelName ( pv - cl . playerview ) : NULL ;
if ( preselectedmodelname )
ent . model = Mod_ForName ( preselectedmodelname , MLV_SILENT ) ;
else
ent . model = NULL ;
if ( ! ent . model )
2015-03-03 00:14:43 +00:00
ent . model = cl . model_precache [ pv - > stats [ STAT_WEAPONMODELI ] ] ;
2013-10-08 14:28:11 +00:00
if ( ! ent . model )
2015-08-24 15:47:40 +00:00
{
pv - > vm . oldmodel = NULL ;
2013-10-08 14:28:11 +00:00
return ;
2015-08-24 15:47:40 +00:00
}
2013-10-08 14:28:11 +00:00
2009-04-01 22:03:56 +00:00
# ifdef HLCLIENT
if ( ! CLHL_AnimateViewEntity ( & ent ) )
# endif
2005-02-12 18:56:04 +00:00
{
2014-05-17 15:25:02 +00:00
//if the model changed, reset everything.
if ( ent . model ! = pv - > vm . oldmodel )
2009-04-01 22:03:56 +00:00
{
2014-05-17 15:25:02 +00:00
pv - > vm . oldmodel = ent . model ;
pv - > vm . oldframe = pv - > vm . prevframe = pv - > stats [ STAT_WEAPONFRAME ] ;
2015-08-24 15:47:40 +00:00
pv - > vm . oldlerptime = pv - > vm . lerptime = cl . time ;
2014-05-17 15:25:02 +00:00
pv - > vm . frameduration = 0.1 ;
2009-04-01 22:03:56 +00:00
}
2014-05-17 15:25:02 +00:00
//if the frame changed, update the oldframe to lerp into the new frame
else if ( pv - > stats [ STAT_WEAPONFRAME ] ! = pv - > vm . prevframe )
2009-04-01 22:03:56 +00:00
{
2014-05-17 15:25:02 +00:00
pv - > vm . oldframe = pv - > vm . prevframe ;
pv - > vm . prevframe = pv - > stats [ STAT_WEAPONFRAME ] ;
pv - > vm . oldlerptime = pv - > vm . lerptime ;
2015-08-24 15:47:40 +00:00
pv - > vm . frameduration = ( cl . time - pv - > vm . lerptime ) ;
2014-05-17 15:25:02 +00:00
if ( pv - > vm . frameduration < 0.01 ) //no faster than 100 times a second... to avoid divide by zero
pv - > vm . frameduration = 0.01 ;
if ( pv - > vm . frameduration > 0.2 ) //no slower than 5 times a second
pv - > vm . frameduration = 0.2 ;
2015-08-24 15:47:40 +00:00
pv - > vm . lerptime = cl . time ;
2009-04-01 22:03:56 +00:00
}
2014-05-17 15:25:02 +00:00
//work out the blend fraction
ent . framestate . g [ FS_REG ] . frame [ 0 ] = pv - > vm . prevframe ;
ent . framestate . g [ FS_REG ] . frame [ 1 ] = pv - > vm . oldframe ;
2015-08-24 15:47:40 +00:00
ent . framestate . g [ FS_REG ] . frametime [ 0 ] = cl . time - pv - > vm . lerptime ;
ent . framestate . g [ FS_REG ] . frametime [ 1 ] = cl . time - pv - > vm . oldlerptime ;
ent . framestate . g [ FS_REG ] . lerpweight [ 0 ] = ( cl . time - pv - > vm . lerptime ) / pv - > vm . frameduration ;
2015-02-02 08:01:53 +00:00
ent . framestate . g [ FS_REG ] . lerpweight [ 0 ] = bound ( 0 , ent . framestate . g [ FS_REG ] . lerpweight [ 0 ] , 1 ) ;
ent . framestate . g [ FS_REG ] . lerpweight [ 1 ] = 1 - ent . framestate . g [ FS_REG ] . lerpweight [ 0 ] ;
2009-04-01 22:03:56 +00:00
}
2005-02-12 18:56:04 +00:00
2014-03-31 17:06:41 +00:00
ent . flags | = RF_WEAPONMODEL | RF_DEPTHHACK | RF_NOSHADOW ;
2009-11-04 21:16:50 +00:00
2011-04-25 03:25:22 +00:00
plnum = - 1 ;
2017-05-28 15:42:32 +00:00
if ( pv - > spectator )
2013-06-23 02:17:02 +00:00
plnum = Cam_TrackNum ( pv ) ;
2011-04-25 03:25:22 +00:00
if ( plnum = = - 1 )
2013-06-23 02:17:02 +00:00
plnum = r_refdef . playerview - > playernum ;
added r_meshpitch cvar that allows for fixing the unfixable mesh pitch bug from vanilla... needs a better name... do note that this will break pretty much any mod, so this is really only for TCs designed to use it. Its likely that I missed places.
nqsv: added support for spectators with nq clients. the angles are a bit rough, but hey. need to do something about frags so nq clients know who's a spectator. use 'cmd observe' to get an nq client to spectate on an fte server (then attack/jump behave the same as in qw clients).
nqsv: rewrote EF_MUZZLEFLASH handling, so svc_muzzleflash is now translated properly to EF_MUZZLEFLASH, and vice versa. No more missing muzzleflashes!
added screenshot_cubemap, so you can actually pre-generate cubemaps with fte (which can be used for reflections or whatever).
misc fixes (server crash, a couple of other less important ones).
external files based on a model's name will now obey r_replacemodels properly, instead of needing to use foo.mdl_0.skin for foo.md3.
identify <playernum> should now use the correct masked ip, instead of abrubtly failing (reported by kt)
vid_toggle console command should now obey vid_width and vid_height when switching to fullscreen, but only if vid_fullscreen is actually set, which should make it seem better behaved (reported by kt).
qcc: cleaned up sym->symboldata[sym->ofs] to be more consistent at all stages.
qcc: typedef float vec4[4]; now works to define a float array with 4 elements (however, it will be passed by-value rather than by-reference).
qcc: cleaned up optional vs __out ordering issues.
qccgui: shift+f3 searches backwards
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@5064 fc73d0e0-1445-4013-8a0c-d673dee63da5
2017-02-27 09:34:35 +00:00
playereffects = 0 ;
2017-12-11 02:55:06 +00:00
if ( r_refdef . playerview - > nolocalplayer & & plnum < cl . maxlerpents )
added r_meshpitch cvar that allows for fixing the unfixable mesh pitch bug from vanilla... needs a better name... do note that this will break pretty much any mod, so this is really only for TCs designed to use it. Its likely that I missed places.
nqsv: added support for spectators with nq clients. the angles are a bit rough, but hey. need to do something about frags so nq clients know who's a spectator. use 'cmd observe' to get an nq client to spectate on an fte server (then attack/jump behave the same as in qw clients).
nqsv: rewrote EF_MUZZLEFLASH handling, so svc_muzzleflash is now translated properly to EF_MUZZLEFLASH, and vice versa. No more missing muzzleflashes!
added screenshot_cubemap, so you can actually pre-generate cubemaps with fte (which can be used for reflections or whatever).
misc fixes (server crash, a couple of other less important ones).
external files based on a model's name will now obey r_replacemodels properly, instead of needing to use foo.mdl_0.skin for foo.md3.
identify <playernum> should now use the correct masked ip, instead of abrubtly failing (reported by kt)
vid_toggle console command should now obey vid_width and vid_height when switching to fullscreen, but only if vid_fullscreen is actually set, which should make it seem better behaved (reported by kt).
qcc: cleaned up sym->symboldata[sym->ofs] to be more consistent at all stages.
qcc: typedef float vec4[4]; now works to define a float array with 4 elements (however, it will be passed by-value rather than by-reference).
qcc: cleaned up optional vs __out ordering issues.
qccgui: shift+f3 searches backwards
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@5064 fc73d0e0-1445-4013-8a0c-d673dee63da5
2017-02-27 09:34:35 +00:00
{
if ( plnum + 1 < cl . maxlerpents )
{
lerpents_t * le = & cl . lerpents [ plnum + 1 ] ;
if ( le - > entstate )
playereffects = le - > entstate - > effects ;
}
}
2017-12-11 02:55:06 +00:00
else if ( plnum < cl . allocated_client_slots )
added r_meshpitch cvar that allows for fixing the unfixable mesh pitch bug from vanilla... needs a better name... do note that this will break pretty much any mod, so this is really only for TCs designed to use it. Its likely that I missed places.
nqsv: added support for spectators with nq clients. the angles are a bit rough, but hey. need to do something about frags so nq clients know who's a spectator. use 'cmd observe' to get an nq client to spectate on an fte server (then attack/jump behave the same as in qw clients).
nqsv: rewrote EF_MUZZLEFLASH handling, so svc_muzzleflash is now translated properly to EF_MUZZLEFLASH, and vice versa. No more missing muzzleflashes!
added screenshot_cubemap, so you can actually pre-generate cubemaps with fte (which can be used for reflections or whatever).
misc fixes (server crash, a couple of other less important ones).
external files based on a model's name will now obey r_replacemodels properly, instead of needing to use foo.mdl_0.skin for foo.md3.
identify <playernum> should now use the correct masked ip, instead of abrubtly failing (reported by kt)
vid_toggle console command should now obey vid_width and vid_height when switching to fullscreen, but only if vid_fullscreen is actually set, which should make it seem better behaved (reported by kt).
qcc: cleaned up sym->symboldata[sym->ofs] to be more consistent at all stages.
qcc: typedef float vec4[4]; now works to define a float array with 4 elements (however, it will be passed by-value rather than by-reference).
qcc: cleaned up optional vs __out ordering issues.
qccgui: shift+f3 searches backwards
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@5064 fc73d0e0-1445-4013-8a0c-d673dee63da5
2017-02-27 09:34:35 +00:00
playereffects = cl . inframes [ parsecountmod ] . playerstate [ plnum ] . effects ;
2005-04-16 16:21:27 +00:00
added r_meshpitch cvar that allows for fixing the unfixable mesh pitch bug from vanilla... needs a better name... do note that this will break pretty much any mod, so this is really only for TCs designed to use it. Its likely that I missed places.
nqsv: added support for spectators with nq clients. the angles are a bit rough, but hey. need to do something about frags so nq clients know who's a spectator. use 'cmd observe' to get an nq client to spectate on an fte server (then attack/jump behave the same as in qw clients).
nqsv: rewrote EF_MUZZLEFLASH handling, so svc_muzzleflash is now translated properly to EF_MUZZLEFLASH, and vice versa. No more missing muzzleflashes!
added screenshot_cubemap, so you can actually pre-generate cubemaps with fte (which can be used for reflections or whatever).
misc fixes (server crash, a couple of other less important ones).
external files based on a model's name will now obey r_replacemodels properly, instead of needing to use foo.mdl_0.skin for foo.md3.
identify <playernum> should now use the correct masked ip, instead of abrubtly failing (reported by kt)
vid_toggle console command should now obey vid_width and vid_height when switching to fullscreen, but only if vid_fullscreen is actually set, which should make it seem better behaved (reported by kt).
qcc: cleaned up sym->symboldata[sym->ofs] to be more consistent at all stages.
qcc: typedef float vec4[4]; now works to define a float array with 4 elements (however, it will be passed by-value rather than by-reference).
qcc: cleaned up optional vs __out ordering issues.
qccgui: shift+f3 searches backwards
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@5064 fc73d0e0-1445-4013-8a0c-d673dee63da5
2017-02-27 09:34:35 +00:00
if ( playereffects & DPEF_NOGUNBOB )
2016-07-12 00:40:13 +00:00
ent . flags | = RF_WEAPONMODELNOBOB ;
2014-10-11 19:39:45 +00:00
/* ent.topcolour = TOP_DEFAULT;//cl.players[plnum].ttopcolor;
ent . bottomcolour = cl . players [ plnum ] . tbottomcolor ;
ent . h2playerclass = cl . players [ plnum ] . h2playerclass ;
*/
added r_meshpitch cvar that allows for fixing the unfixable mesh pitch bug from vanilla... needs a better name... do note that this will break pretty much any mod, so this is really only for TCs designed to use it. Its likely that I missed places.
nqsv: added support for spectators with nq clients. the angles are a bit rough, but hey. need to do something about frags so nq clients know who's a spectator. use 'cmd observe' to get an nq client to spectate on an fte server (then attack/jump behave the same as in qw clients).
nqsv: rewrote EF_MUZZLEFLASH handling, so svc_muzzleflash is now translated properly to EF_MUZZLEFLASH, and vice versa. No more missing muzzleflashes!
added screenshot_cubemap, so you can actually pre-generate cubemaps with fte (which can be used for reflections or whatever).
misc fixes (server crash, a couple of other less important ones).
external files based on a model's name will now obey r_replacemodels properly, instead of needing to use foo.mdl_0.skin for foo.md3.
identify <playernum> should now use the correct masked ip, instead of abrubtly failing (reported by kt)
vid_toggle console command should now obey vid_width and vid_height when switching to fullscreen, but only if vid_fullscreen is actually set, which should make it seem better behaved (reported by kt).
qcc: cleaned up sym->symboldata[sym->ofs] to be more consistent at all stages.
qcc: typedef float vec4[4]; now works to define a float array with 4 elements (however, it will be passed by-value rather than by-reference).
qcc: cleaned up optional vs __out ordering issues.
qccgui: shift+f3 searches backwards
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@5064 fc73d0e0-1445-4013-8a0c-d673dee63da5
2017-02-27 09:34:35 +00:00
CLQ1_AddPowerupShell ( V_AddEntity ( & ent ) , true , playereffects ) ;
2012-09-30 05:52:03 +00:00
2015-08-20 03:17:47 +00:00
//small hack to mask depth so only the front faces of the weaponmodel appear (no glitchy intra faces).
2012-09-30 05:52:03 +00:00
if ( alpha < 1 & & qrenderer = = QR_OPENGL )
{
2013-08-21 07:14:39 +00:00
ent . forcedshader = R_RegisterShader ( " viewmodeldepthmask " , SUF_NONE ,
2012-09-30 05:52:03 +00:00
" { \n "
" noshadows \n "
" surfaceparm nodlight \n "
" { \n "
" map $whiteimage \n "
" maskcolor \n "
" depthwrite \n "
" } \n "
" } \n "
) ;
ent . shaderRGBAf [ 3 ] = 1 ;
2014-03-31 17:06:41 +00:00
ent . flags & = ~ RF_TRANSLUCENT ;
2012-09-30 05:52:03 +00:00
V_AddEntity ( & ent ) ;
ent . forcedshader = NULL ;
ent . shaderRGBAf [ 3 ] = alpha ;
2014-03-31 17:06:41 +00:00
ent . flags | = RF_TRANSLUCENT ;
2012-09-30 05:52:03 +00:00
}
2015-09-01 04:45:15 +00:00
# endif
2005-02-12 18:56:04 +00:00
}
2004-08-23 00:15:46 +00:00
//======================================================================
/*
= = = = = = = = = = = = = = =
CL_SetSolid
Builds all the pmove physents for the current frame
= = = = = = = = = = = = = = =
*/
void CL_SetSolidEntities ( void )
{
int i ;
2013-03-12 22:53:23 +00:00
inframe_t * frame ;
2004-08-23 00:15:46 +00:00
packet_entities_t * pak ;
entity_state_t * state ;
2012-02-12 05:18:31 +00:00
physent_t * pent ;
2019-02-24 08:32:45 +00:00
model_t * mod ;
2004-08-23 00:15:46 +00:00
2019-07-29 05:28:20 +00:00
VALGRIND_MAKE_MEM_UNDEFINED ( & pmove , sizeof ( pmove ) ) ;
2019-09-04 07:59:40 +00:00
# ifdef CSQC_DAT
2019-07-29 05:28:20 +00:00
pmove . world = & csqc_world ;
2019-09-04 07:59:40 +00:00
# endif
2019-07-29 05:28:20 +00:00
2009-03-03 01:52:30 +00:00
memset ( & pmove . physents [ 0 ] , 0 , sizeof ( physent_t ) ) ;
2004-08-23 00:15:46 +00:00
pmove . physents [ 0 ] . model = cl . worldmodel ;
2006-05-29 04:50:24 +00:00
VectorClear ( pmove . physents [ 0 ] . origin ) ;
2004-08-23 00:15:46 +00:00
pmove . physents [ 0 ] . info = 0 ;
pmove . numphysent = 1 ;
2017-08-29 02:29:06 +00:00
frame = & cl . inframes [ cl . validsequence & UPDATE_MASK ] ;
2004-08-23 00:15:46 +00:00
pak = & frame - > packet_entities ;
for ( i = 0 ; i < pak - > num_entities ; i + + )
{
state = & pak - > entities [ i ] ;
2016-07-12 00:40:13 +00:00
if ( state - > solidsize = = ES_SOLID_NOT )
2004-08-23 00:15:46 +00:00
continue ;
2012-02-12 05:18:31 +00:00
2016-07-12 00:40:13 +00:00
if ( state - > solidsize = = ES_SOLID_BSP )
2012-02-12 05:18:31 +00:00
{ /*bsp model size*/
if ( state - > modelindex < = 0 )
continue ;
2019-02-24 08:32:45 +00:00
mod = cl . model_precache [ state - > modelindex ] ;
2020-08-13 08:39:48 +00:00
if ( ! mod | | mod - > loadstate ! = MLS_LOADED )
2012-02-12 05:18:31 +00:00
continue ;
2013-03-12 22:53:23 +00:00
/*vanilla protocols have no 'solid' information. all entities get assigned ES_SOLID_BSP, even if its not actually solid.
so we need to make sure that item pickups are not erroneously considered solid , but doors etc are .
2019-02-24 08:32:45 +00:00
normally , ONLY inline models are considered solid when we have no solid info .
monsters will always be non - solid , too .
2013-03-12 22:53:23 +00:00
*/
2019-02-24 08:32:45 +00:00
if ( ! ( cls . fteprotocolextensions2 & PEXT2_REPLACEMENTDELTAS ) & & mod - > numsubmodels < = 1 )
2012-02-12 05:18:31 +00:00
continue ;
2013-03-12 22:53:23 +00:00
pent = & pmove . physents [ pmove . numphysent ] ;
memset ( pent , 0 , sizeof ( physent_t ) ) ;
2019-02-24 08:32:45 +00:00
pent - > model = mod ;
2013-03-12 22:53:23 +00:00
VectorCopy ( state - > angles , pent - > angles ) ;
added r_meshpitch cvar that allows for fixing the unfixable mesh pitch bug from vanilla... needs a better name... do note that this will break pretty much any mod, so this is really only for TCs designed to use it. Its likely that I missed places.
nqsv: added support for spectators with nq clients. the angles are a bit rough, but hey. need to do something about frags so nq clients know who's a spectator. use 'cmd observe' to get an nq client to spectate on an fte server (then attack/jump behave the same as in qw clients).
nqsv: rewrote EF_MUZZLEFLASH handling, so svc_muzzleflash is now translated properly to EF_MUZZLEFLASH, and vice versa. No more missing muzzleflashes!
added screenshot_cubemap, so you can actually pre-generate cubemaps with fte (which can be used for reflections or whatever).
misc fixes (server crash, a couple of other less important ones).
external files based on a model's name will now obey r_replacemodels properly, instead of needing to use foo.mdl_0.skin for foo.md3.
identify <playernum> should now use the correct masked ip, instead of abrubtly failing (reported by kt)
vid_toggle console command should now obey vid_width and vid_height when switching to fullscreen, but only if vid_fullscreen is actually set, which should make it seem better behaved (reported by kt).
qcc: cleaned up sym->symboldata[sym->ofs] to be more consistent at all stages.
qcc: typedef float vec4[4]; now works to define a float array with 4 elements (however, it will be passed by-value rather than by-reference).
qcc: cleaned up optional vs __out ordering issues.
qccgui: shift+f3 searches backwards
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@5064 fc73d0e0-1445-4013-8a0c-d673dee63da5
2017-02-27 09:34:35 +00:00
pent - > angles [ 0 ] * = r_meshpitch . value ;
2020-10-06 03:17:28 +00:00
pent - > angles [ 2 ] * = r_meshroll . value ;
2012-02-12 05:18:31 +00:00
}
else
{
pent = & pmove . physents [ pmove . numphysent ] ;
memset ( pent , 0 , sizeof ( physent_t ) ) ;
pent - > info = state - > number ;
/*don't bother with angles*/
2016-07-12 00:40:13 +00:00
COM_DecodeSize ( state - > solidsize , pent - > mins , pent - > maxs ) ;
2012-02-12 05:18:31 +00:00
}
if ( + + pmove . numphysent = = MAX_PHYSENTS )
break ;
VectorCopy ( state - > origin , pent - > origin ) ;
pent - > info = state - > number ;
switch ( ( int ) state - > skinnum )
{
case 0 :
break ;
2012-02-27 12:23:15 +00:00
case Q1CONTENTS_LADDER :
2012-02-12 05:18:31 +00:00
pent - > nonsolid = true ;
pent - > forcecontentsmask = FTECONTENTS_LADDER ;
break ;
case Q1CONTENTS_SKY :
pent - > nonsolid = true ;
pent - > forcecontentsmask = FTECONTENTS_SKY ;
break ;
case Q1CONTENTS_LAVA :
pent - > nonsolid = true ;
pent - > forcecontentsmask = FTECONTENTS_LAVA ;
break ;
case Q1CONTENTS_SLIME :
pent - > nonsolid = true ;
pent - > forcecontentsmask = FTECONTENTS_SLIME ;
break ;
case Q1CONTENTS_WATER :
pent - > nonsolid = true ;
pent - > forcecontentsmask = FTECONTENTS_WATER ;
break ;
2004-08-23 00:15:46 +00:00
}
}
}
/*
= = =
Calculate the new position of players , without other player clipping
We do this to set up real player prediction .
Players are predicted twice , first without clipping other players ,
then with clipping against them .
This sets up the first phase .
= = =
*/
void CL_SetUpPlayerPrediction ( qboolean dopred )
{
int j ;
player_state_t * state ;
player_state_t exact ;
double playertime ;
int msec ;
2013-03-12 22:53:23 +00:00
inframe_t * frame ;
2004-08-23 00:15:46 +00:00
struct predicted_player * pplayer ;
2015-06-05 09:04:05 +00:00
extern cvar_t cl_nopred , cl_demospeed ;
2012-04-24 07:59:11 +00:00
float predictmsmult = 1000 * cl_predict_players_frac . value ;
2004-08-23 00:15:46 +00:00
2009-05-24 10:11:17 +00:00
int s ;
2015-06-28 03:43:10 +00:00
playertime = realtime - cls . latency * cl_predict_players_latency . value + cl_predict_players_nudge . value ;
2004-08-23 00:15:46 +00:00
if ( playertime > realtime )
playertime = realtime ;
2014-10-05 20:04:11 +00:00
if ( cl_nopred . value | | /*cls.demoplayback ||*/ cl . paused | | cl . worldmodel - > loadstate ! = MLS_LOADED )
2004-08-23 00:15:46 +00:00
return ;
2015-06-05 09:04:05 +00:00
if ( cls . demoplayback )
predictmsmult * = cl_demospeed . value ;
2013-03-12 22:53:23 +00:00
frame = & cl . inframes [ cl . parsecount & UPDATE_MASK ] ;
2004-08-23 00:15:46 +00:00
2005-02-06 02:47:36 +00:00
for ( j = 0 , pplayer = predicted_players , state = frame - > playerstate ;
2013-10-29 17:38:22 +00:00
j < cl . allocated_client_slots ;
2004-10-04 07:26:16 +00:00
j + + , pplayer + + , state + + )
{
2004-08-23 00:15:46 +00:00
pplayer - > active = false ;
if ( state - > messagenum ! = cl . parsecount )
continue ; // not present this frame
if ( ! state - > modelindex )
continue ;
pplayer - > active = true ;
pplayer - > flags = state - > flags ;
2013-06-23 02:17:02 +00:00
// note that the local players are special, since they move locally
// we use their last predicted postition
2009-05-24 10:11:17 +00:00
for ( s = 0 ; s < cl . splitclients ; s + + )
2004-10-04 07:26:16 +00:00
{
2013-06-23 02:17:02 +00:00
if ( j = = cl . playerview [ s ] . playernum )
2009-05-24 10:11:17 +00:00
{
2013-06-23 02:17:02 +00:00
VectorCopy ( cl . inframes [ cls . netchan . outgoing_sequence & UPDATE_MASK ] . playerstate [ cl . playerview [ s ] . playernum ] . origin , pplayer - > origin ) ;
2009-05-24 10:11:17 +00:00
break ;
}
2004-10-04 07:26:16 +00:00
}
2009-05-24 10:11:17 +00:00
if ( s = = cl . splitclients )
2004-10-04 07:26:16 +00:00
{
2004-08-23 00:15:46 +00:00
// only predict half the move to minimize overruns
2012-04-24 07:59:11 +00:00
msec = predictmsmult * ( playertime - state - > state_time ) ;
2004-08-23 00:15:46 +00:00
if ( msec < = 0 | |
2011-06-15 23:01:07 +00:00
! cl_predict_players . ival | |
2004-08-23 00:15:46 +00:00
! dopred )
{
VectorCopy ( state - > origin , pplayer - > origin ) ;
//Con_DPrintf ("nopredict\n");
}
else
{
// predict players movement
2012-04-24 07:59:11 +00:00
if ( msec > 250 )
msec = 250 ;
2004-08-23 00:15:46 +00:00
state - > command . msec = msec ;
//Con_DPrintf ("predict: %i\n", msec);
2012-04-24 07:59:11 +00:00
CL_PredictUsercmd ( 0 , j + 1 , state , & exact , & state - > command ) ;
2004-08-23 00:15:46 +00:00
VectorCopy ( exact . origin , pplayer - > origin ) ;
}
}
}
}
/*
= = = = = = = = = = = = = = =
CL_SetSolid
Builds all the pmove physents for the current frame
Note that CL_SetUpPlayerPrediction ( ) must be called first !
pmove must be setup with world and solid entity hulls before calling
( via CL_PredictMove )
= = = = = = = = = = = = = = =
*/
2012-02-12 05:18:31 +00:00
void CL_SetSolidPlayers ( void )
2004-08-23 00:15:46 +00:00
{
int j ;
struct predicted_player * pplayer ;
physent_t * pent ;
2009-11-04 21:16:50 +00:00
if ( ! cl_solid_players . ival )
2004-08-23 00:15:46 +00:00
return ;
pent = pmove . physents + pmove . numphysent ;
if ( pmove . numphysent = = MAX_PHYSENTS ) //too many.
return ;
2013-10-29 17:38:22 +00:00
for ( j = 0 , pplayer = predicted_players ; j < cl . allocated_client_slots ; j + + , pplayer + + )
2012-04-24 07:59:11 +00:00
{
2004-08-23 00:15:46 +00:00
if ( ! pplayer - > active )
continue ; // not present this frame
2019-03-01 22:39:30 +00:00
if ( ! ( pplayer - > flags & PF_SOLID ) )
continue ;
2004-08-23 00:15:46 +00:00
2009-03-03 01:52:30 +00:00
memset ( pent , 0 , sizeof ( physent_t ) ) ;
2004-08-23 00:15:46 +00:00
VectorCopy ( pplayer - > origin , pent - > origin ) ;
2012-02-14 15:50:34 +00:00
pent - > info = j + 1 ;
2014-01-13 02:42:25 +00:00
VectorCopy ( pmove . player_mins , pent - > mins ) ;
VectorCopy ( pmove . player_maxs , pent - > maxs ) ;
2004-08-23 00:15:46 +00:00
if ( + + pmove . numphysent = = MAX_PHYSENTS ) //we just hit 88 miles per hour.
break ;
pent + + ;
}
}
/*
= = = = = = = = = = = = = = =
CL_EmitEntities
Builds the visedicts array for cl . time
Made up of : clients , packet_entities , nails , and tents
= = = = = = = = = = = = = = =
*/
------------------------------------------------------------------------
r4169 | acceptthis | 2013-01-17 08:55:12 +0000 (Thu, 17 Jan 2013) | 31 lines
removed MAX_VISEDICTS limit.
PEXT2_REPLACEMENTDELTAS tweaked, now has 4 million entity limit. still not enabled by default.
TE_BEAM now maps to a separate TEQW_BEAM to avoid conflicts with QW.
added android multitouch emulation for windows/rawinput (in_simulatemultitouch).
split topcolor/bottomcolor from scoreboard, for dp's colormap|1024 feature.
now using utf-8 for windows consoles.
qcc warnings/errors now give clickable console links for quick+easy editing.
disabled menutint when the currently active item changes contrast or gamma (for OneManClan).
Added support for drawfont/drawfontscale.
tweaked the qcvm a little to reduce the number of pointers.
.doll file loading. still experimental and will likely crash. requires csqc active, even if its a dummy progs. this will be fixed in time. Still other things that need cleaning up.
windows: gl_font "?" shows the standard windows font-selection dialog, and can be used to select windows fonts. not all work. and you probably don't want to use windings.
fixed splitscreen support when playing mvds. added mini-scoreboards to splitscreen.
editor/debugger now shows asm if there's no linenumber info. also, pressing f1 for help shows the shortcuts.
Added support for .framegroups files for psk(psa) and iqm formats.
True support for ezquake's colour codes. Mutually exclusive with background colours.
path command output slightly more readable.
added support for digest_hex (MD4, SHA1, CRC16).
skingroups now colourmap correctly.
Fix terrain colour hints, and litdata from the wrong bsp.
fix ftp dual-homed issue. support epsv command, and enable ipv6 (eprt still not supported).
remove d3d11 compilation from the makefile. the required headers are not provided by mingw, and are not available to the build bot, so don't bother.
fix v *= v.x and similar opcodes.
fteqcc: fixed support for áéíóú type chars in names. utf-8 files now properly supported (even with the utf-8 bom/identifier). utf-16 also supported.
fteqcc: fixed '#if 1 == 3 && 4' parsing.
fteqcc: -Werror acts on the warning, rather than as a separate error. Line numbers are thus more readable.
fteqcc: copyright message now includes compile date instead.
fteqccgui: the treeview control is now coloured depending on whether there were warnings/errors in the last compile.
fteqccgui: the output window is now focused and scrolls down as compilation progresses.
pr_dumpplatform command dumps out some pragmas to convert more serious warnings to errors. This is to avoid the infamous 'fteqcc sucks cos my code sucks' issue.
rewrote prespawn/modelist/soundlist code. server tracks progress now.
------------------------------------------------------------------------
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@4167 fc73d0e0-1445-4013-8a0c-d673dee63da5
2013-03-12 22:29:40 +00:00
void CL_ClearEntityLists ( void )
2005-02-12 18:56:04 +00:00
{
2015-03-03 07:54:10 +00:00
cl_framecount + + ;
2020-04-19 01:23:32 +00:00
if ( cl_expandvisents | | cl_numvisedicts + 128 > = cl_maxvisedicts )
------------------------------------------------------------------------
r4169 | acceptthis | 2013-01-17 08:55:12 +0000 (Thu, 17 Jan 2013) | 31 lines
removed MAX_VISEDICTS limit.
PEXT2_REPLACEMENTDELTAS tweaked, now has 4 million entity limit. still not enabled by default.
TE_BEAM now maps to a separate TEQW_BEAM to avoid conflicts with QW.
added android multitouch emulation for windows/rawinput (in_simulatemultitouch).
split topcolor/bottomcolor from scoreboard, for dp's colormap|1024 feature.
now using utf-8 for windows consoles.
qcc warnings/errors now give clickable console links for quick+easy editing.
disabled menutint when the currently active item changes contrast or gamma (for OneManClan).
Added support for drawfont/drawfontscale.
tweaked the qcvm a little to reduce the number of pointers.
.doll file loading. still experimental and will likely crash. requires csqc active, even if its a dummy progs. this will be fixed in time. Still other things that need cleaning up.
windows: gl_font "?" shows the standard windows font-selection dialog, and can be used to select windows fonts. not all work. and you probably don't want to use windings.
fixed splitscreen support when playing mvds. added mini-scoreboards to splitscreen.
editor/debugger now shows asm if there's no linenumber info. also, pressing f1 for help shows the shortcuts.
Added support for .framegroups files for psk(psa) and iqm formats.
True support for ezquake's colour codes. Mutually exclusive with background colours.
path command output slightly more readable.
added support for digest_hex (MD4, SHA1, CRC16).
skingroups now colourmap correctly.
Fix terrain colour hints, and litdata from the wrong bsp.
fix ftp dual-homed issue. support epsv command, and enable ipv6 (eprt still not supported).
remove d3d11 compilation from the makefile. the required headers are not provided by mingw, and are not available to the build bot, so don't bother.
fix v *= v.x and similar opcodes.
fteqcc: fixed support for áéíóú type chars in names. utf-8 files now properly supported (even with the utf-8 bom/identifier). utf-16 also supported.
fteqcc: fixed '#if 1 == 3 && 4' parsing.
fteqcc: -Werror acts on the warning, rather than as a separate error. Line numbers are thus more readable.
fteqcc: copyright message now includes compile date instead.
fteqccgui: the treeview control is now coloured depending on whether there were warnings/errors in the last compile.
fteqccgui: the output window is now focused and scrolls down as compilation progresses.
pr_dumpplatform command dumps out some pragmas to convert more serious warnings to errors. This is to avoid the infamous 'fteqcc sucks cos my code sucks' issue.
rewrote prespawn/modelist/soundlist code. server tracks progress now.
------------------------------------------------------------------------
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@4167 fc73d0e0-1445-4013-8a0c-d673dee63da5
2013-03-12 22:29:40 +00:00
{
2013-03-12 22:40:16 +00:00
int newnum = cl_maxvisedicts + 256 ;
------------------------------------------------------------------------
r4169 | acceptthis | 2013-01-17 08:55:12 +0000 (Thu, 17 Jan 2013) | 31 lines
removed MAX_VISEDICTS limit.
PEXT2_REPLACEMENTDELTAS tweaked, now has 4 million entity limit. still not enabled by default.
TE_BEAM now maps to a separate TEQW_BEAM to avoid conflicts with QW.
added android multitouch emulation for windows/rawinput (in_simulatemultitouch).
split topcolor/bottomcolor from scoreboard, for dp's colormap|1024 feature.
now using utf-8 for windows consoles.
qcc warnings/errors now give clickable console links for quick+easy editing.
disabled menutint when the currently active item changes contrast or gamma (for OneManClan).
Added support for drawfont/drawfontscale.
tweaked the qcvm a little to reduce the number of pointers.
.doll file loading. still experimental and will likely crash. requires csqc active, even if its a dummy progs. this will be fixed in time. Still other things that need cleaning up.
windows: gl_font "?" shows the standard windows font-selection dialog, and can be used to select windows fonts. not all work. and you probably don't want to use windings.
fixed splitscreen support when playing mvds. added mini-scoreboards to splitscreen.
editor/debugger now shows asm if there's no linenumber info. also, pressing f1 for help shows the shortcuts.
Added support for .framegroups files for psk(psa) and iqm formats.
True support for ezquake's colour codes. Mutually exclusive with background colours.
path command output slightly more readable.
added support for digest_hex (MD4, SHA1, CRC16).
skingroups now colourmap correctly.
Fix terrain colour hints, and litdata from the wrong bsp.
fix ftp dual-homed issue. support epsv command, and enable ipv6 (eprt still not supported).
remove d3d11 compilation from the makefile. the required headers are not provided by mingw, and are not available to the build bot, so don't bother.
fix v *= v.x and similar opcodes.
fteqcc: fixed support for áéíóú type chars in names. utf-8 files now properly supported (even with the utf-8 bom/identifier). utf-16 also supported.
fteqcc: fixed '#if 1 == 3 && 4' parsing.
fteqcc: -Werror acts on the warning, rather than as a separate error. Line numbers are thus more readable.
fteqcc: copyright message now includes compile date instead.
fteqccgui: the treeview control is now coloured depending on whether there were warnings/errors in the last compile.
fteqccgui: the output window is now focused and scrolls down as compilation progresses.
pr_dumpplatform command dumps out some pragmas to convert more serious warnings to errors. This is to avoid the infamous 'fteqcc sucks cos my code sucks' issue.
rewrote prespawn/modelist/soundlist code. server tracks progress now.
------------------------------------------------------------------------
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@4167 fc73d0e0-1445-4013-8a0c-d673dee63da5
2013-03-12 22:29:40 +00:00
entity_t * n = BZ_Realloc ( cl_visedicts , newnum * sizeof ( * n ) ) ;
if ( n )
{
cl_visedicts = n ;
cl_maxvisedicts = newnum ;
}
2020-04-19 01:23:32 +00:00
cl_expandvisents = false ;
------------------------------------------------------------------------
r4169 | acceptthis | 2013-01-17 08:55:12 +0000 (Thu, 17 Jan 2013) | 31 lines
removed MAX_VISEDICTS limit.
PEXT2_REPLACEMENTDELTAS tweaked, now has 4 million entity limit. still not enabled by default.
TE_BEAM now maps to a separate TEQW_BEAM to avoid conflicts with QW.
added android multitouch emulation for windows/rawinput (in_simulatemultitouch).
split topcolor/bottomcolor from scoreboard, for dp's colormap|1024 feature.
now using utf-8 for windows consoles.
qcc warnings/errors now give clickable console links for quick+easy editing.
disabled menutint when the currently active item changes contrast or gamma (for OneManClan).
Added support for drawfont/drawfontscale.
tweaked the qcvm a little to reduce the number of pointers.
.doll file loading. still experimental and will likely crash. requires csqc active, even if its a dummy progs. this will be fixed in time. Still other things that need cleaning up.
windows: gl_font "?" shows the standard windows font-selection dialog, and can be used to select windows fonts. not all work. and you probably don't want to use windings.
fixed splitscreen support when playing mvds. added mini-scoreboards to splitscreen.
editor/debugger now shows asm if there's no linenumber info. also, pressing f1 for help shows the shortcuts.
Added support for .framegroups files for psk(psa) and iqm formats.
True support for ezquake's colour codes. Mutually exclusive with background colours.
path command output slightly more readable.
added support for digest_hex (MD4, SHA1, CRC16).
skingroups now colourmap correctly.
Fix terrain colour hints, and litdata from the wrong bsp.
fix ftp dual-homed issue. support epsv command, and enable ipv6 (eprt still not supported).
remove d3d11 compilation from the makefile. the required headers are not provided by mingw, and are not available to the build bot, so don't bother.
fix v *= v.x and similar opcodes.
fteqcc: fixed support for áéíóú type chars in names. utf-8 files now properly supported (even with the utf-8 bom/identifier). utf-16 also supported.
fteqcc: fixed '#if 1 == 3 && 4' parsing.
fteqcc: -Werror acts on the warning, rather than as a separate error. Line numbers are thus more readable.
fteqcc: copyright message now includes compile date instead.
fteqccgui: the treeview control is now coloured depending on whether there were warnings/errors in the last compile.
fteqccgui: the output window is now focused and scrolls down as compilation progresses.
pr_dumpplatform command dumps out some pragmas to convert more serious warnings to errors. This is to avoid the infamous 'fteqcc sucks cos my code sucks' issue.
rewrote prespawn/modelist/soundlist code. server tracks progress now.
------------------------------------------------------------------------
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@4167 fc73d0e0-1445-4013-8a0c-d673dee63da5
2013-03-12 22:29:40 +00:00
}
2005-02-12 18:56:04 +00:00
cl_numvisedicts = 0 ;
2009-11-04 21:16:50 +00:00
cl_numstrisidx = 0 ;
cl_numstrisvert = 0 ;
cl_numstris = 0 ;
2005-02-12 18:56:04 +00:00
}
------------------------------------------------------------------------
r4169 | acceptthis | 2013-01-17 08:55:12 +0000 (Thu, 17 Jan 2013) | 31 lines
removed MAX_VISEDICTS limit.
PEXT2_REPLACEMENTDELTAS tweaked, now has 4 million entity limit. still not enabled by default.
TE_BEAM now maps to a separate TEQW_BEAM to avoid conflicts with QW.
added android multitouch emulation for windows/rawinput (in_simulatemultitouch).
split topcolor/bottomcolor from scoreboard, for dp's colormap|1024 feature.
now using utf-8 for windows consoles.
qcc warnings/errors now give clickable console links for quick+easy editing.
disabled menutint when the currently active item changes contrast or gamma (for OneManClan).
Added support for drawfont/drawfontscale.
tweaked the qcvm a little to reduce the number of pointers.
.doll file loading. still experimental and will likely crash. requires csqc active, even if its a dummy progs. this will be fixed in time. Still other things that need cleaning up.
windows: gl_font "?" shows the standard windows font-selection dialog, and can be used to select windows fonts. not all work. and you probably don't want to use windings.
fixed splitscreen support when playing mvds. added mini-scoreboards to splitscreen.
editor/debugger now shows asm if there's no linenumber info. also, pressing f1 for help shows the shortcuts.
Added support for .framegroups files for psk(psa) and iqm formats.
True support for ezquake's colour codes. Mutually exclusive with background colours.
path command output slightly more readable.
added support for digest_hex (MD4, SHA1, CRC16).
skingroups now colourmap correctly.
Fix terrain colour hints, and litdata from the wrong bsp.
fix ftp dual-homed issue. support epsv command, and enable ipv6 (eprt still not supported).
remove d3d11 compilation from the makefile. the required headers are not provided by mingw, and are not available to the build bot, so don't bother.
fix v *= v.x and similar opcodes.
fteqcc: fixed support for áéíóú type chars in names. utf-8 files now properly supported (even with the utf-8 bom/identifier). utf-16 also supported.
fteqcc: fixed '#if 1 == 3 && 4' parsing.
fteqcc: -Werror acts on the warning, rather than as a separate error. Line numbers are thus more readable.
fteqcc: copyright message now includes compile date instead.
fteqccgui: the treeview control is now coloured depending on whether there were warnings/errors in the last compile.
fteqccgui: the output window is now focused and scrolls down as compilation progresses.
pr_dumpplatform command dumps out some pragmas to convert more serious warnings to errors. This is to avoid the infamous 'fteqcc sucks cos my code sucks' issue.
rewrote prespawn/modelist/soundlist code. server tracks progress now.
------------------------------------------------------------------------
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@4167 fc73d0e0-1445-4013-8a0c-d673dee63da5
2013-03-12 22:29:40 +00:00
void CL_FreeVisEdicts ( void )
{
2015-03-03 07:54:10 +00:00
cl_framecount + + ;
------------------------------------------------------------------------
r4169 | acceptthis | 2013-01-17 08:55:12 +0000 (Thu, 17 Jan 2013) | 31 lines
removed MAX_VISEDICTS limit.
PEXT2_REPLACEMENTDELTAS tweaked, now has 4 million entity limit. still not enabled by default.
TE_BEAM now maps to a separate TEQW_BEAM to avoid conflicts with QW.
added android multitouch emulation for windows/rawinput (in_simulatemultitouch).
split topcolor/bottomcolor from scoreboard, for dp's colormap|1024 feature.
now using utf-8 for windows consoles.
qcc warnings/errors now give clickable console links for quick+easy editing.
disabled menutint when the currently active item changes contrast or gamma (for OneManClan).
Added support for drawfont/drawfontscale.
tweaked the qcvm a little to reduce the number of pointers.
.doll file loading. still experimental and will likely crash. requires csqc active, even if its a dummy progs. this will be fixed in time. Still other things that need cleaning up.
windows: gl_font "?" shows the standard windows font-selection dialog, and can be used to select windows fonts. not all work. and you probably don't want to use windings.
fixed splitscreen support when playing mvds. added mini-scoreboards to splitscreen.
editor/debugger now shows asm if there's no linenumber info. also, pressing f1 for help shows the shortcuts.
Added support for .framegroups files for psk(psa) and iqm formats.
True support for ezquake's colour codes. Mutually exclusive with background colours.
path command output slightly more readable.
added support for digest_hex (MD4, SHA1, CRC16).
skingroups now colourmap correctly.
Fix terrain colour hints, and litdata from the wrong bsp.
fix ftp dual-homed issue. support epsv command, and enable ipv6 (eprt still not supported).
remove d3d11 compilation from the makefile. the required headers are not provided by mingw, and are not available to the build bot, so don't bother.
fix v *= v.x and similar opcodes.
fteqcc: fixed support for áéíóú type chars in names. utf-8 files now properly supported (even with the utf-8 bom/identifier). utf-16 also supported.
fteqcc: fixed '#if 1 == 3 && 4' parsing.
fteqcc: -Werror acts on the warning, rather than as a separate error. Line numbers are thus more readable.
fteqcc: copyright message now includes compile date instead.
fteqccgui: the treeview control is now coloured depending on whether there were warnings/errors in the last compile.
fteqccgui: the output window is now focused and scrolls down as compilation progresses.
pr_dumpplatform command dumps out some pragmas to convert more serious warnings to errors. This is to avoid the infamous 'fteqcc sucks cos my code sucks' issue.
rewrote prespawn/modelist/soundlist code. server tracks progress now.
------------------------------------------------------------------------
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@4167 fc73d0e0-1445-4013-8a0c-d673dee63da5
2013-03-12 22:29:40 +00:00
BZ_Free ( cl_visedicts ) ;
cl_visedicts = NULL ;
cl_maxvisedicts = 0 ;
cl_numvisedicts = 0 ;
}
2012-05-14 01:41:08 +00:00
/*
static void CL_WaterSplashes ( void )
{
int i ;
entity_t * ent ;
vec3_t org ;
2005-02-12 18:56:04 +00:00
2012-05-14 01:41:08 +00:00
static unsigned int ltime ;
unsigned int ntime = cl . time * 1000 ;
if ( ntime - ltime < 200 )
return ;
ltime = ntime ;
for ( i = 0 ; i < cl_numvisedicts ; i + + )
{
ent = & cl_visedicts [ i ] ;
if ( ent - > model )
{
if ( ent - > origin [ 2 ] + ent - > model - > mins [ 2 ] < r_refdef . waterheight & &
ent - > origin [ 2 ] + ent - > model - > maxs [ 2 ] > r_refdef . waterheight )
{
org [ 0 ] = ent - > origin [ 0 ] ;
org [ 1 ] = ent - > origin [ 1 ] ;
org [ 2 ] = r_refdef . waterheight ;
P_RunParticleEffectTypeString ( org , NULL , 1 , " te_watertransition " ) ;
}
}
}
}
*/
2004-08-23 00:15:46 +00:00
void CL_EmitEntities ( void )
{
if ( cls . state ! = ca_active )
return ;
2004-11-27 08:16:25 +00:00
CL_DecayLights ( ) ;
2004-08-23 00:15:46 +00:00
# ifdef Q2CLIENT
2005-05-26 12:55:34 +00:00
if ( cls . protocol = = CP_QUAKE2 )
2004-08-23 00:15:46 +00:00
{
------------------------------------------------------------------------
r4169 | acceptthis | 2013-01-17 08:55:12 +0000 (Thu, 17 Jan 2013) | 31 lines
removed MAX_VISEDICTS limit.
PEXT2_REPLACEMENTDELTAS tweaked, now has 4 million entity limit. still not enabled by default.
TE_BEAM now maps to a separate TEQW_BEAM to avoid conflicts with QW.
added android multitouch emulation for windows/rawinput (in_simulatemultitouch).
split topcolor/bottomcolor from scoreboard, for dp's colormap|1024 feature.
now using utf-8 for windows consoles.
qcc warnings/errors now give clickable console links for quick+easy editing.
disabled menutint when the currently active item changes contrast or gamma (for OneManClan).
Added support for drawfont/drawfontscale.
tweaked the qcvm a little to reduce the number of pointers.
.doll file loading. still experimental and will likely crash. requires csqc active, even if its a dummy progs. this will be fixed in time. Still other things that need cleaning up.
windows: gl_font "?" shows the standard windows font-selection dialog, and can be used to select windows fonts. not all work. and you probably don't want to use windings.
fixed splitscreen support when playing mvds. added mini-scoreboards to splitscreen.
editor/debugger now shows asm if there's no linenumber info. also, pressing f1 for help shows the shortcuts.
Added support for .framegroups files for psk(psa) and iqm formats.
True support for ezquake's colour codes. Mutually exclusive with background colours.
path command output slightly more readable.
added support for digest_hex (MD4, SHA1, CRC16).
skingroups now colourmap correctly.
Fix terrain colour hints, and litdata from the wrong bsp.
fix ftp dual-homed issue. support epsv command, and enable ipv6 (eprt still not supported).
remove d3d11 compilation from the makefile. the required headers are not provided by mingw, and are not available to the build bot, so don't bother.
fix v *= v.x and similar opcodes.
fteqcc: fixed support for áéíóú type chars in names. utf-8 files now properly supported (even with the utf-8 bom/identifier). utf-16 also supported.
fteqcc: fixed '#if 1 == 3 && 4' parsing.
fteqcc: -Werror acts on the warning, rather than as a separate error. Line numbers are thus more readable.
fteqcc: copyright message now includes compile date instead.
fteqccgui: the treeview control is now coloured depending on whether there were warnings/errors in the last compile.
fteqccgui: the output window is now focused and scrolls down as compilation progresses.
pr_dumpplatform command dumps out some pragmas to convert more serious warnings to errors. This is to avoid the infamous 'fteqcc sucks cos my code sucks' issue.
rewrote prespawn/modelist/soundlist code. server tracks progress now.
------------------------------------------------------------------------
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@4167 fc73d0e0-1445-4013-8a0c-d673dee63da5
2013-03-12 22:29:40 +00:00
CL_ClearEntityLists ( ) ;
2004-08-23 00:15:46 +00:00
CLQ2_AddEntities ( ) ;
return ;
}
# endif
if ( ! cl . validsequence )
return ;
------------------------------------------------------------------------
r4169 | acceptthis | 2013-01-17 08:55:12 +0000 (Thu, 17 Jan 2013) | 31 lines
removed MAX_VISEDICTS limit.
PEXT2_REPLACEMENTDELTAS tweaked, now has 4 million entity limit. still not enabled by default.
TE_BEAM now maps to a separate TEQW_BEAM to avoid conflicts with QW.
added android multitouch emulation for windows/rawinput (in_simulatemultitouch).
split topcolor/bottomcolor from scoreboard, for dp's colormap|1024 feature.
now using utf-8 for windows consoles.
qcc warnings/errors now give clickable console links for quick+easy editing.
disabled menutint when the currently active item changes contrast or gamma (for OneManClan).
Added support for drawfont/drawfontscale.
tweaked the qcvm a little to reduce the number of pointers.
.doll file loading. still experimental and will likely crash. requires csqc active, even if its a dummy progs. this will be fixed in time. Still other things that need cleaning up.
windows: gl_font "?" shows the standard windows font-selection dialog, and can be used to select windows fonts. not all work. and you probably don't want to use windings.
fixed splitscreen support when playing mvds. added mini-scoreboards to splitscreen.
editor/debugger now shows asm if there's no linenumber info. also, pressing f1 for help shows the shortcuts.
Added support for .framegroups files for psk(psa) and iqm formats.
True support for ezquake's colour codes. Mutually exclusive with background colours.
path command output slightly more readable.
added support for digest_hex (MD4, SHA1, CRC16).
skingroups now colourmap correctly.
Fix terrain colour hints, and litdata from the wrong bsp.
fix ftp dual-homed issue. support epsv command, and enable ipv6 (eprt still not supported).
remove d3d11 compilation from the makefile. the required headers are not provided by mingw, and are not available to the build bot, so don't bother.
fix v *= v.x and similar opcodes.
fteqcc: fixed support for áéíóú type chars in names. utf-8 files now properly supported (even with the utf-8 bom/identifier). utf-16 also supported.
fteqcc: fixed '#if 1 == 3 && 4' parsing.
fteqcc: -Werror acts on the warning, rather than as a separate error. Line numbers are thus more readable.
fteqcc: copyright message now includes compile date instead.
fteqccgui: the treeview control is now coloured depending on whether there were warnings/errors in the last compile.
fteqccgui: the output window is now focused and scrolls down as compilation progresses.
pr_dumpplatform command dumps out some pragmas to convert more serious warnings to errors. This is to avoid the infamous 'fteqcc sucks cos my code sucks' issue.
rewrote prespawn/modelist/soundlist code. server tracks progress now.
------------------------------------------------------------------------
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@4167 fc73d0e0-1445-4013-8a0c-d673dee63da5
2013-03-12 22:29:40 +00:00
CL_ClearEntityLists ( ) ;
2004-08-23 00:15:46 +00:00
CL_LinkPlayers ( ) ;
CL_LinkPacketEntities ( ) ;
CL_LinkProjectiles ( ) ;
CL_UpdateTEnts ( ) ;
2012-05-14 01:41:08 +00:00
// CL_WaterSplashes();
2004-08-23 00:15:46 +00:00
}
2004-12-15 17:47:42 +00:00
void CL_ClearPredict ( void )
{
2004-08-23 00:15:46 +00:00
memset ( predicted_players , 0 , sizeof ( predicted_players ) ) ;
}