2004-11-23 14:29:51 +00:00
# include "quakedef.h"
2009-11-17 00:15:44 +00:00
# include "pr_common.h"
# include "shader.h"
2004-11-29 01:21:00 +00:00
2009-11-04 21:16:50 +00:00
# ifdef GLQUAKE
2004-11-23 14:29:51 +00:00
# include "glquake.h"
# endif
2005-10-07 16:27:20 +00:00
2009-11-17 00:15:44 +00:00
# if defined(MENU_DAT) || defined(CSQC_DAT)
2013-03-12 22:53:23 +00:00
# include "cl_master.h"
2009-11-17 00:15:44 +00:00
2013-06-23 02:17:02 +00:00
extern unsigned int r2d_be_flags ;
2013-05-11 05:03:07 +00:00
# define DRAWFLAG_NORMAL 0
# define DRAWFLAG_ADD 1
# define DRAWFLAG_MODULATE 2
# define DRAWFLAG_MODULATE2 3
static unsigned int PF_SelectDPDrawFlag ( int flag )
{
//flags:
//0 = blend
//1 = add
//2 = modulate
//3 = modulate*2
flag & = 3 ;
if ( flag = = DRAWFLAG_ADD )
return BEF_FORCEADDITIVE ;
else
return 0 ;
}
2009-11-17 00:15:44 +00:00
//float drawfill(vector position, vector size, vector rgb, float alpha, float flag) = #457;
------------------------------------------------------------------------
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 QCBUILTIN PF_CL_drawfill ( pubprogfuncs_t * prinst , struct globalvars_s * pr_globals )
2004-11-23 14:29:51 +00:00
{
2009-11-17 00:15:44 +00:00
float * pos = G_VECTOR ( OFS_PARM0 ) ;
float * size = G_VECTOR ( OFS_PARM1 ) ;
float * rgb = G_VECTOR ( OFS_PARM2 ) ;
float alpha = G_FLOAT ( OFS_PARM3 ) ;
2013-06-23 02:17:02 +00:00
int flag = prinst - > callargc > = 5 ? G_FLOAT ( OFS_PARM4 ) : 0 ;
2009-11-17 00:15:44 +00:00
2013-06-23 02:17:02 +00:00
r2d_be_flags = PF_SelectDPDrawFlag ( flag ) ;
2011-03-31 01:14:01 +00:00
R2D_ImageColours ( rgb [ 0 ] , rgb [ 1 ] , rgb [ 2 ] , alpha ) ;
R2D_FillBlock ( pos [ 0 ] , pos [ 1 ] , size [ 0 ] , size [ 1 ] ) ;
2013-06-23 02:17:02 +00:00
r2d_be_flags = 0 ;
2009-11-17 00:15:44 +00:00
G_FLOAT ( OFS_RETURN ) = 1 ;
2004-11-23 14:29:51 +00:00
}
2009-11-17 00:15:44 +00:00
//void drawsetcliparea(float x, float y, float width, float height) = #458;
------------------------------------------------------------------------
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 QCBUILTIN PF_CL_drawsetcliparea ( pubprogfuncs_t * prinst , struct globalvars_s * pr_globals )
2005-10-01 03:09:17 +00:00
{
2013-06-23 02:17:02 +00:00
srect_t srect ;
srect . x = G_FLOAT ( OFS_PARM0 ) / ( float ) vid . width ;
srect . y = ( G_FLOAT ( OFS_PARM1 ) / ( float ) vid . height ) ;
srect . width = G_FLOAT ( OFS_PARM2 ) / ( float ) vid . width ;
srect . height = G_FLOAT ( OFS_PARM3 ) / ( float ) vid . height ;
srect . dmin = - 99999 ;
srect . dmax = 99999 ;
srect . y = ( 1 - srect . y ) - srect . height ;
BE_Scissor ( & srect ) ;
2005-10-01 03:09:17 +00:00
2013-06-23 02:17:02 +00:00
G_FLOAT ( OFS_RETURN ) = 1 ;
2009-11-17 00:15:44 +00:00
}
//void drawresetcliparea(void) = #459;
------------------------------------------------------------------------
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 QCBUILTIN PF_CL_drawresetcliparea ( pubprogfuncs_t * prinst , struct globalvars_s * pr_globals )
2009-11-17 00:15:44 +00:00
{
2013-06-23 02:17:02 +00:00
BE_Scissor ( NULL ) ;
G_FLOAT ( OFS_RETURN ) = 1 ;
2009-11-17 00:15:44 +00:00
}
2004-11-23 14:29:51 +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
# define FONT_SLOTS 16
2013-12-29 22:48:28 +00:00
# define FONT_SIZES 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
struct {
2013-12-29 22:48:28 +00:00
unsigned int owner ; //kdm_foo. whoever has an interest in this font. font is purged when this becomes 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
char slotname [ 16 ] ;
2013-12-29 22:48:28 +00:00
char facename [ MAX_OSPATH ] ;
------------------------------------------------------------------------
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
int sizes ;
2013-12-29 22:48:28 +00:00
int size [ FONT_SIZES ] ;
struct font_s * font [ FONT_SIZES ] ;
------------------------------------------------------------------------
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
} fontslot [ FONT_SLOTS ] ;
2013-08-21 07:14:39 +00:00
2013-12-29 22:48:28 +00:00
struct font_s * PR_CL_ChooseFont ( float * fontsel , float szx , float szy )
------------------------------------------------------------------------
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
{
int fontidx = 0 ; //default by default...
2013-12-29 22:48:28 +00:00
struct font_s * font = font_default ;
2013-03-12 22:53:23 +00:00
2013-12-29 22:48:28 +00:00
if ( fontsel )
------------------------------------------------------------------------
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-12-29 22:48:28 +00:00
fontidx = * fontsel ;
------------------------------------------------------------------------
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 ( fontidx > = 0 & & fontidx < FONT_SLOTS )
{
int i , j ;
int fontdiff = 10000 ;
for ( i = 0 ; i < fontslot [ fontidx ] . sizes ; i + + )
{
j = abs ( szy - fontslot [ fontidx ] . size [ i ] ) ;
2013-03-12 22:35:33 +00:00
if ( j < fontdiff & & fontslot [ fontidx ] . font [ 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
{
fontdiff = j ;
font = fontslot [ fontidx ] . font [ i ] ;
}
}
}
2013-08-21 07:14:39 +00:00
return font ;
}
void PR_CL_BeginString ( pubprogfuncs_t * prinst , float vx , float vy , float szx , float szy , float * px , float * py )
{
2013-10-08 14:28:11 +00:00
world_t * world = prinst - > parms - > user ;
2013-12-29 22:48:28 +00:00
struct font_s * font = PR_CL_ChooseFont ( world - > g . drawfont , szx , szy ) ;
2013-10-08 14:28:11 +00:00
if ( world - > g . drawfontscale & & ( world - > g . drawfontscale [ 0 ] | | world - > g . drawfontscale [ 1 ] ) )
{
szx * = world - > g . drawfontscale [ 0 ] ;
szy * = world - > g . drawfontscale [ 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
Font_BeginScaledString ( font , vx , vy , szx , szy , px , py ) ;
}
2014-03-30 08:55:06 +00:00
int PR_findnamedfont ( const char * name , qboolean isslotname )
------------------------------------------------------------------------
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
{
int i ;
if ( isslotname )
{
for ( i = 0 ; i < FONT_SLOTS ; i + + )
{
if ( ! stricmp ( fontslot [ i ] . slotname , name ) )
return i ;
}
}
else
{
for ( i = 0 ; i < FONT_SLOTS ; i + + )
{
if ( ! stricmp ( fontslot [ i ] . facename , name ) )
return i ;
}
}
return - 1 ;
}
2013-12-29 22:48:28 +00:00
//purgeowner 0 will reload all fonts. other values will purge only fonts which are now unused.
void PR_ResetFonts ( unsigned int purgeowner )
------------------------------------------------------------------------
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
{
int i , j ;
for ( i = 0 ; i < FONT_SLOTS ; i + + )
{
2013-12-29 22:48:28 +00:00
fontslot [ i ] . owner & = ~ purgeowner ;
//don't bother flushing fonts when we don't really need to.
if ( fontslot [ i ] . owner & & purgeowner )
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
for ( j = 0 ; j < fontslot [ i ] . sizes ; j + + )
{
2013-03-12 22:35:33 +00:00
if ( fontslot [ i ] . font [ j ] )
Font_Free ( fontslot [ i ] . font [ j ] ) ;
------------------------------------------------------------------------
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
fontslot [ i ] . font [ j ] = NULL ;
}
2013-12-29 22:48:28 +00:00
//if noone is interested in it now, it can be purged fully.
if ( ! fontslot [ i ] . owner )
------------------------------------------------------------------------
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
{
fontslot [ i ] . sizes = 0 ;
fontslot [ i ] . slotname [ 0 ] = ' \0 ' ;
fontslot [ i ] . facename [ 0 ] = ' \0 ' ;
}
else
2013-12-29 22:48:28 +00:00
{ //otherwise load it.
------------------------------------------------------------------------
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
for ( j = 0 ; j < fontslot [ i ] . sizes ; j + + )
2013-12-29 22:48:28 +00:00
{
if ( qrenderer = = QR_NONE )
fontslot [ i ] . font [ j ] = NULL ;
else
fontslot [ i ] . font [ j ] = Font_LoadFont ( fontslot [ i ] . size [ j ] , fontslot [ i ] . facename ) ;
}
------------------------------------------------------------------------
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 QCBUILTIN PF_CL_findfont ( pubprogfuncs_t * prinst , struct globalvars_s * pr_globals )
{
2014-03-30 08:55:06 +00:00
const char * slotname = PR_GetStringOfs ( prinst , OFS_PARM0 ) ;
------------------------------------------------------------------------
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
G_FLOAT ( OFS_RETURN ) = PR_findnamedfont ( slotname , true ) + 1 ; //return default on failure.
}
void QCBUILTIN PF_CL_loadfont ( pubprogfuncs_t * prinst , struct globalvars_s * pr_globals )
{
2014-03-30 08:55:06 +00:00
const char * slotname = PR_GetStringOfs ( prinst , OFS_PARM0 ) ;
const char * facename = PR_GetStringOfs ( prinst , OFS_PARM1 ) ;
const char * sizestr = PR_GetStringOfs ( prinst , OFS_PARM2 ) ;
------------------------------------------------------------------------
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
int slotnum = G_FLOAT ( OFS_PARM3 ) ;
//float fix_scale = G_FLOAT(OFS_PARM4);
//float fix_voffset = G_FLOAT(OFS_PARM5);
int i , sz ;
2013-12-29 22:48:28 +00:00
world_t * world = prinst - > parms - > user ;
------------------------------------------------------------------------
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
G_FLOAT ( OFS_RETURN ) = 0 ; //return default on failure.
2013-03-12 22:35:33 +00:00
if ( slotnum < 0 & & * slotname )
------------------------------------------------------------------------
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
slotnum = PR_findnamedfont ( slotname , true ) ;
2013-03-12 22:35:33 +00:00
else if ( slotnum < 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
slotnum = PR_findnamedfont ( facename , false ) ;
2013-03-12 22:35:33 +00:00
if ( slotnum < 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
slotnum = PR_findnamedfont ( " " , true ) ;
2013-03-12 22:35:33 +00:00
if ( slotnum < 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
return ; //eep.
if ( ( unsigned ) slotnum > = FONT_SLOTS )
return ;
//if its changed, purge it.
if ( stricmp ( fontslot [ slotnum ] . slotname , slotname ) | | stricmp ( fontslot [ slotnum ] . facename , facename ) )
{
Q_strncpyz ( fontslot [ slotnum ] . slotname , slotname , sizeof ( fontslot [ slotnum ] . slotname ) ) ;
Q_strncpyz ( fontslot [ slotnum ] . facename , facename , sizeof ( fontslot [ slotnum ] . facename ) ) ;
for ( i = 0 ; i < fontslot [ slotnum ] . sizes ; i + + )
{
2013-03-12 22:35:33 +00:00
if ( fontslot [ slotnum ] . font [ i ] )
Font_Free ( fontslot [ slotnum ] . font [ 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
fontslot [ slotnum ] . font [ i ] = NULL ;
}
2013-12-29 22:48:28 +00:00
fontslot [ slotnum ] . owner = 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
}
2013-12-29 22:48:28 +00:00
fontslot [ slotnum ] . owner | = world - > keydestmask ;
------------------------------------------------------------------------
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 ( * sizestr )
{
sizestr = COM_Parse ( sizestr ) ;
sz = atoi ( com_token ) ;
for ( i = 0 ; i < fontslot [ slotnum ] . sizes ; i + + )
{
if ( fontslot [ slotnum ] . size [ i ] = = sz )
break ;
}
if ( i = = fontslot [ slotnum ] . sizes )
{
if ( i > = FONT_SIZES )
break ;
fontslot [ slotnum ] . size [ i ] = sz ;
2013-12-29 22:48:28 +00:00
if ( qrenderer = = QR_NONE )
fontslot [ slotnum ] . font [ i ] = NULL ;
else
fontslot [ slotnum ] . font [ i ] = Font_LoadFont ( fontslot [ slotnum ] . size [ i ] , facename ) ;
------------------------------------------------------------------------
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
fontslot [ slotnum ] . sizes + + ;
}
}
2013-03-12 22:35:33 +00:00
G_FLOAT ( OFS_RETURN ) = slotnum ;
------------------------------------------------------------------------
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-12-29 22:48:28 +00:00
void CL_LoadFont_f ( void )
{
//console command for compat with dp/debug.
if ( Cmd_Argc ( ) = = 1 )
{
int i , j ;
for ( i = 0 ; i < FONT_SLOTS ; i + + )
{
if ( fontslot [ i ] . sizes )
{
Con_Printf ( " %s: %s ( " , fontslot [ i ] . slotname , fontslot [ i ] . facename ) ;
for ( j = 0 ; j < fontslot [ i ] . sizes ; j + + )
{
if ( j )
2014-02-13 23:54:57 +00:00
Con_Printf ( " , " ) ;
2013-12-29 22:48:28 +00:00
Con_Printf ( " %i " , fontslot [ i ] . size [ j ] ) ;
}
Con_Printf ( " ) \n " ) ;
}
}
}
else
{
int i ;
int slotnum = 0 ;
char * slotname = Cmd_Argv ( 1 ) ;
char * facename = Cmd_Argv ( 2 ) ;
int sizenum = 3 ;
//loadfont slot face size1 size2...
slotnum = PR_findnamedfont ( slotname , true ) ;
if ( slotnum < 0 )
{
char * dpnames [ ] = { " default " , " console " , " sbar " , " notify " , " chat " , " centerprint " , " infobar " , " menu " , " user0 " , " user1 " , " user2 " , " user3 " , " user4 " , " user5 " , " user6 " , " user7 " , NULL } ;
for ( i = 0 ; dpnames [ i ] ; i + + )
{
if ( ! strcmp ( dpnames [ i ] , slotname ) )
{
//assign it to this slot only if this slot does not already have a face. avoids corrupting already-loaded fonts.
if ( ! * fontslot [ i ] . facename )
slotnum = i ;
break ;
}
}
if ( slotnum < 0 )
slotnum = PR_findnamedfont ( " " , true ) ; //whatever is still free
}
if ( slotnum < 0 )
{
Con_Printf ( " out of font slots \n " ) ;
return ;
}
//if there's a new font in this slot, purge the old and change the name+face strings
if ( stricmp ( fontslot [ slotnum ] . slotname , slotname ) | | stricmp ( fontslot [ slotnum ] . facename , facename ) )
{
Q_strncpyz ( fontslot [ slotnum ] . slotname , slotname , sizeof ( fontslot [ slotnum ] . slotname ) ) ;
Q_strncpyz ( fontslot [ slotnum ] . facename , facename , sizeof ( fontslot [ slotnum ] . facename ) ) ;
for ( i = 0 ; i < fontslot [ slotnum ] . sizes ; i + + )
{
if ( fontslot [ slotnum ] . font [ i ] )
Font_Free ( fontslot [ slotnum ] . font [ i ] ) ;
fontslot [ slotnum ] . font [ i ] = NULL ;
}
fontslot [ slotnum ] . owner = 0 ;
}
if ( ! * facename )
return ;
fontslot [ slotnum ] . owner | = kdm_console ; //fonts owned by the console are never forgotten.
while ( sizenum < Cmd_Argc ( ) )
{
int sz = atoi ( Cmd_Argv ( sizenum + + ) ) ;
if ( sz < = 0 )
sz = 8 ;
for ( i = 0 ; i < fontslot [ slotnum ] . sizes ; i + + )
{
if ( fontslot [ slotnum ] . size [ i ] = = sz )
break ;
}
if ( i = = fontslot [ slotnum ] . sizes )
{
if ( i > = FONT_SIZES )
break ;
fontslot [ slotnum ] . size [ i ] = sz ;
if ( qrenderer = = QR_NONE )
fontslot [ slotnum ] . font [ i ] = NULL ;
else
fontslot [ slotnum ] . font [ i ] = Font_LoadFont ( fontslot [ slotnum ] . size [ i ] , facename ) ;
fontslot [ slotnum ] . sizes + + ;
}
}
}
}
------------------------------------------------------------------------
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 QCBUILTIN PF_CL_DrawTextField ( pubprogfuncs_t * prinst , struct globalvars_s * pr_globals )
2010-07-11 02:22:39 +00:00
{
float * pos = G_VECTOR ( OFS_PARM0 ) ;
float * size = G_VECTOR ( OFS_PARM1 ) ;
unsigned int flags = G_FLOAT ( OFS_PARM2 ) ;
2014-03-30 08:55:06 +00:00
const char * text = PR_GetStringOfs ( prinst , OFS_PARM3 ) ;
2010-07-11 02:22:39 +00:00
R_DrawTextField ( pos [ 0 ] , pos [ 1 ] , size [ 0 ] , size [ 1 ] , text , CON_WHITEMASK , flags ) ;
}
2004-11-23 14:29:51 +00:00
2009-11-17 00:15:44 +00:00
//float drawstring(vector position, string text, vector scale, float alpha, float flag) = #455;
------------------------------------------------------------------------
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 QCBUILTIN PF_CL_drawcolouredstring ( pubprogfuncs_t * prinst , struct globalvars_s * pr_globals )
2004-11-23 14:29:51 +00:00
{
2009-11-17 00:15:44 +00:00
float * pos = G_VECTOR ( OFS_PARM0 ) ;
2014-03-30 08:55:06 +00:00
const char * text = PR_GetStringOfs ( prinst , OFS_PARM1 ) ;
2009-11-17 00:15:44 +00:00
float * size = G_VECTOR ( OFS_PARM2 ) ;
2011-05-20 04:10:46 +00:00
float alpha = 0 ;
float flag = 0 ;
float r , g , b ;
------------------------------------------------------------------------
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 px , py , ipx ;
2004-11-23 14:29:51 +00:00
2010-07-11 02:22:39 +00:00
conchar_t buffer [ 2048 ] , * str ;
------------------------------------------------------------------------
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 ( prinst - > callargc > = 6 )
2011-05-20 04:10:46 +00:00
{
r = G_FLOAT ( OFS_PARM3 + 0 ) ;
g = G_FLOAT ( OFS_PARM3 + 1 ) ;
b = G_FLOAT ( OFS_PARM3 + 2 ) ;
alpha = G_FLOAT ( OFS_PARM4 ) ;
2013-06-23 02:17:02 +00:00
flag = G_FLOAT ( OFS_PARM5 ) ; //flag is mandatory to distinguish it.
2011-05-20 04:10:46 +00:00
}
else
{
r = 1 ;
g = 1 ;
b = 1 ;
alpha = G_FLOAT ( OFS_PARM3 ) ;
2013-06-23 02:17:02 +00:00
flag = prinst - > callargc > = 5 ? G_FLOAT ( OFS_PARM4 ) : 0 ;
2011-05-20 04:10:46 +00:00
}
2009-11-17 00:15:44 +00:00
if ( ! text )
2004-11-23 14:29:51 +00:00
{
2009-11-17 00:15:44 +00:00
G_FLOAT ( OFS_RETURN ) = - 1 ; //was null..
return ;
}
2004-11-23 14:29:51 +00:00
2010-07-11 02:22:39 +00:00
COM_ParseFunString ( CON_WHITEMASK , text , buffer , sizeof ( buffer ) , false ) ;
str = buffer ;
2013-05-11 05:03:07 +00:00
r2d_be_flags = PF_SelectDPDrawFlag ( flag ) ;
------------------------------------------------------------------------
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
PR_CL_BeginString ( prinst , pos [ 0 ] , pos [ 1 ] , size [ 0 ] , size [ 1 ] , & px , & py ) ;
2012-10-08 04:36:10 +00:00
ipx = px ;
2011-05-20 04:10:46 +00:00
Font_ForceColour ( r , g , b , alpha ) ;
2010-07-11 02:22:39 +00:00
while ( * str )
{
2012-10-08 04:36:10 +00:00
if ( ( * str & CON_CHARMASK ) = = ' \n ' )
py + = Font_CharHeight ( ) ;
else if ( ( * str & CON_CHARMASK ) = = ' \r ' )
px = ipx ;
else
------------------------------------------------------------------------
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
px = Font_DrawScaleChar ( px , py , * str ) ;
2012-11-27 03:23:19 +00:00
str + + ;
2010-07-11 02:22:39 +00:00
}
Font_InvalidateColour ( ) ;
------------------------------------------------------------------------
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
Font_EndString ( NULL ) ;
2013-05-11 05:03:07 +00:00
r2d_be_flags = 0 ;
2009-11-17 00:15:44 +00:00
}
2004-11-23 14:29:51 +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 QCBUILTIN PF_CL_stringwidth ( pubprogfuncs_t * prinst , struct globalvars_s * pr_globals )
2009-11-17 00:15:44 +00:00
{
2011-09-03 03:49:43 +00:00
conchar_t buffer [ 2048 ] , * end ;
float px , py ;
2014-03-30 08:55:06 +00:00
const char * text = PR_GetStringOfs ( prinst , OFS_PARM0 ) ;
2011-05-27 17:59:31 +00:00
int usecolours = G_FLOAT ( OFS_PARM1 ) ;
------------------------------------------------------------------------
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 * size = ( prinst - > callargc > 2 ) ? G_VECTOR ( OFS_PARM2 ) : NULL ;
2011-05-20 04:10:46 +00:00
2011-09-03 03:49:43 +00:00
end = COM_ParseFunString ( CON_WHITEMASK , text , buffer , sizeof ( buffer ) , ! usecolours ) ;
2011-05-20 04:10: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
PR_CL_BeginString ( prinst , 0 , 0 , size ? size [ 0 ] : 8 , size ? size [ 1 ] : 8 , & px , & py ) ;
2013-06-23 02:17:02 +00:00
px = Font_LineScaleWidth ( buffer , end ) ;
------------------------------------------------------------------------
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
Font_EndString ( NULL ) ;
2011-09-03 03:49:43 +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
G_FLOAT ( OFS_RETURN ) = ( px * vid . width ) / vid . rotpixelwidth ;
2004-11-23 14:29:51 +00:00
}
2009-11-17 00:15:44 +00:00
//float drawpic(vector position, string pic, vector size, vector rgb, float alpha, float flag) = #456;
------------------------------------------------------------------------
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 QCBUILTIN PF_CL_drawpic ( pubprogfuncs_t * prinst , struct globalvars_s * pr_globals )
2009-11-17 00:15:44 +00:00
{
float * pos = G_VECTOR ( OFS_PARM0 ) ;
2014-03-30 08:55:06 +00:00
const char * picname = PR_GetStringOfs ( prinst , OFS_PARM1 ) ;
2009-11-17 00:15:44 +00:00
float * size = G_VECTOR ( OFS_PARM2 ) ;
float * rgb = G_VECTOR ( OFS_PARM3 ) ;
float alpha = G_FLOAT ( OFS_PARM4 ) ;
2013-06-23 02:17:02 +00:00
int flag = prinst - > callargc > = 6 ? ( int ) G_FLOAT ( OFS_PARM5 ) : 0 ;
2004-11-23 14:29:51 +00:00
2009-11-17 00:15:44 +00:00
mpic_t * p ;
2004-11-23 14:29:51 +00:00
2011-03-31 01:14:01 +00:00
p = R2D_SafeCachePic ( picname ) ;
2014-10-05 20:04:11 +00:00
if ( ! p | | ! R_GetShaderSizes ( p , NULL , NULL , false ) )
2011-03-31 01:14:01 +00:00
p = R2D_SafePicFromWad ( picname ) ;
2014-02-07 08:38:40 +00:00
if ( ! p )
{
if ( ! CL_IsDownloading ( picname ) )
p = R2D_SafeCachePic ( " no_texture " ) ;
}
else
G_FLOAT ( OFS_RETURN ) = 0 ;
2004-11-23 14:29:51 +00:00
2011-04-20 23:34:13 +00:00
r2d_be_flags = PF_SelectDPDrawFlag ( flag ) ;
2011-03-31 01:14:01 +00:00
R2D_ImageColours ( rgb [ 0 ] , rgb [ 1 ] , rgb [ 2 ] , alpha ) ;
R2D_Image ( pos [ 0 ] , pos [ 1 ] , size [ 0 ] , size [ 1 ] , 0 , 0 , 1 , 1 , p ) ;
2011-04-20 23:34:13 +00:00
r2d_be_flags = 0 ;
2004-11-23 14:29:51 +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 QCBUILTIN PF_CL_drawsubpic ( pubprogfuncs_t * prinst , struct globalvars_s * pr_globals )
2004-11-23 14:29:51 +00:00
{
2009-11-17 00:15:44 +00:00
float * pos = G_VECTOR ( OFS_PARM0 ) ;
float * size = G_VECTOR ( OFS_PARM1 ) ;
2014-03-30 08:55:06 +00:00
const char * picname = PR_GetStringOfs ( prinst , OFS_PARM2 ) ;
2009-11-17 00:15:44 +00:00
float * srcPos = G_VECTOR ( OFS_PARM3 ) ;
float * srcSize = G_VECTOR ( OFS_PARM4 ) ;
float * rgb = G_VECTOR ( OFS_PARM5 ) ;
float alpha = G_FLOAT ( OFS_PARM6 ) ;
2013-06-23 02:17:02 +00:00
int flag = prinst - > callargc > = 8 ? ( int ) G_FLOAT ( OFS_PARM7 ) : 0 ;
2004-11-23 14:29:51 +00:00
2009-11-17 00:15:44 +00:00
mpic_t * p ;
2004-11-23 14:29:51 +00:00
2011-03-31 01:14:01 +00:00
p = R2D_SafeCachePic ( picname ) ;
------------------------------------------------------------------------
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 ( ! p )
p = R2D_SafePicFromWad ( picname ) ;
2004-11-23 14:29:51 +00:00
2011-04-20 23:34:13 +00:00
r2d_be_flags = PF_SelectDPDrawFlag ( flag ) ;
2011-03-31 01:14:01 +00:00
R2D_ImageColours ( rgb [ 0 ] , rgb [ 1 ] , rgb [ 2 ] , alpha ) ;
R2D_Image ( pos [ 0 ] , pos [ 1 ] ,
2009-11-17 00:15:44 +00:00
size [ 0 ] , size [ 1 ] ,
srcPos [ 0 ] , srcPos [ 1 ] ,
srcPos [ 0 ] + srcSize [ 0 ] , srcPos [ 1 ] + srcSize [ 1 ] ,
p ) ;
2011-04-20 23:34:13 +00:00
r2d_be_flags = 0 ;
2004-11-23 14:29:51 +00:00
2009-11-17 00:15:44 +00:00
G_FLOAT ( OFS_RETURN ) = 1 ;
}
2004-11-23 14:29:51 +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 QCBUILTIN PF_CL_is_cached_pic ( pubprogfuncs_t * prinst , struct globalvars_s * pr_globals )
2004-11-23 14:29:51 +00:00
{
2014-03-30 08:55:06 +00:00
const char * str ;
2004-11-23 14:29:51 +00:00
str = PR_GetStringOfs ( prinst , OFS_PARM0 ) ;
2013-08-21 07:14:39 +00:00
G_FLOAT ( OFS_RETURN ) = ! ! R_RegisterCustom ( str , SUF_2D , NULL , NULL ) ;
2004-11-23 14:29:51 +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 QCBUILTIN PF_CL_precache_pic ( pubprogfuncs_t * prinst , struct globalvars_s * pr_globals )
2004-11-23 14:29:51 +00:00
{
2014-03-30 08:55:06 +00:00
const char * str ;
2004-12-24 08:45:56 +00:00
mpic_t * pic ;
2008-03-11 13:36:18 +00:00
float fromwad ;
2006-01-11 22:23:23 +00:00
2004-11-23 14:29:51 +00:00
str = PR_GetStringOfs ( prinst , OFS_PARM0 ) ;
------------------------------------------------------------------------
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 ( prinst - > callargc > 1 )
2008-03-11 13:36:18 +00:00
fromwad = G_FLOAT ( OFS_PARM1 ) ;
else
fromwad = false ;
2004-11-23 14:29:51 +00:00
2008-03-11 13:36:18 +00:00
if ( fromwad )
2011-03-31 01:14:01 +00:00
pic = R2D_SafePicFromWad ( str ) ;
2008-03-11 13:36:18 +00:00
else
{
2014-06-21 17:58:17 +00:00
pic = R2D_SafeCachePic ( str ) ;
2014-10-05 20:04:11 +00:00
if ( ( ! pic | | ! R_GetShaderSizes ( pic , NULL , NULL , true ) ) & & cls . state
2008-11-09 22:29:28 +00:00
# ifndef CLIENTONLY
& & ! sv . active
# endif
2014-06-21 17:58:17 +00:00
& & strchr ( str , ' . ' ) ) //only try to download it if it looks as though it contains a path.
2008-11-09 22:29:28 +00:00
CL_CheckOrEnqueDownloadFile ( str , str , 0 ) ;
2008-03-11 13:36:18 +00:00
}
2004-11-23 14:29:51 +00:00
if ( pic )
G_INT ( OFS_RETURN ) = G_INT ( OFS_PARM0 ) ;
else
G_INT ( OFS_RETURN ) = 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
void QCBUILTIN PF_CL_free_pic ( pubprogfuncs_t * prinst , struct globalvars_s * pr_globals )
2004-11-23 14:29:51 +00:00
{
2013-05-11 05:03:07 +00:00
//we don't support this, as the shader could be used elsewhere also, and we have pointers to things.
/*
2004-11-23 14:29:51 +00:00
char * str ;
str = PR_GetStringOfs ( prinst , OFS_PARM0 ) ;
2013-05-11 05:03:07 +00:00
R_UnloadShader ( R_RegisterCustom ( str , NULL , NULL ) ) ;
*/
2004-11-23 14:29:51 +00:00
}
//float drawcharacter(vector position, float character, vector scale, vector rgb, float alpha, float flag) = #454;
------------------------------------------------------------------------
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 QCBUILTIN PF_CL_drawcharacter ( pubprogfuncs_t * prinst , struct globalvars_s * pr_globals )
2004-11-23 14:29:51 +00:00
{
float * pos = G_VECTOR ( OFS_PARM0 ) ;
int chara = G_FLOAT ( OFS_PARM1 ) ;
float * size = G_VECTOR ( OFS_PARM2 ) ;
float * rgb = G_VECTOR ( OFS_PARM3 ) ;
float alpha = G_FLOAT ( OFS_PARM4 ) ;
2013-06-23 02:17:02 +00:00
int flag = prinst - > callargc > = 6 ? G_FLOAT ( OFS_PARM5 ) : 0 ;
2004-11-23 14:29:51 +00:00
2010-07-11 02:22:39 +00:00
float x , y ;
2004-11-23 14:29:51 +00:00
if ( ! chara )
{
G_FLOAT ( OFS_RETURN ) = - 1 ; //was null..
return ;
}
2012-11-27 03:23:19 +00:00
//no control chars. use quake ones if so
2013-05-11 14:02:55 +00:00
if ( ! ( flag & 4 ) )
if ( chara < 32 & & chara ! = ' \t ' )
chara | = 0xe000 ;
2012-11-27 03:23:19 +00:00
2013-05-11 14:02:55 +00:00
r2d_be_flags = PF_SelectDPDrawFlag ( flag ) ;
------------------------------------------------------------------------
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
PR_CL_BeginString ( prinst , pos [ 0 ] , pos [ 1 ] , size [ 0 ] , size [ 1 ] , & x , & y ) ;
2009-11-04 21:16:50 +00:00
Font_ForceColour ( rgb [ 0 ] , rgb [ 1 ] , rgb [ 2 ] , alpha ) ;
2013-05-03 04:28:08 +00:00
Font_DrawScaleChar ( x , y , CON_WHITEMASK | chara ) ;
2010-03-14 14:35:56 +00:00
Font_InvalidateColour ( ) ;
------------------------------------------------------------------------
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
Font_EndString ( NULL ) ;
2013-05-11 14:02:55 +00:00
r2d_be_flags = 0 ;
2004-11-23 14:29:51 +00:00
G_FLOAT ( OFS_RETURN ) = 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
2009-05-24 10:11:17 +00:00
//float drawrawstring(vector position, string text, vector scale, vector rgb, float alpha, float flag) = #455;
------------------------------------------------------------------------
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 QCBUILTIN PF_CL_drawrawstring ( pubprogfuncs_t * prinst , struct globalvars_s * pr_globals )
2013-10-08 14:28:11 +00:00
{
2004-11-23 14:29:51 +00:00
float * pos = G_VECTOR ( OFS_PARM0 ) ;
2014-03-30 08:55:06 +00:00
const char * text = PR_GetStringOfs ( prinst , OFS_PARM1 ) ;
2004-11-23 14:29:51 +00:00
float * size = G_VECTOR ( OFS_PARM2 ) ;
2009-11-04 21:16:50 +00:00
float * rgb = G_VECTOR ( OFS_PARM3 ) ;
float alpha = G_FLOAT ( OFS_PARM4 ) ;
2013-06-23 02:17:02 +00:00
int flag = prinst - > callargc > = 6 ? G_FLOAT ( OFS_PARM5 ) : 0 ;
2010-07-11 02:22:39 +00:00
float x , y ;
2012-11-27 03:23:19 +00:00
unsigned int c ;
2013-05-03 04:28:08 +00:00
int error ;
2004-11-23 14:29:51 +00:00
if ( ! text )
{
G_FLOAT ( OFS_RETURN ) = - 1 ; //was null..
return ;
}
2013-06-23 02:17:02 +00:00
r2d_be_flags = PF_SelectDPDrawFlag ( flag ) ;
------------------------------------------------------------------------
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
PR_CL_BeginString ( prinst , pos [ 0 ] , pos [ 1 ] , size [ 0 ] , size [ 1 ] , & x , & y ) ;
2009-11-04 21:16:50 +00:00
Font_ForceColour ( rgb [ 0 ] , rgb [ 1 ] , rgb [ 2 ] , alpha ) ;
2011-05-20 04:10:46 +00:00
2004-11-23 14:29:51 +00:00
while ( * text )
{
2013-05-03 04:28:08 +00:00
if ( 1 ) //VMUTF8)
2014-03-30 08:55:06 +00:00
c = unicode_decode ( & error , text , ( char * * ) & text , false ) ;
2013-05-03 04:28:08 +00:00
else
{
//FIXME: which charset is this meant to be using?
//quakes? 8859-1? utf8? some weird hacky mixture?
c = * text + + & 0xff ;
if ( ( c & 0x7f ) < 32 )
c | = 0xe000 ; //if its a control char, just use the quake range instead.
else if ( c & 0x80 )
c | = 0xe000 ; //if its a high char, just use the quake range instead. we could colour it, but why bother
}
x = Font_DrawScaleChar ( x , y , CON_WHITEMASK | c ) ;
2004-11-23 14:29:51 +00:00
}
2010-03-14 14:35:56 +00:00
Font_InvalidateColour ( ) ;
------------------------------------------------------------------------
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
Font_EndString ( NULL ) ;
2013-06-23 02:17:02 +00:00
r2d_be_flags = 0 ;
2004-11-23 14:29:51 +00:00
}
2008-11-09 22:29:28 +00:00
2013-06-23 02:17:02 +00:00
//void (float width, vector pos1, vector pos2, vector rgb, float alpha, optional float flags) drawline;
------------------------------------------------------------------------
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 QCBUILTIN PF_CL_drawline ( pubprogfuncs_t * prinst , struct globalvars_s * pr_globals )
2009-05-24 10:11:17 +00:00
{
2013-06-23 02:17:02 +00:00
//float width = G_FLOAT(OFS_PARM0);
float * point1 = G_VECTOR ( OFS_PARM1 ) ;
float * point2 = G_VECTOR ( OFS_PARM2 ) ;
float * rgb = G_VECTOR ( OFS_PARM3 ) ;
float alpha = G_FLOAT ( OFS_PARM4 ) ;
int flags = prinst - > callargc > = 6 ? G_FLOAT ( OFS_PARM5 ) : 0 ;
shader_t * shader_draw_line ;
mesh_t mesh ;
vecV_t vpos [ 2 ] ;
vec2_t vst [ 2 ] ;
vec4_t vcol [ 2 ] ;
index_t idx [ 2 ] ;
memset ( & mesh , 0 , sizeof ( mesh ) ) ;
mesh . indexes = idx ;
2013-08-27 13:18:09 +00:00
mesh . xyz_array = vpos ;
2013-06-23 02:17:02 +00:00
mesh . st_array = vst ;
2013-08-27 13:18:09 +00:00
mesh . colors4f_array [ 0 ] = vcol ;
2013-06-23 02:17:02 +00:00
VectorCopy ( point1 , vpos [ 0 ] ) ;
Vector2Set ( vst [ 0 ] , 0 , 0 ) ;
Vector4Set ( vcol [ 0 ] , rgb [ 0 ] , rgb [ 1 ] , rgb [ 2 ] , alpha ) ;
VectorCopy ( point2 , vpos [ 1 ] ) ;
Vector2Set ( vst [ 1 ] , 0 , 0 ) ;
Vector4Set ( vcol [ 1 ] , rgb [ 0 ] , rgb [ 1 ] , rgb [ 2 ] , alpha ) ;
mesh . numvertexes = 2 ;
mesh . indexes [ 0 ] = 0 ;
mesh . indexes [ 1 ] = 1 ;
mesh . numindexes = 2 ;
//this shader lookup might get pricy.
2013-08-21 07:14:39 +00:00
shader_draw_line = R_RegisterShader ( " shader_draw_line " , SUF_NONE ,
2013-06-23 02:17:02 +00:00
" { \n "
" program defaultfill \n "
" { \n "
" map $whiteimage \n "
" rgbgen exactvertex \n "
" alphagen vertex \n "
2014-07-01 02:51:41 +00:00
" blendfunc blend \n "
2013-06-23 02:17:02 +00:00
" } \n "
" } \n " ) ;
BE_DrawMesh_Single ( shader_draw_line , & mesh , NULL , & shader_draw_line - > defaulttextures , flags | BEF_LINES ) ;
2009-11-17 00:15:44 +00:00
}
//vector drawgetimagesize(string pic) = #460;
------------------------------------------------------------------------
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 QCBUILTIN PF_CL_drawgetimagesize ( pubprogfuncs_t * prinst , struct globalvars_s * pr_globals )
2009-11-17 00:15:44 +00:00
{
2014-03-30 08:55:06 +00:00
const char * picname = PR_GetStringOfs ( prinst , OFS_PARM0 ) ;
2011-03-31 01:14:01 +00:00
mpic_t * p = R2D_SafeCachePic ( picname ) ;
2009-11-17 00:15:44 +00:00
float * ret = G_VECTOR ( OFS_RETURN ) ;
2014-10-05 20:04:11 +00:00
int iw , ih ;
if ( R_GetShaderSizes ( p , & iw , & ih , true ) > 0 )
2009-11-17 00:15:44 +00:00
{
2014-10-05 20:04:11 +00:00
ret [ 0 ] = iw ;
ret [ 1 ] = ih ;
2009-11-17 00:15:44 +00:00
ret [ 2 ] = 0 ;
}
else
{
ret [ 0 ] = 0 ;
ret [ 1 ] = 0 ;
ret [ 2 ] = 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
//vector getmousepos(void) = #66;
void QCBUILTIN PF_cl_getmousepos ( pubprogfuncs_t * prinst , struct globalvars_s * pr_globals )
{
float * ret = G_VECTOR ( OFS_RETURN ) ;
2013-10-08 14:28:11 +00:00
world_t * world = prinst - > parms - > user ;
unsigned int target = world - > keydestmask ;
------------------------------------------------------------------------
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-10-08 14:28:11 +00:00
if ( key_dest_absolutemouse & target )
------------------------------------------------------------------------
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
{
ret [ 0 ] = mousecursor_x ;
ret [ 1 ] = mousecursor_y ;
}
else
{
ret [ 0 ] = mousemove_x ;
ret [ 1 ] = mousemove_y ;
}
mousemove_x = 0 ;
mousemove_y = 0 ;
// extern int mousecursor_x, mousecursor_y;
// ret[0] = mousecursor_x;
// ret[1] = mousecursor_y;
ret [ 2 ] = 0 ;
}
2013-08-21 07:14:39 +00:00
void QCBUILTIN PF_SubConGetSet ( pubprogfuncs_t * prinst , struct globalvars_s * pr_globals )
{
2014-03-30 08:55:06 +00:00
const char * conname = PR_GetStringOfs ( prinst , OFS_PARM0 ) ;
const char * field = PR_GetStringOfs ( prinst , OFS_PARM1 ) ;
const char * value = ( prinst - > callargc > 2 ) ? PR_GetStringOfs ( prinst , OFS_PARM2 ) : NULL ;
2013-08-21 07:14:39 +00:00
console_t * con = Con_FindConsole ( conname ) ;
G_INT ( OFS_RETURN ) = 0 ;
if ( ! con )
{
//null if it doesn't exist
return ;
}
if ( ! strcmp ( field , " title " ) )
{
RETURN_TSTRING ( con - > title ) ;
if ( value )
Q_strncpyz ( con - > title , value , sizeof ( con - > title ) ) ;
}
else if ( ! strcmp ( field , " name " ) )
{
RETURN_TSTRING ( con - > name ) ;
if ( value & & * value & & * con - > name )
Q_strncpyz ( con - > name , value , sizeof ( con - > name ) ) ;
}
else if ( ! strcmp ( field , " next " ) )
{
con = con - > next ;
if ( con )
RETURN_TSTRING ( con - > name ) ;
}
else if ( ! strcmp ( field , " unseen " ) )
{
RETURN_TSTRING ( va ( " %i " , con - > unseentext ) ) ;
if ( value )
con - > unseentext = atoi ( value ) ;
}
2013-11-21 23:02:28 +00:00
else if ( ! strcmp ( field , " markup " ) )
{
int cur ;
if ( con - > parseflags & PFS_NOMARKUP )
cur = 0 ;
else if ( con - > parseflags & PFS_KEEPMARKUP )
cur = 2 ;
else
cur = 1 ;
RETURN_TSTRING ( va ( " %i " , cur ) ) ;
if ( value )
{
cur = atoi ( value ) ;
con - > parseflags & = ~ ( PFS_NOMARKUP | PFS_KEEPMARKUP ) ;
if ( cur = = 0 )
con - > parseflags | = PFS_NOMARKUP ;
else if ( cur = = 2 )
con - > parseflags | = PFS_KEEPMARKUP ;
}
}
else if ( ! strcmp ( field , " forceutf8 " ) )
{
RETURN_TSTRING ( ( con - > parseflags & PFS_FORCEUTF8 ) ? " 1 " : " 0 " ) ;
if ( value )
{
con - > parseflags & = ~ PFS_FORCEUTF8 ;
if ( atoi ( value ) )
con - > parseflags | = PFS_FORCEUTF8 ;
}
}
2014-04-24 01:53:01 +00:00
else if ( ! strcmp ( field , " close " ) )
{
RETURN_TSTRING ( " 0 " ) ; //meant to return the old state...
if ( value & & atoi ( value ) )
Con_Destroy ( con ) ;
}
else if ( ! strcmp ( field , " clear " ) )
{
RETURN_TSTRING ( con - > linecount ? " 0 " : " 1 " ) ;
if ( value & & atoi ( value ) )
Con_ClearCon ( con ) ;
}
2013-08-21 07:14:39 +00:00
else if ( ! strcmp ( field , " hidden " ) )
{
RETURN_TSTRING ( ( con - > flags & CON_HIDDEN ) ? " 1 " : " 0 " ) ;
if ( value )
con - > flags = ( con - > flags & ~ CON_HIDDEN ) | ( atoi ( value ) ? CON_HIDDEN : 0 ) ;
}
else if ( ! strcmp ( field , " linecount " ) )
{
RETURN_TSTRING ( va ( " %i " , con - > linecount ) ) ;
if ( value )
con - > unseentext = atoi ( value ) ;
}
}
void QCBUILTIN PF_SubConPrintf ( pubprogfuncs_t * prinst , struct globalvars_s * pr_globals )
{
char outbuf [ 4096 ] ;
2014-03-30 08:55:06 +00:00
const char * conname = PR_GetStringOfs ( prinst , OFS_PARM0 ) ;
const char * fmt = PR_GetStringOfs ( prinst , OFS_PARM1 ) ;
2013-08-21 07:14:39 +00:00
console_t * con = Con_FindConsole ( conname ) ;
if ( ! con )
return ;
PF_sprintf_internal ( prinst , pr_globals , fmt , 2 , outbuf , sizeof ( outbuf ) ) ;
2014-10-05 20:04:11 +00:00
Con_PrintCon ( con , outbuf , con - > parseflags ) ;
2013-08-21 07:14:39 +00:00
}
void QCBUILTIN PF_SubConDraw ( pubprogfuncs_t * prinst , struct globalvars_s * pr_globals )
{
2014-03-30 08:55:06 +00:00
const char * conname = PR_GetStringOfs ( prinst , OFS_PARM0 ) ;
2013-08-21 07:14:39 +00:00
float * pos = G_VECTOR ( OFS_PARM1 ) ;
float * size = G_VECTOR ( OFS_PARM2 ) ;
float fontsize = G_FLOAT ( OFS_PARM3 ) ;
console_t * con = Con_FindConsole ( conname ) ;
2013-10-08 14:28:11 +00:00
world_t * world = prinst - > parms - > user ;
2013-08-21 07:14:39 +00:00
if ( ! con )
return ;
2013-10-08 14:28:11 +00:00
if ( world - > g . drawfontscale )
{
// szx *= world->g.drawfontscale[0];
fontsize * = world - > g . drawfontscale [ 1 ] ;
}
2013-12-29 22:48:28 +00:00
Con_DrawOneConsole ( con , PR_CL_ChooseFont ( world - > g . drawfont , fontsize , fontsize ) , pos [ 0 ] , pos [ 1 ] , size [ 0 ] , size [ 1 ] ) ;
2013-08-21 07:14:39 +00:00
}
qboolean Key_Console ( console_t * con , unsigned int unicode , int key ) ;
void Key_ConsoleRelease ( console_t * con , unsigned int unicode , int key ) ;
void QCBUILTIN PF_SubConInput ( pubprogfuncs_t * prinst , struct globalvars_s * pr_globals )
{
2014-03-30 08:55:06 +00:00
const char * conname = PR_GetStringOfs ( prinst , OFS_PARM0 ) ;
2013-08-21 07:14:39 +00:00
int ie = G_FLOAT ( OFS_PARM1 ) ;
float pa = G_FLOAT ( OFS_PARM2 ) ;
float pb = G_FLOAT ( OFS_PARM3 ) ;
2014-02-13 23:54:57 +00:00
// float pc = G_FLOAT(OFS_PARM4);
2013-08-21 07:14:39 +00:00
console_t * con = Con_FindConsole ( conname ) ;
G_FLOAT ( OFS_RETURN ) = 0 ;
if ( ! con )
return ;
switch ( ie )
{
case CSIE_KEYDOWN :
//scan, char
2013-08-27 13:18:09 +00:00
if ( ( pa & & qcinput_scan ! = pa ) | | ( pb & & pb ! = qcinput_unicode ) )
G_FLOAT ( OFS_RETURN ) = 0 ;
else
G_FLOAT ( OFS_RETURN ) = Key_Console ( con , pb , MP_TranslateQCtoFTECodes ( pa ) ) ;
2013-08-21 07:14:39 +00:00
break ;
case CSIE_KEYUP :
//scan, char
Key_ConsoleRelease ( con , MP_TranslateQCtoFTECodes ( pa ) , pb ) ;
G_FLOAT ( OFS_RETURN ) = 0 ; //does not inhibit
break ;
case CSIE_MOUSEABS :
//x, y
2013-10-08 14:28:11 +00:00
if ( con = = con_current & & ( key_dest_mask & kdm_console ) )
2013-08-21 07:14:39 +00:00
break ; //no interfering with the main console!
con - > mousecursor [ 0 ] = pa ;
con - > mousecursor [ 1 ] = pb ;
G_FLOAT ( OFS_RETURN ) = true ;
break ;
case CSIE_FOCUS :
//mouse, key
if ( pb > = 0 )
{
con - > flags = ( con - > flags & ~ CONF_KEYFOCUSED ) | ( pb ? CONF_KEYFOCUSED : 0 ) ;
G_FLOAT ( OFS_RETURN ) = true ;
}
break ;
}
}
2009-11-17 00:15:44 +00:00
# endif
# ifdef MENU_DAT
typedef struct menuedict_s
{
qboolean isfree ;
float freetime ; // sv.time when the object was freed
int entnum ;
qboolean readonly ; //world
void * fields ;
} menuedict_t ;
2014-05-30 03:57:30 +00:00
static struct
{
evalc_t chain ;
evalc_t model ;
evalc_t mins ;
evalc_t maxs ;
evalc_t origin ;
evalc_t angles ;
evalc_t skin ;
evalc_t colormap ;
evalc_t frame1 ;
evalc_t frame2 ;
evalc_t lerpfrac ;
evalc_t frame1time ;
evalc_t frame2time ;
evalc_t renderflags ;
} menuc_eval ;
static playerview_t menuview ;
2009-11-17 00:15:44 +00:00
int menuentsize ;
// cvars
# define MENUPROGSGROUP "Menu progs control"
cvar_t forceqmenu = SCVAR ( " forceqmenu " , " 0 " ) ;
cvar_t pr_menuqc_coreonerror = SCVAR ( " pr_menuqc_coreonerror " , " 1 " ) ;
//new generic functions.
------------------------------------------------------------------------
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 QCBUILTIN PF_mod ( pubprogfuncs_t * prinst , struct globalvars_s * pr_globals )
2009-11-17 00:15:44 +00:00
{
2011-05-20 04:10:46 +00:00
int a = G_FLOAT ( OFS_PARM0 ) ;
int b = G_FLOAT ( OFS_PARM1 ) ;
if ( b = = 0 )
{
Con_Printf ( " mod by zero \n " ) ;
------------------------------------------------------------------------
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
prinst - > pr_trace = 1 ;
2011-05-20 04:10:46 +00:00
G_FLOAT ( OFS_RETURN ) = 0 ;
}
else
G_FLOAT ( OFS_RETURN ) = a % b ;
2009-11-17 00:15:44 +00:00
}
2014-03-30 08:55:06 +00:00
const char * RemapCvarNameFromDPToFTE ( const char * name )
2009-11-17 00:15:44 +00:00
{
if ( ! stricmp ( name , " vid_bitsperpixel " ) )
return " vid_bpp " ;
if ( ! stricmp ( name , " _cl_playermodel " ) )
return " model " ;
if ( ! stricmp ( name , " _cl_playerskin " ) )
return " skin " ;
if ( ! stricmp ( name , " _cl_color " ) )
return " topcolor " ;
if ( ! stricmp ( name , " _cl_name " ) )
return " name " ;
if ( ! stricmp ( name , " v_contrast " ) )
return " v_contrast " ;
if ( ! stricmp ( name , " v_hwgamma " ) )
return " vid_hardwaregamma " ;
if ( ! stricmp ( name , " showfps " ) )
return " show_fps " ;
if ( ! stricmp ( name , " sv_progs " ) )
return " progs " ;
return name ;
2009-05-24 10:11:17 +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
static void QCBUILTIN PF_menu_cvar ( pubprogfuncs_t * prinst , struct globalvars_s * pr_globals )
2008-11-09 22:29:28 +00:00
{
2009-11-17 00:15:44 +00:00
cvar_t * var ;
2014-03-30 08:55:06 +00:00
const char * str ;
2011-05-29 04:26:29 +00:00
2009-11-17 00:15:44 +00:00
str = PR_GetStringOfs ( prinst , OFS_PARM0 ) ;
2012-11-27 03:23:19 +00:00
if ( ! strcmp ( str , " vid_conwidth " ) )
G_FLOAT ( OFS_RETURN ) = vid . width ;
else if ( ! strcmp ( str , " vid_conheight " ) )
G_FLOAT ( OFS_RETURN ) = vid . height ;
2013-03-12 22:44:00 +00:00
else if ( ! strcmp ( str , " vid_pixwidth " ) )
G_FLOAT ( OFS_RETURN ) = vid . pixelwidth ;
else if ( ! strcmp ( str , " vid_pixheight " ) )
G_FLOAT ( OFS_RETURN ) = vid . pixelheight ;
2012-11-27 03:23:19 +00:00
else
2009-05-24 10:11:17 +00:00
{
2012-11-27 03:23:19 +00:00
str = RemapCvarNameFromDPToFTE ( str ) ;
var = Cvar_Get ( str , " " , 0 , " menu cvars " ) ;
2014-09-20 04:11:39 +00:00
if ( var & & ! ( var - > flags & CVAR_NOUNSAFEEXPAND ) )
2012-11-27 03:23:19 +00:00
{
2014-09-20 04:11:39 +00:00
//menuqc sees desired settings, not latched settings.
2012-11-27 03:23:19 +00:00
if ( var - > latched_string )
G_FLOAT ( OFS_RETURN ) = atof ( var - > latched_string ) ;
else
G_FLOAT ( OFS_RETURN ) = var - > value ;
}
else
G_FLOAT ( OFS_RETURN ) = 0 ;
2009-05-24 10:11:17 +00:00
}
2008-11-09 22:29:28 +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
static void QCBUILTIN PF_menu_cvar_set ( pubprogfuncs_t * prinst , struct globalvars_s * pr_globals )
2009-11-17 00:15:44 +00:00
{
2014-03-30 08:55:06 +00:00
const char * var_name , * val ;
2009-11-17 00:15:44 +00:00
cvar_t * var ;
2008-11-09 22:29:28 +00:00
2009-11-17 00:15:44 +00:00
var_name = PR_GetStringOfs ( prinst , OFS_PARM0 ) ;
var_name = RemapCvarNameFromDPToFTE ( var_name ) ;
val = PR_GetStringOfs ( prinst , OFS_PARM1 ) ;
2008-11-09 22:29:28 +00:00
2009-11-17 00:15:44 +00:00
var = Cvar_Get ( var_name , val , 0 , " QC variables " ) ;
2014-09-20 04:11:39 +00:00
if ( var - > flags & CVAR_NOTFROMSERVER )
{
//fixme: menuqc needs some way to display a prompt to allow it anyway.
return ;
}
2009-11-17 00:15:44 +00:00
Cvar_Set ( var , val ) ;
}
------------------------------------------------------------------------
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
static void QCBUILTIN PF_menu_cvar_string ( pubprogfuncs_t * prinst , struct globalvars_s * pr_globals )
2009-11-04 21:16:50 +00:00
{
2014-03-30 08:55:06 +00:00
const char * str = PR_GetStringOfs ( prinst , OFS_PARM0 ) ;
2009-11-17 00:15:44 +00:00
cvar_t * cv = Cvar_Get ( RemapCvarNameFromDPToFTE ( str ) , " " , 0 , " QC variables " ) ;
2014-04-24 01:53:01 +00:00
if ( ! cv )
G_INT ( OFS_RETURN ) = 0 ;
2014-09-20 04:11:39 +00:00
else if ( cv - > flags & CVAR_NOUNSAFEEXPAND )
G_INT ( OFS_RETURN ) = 0 ;
2014-04-24 01:53:01 +00:00
else if ( cv - > latched_string )
2014-09-20 04:11:39 +00:00
G_INT ( OFS_RETURN ) = ( int ) PR_TempString ( prinst , cv - > latched_string ) ;
2014-04-24 01:53:01 +00:00
else
2014-09-20 04:11:39 +00:00
G_INT ( OFS_RETURN ) = ( int ) PR_TempString ( prinst , cv - > string ) ;
2009-11-04 21:16:50 +00:00
}
2008-11-09 22:29:28 +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 QCBUILTIN PF_nonfatalobjerror ( pubprogfuncs_t * prinst , struct globalvars_s * pr_globals )
2009-11-17 00:15:44 +00:00
{
char * s ;
struct edict_s * ed ;
eval_t * selfp ;
2011-05-29 04:26:29 +00:00
2009-11-17 00:15:44 +00:00
s = PF_VarString ( prinst , 0 , pr_globals ) ;
2008-11-09 22:29:28 +00:00
2014-05-30 03:57:30 +00:00
PR_StackTrace ( prinst , true ) ;
2008-11-09 22:29:28 +00:00
2011-05-20 04:10:46 +00:00
selfp = PR_FindGlobal ( prinst , " self " , PR_CURRENT , NULL ) ;
2009-11-17 00:15:44 +00:00
if ( selfp & & selfp - > _int )
2004-11-23 14:29:51 +00:00
{
2009-11-17 00:15:44 +00:00
ed = PROG_TO_EDICT ( prinst , selfp - > _int ) ;
2004-11-23 14:29:51 +00:00
2009-11-17 00:15:44 +00:00
PR_PrintEdict ( prinst , ed ) ;
2004-11-23 14:29:51 +00:00
2009-11-17 00:15:44 +00:00
if ( developer . value )
------------------------------------------------------------------------
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
prinst - > pr_trace = 2 ;
2009-11-17 00:15:44 +00:00
else
{
ED_Free ( prinst , ed ) ;
}
2004-11-23 14:29:51 +00:00
}
2009-11-17 00:15:44 +00:00
Con_Printf ( " ======OBJECT ERROR====== \n %s \n " , s ) ;
2004-11-23 14:29:51 +00:00
}
2005-10-01 03:09:17 +00:00
2009-11-17 00:15:44 +00:00
//float isserver(void) = #60;
------------------------------------------------------------------------
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 QCBUILTIN PF_isserver ( pubprogfuncs_t * prinst , struct globalvars_s * pr_globals )
2004-11-23 14:29:51 +00:00
{
2009-11-17 00:15:44 +00:00
# ifdef CLIENTONLY
G_FLOAT ( OFS_RETURN ) = false ;
# else
G_FLOAT ( OFS_RETURN ) = sv . state ! = ss_dead ;
2005-10-01 03:09:17 +00:00
# endif
2004-11-23 14:29:51 +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 QCBUILTIN PF_isdemo ( pubprogfuncs_t * prinst , struct globalvars_s * pr_globals )
2012-11-27 03:23:19 +00:00
{
G_FLOAT ( OFS_RETURN ) = ! ! cls . demoplayback ;
}
2005-07-05 23:46:10 +00:00
2009-11-17 00:15:44 +00:00
//float clientstate(void) = #62;
------------------------------------------------------------------------
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 QCBUILTIN PF_clientstate ( pubprogfuncs_t * prinst , struct globalvars_s * pr_globals )
2005-07-05 23:46:10 +00:00
{
2009-11-17 00:15:44 +00:00
G_FLOAT ( OFS_RETURN ) = cls . state > = ca_connected ? 2 : 1 ; //fit in with netquake (we never run a menu.dat dedicated)
}
2005-07-16 17:04:36 +00:00
2009-11-17 00:15:44 +00:00
//too specific to the prinst's builtins.
------------------------------------------------------------------------
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
static void QCBUILTIN PF_Fixme ( pubprogfuncs_t * prinst , struct globalvars_s * pr_globals )
2009-11-17 00:15:44 +00:00
{
Con_Printf ( " \n " ) ;
2005-07-14 01:57:34 +00:00
2009-11-17 00:15:44 +00:00
prinst - > RunError ( prinst , " \n Builtin %i not implemented. \n Menu is not compatible. " , prinst - > lastcalledbuiltinnumber ) ;
PR_BIError ( prinst , " bulitin not implemented " ) ;
2005-07-05 23:46:10 +00:00
}
2004-11-23 14:29:51 +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 QCBUILTIN PF_CL_precache_sound ( pubprogfuncs_t * prinst , struct globalvars_s * pr_globals )
2009-11-17 00:15:44 +00:00
{
2014-03-30 08:55:06 +00:00
const char * str ;
2011-05-29 04:26:29 +00:00
2009-11-17 00:15:44 +00:00
str = PR_GetStringOfs ( prinst , OFS_PARM0 ) ;
2006-03-23 19:22:12 +00:00
2009-11-17 00:15:44 +00:00
if ( S_PrecacheSound ( str ) )
G_INT ( OFS_RETURN ) = G_INT ( OFS_PARM0 ) ;
2004-11-23 14:29:51 +00:00
else
2009-11-17 00:15:44 +00:00
G_INT ( OFS_RETURN ) = 0 ;
2004-11-23 14:29:51 +00:00
}
//void setkeydest(float dest) = #601;
------------------------------------------------------------------------
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 QCBUILTIN PF_cl_setkeydest ( pubprogfuncs_t * prinst , struct globalvars_s * pr_globals )
2004-11-23 14:29:51 +00:00
{
switch ( ( int ) G_FLOAT ( OFS_PARM0 ) )
{
case 0 :
// key_game
2014-04-24 01:53:01 +00:00
if ( Key_Dest_Has ( kdm_menu ) )
{
Key_Dest_Remove ( kdm_menu ) ;
2014-05-20 02:23:37 +00:00
// Key_Dest_Remove(kdm_message);
if ( cls . state = = ca_disconnected )
Key_Dest_Add ( kdm_console ) ;
2014-04-24 01:53:01 +00:00
}
2004-11-23 14:29:51 +00:00
break ;
case 2 :
// key_menu
m_state = m_menu_dat ;
2013-10-08 14:28:11 +00:00
Key_Dest_Remove ( kdm_message ) ;
2013-12-02 14:30:30 +00:00
if ( ! Key_Dest_Has ( kdm_menu ) )
Key_Dest_Remove ( kdm_console ) ;
2013-10-08 14:28:11 +00:00
Key_Dest_Add ( kdm_menu ) ;
2004-11-23 14:29:51 +00:00
break ;
case 1 :
// key_message
2013-10-08 14:28:11 +00:00
//Key_Dest_Remove(kdm_menu);
//Key_Dest_Add(kdm_message);
2004-11-23 14:29:51 +00:00
// break;
default :
PR_BIError ( prinst , " PF_setkeydest: wrong destination %i ! \n " , ( int ) G_FLOAT ( OFS_PARM0 ) ) ;
}
}
//float getkeydest(void) = #602;
------------------------------------------------------------------------
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 QCBUILTIN PF_cl_getkeydest ( pubprogfuncs_t * prinst , struct globalvars_s * pr_globals )
2004-11-23 14:29:51 +00:00
{
2013-10-08 14:28:11 +00:00
if ( Key_Dest_Has ( kdm_menu ) )
2004-11-23 14:29:51 +00:00
{
if ( m_state = = m_menu_dat )
G_FLOAT ( OFS_RETURN ) = 2 ;
else
G_FLOAT ( OFS_RETURN ) = 3 ;
}
2013-10-08 14:28:11 +00:00
// else if (Key_Dest_Has(kdm_message))
// G_FLOAT(OFS_RETURN) = 1;
else
G_FLOAT ( OFS_RETURN ) = 0 ;
2004-11-23 14:29:51 +00:00
}
//void setmousetarget(float trg) = #603;
------------------------------------------------------------------------
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 QCBUILTIN PF_cl_setmousetarget ( pubprogfuncs_t * prinst , struct globalvars_s * pr_globals )
2004-11-23 14:29:51 +00:00
{
2013-10-08 14:28:11 +00:00
world_t * world = prinst - > parms - > user ;
unsigned int target = world - > keydestmask ;
2004-11-23 14:29:51 +00:00
switch ( ( int ) G_FLOAT ( OFS_PARM0 ) )
{
2013-10-08 14:28:11 +00:00
case 1 : //1 is delta-based (mt_menu).
key_dest_absolutemouse & = ~ target ;
2004-11-23 14:29:51 +00:00
break ;
2013-10-08 14:28:11 +00:00
case 2 : //2 is absolute (mt_client).
key_dest_absolutemouse | = target ;
2012-11-27 03:23:19 +00:00
break ;
2004-11-23 14:29:51 +00:00
default :
PR_BIError ( prinst , " PF_setmousetarget: not a valid destination \n " ) ;
}
}
//float getmousetarget(void) = #604;
------------------------------------------------------------------------
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 QCBUILTIN PF_cl_getmousetarget ( pubprogfuncs_t * prinst , struct globalvars_s * pr_globals )
2004-11-23 14:29:51 +00:00
{
2013-10-08 14:28:11 +00:00
world_t * world = prinst - > parms - > user ;
unsigned int target = world - > keydestmask ;
G_FLOAT ( OFS_RETURN ) = ( key_dest_absolutemouse & target ) ? 2 : 1 ;
2004-11-23 14:29:51 +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
static void QCBUILTIN PF_Remove_ ( pubprogfuncs_t * prinst , struct globalvars_s * pr_globals )
2004-11-23 14:29:51 +00:00
{
2005-02-28 07:16:19 +00:00
menuedict_t * ed ;
2011-05-29 04:26:29 +00:00
2005-02-28 07:16:19 +00:00
ed = ( void * ) G_EDICT ( prinst , OFS_PARM0 ) ;
2004-11-23 14:29:51 +00:00
if ( ed - > isfree )
{
Con_DPrintf ( " Tried removing free entity \n " ) ;
2014-05-30 03:57:30 +00:00
PR_StackTrace ( prinst , false ) ;
2004-11-23 14:29:51 +00:00
return ;
}
2005-02-28 07:16:19 +00:00
ED_Free ( prinst , ( void * ) ed ) ;
2004-11-23 14:29:51 +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
static void QCBUILTIN PF_CopyEntity ( pubprogfuncs_t * prinst , struct globalvars_s * pr_globals )
2004-11-23 14:29:51 +00:00
{
2005-03-28 07:05:38 +00:00
menuedict_t * in , * out ;
2004-11-23 14:29:51 +00:00
2005-03-28 07:05:38 +00:00
in = ( menuedict_t * ) G_EDICT ( prinst , OFS_PARM0 ) ;
out = ( menuedict_t * ) G_EDICT ( prinst , OFS_PARM1 ) ;
2004-11-23 14:29:51 +00:00
2005-03-28 07:05:38 +00:00
memcpy ( out - > fields , in - > fields , menuentsize ) ;
2004-11-23 14:29:51 +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 QCBUILTIN PF_localsound ( pubprogfuncs_t * prinst , struct globalvars_s * pr_globals )
2004-11-23 14:29:51 +00:00
{
2014-03-30 08:55:06 +00:00
const char * soundname = PR_GetStringOfs ( prinst , OFS_PARM0 ) ;
2004-11-23 14:29:51 +00:00
S_LocalSound ( soundname ) ;
}
------------------------------------------------------------------------
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 QCBUILTIN PF_menu_checkextension ( pubprogfuncs_t * prinst , struct globalvars_s * pr_globals )
2004-11-23 14:29:51 +00:00
{
2014-03-30 08:55:06 +00:00
const char * extname = PR_GetStringOfs ( prinst , OFS_PARM0 ) ;
2013-03-12 22:35:33 +00:00
int i ;
2004-11-23 14:29:51 +00:00
G_FLOAT ( OFS_RETURN ) = 0 ;
2013-03-12 22:35:33 +00:00
for ( i = 0 ; i < QSG_Extensions_count ; i + + )
{
if ( ! QSG_Extensions [ i ] . name )
continue ;
if ( ! stricmp ( extname , QSG_Extensions [ i ] . name ) )
{
G_FLOAT ( OFS_RETURN ) = 1 ;
break ;
}
}
2004-11-23 14:29:51 +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 QCBUILTIN PF_CL_precache_file ( pubprogfuncs_t * prinst , struct globalvars_s * pr_globals )
2004-11-23 14:29:51 +00:00
{
G_INT ( OFS_RETURN ) = G_INT ( OFS_PARM0 ) ;
}
2004-11-26 06:07:41 +00:00
//entity findchainstring(.string _field, string match) = #26;
------------------------------------------------------------------------
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 QCBUILTIN PF_menu_findchain ( pubprogfuncs_t * prinst , struct globalvars_s * pr_globals )
2004-11-26 06:07:41 +00:00
{
int i , f ;
2014-03-30 08:55:06 +00:00
const char * s ;
2007-06-20 00:02:54 +00:00
string_t t ;
2005-03-28 07:05:38 +00:00
menuedict_t * ent , * chain ; //note, all edicts share the common header, but don't use it's fields!
2004-11-26 06:07:41 +00:00
eval_t * val ;
2005-03-28 07:05:38 +00:00
chain = ( menuedict_t * ) * prinst - > parms - > sv_edicts ;
2004-11-26 06:07:41 +00:00
f = G_INT ( OFS_PARM0 ) + prinst - > fieldadjust ;
s = PR_GetStringOfs ( prinst , OFS_PARM1 ) ;
for ( i = 1 ; i < * prinst - > parms - > sv_num_edicts ; i + + )
{
2005-03-28 07:05:38 +00:00
ent = ( menuedict_t * ) EDICT_NUM ( prinst , i ) ;
2004-11-26 06:07:41 +00:00
if ( ent - > isfree )
continue ;
2007-06-20 00:02:54 +00:00
t = * ( string_t * ) & ( ( float * ) ent - > fields ) [ f ] ;
2004-11-26 06:07:41 +00:00
if ( ! t )
continue ;
2007-06-20 00:02:54 +00:00
if ( strcmp ( PR_GetString ( prinst , t ) , s ) )
2004-11-26 06:07:41 +00:00
continue ;
2014-05-30 03:57:30 +00:00
val = prinst - > GetEdictFieldValue ( prinst , ( void * ) ent , " chain " , & menuc_eval . chain ) ;
2004-11-26 06:07:41 +00:00
if ( val )
2005-03-28 07:05:38 +00:00
val - > edict = EDICT_TO_PROG ( prinst , ( void * ) chain ) ;
2004-11-26 06:07:41 +00:00
chain = ent ;
}
2005-03-28 07:05:38 +00:00
RETURN_EDICT ( prinst , ( void * ) chain ) ;
2004-11-26 06:07:41 +00:00
}
//entity findchainfloat(.float _field, float match) = #27;
------------------------------------------------------------------------
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 QCBUILTIN PF_menu_findchainfloat ( pubprogfuncs_t * prinst , struct globalvars_s * pr_globals )
2004-11-26 06:07:41 +00:00
{
int i , f ;
float s ;
2005-03-28 07:05:38 +00:00
menuedict_t * ent , * chain ; //note, all edicts share the common header, but don't use it's fields!
2004-11-26 06:07:41 +00:00
eval_t * val ;
2005-03-28 07:05:38 +00:00
chain = ( menuedict_t * ) * prinst - > parms - > sv_edicts ;
2004-11-26 06:07:41 +00:00
f = G_INT ( OFS_PARM0 ) + prinst - > fieldadjust ;
s = G_FLOAT ( OFS_PARM1 ) ;
for ( i = 1 ; i < * prinst - > parms - > sv_num_edicts ; i + + )
{
2005-03-28 07:05:38 +00:00
ent = ( menuedict_t * ) EDICT_NUM ( prinst , i ) ;
2004-11-26 06:07:41 +00:00
if ( ent - > isfree )
continue ;
2005-03-28 07:05:38 +00:00
if ( ( ( float * ) ent - > fields ) [ f ] ! = s )
2004-11-26 06:07:41 +00:00
continue ;
2014-05-30 03:57:30 +00:00
val = prinst - > GetEdictFieldValue ( prinst , ( void * ) ent , " chain " , & menuc_eval . chain ) ;
2004-11-26 06:07:41 +00:00
if ( val )
2005-03-28 07:05:38 +00:00
val - > edict = EDICT_TO_PROG ( prinst , ( void * ) chain ) ;
2004-11-26 06:07:41 +00:00
chain = ent ;
}
2005-03-28 07:05:38 +00:00
RETURN_EDICT ( prinst , ( void * ) chain ) ;
2004-11-26 06:07:41 +00:00
}
2013-03-12 22:35:33 +00:00
//entity findchainflags(.float _field, float match);
void QCBUILTIN PF_menu_findchainflags ( pubprogfuncs_t * prinst , struct globalvars_s * pr_globals )
{
int i , f ;
int s ;
menuedict_t * ent , * chain ; //note, all edicts share the common header, but don't use it's fields!
eval_t * val ;
chain = ( menuedict_t * ) * prinst - > parms - > sv_edicts ;
f = G_INT ( OFS_PARM0 ) + prinst - > fieldadjust ;
s = G_FLOAT ( OFS_PARM1 ) ;
for ( i = 1 ; i < * prinst - > parms - > sv_num_edicts ; i + + )
{
ent = ( menuedict_t * ) EDICT_NUM ( prinst , i ) ;
if ( ent - > isfree )
continue ;
if ( ( int ) ( ( float * ) ent - > fields ) [ f ] & s )
continue ;
2014-05-30 03:57:30 +00:00
val = prinst - > GetEdictFieldValue ( prinst , ( void * ) ent , " chain " , & menuc_eval . chain ) ;
2013-03-12 22:35:33 +00:00
if ( val )
val - > edict = EDICT_TO_PROG ( prinst , ( void * ) chain ) ;
chain = ent ;
}
RETURN_EDICT ( prinst , ( void * ) chain ) ;
}
2004-11-26 06:07:41 +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 QCBUILTIN PF_etof ( pubprogfuncs_t * prinst , struct globalvars_s * pr_globals )
2004-12-02 07:15:29 +00:00
{
G_FLOAT ( OFS_RETURN ) = G_EDICTNUM ( prinst , OFS_PARM0 ) ;
}
------------------------------------------------------------------------
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 QCBUILTIN PF_ftoe ( pubprogfuncs_t * prinst , struct globalvars_s * pr_globals )
2004-12-08 04:14:52 +00:00
{
int entnum = G_FLOAT ( OFS_PARM0 ) ;
RETURN_EDICT ( prinst , EDICT_NUM ( prinst , entnum ) ) ;
}
------------------------------------------------------------------------
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 QCBUILTIN PF_IsNotNull ( pubprogfuncs_t * prinst , struct globalvars_s * pr_globals )
2004-12-08 04:14:52 +00:00
{
int str = G_INT ( OFS_PARM0 ) ;
2005-02-17 03:33:36 +00:00
G_FLOAT ( OFS_RETURN ) = ! ! str ;
}
//float altstr_count(string str) = #82;
//returns number of single quoted strings in the string.
------------------------------------------------------------------------
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 QCBUILTIN PF_altstr_count ( pubprogfuncs_t * prinst , struct globalvars_s * pr_globals )
2005-02-17 03:33:36 +00:00
{
2014-03-30 08:55:06 +00:00
const char * s ;
2005-02-17 03:33:36 +00:00
int count = 0 ;
s = PR_GetStringOfs ( prinst , OFS_PARM0 ) ;
for ( ; * s ; s + + )
{
if ( * s = = ' \\ ' )
{
if ( ! * + + s )
break ;
}
else if ( * s = = ' \' ' )
count + + ;
}
G_FLOAT ( OFS_RETURN ) = count / 2 ;
}
//string altstr_prepare(string str) = #83;
------------------------------------------------------------------------
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 QCBUILTIN PF_altstr_prepare ( pubprogfuncs_t * prinst , struct globalvars_s * pr_globals )
2005-02-17 03:33:36 +00:00
{
2007-03-11 16:51:45 +00:00
char outstr [ 8192 ] , * out ;
2014-03-30 08:55:06 +00:00
const char * instr , * in ;
2005-02-17 03:33:36 +00:00
int size ;
// VM_SAFEPARMCOUNT( 1, VM_altstr_prepare );
instr = PR_GetStringOfs ( prinst , OFS_PARM0 ) ;
//VM_CheckEmptyString( instr );
2007-03-11 16:51:45 +00:00
for ( out = outstr , in = instr , size = sizeof ( outstr ) - 1 ; size & & * in ; size - - , in + + , out + + )
{
if ( * in = = ' \' ' )
{
2005-02-17 03:33:36 +00:00
* out + + = ' \\ ' ;
* out = ' \' ' ;
size - - ;
2007-03-11 16:51:45 +00:00
}
else
2005-02-17 03:33:36 +00:00
* out = * in ;
2007-03-11 16:51:45 +00:00
}
2005-02-17 03:33:36 +00:00
* out = 0 ;
2007-03-11 16:51:45 +00:00
G_INT ( OFS_RETURN ) = ( int ) PR_TempString ( prinst , outstr ) ;
2005-02-17 03:33:36 +00:00
}
//string altstr_get(string str, float num) = #84;
------------------------------------------------------------------------
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 QCBUILTIN PF_altstr_get ( pubprogfuncs_t * prinst , struct globalvars_s * pr_globals )
2005-02-17 03:33:36 +00:00
{
2014-03-30 08:55:06 +00:00
const char * altstr , * pos ;
char outstr [ 8192 ] , * out ;
2005-02-17 03:33:36 +00:00
int count , size ;
// VM_SAFEPARMCOUNT( 2, VM_altstr_get );
altstr = PR_GetStringOfs ( prinst , OFS_PARM0 ) ;
//VM_CheckEmptyString( altstr );
count = G_FLOAT ( OFS_PARM1 ) ;
count = count * 2 + 1 ;
for ( pos = altstr ; * pos & & count ; pos + + )
2007-03-11 16:51:45 +00:00
{
2005-02-17 03:33:36 +00:00
if ( * pos = = ' \\ ' & & ! * + + pos )
break ;
else if ( * pos = = ' \' ' )
count - - ;
2007-03-11 16:51:45 +00:00
}
2005-02-17 03:33:36 +00:00
2007-03-11 16:51:45 +00:00
if ( ! * pos )
{
2005-02-17 03:33:36 +00:00
G_INT ( OFS_RETURN ) = ( int ) PR_SetString ( prinst , " " ) ;
return ;
}
2007-03-11 16:51:45 +00:00
for ( out = outstr , size = sizeof ( outstr ) - 1 ; size & & * pos ; size - - , pos + + , out + + )
{
if ( * pos = = ' \\ ' )
{
2005-02-17 03:33:36 +00:00
if ( ! * + + pos )
break ;
* out = * pos ;
size - - ;
2007-03-11 16:51:45 +00:00
}
else if ( * pos = = ' \' ' )
2005-02-17 03:33:36 +00:00
break ;
else
* out = * pos ;
2007-03-11 16:51:45 +00:00
}
2005-02-17 03:33:36 +00:00
* out = 0 ;
2013-03-12 22:35:33 +00:00
G_INT ( OFS_RETURN ) = ( int ) PR_TempString ( prinst , outstr ) ;
2005-02-17 03:33:36 +00:00
}
//string altstr_set(string str, float num, string set) = #85
------------------------------------------------------------------------
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 QCBUILTIN PF_altstr_set ( pubprogfuncs_t * prinst , struct globalvars_s * pr_globals )
2005-02-17 03:33:36 +00:00
{
int num ;
2014-03-30 08:55:06 +00:00
const char * altstr , * str ;
const char * in ;
2007-03-11 16:51:45 +00:00
char outstr [ 8192 ] , * out ;
2005-02-17 03:33:36 +00:00
// VM_SAFEPARMCOUNT( 3, VM_altstr_set );
altstr = PR_GetStringOfs ( prinst , OFS_PARM0 ) ;
//VM_CheckEmptyString( altstr );
num = G_FLOAT ( OFS_PARM1 ) ;
str = PR_GetStringOfs ( prinst , OFS_PARM2 ) ;
//VM_CheckEmptyString( str );
2007-03-11 16:51:45 +00:00
out = outstr ;
2005-02-17 03:33:36 +00:00
for ( num = num * 2 + 1 , in = altstr ; * in & & num ; * out + + = * in + + )
2007-03-11 16:51:45 +00:00
{
2005-02-17 03:33:36 +00:00
if ( * in = = ' \\ ' & & ! * + + in )
break ;
else if ( * in = = ' \' ' )
num - - ;
2007-03-11 16:51:45 +00:00
}
2005-02-17 03:33:36 +00:00
2007-03-11 16:51:45 +00:00
if ( ! in )
{
2005-02-17 03:33:36 +00:00
G_INT ( OFS_RETURN ) = ( int ) PR_SetString ( prinst , " " ) ;
return ;
}
// copy set in
2007-03-11 16:51:45 +00:00
for ( ; * str ; * out + + = * str + + )
;
2005-02-17 03:33:36 +00:00
// now jump over the old contents
for ( ; * in ; in + + )
2007-03-11 16:51:45 +00:00
{
2005-02-17 03:33:36 +00:00
if ( * in = = ' \' ' | | ( * in = = ' \\ ' & & ! * + + in ) )
break ;
2007-03-11 16:51:45 +00:00
}
2005-02-17 03:33:36 +00:00
if ( ! in ) {
G_INT ( OFS_RETURN ) = ( int ) PR_SetString ( prinst , " " ) ;
return ;
}
strcpy ( out , in ) ;
2007-03-11 16:51:45 +00:00
G_INT ( OFS_RETURN ) = ( int ) PR_TempString ( prinst , outstr ) ;
2005-02-17 03:33:36 +00:00
2004-12-08 04:14:52 +00:00
}
2004-12-02 07:15:29 +00:00
2012-11-27 03:23:19 +00:00
//string(string serveraddress) crypto_getkeyfp
------------------------------------------------------------------------
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 QCBUILTIN PF_crypto_getkeyfp ( pubprogfuncs_t * prinst , struct globalvars_s * pr_globals )
2012-11-27 03:23:19 +00:00
{
//not supported.
G_INT ( OFS_RETURN ) = 0 ;
}
//string(string serveraddress) crypto_getidfp
------------------------------------------------------------------------
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 QCBUILTIN PF_crypto_getidfp ( pubprogfuncs_t * prinst , struct globalvars_s * pr_globals )
2012-11-27 03:23:19 +00:00
{
//not supported.
G_INT ( OFS_RETURN ) = 0 ;
}
//string(string serveraddress) crypto_getencryptlevel
------------------------------------------------------------------------
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 QCBUILTIN PF_crypto_getencryptlevel ( pubprogfuncs_t * prinst , struct globalvars_s * pr_globals )
2012-11-27 03:23:19 +00:00
{
//not supported.
G_INT ( OFS_RETURN ) = 0 ;
}
//string(float i) crypto_getmykeyfp
------------------------------------------------------------------------
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 QCBUILTIN PF_crypto_getmykeyfp ( pubprogfuncs_t * prinst , struct globalvars_s * pr_globals )
2012-11-27 03:23:19 +00:00
{
//not supported.
G_INT ( OFS_RETURN ) = 0 ;
}
//string(float i) crypto_getmyidfp
------------------------------------------------------------------------
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 QCBUILTIN PF_crypto_getmyidfp ( pubprogfuncs_t * prinst , struct globalvars_s * pr_globals )
2012-11-27 03:23:19 +00:00
{
//not supported.
G_INT ( OFS_RETURN ) = 0 ;
}
2014-05-30 03:57:30 +00:00
static void QCBUILTIN PF_m_precache_model ( pubprogfuncs_t * prinst , struct globalvars_s * pr_globals )
{
const char * modelname = PR_GetStringOfs ( prinst , OFS_PARM0 ) ;
Mod_ForName ( modelname , MLV_WARN ) ;
}
static void QCBUILTIN PF_m_setmodel ( pubprogfuncs_t * prinst , struct globalvars_s * pr_globals )
{
menuedict_t * ent = ( void * ) G_EDICT ( prinst , OFS_PARM0 ) ;
string_t modelname = G_INT ( OFS_PARM1 ) ; //FIXME: zone it or something?
eval_t * modelval = prinst - > GetEdictFieldValue ( prinst , ( void * ) ent , " model " , & menuc_eval . model ) ;
eval_t * minsval = prinst - > GetEdictFieldValue ( prinst , ( void * ) ent , " mins " , & menuc_eval . mins ) ;
eval_t * maxsval = prinst - > GetEdictFieldValue ( prinst , ( void * ) ent , " maxs " , & menuc_eval . maxs ) ;
model_t * mod = Mod_ForName ( prinst - > StringToNative ( prinst , modelname ) , MLV_WARN ) ;
if ( modelval )
modelval - > string = modelname ;
if ( mod & & minsval )
VectorCopy ( mod - > mins , minsval - > _vector ) ;
if ( mod & & maxsval )
VectorCopy ( mod - > maxs , maxsval - > _vector ) ;
}
//trivially basic
static void QCBUILTIN PF_m_setorigin ( pubprogfuncs_t * prinst , struct globalvars_s * pr_globals )
{
menuedict_t * ent = ( void * ) G_EDICT ( prinst , OFS_PARM0 ) ;
float * org = G_VECTOR ( OFS_PARM1 ) ;
eval_t * val = prinst - > GetEdictFieldValue ( prinst , ( void * ) ent , " origin " , & menuc_eval . origin ) ;
if ( val )
VectorCopy ( org , val - > _vector ) ;
}
static void QCBUILTIN PF_m_clearscene ( pubprogfuncs_t * prinst , struct globalvars_s * pr_globals )
{
// CL_DecayLights ();
# if defined(SKELETALOBJECTS) || defined(RAGDOLLS)
skel_dodelete ( prinst ) ;
# endif
CL_ClearEntityLists ( ) ;
V_ClearRefdef ( & menuview ) ;
r_refdef . drawsbar = false ;
r_refdef . drawcrosshair = false ;
V_CalcRefdef ( & menuview ) ; //set up the defaults
r_refdef . flags | = RDF_NOWORLDMODEL ;
}
static qboolean CopyMenuEdictToEntity ( pubprogfuncs_t * prinst , menuedict_t * in , entity_t * out )
{
eval_t * modelval = prinst - > GetEdictFieldValue ( prinst , ( void * ) in , " model " , & menuc_eval . model ) ;
eval_t * originval = prinst - > GetEdictFieldValue ( prinst , ( void * ) in , " origin " , & menuc_eval . origin ) ;
eval_t * anglesval = prinst - > GetEdictFieldValue ( prinst , ( void * ) in , " angles " , & menuc_eval . angles ) ;
eval_t * skinval = prinst - > GetEdictFieldValue ( prinst , ( void * ) in , " skin " , & menuc_eval . skin ) ;
eval_t * frame1val = prinst - > GetEdictFieldValue ( prinst , ( void * ) in , " frame " , & menuc_eval . frame1 ) ;
eval_t * frame2val = prinst - > GetEdictFieldValue ( prinst , ( void * ) in , " frame2 " , & menuc_eval . frame2 ) ;
eval_t * lerpfracval = prinst - > GetEdictFieldValue ( prinst , ( void * ) in , " lerpfrac " , & menuc_eval . lerpfrac ) ;
eval_t * frame1timeval = prinst - > GetEdictFieldValue ( prinst , ( void * ) in , " frame1time " , & menuc_eval . frame1time ) ;
eval_t * frame2timeval = prinst - > GetEdictFieldValue ( prinst , ( void * ) in , " frame2time " , & menuc_eval . frame2time ) ;
eval_t * colormapval = prinst - > GetEdictFieldValue ( prinst , ( void * ) in , " colormap " , & menuc_eval . colormap ) ;
eval_t * renderflagsval = prinst - > GetEdictFieldValue ( prinst , ( void * ) in , " renderflags " , & menuc_eval . renderflags ) ;
int ival ;
int rflags ;
rflags = renderflagsval ? renderflagsval - > _float : 0 ;
memset ( out , 0 , sizeof ( * out ) ) ;
if ( modelval )
out - > model = Mod_ForName ( prinst - > StringToNative ( prinst , modelval - > _int ) , MLV_WARN ) ;
if ( originval )
VectorCopy ( originval - > _vector , out - > origin ) ;
if ( ! anglesval ) anglesval = ( eval_t * ) vec3_origin ;
AngleVectors ( anglesval - > _vector , out - > axis [ 0 ] , out - > axis [ 1 ] , out - > axis [ 2 ] ) ;
VectorInverse ( out - > axis [ 1 ] ) ;
out - > scale = 1 ;
out - > skinnum = skinval ? skinval - > _float : 0 ;
out - > framestate . g [ FS_REG ] . frame [ 0 ] = frame1val ? frame1val - > _float : 0 ;
out - > framestate . g [ FS_REG ] . frame [ 1 ] = frame2val ? frame2val - > _float : 0 ;
out - > framestate . g [ FS_REG ] . lerpfrac = lerpfracval ? lerpfracval - > _float : 0 ;
out - > framestate . g [ FS_REG ] . frametime [ 0 ] = frame1timeval ? frame1timeval - > _float : 0 ;
out - > framestate . g [ FS_REG ] . frametime [ 1 ] = frame2timeval ? frame2timeval - > _float : 0 ;
//FIXME: colourmap
ival = colormapval ? colormapval - > _float : 0 ;
out - > playerindex = - 1 ;
if ( ival > = 1024 )
{
//DP COLORMAP extension
out - > topcolour = ( ival > > 4 ) & 0x0f ;
out - > bottomcolour = ival & 0xf ;
}
/* else if (ival > 0 && ival <= MAX_CLIENTS)
{ //FIXME: tie to the current skin/topcolor/bottomcolor cvars somehow?
out - > playerindex = ival - 1 ;
out - > topcolour = cl . players [ ival - 1 ] . ttopcolor ;
out - > bottomcolour = cl . players [ ival - 1 ] . tbottomcolor ;
} */
else
{
out - > topcolour = TOP_DEFAULT ;
out - > bottomcolour = BOTTOM_DEFAULT ;
}
if ( rflags & CSQCRF_ADDITIVE )
out - > flags | = RF_ADDITIVE ;
if ( rflags & CSQCRF_DEPTHHACK )
out - > flags | = RF_DEPTHHACK ;
if ( out - > model )
return true ;
return false ;
}
static void QCBUILTIN PF_m_addentity ( pubprogfuncs_t * prinst , struct globalvars_s * pr_globals )
{
menuedict_t * in = ( void * ) G_EDICT ( prinst , OFS_PARM0 ) ;
entity_t ent ;
if ( in - > isfree | | in - > entnum = = 0 )
{
Con_Printf ( " Tried drawing a free/removed/world entity \n " ) ;
return ;
}
if ( CopyMenuEdictToEntity ( prinst , in , & ent ) )
V_AddAxisEntity ( & ent ) ;
}
static void QCBUILTIN PF_m_renderscene ( pubprogfuncs_t * prinst , struct globalvars_s * pr_globals )
{
V_ApplyRefdef ( ) ;
R_RenderView ( ) ;
}
void QCBUILTIN PF_R_SetViewFlag ( pubprogfuncs_t * prinst , struct globalvars_s * pr_globals ) ;
void QCBUILTIN PF_R_GetViewFlag ( pubprogfuncs_t * prinst , struct globalvars_s * pr_globals ) ;
2013-03-12 22:35:33 +00:00
static struct {
char * name ;
builtin_t bifunc ;
int ebfsnum ;
} BuiltinList [ ] = {
{ " checkextension " , PF_menu_checkextension , 1 } ,
{ " error " , PF_error , 2 } ,
{ " objerror " , PF_nonfatalobjerror , 3 } ,
{ " print " , PF_print , 4 } ,
{ " bprint " , PF_Fixme , 5 } ,
{ " msprint " , PF_Fixme , 6 } ,
{ " cprint " , PF_Fixme , 7 } ,
{ " normalize " , PF_normalize , 8 } ,
{ " vlen " , PF_vlen , 9 } ,
{ " vectoyaw " , PF_vectoyaw , 10 } ,
{ " vectoangles " , PF_vectoangles , 11 } ,
{ " random " , PF_random , 12 } ,
{ " localcmd " , PF_localcmd , 13 } ,
{ " cvar " , PF_menu_cvar , 14 } ,
{ " cvar_set " , PF_menu_cvar_set , 15 } ,
{ " dprint " , PF_dprint , 16 } ,
{ " ftos " , PF_ftos , 17 } ,
{ " fabs " , PF_fabs , 18 } ,
{ " vtos " , PF_vtos , 19 } ,
{ " etos " , PF_etos , 20 } ,
{ " stof " , PF_stof , 21 } ,
{ " spawn " , PF_Spawn , 22 } ,
{ " remove " , PF_Remove_ , 23 } ,
{ " find " , PF_FindString , 24 } ,
{ " findfloat " , PF_FindFloat , 25 } ,
{ " findchain " , PF_menu_findchain , 26 } ,
{ " findchainfloat " , PF_menu_findchainfloat , 27 } ,
{ " precache_file " , PF_CL_precache_file , 28 } ,
{ " precache_sound " , PF_CL_precache_sound , 29 } ,
{ " coredump " , PF_coredump , 30 } ,
{ " traceon " , PF_traceon , 31 } ,
{ " traceoff " , PF_traceoff , 32 } ,
{ " eprint " , PF_eprint , 33 } ,
{ " rint " , PF_rint , 34 } ,
{ " floor " , PF_floor , 35 } ,
{ " ceil " , PF_ceil , 36 } ,
{ " nextent " , PF_nextent , 37 } ,
{ " sin " , PF_Sin , 38 } ,
{ " cos " , PF_Cos , 39 } ,
{ " sqrt " , PF_Sqrt , 40 } ,
{ " randomvector " , PF_randomvector , 41 } ,
{ " registercvar " , PF_registercvar , 42 } ,
{ " min " , PF_min , 43 } ,
{ " max " , PF_max , 44 } ,
{ " bound " , PF_bound , 45 } ,
{ " pow " , PF_pow , 46 } ,
{ " copyentity " , PF_CopyEntity , 47 } ,
{ " fopen " , PF_fopen , 48 } ,
{ " fclose " , PF_fclose , 49 } ,
{ " fgets " , PF_fgets , 50 } ,
{ " fputs " , PF_fputs , 51 } ,
{ " strlen " , PF_strlen , 52 } ,
{ " strcat " , PF_strcat , 53 } ,
{ " substring " , PF_substring , 54 } ,
{ " stov " , PF_stov , 55 } ,
{ " strzone " , PF_dupstring , 56 } ,
{ " strunzone " , PF_forgetstring , 57 } ,
{ " tokenize " , PF_Tokenize , 58 } ,
{ " argv " , PF_ArgV , 59 } ,
{ " isserver " , PF_isserver , 60 } ,
{ " clientcount " , PF_Fixme , 61 } , //float clientcount(void) = #61;
{ " clientstate " , PF_clientstate , 62 } ,
{ " clientcommand " , PF_Fixme , 63 } , //void clientcommand(float client, string s) = #63;
{ " changelevel " , PF_Fixme , 64 } , //void changelevel(string map) = #64;
{ " localsound " , PF_localsound , 65 } ,
{ " getmousepos " , PF_cl_getmousepos , 66 } ,
{ " gettime " , PF_gettime , 67 } ,
{ " loadfromdata " , PF_loadfromdata , 68 } ,
{ " loadfromfile " , PF_loadfromfile , 69 } ,
{ " mod " , PF_mod , 70 } ,
{ " cvar_string " , PF_menu_cvar_string , 71 } ,
{ " crash " , PF_Fixme , 72 } , //void crash(void) = #72;
{ " stackdump " , PF_Fixme , 73 } , //void stackdump(void) = #73;
{ " search_begin " , PF_search_begin , 74 } ,
{ " search_end " , PF_search_end , 75 } ,
{ " search_getsize " , PF_search_getsize , 76 } ,
{ " search_getfilename " , PF_search_getfilename , 77 } ,
{ " chr2str " , PF_chr2str , 78 } ,
{ " etof " , PF_etof , 79 } ,
{ " ftoe " , PF_ftoe , 80 } ,
{ " validstring " , PF_IsNotNull , 81 } ,
{ " altstr_count " , PF_altstr_count , 82 } ,
{ " altstr_prepare " , PF_altstr_prepare , 83 } ,
{ " altstr_get " , PF_altstr_get , 84 } ,
{ " altstr_set " , PF_altstr_set , 85 } ,
{ " altstr_ins " , PF_Fixme , 86 } ,
{ " findflags " , PF_FindFlags , 87 } ,
{ " findchainflags " , PF_menu_findchainflags , 88 } ,
{ " mcvar_defstring " , PF_cvar_defstring , 89 } ,
2014-05-30 03:57:30 +00:00
{ " setmodel " , PF_m_setmodel , 90 } ,
{ " precache_model " , PF_m_precache_model , 91 } ,
{ " setorigin " , PF_m_setorigin , 92 } ,
2013-03-12 22:35:33 +00:00
//gap
{ " abort " , PF_Abort , 211 } ,
//gap
{ " strstrofs " , PF_strstrofs , 221 } ,
{ " str2chr " , PF_str2chr , 222 } ,
{ " chr2str " , PF_chr2str , 223 } ,
{ " strconv " , PF_strconv , 224 } ,
{ " strpad " , PF_strpad , 225 } ,
{ " infoadd " , PF_infoadd , 226 } ,
{ " infoget " , PF_infoget , 227 } ,
2013-06-23 02:17:02 +00:00
{ " strcmp " , PF_strncmp , 228 } ,
2013-03-12 22:35:33 +00:00
{ " strncmp " , PF_strncmp , 228 } ,
2013-06-23 02:17:02 +00:00
{ " strcasecmp " , PF_strncasecmp , 229 } ,
2013-03-12 22:35:33 +00:00
{ " strncasecmp " , PF_strncasecmp , 230 } ,
//gap
{ " shaderforname " , PF_shaderforname , 238 } ,
//gap
2013-05-03 04:28:08 +00:00
{ " hash_createtab " , PF_hash_createtab , 287 } ,
{ " hash_destroytab " , PF_hash_destroytab , 288 } ,
{ " hash_add " , PF_hash_add , 289 } ,
{ " hash_get " , PF_hash_get , 290 } ,
{ " hash_delete " , PF_hash_delete , 291 } ,
{ " hash_getkey " , PF_hash_getkey , 292 } ,
2013-08-21 07:14:39 +00:00
{ " hash_getcb " , PF_hash_getcb , 293 } ,
{ " checkcommand " , PF_checkcommand , 294 } ,
2014-05-30 03:57:30 +00:00
{ " argescape " , PF_argescape , 295 } ,
2013-05-03 04:28:08 +00:00
//gap
2014-05-30 03:57:30 +00:00
{ " clearscene " , PF_m_clearscene , 300 } ,
//no addentities
{ " addentity " , PF_m_addentity , 302 } , //FIXME: needs setmodel, origin, angles, colormap(eep), frame etc, skin,
{ " setproperty " , PF_R_SetViewFlag , 303 } , //should be okay to share
{ " renderscene " , PF_m_renderscene , 304 } , //too module-specific
// {"dynamiclight_add", PF_R_DynamicLight_Add, 305},//should be okay to share
{ " R_BeginPolygon " , PF_R_PolygonBegin , 306 } , //useful for 2d stuff
{ " R_PolygonVertex " , PF_R_PolygonVertex , 307 } ,
{ " R_EndPolygon " , PF_R_PolygonEnd , 308 } ,
{ " getproperty " , PF_R_GetViewFlag , 309 } , //should be okay to share
//unproject 310
//project 311
2013-12-08 20:06:55 +00:00
{ " print_csqc " , PF_print , 339 } ,
2013-06-23 02:17:02 +00:00
{ " keynumtostring_csqc " , PF_cl_keynumtostring , 340 } ,
2014-01-13 02:42:25 +00:00
{ " stringtokeynum_csqc " , PF_cl_stringtokeynum , 341 } ,
2013-03-12 22:53:23 +00:00
{ " getkeybind " , PF_cl_getkeybind , 342 } ,
//gap
2013-03-12 22:35:33 +00:00
{ " isdemo " , PF_isdemo , 349 } ,
//gap
{ " findfont " , PF_CL_findfont , 356 } ,
{ " loadfont " , PF_CL_loadfont , 357 } ,
//gap
{ " memalloc " , PF_memalloc , 384 } ,
{ " memfree " , PF_memfree , 385 } ,
{ " memcpy " , PF_memcpy , 386 } ,
2013-05-03 04:28:08 +00:00
{ " memfill8 " , PF_memfill8 , 387 } ,
{ " memgetval " , PF_memgetval , 388 } ,
{ " memsetval " , PF_memsetval , 389 } ,
{ " memptradd " , PF_memptradd , 390 } ,
2014-05-30 03:57:30 +00:00
{ " con_getset " , PF_SubConGetSet , 391 } ,
{ " con_printf " , PF_SubConPrintf , 392 } ,
{ " con_draw " , PF_SubConDraw , 393 } ,
{ " con_input " , PF_SubConInput , 394 } ,
2013-03-12 22:35:33 +00:00
//gap
{ " buf_create " , PF_buf_create , 440 } ,
{ " buf_del " , PF_buf_del , 441 } ,
{ " buf_getsize " , PF_buf_getsize , 442 } ,
{ " buf_copy " , PF_buf_copy , 443 } ,
{ " buf_sort " , PF_buf_sort , 444 } ,
{ " buf_implode " , PF_buf_implode , 445 } ,
{ " bufstr_get " , PF_bufstr_get , 446 } ,
{ " bufstr_set " , PF_bufstr_set , 447 } ,
{ " bufstr_add " , PF_bufstr_add , 448 } ,
{ " bufstr_free " , PF_bufstr_free , 449 } ,
2014-05-30 03:57:30 +00:00
//450
2013-12-02 14:30:30 +00:00
{ " iscachedpic " , PF_CL_is_cached_pic , 451 } ,
2013-03-12 22:35:33 +00:00
{ " precache_pic " , PF_CL_precache_pic , 452 } ,
{ " free_pic " , PF_CL_free_pic , 453 } ,
{ " drawcharacter " , PF_CL_drawcharacter , 454 } ,
{ " drawrawstring " , PF_CL_drawrawstring , 455 } ,
{ " drawpic " , PF_CL_drawpic , 456 } ,
{ " drawfill " , PF_CL_drawfill , 457 } ,
{ " drawsetcliparea " , PF_CL_drawsetcliparea , 458 } ,
{ " drawresetcliparea " , PF_CL_drawresetcliparea , 459 } ,
{ " drawgetimagesize " , PF_CL_drawgetimagesize , 460 } ,
{ " cin_open " , PF_cin_open , 461 } ,
{ " cin_close " , PF_cin_close , 462 } ,
{ " cin_setstate " , PF_cin_setstate , 463 } ,
{ " cin_getstate " , PF_cin_getstate , 464 } ,
{ " cin_restart " , PF_cin_restart , 465 } ,
{ " drawline " , PF_drawline , 466 } ,
{ " drawstring " , PF_CL_drawcolouredstring , 467 } ,
{ " stringwidth " , PF_CL_stringwidth , 468 } ,
{ " drawsubpic " , PF_CL_drawsubpic , 469 } ,
2014-05-30 03:57:30 +00:00
//470
------------------------------------------------------------------------
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
//MERGES WITH CLIENT+SERVER BUILTIN MAPPINGS BELOW
2013-03-12 22:35:33 +00:00
{ " asin " , PF_asin , 471 } ,
{ " acos " , PF_acos , 472 } ,
{ " atan " , PF_atan , 473 } ,
{ " atan2 " , PF_atan2 , 474 } ,
{ " tan " , PF_tan , 475 } ,
{ " strlennocol " , PF_strlennocol , 476 } ,
{ " strdecolorize " , PF_strdecolorize , 477 } ,
{ " strftime " , PF_strftime , 478 } ,
{ " tokenizebyseparator " , PF_tokenizebyseparator , 479 } ,
{ " strtolower " , PF_strtolower , 480 } ,
{ " strtoupper " , PF_strtoupper , 481 } ,
{ " cvar_defstring " , PF_cvar_defstring , 482 } ,
2014-05-30 03:57:30 +00:00
//483
2013-03-12 22:35:33 +00:00
{ " strreplace " , PF_strreplace , 484 } ,
{ " strireplace " , PF_strireplace , 485 } ,
2014-05-30 03:57:30 +00:00
//486
2013-03-12 22:35:33 +00:00
{ " gecko_create " , PF_cs_gecko_create , 487 } ,
{ " gecko_destroy " , PF_cs_gecko_destroy , 488 } ,
{ " gecko_navigate " , PF_cs_gecko_navigate , 489 } ,
{ " gecko_keyevent " , PF_cs_gecko_keyevent , 490 } ,
{ " gecko_mousemove " , PF_cs_gecko_mousemove , 491 } ,
{ " gecko_resize " , PF_cs_gecko_resize , 492 } ,
2013-12-02 14:30:30 +00:00
{ " gecko_get_texture_extent " , PF_cs_gecko_get_texture_extent , 493 } ,
2013-03-12 22:35:33 +00:00
{ " crc16 " , PF_crc16 , 494 } ,
{ " cvar_type " , PF_cvar_type , 495 } ,
{ " numentityfields " , PF_numentityfields , 496 } ,
{ " entityfieldname " , PF_entityfieldname , 497 } ,
{ " entityfieldtype " , PF_entityfieldtype , 498 } ,
{ " getentityfieldstring " , PF_getentityfieldstring , 499 } ,
{ " putentityfieldstring " , PF_putentityfieldstring , 500 } ,
{ " whichpack " , PF_whichpack , 503 } ,
//gap
{ " uri_escape " , PF_uri_escape , 510 } ,
{ " uri_unescape " , PF_uri_unescape , 511 } ,
{ " num_for_edict " , PF_etof , 512 } ,
{ " uri_get " , PF_uri_get , 513 } ,
{ " tokenize_console " , PF_tokenize_console , 514 } ,
{ " argv_start_index " , PF_argv_start_index , 515 } ,
{ " argv_end_index " , PF_argv_end_index , 516 } ,
{ " buf_cvarlist " , PF_buf_cvarlist , 517 } ,
{ " cvar_description " , PF_cvar_description , 518 } ,
//gap
2013-03-12 23:24:15 +00:00
{ " soundlength " , PF_soundlength , 534 } ,
2013-06-23 02:17:02 +00:00
{ " buf_loadfile " , PF_buf_loadfile , 535 } ,
{ " buf_writefile " , PF_buf_writefile , 536 } ,
2013-03-12 23:24:15 +00:00
//gap
2013-03-12 22:35:33 +00:00
{ " setkeydest " , PF_cl_setkeydest , 601 } ,
{ " getkeydest " , PF_cl_getkeydest , 602 } ,
{ " setmousetarget " , PF_cl_setmousetarget , 603 } ,
{ " getmousetarget " , PF_cl_getmousetarget , 604 } ,
{ " callfunction " , PF_callfunction , 605 } ,
{ " writetofile " , PF_writetofile , 606 } ,
{ " isfunction " , PF_isfunction , 607 } ,
{ " getresolution " , PF_cl_getresolution , 608 } ,
{ " keynumtostring " , PF_cl_keynumtostring , 609 } ,
{ " findkeysforcommand " , PF_cl_findkeysforcommand , 610 } ,
2013-03-12 22:53:23 +00:00
{ " gethostcachevalue " , PF_cl_gethostcachevalue , 611 } ,
{ " gethostcachestring " , PF_cl_gethostcachestring , 612 } ,
2013-03-12 22:35:33 +00:00
{ " parseentitydata " , PF_parseentitydata , 613 } ,
{ " stringtokeynum " , PF_cl_stringtokeynum , 614 } ,
2013-03-12 22:53:23 +00:00
{ " resethostcachemasks " , PF_cl_resethostcachemasks , 615 } ,
{ " sethostcachemaskstring " , PF_cl_sethostcachemaskstring , 616 } ,
{ " sethostcachemasknumber " , PF_cl_sethostcachemasknumber , 617 } ,
{ " resorthostcache " , PF_cl_resorthostcache , 618 } ,
{ " sethostcachesort " , PF_cl_sethostcachesort , 619 } ,
{ " refreshhostcache " , PF_cl_refreshhostcache , 620 } ,
{ " gethostcachenumber " , PF_cl_gethostcachenumber , 621 } ,
{ " gethostcacheindexforkey " , PF_cl_gethostcacheindexforkey , 622 } ,
{ " addwantedhostcachekey " , PF_cl_addwantedhostcachekey , 623 } ,
2013-03-12 23:09:25 +00:00
# ifdef CL_MASTER
2013-03-12 22:53:23 +00:00
{ " getextresponse " , PF_cl_getextresponse , 624 } ,
2013-03-12 23:09:25 +00:00
# endif
2013-03-12 22:35:33 +00:00
{ " netaddress_resolve " , PF_netaddress_resolve , 625 } ,
//gap
{ " sprintf " , PF_sprintf , 627 } ,
//gap
{ " setkeybind " , PF_Fixme , 630 } ,
2013-03-12 22:53:23 +00:00
{ " getbindmaps " , PF_cl_GetBindMap , 631 } ,
{ " setbindmaps " , PF_cl_SetBindMap , 632 } ,
2013-03-12 22:35:33 +00:00
{ " crypto_getkeyfp " , PF_crypto_getkeyfp , 633 } ,
{ " crypto_getidfp " , PF_crypto_getidfp , 634 } ,
{ " crypto_getencryptlevel " , PF_crypto_getencryptlevel , 635 } ,
{ " crypto_getmykeyfp " , PF_crypto_getmykeyfp , 636 } ,
{ " crypto_getmyidfp " , PF_crypto_getmyidfp , 637 } ,
{ " digest_hex " , PF_digest_hex , 639 } ,
2013-03-12 22:40:16 +00:00
{ " crypto_getmyidstatus " , PF_crypto_getmyidfp , 641 } ,
{ NULL }
2004-11-23 14:29:51 +00:00
} ;
2013-03-12 22:35:33 +00:00
builtin_t menu_builtins [ 1024 ] ;
2004-11-23 14:29:51 +00:00
2013-03-12 22:35:33 +00:00
int MP_BuiltinValid ( char * name , int num )
{
int i ;
for ( i = 0 ; BuiltinList [ i ] . name ; i + + )
{
if ( BuiltinList [ i ] . ebfsnum = = num )
{
if ( ! strcmp ( BuiltinList [ i ] . name , name ) )
{
if ( /*BuiltinList[i].bifunc == PF_NoMenu ||*/ BuiltinList [ i ] . bifunc = = PF_Fixme )
return false ;
else
return true ;
}
}
}
return false ;
}
2004-11-23 14:29:51 +00:00
2013-03-12 22:35:33 +00:00
static void MP_SetupBuiltins ( void )
{
int i ;
for ( i = 0 ; i < sizeof ( menu_builtins ) / sizeof ( menu_builtins [ 0 ] ) ; i + + )
menu_builtins [ i ] = PF_Fixme ;
for ( i = 0 ; BuiltinList [ i ] . bifunc ; i + + )
{
if ( BuiltinList [ i ] . ebfsnum )
menu_builtins [ BuiltinList [ i ] . ebfsnum ] = BuiltinList [ i ] . bifunc ;
}
}
2004-11-23 14:29:51 +00:00
2013-03-12 22:35:33 +00:00
void M_Init_Internal ( void ) ;
2004-11-23 14:29:51 +00:00
void M_DeInit_Internal ( void ) ;
int inmenuprogs ;
progparms_t menuprogparms ;
menuedict_t * menu_edicts ;
int num_menu_edicts ;
2013-03-12 22:53:23 +00:00
world_t menu_world ;
2004-11-23 14:29:51 +00:00
func_t mp_init_function ;
func_t mp_shutdown_function ;
func_t mp_draw_function ;
func_t mp_keydown_function ;
func_t mp_keyup_function ;
func_t mp_toggle_function ;
jmp_buf mp_abort ;
void MP_Shutdown ( void )
{
func_t temp ;
2013-03-12 22:53:23 +00:00
if ( ! menu_world . progs )
2004-11-23 14:29:51 +00:00
return ;
2005-09-08 22:52:46 +00:00
/*
{
char * buffer ;
int size = 1024 * 1024 * 8 ;
buffer = Z_Malloc ( size ) ;
menuprogs - > save_ents ( menuprogs , buffer , & size , 1 ) ;
COM_WriteFile ( " menucore.txt " , buffer , size ) ;
Z_Free ( buffer ) ;
}
*/
2004-11-23 14:29:51 +00:00
temp = mp_shutdown_function ;
mp_shutdown_function = 0 ;
if ( temp & & ! inmenuprogs )
2013-03-12 22:53:23 +00:00
PR_ExecuteProgram ( menu_world . progs , temp ) ;
2004-11-23 14:29:51 +00:00
2013-03-12 22:53:23 +00:00
PR_Common_Shutdown ( menu_world . progs , false ) ;
menu_world . progs - > CloseProgs ( menu_world . progs ) ;
memset ( & menu_world , 0 , sizeof ( menu_world ) ) ;
2013-12-29 22:48:28 +00:00
PR_ResetFonts ( kdm_menu ) ;
2004-11-23 14:29:51 +00:00
2012-11-27 03:23:19 +00:00
# ifdef CL_MASTER
Master_ClearMasks ( ) ;
# endif
2014-03-30 08:55:06 +00:00
if ( m_state = = m_menu_dat )
{
Key_Dest_Remove ( kdm_menu ) ;
m_state = 0 ;
}
2004-11-23 14:29:51 +00:00
2013-10-08 14:28:11 +00:00
key_dest_absolutemouse & = ~ kdm_menu ;
2004-11-23 14:29:51 +00:00
}
2005-04-19 21:09:29 +00:00
void * VARGS PR_CB_Malloc ( int size ) ; //these functions should be tracked by the library reliably, so there should be no need to track them ourselves.
void VARGS PR_CB_Free ( void * mem ) ;
2004-11-23 14:29:51 +00:00
//Any menu builtin error or anything like that will come here.
void VARGS Menu_Abort ( char * format , . . . )
{
va_list argptr ;
char string [ 1024 ] ;
va_start ( argptr , format ) ;
2006-03-06 01:41:09 +00:00
vsnprintf ( string , sizeof ( string ) - 1 , format , argptr ) ;
2004-11-23 14:29:51 +00:00
va_end ( argptr ) ;
Con_Printf ( " Menu_Abort: %s \n Shutting down menu.dat \n " , string ) ;
2005-08-19 19:06:22 +00:00
if ( pr_menuqc_coreonerror . value )
2005-07-28 14:33:18 +00:00
{
char * buffer ;
int size = 1024 * 1024 * 8 ;
buffer = Z_Malloc ( size ) ;
2013-08-21 07:14:39 +00:00
menu_world . progs - > save_ents ( menu_world . progs , buffer , & size , size , 3 ) ;
2005-07-29 18:48:55 +00:00
COM_WriteFile ( " menucore.txt " , buffer , size ) ;
Z_Free ( buffer ) ;
2005-07-28 14:33:18 +00:00
}
2004-12-08 04:14:52 +00:00
2004-11-23 14:29:51 +00:00
MP_Shutdown ( ) ;
2013-03-12 22:35:33 +00:00
M_Init_Internal ( ) ;
2012-11-27 03:23:19 +00:00
if ( inmenuprogs ) //something in the menu caused the problem, so...
{
inmenuprogs = 0 ;
longjmp ( mp_abort , 1 ) ;
}
2004-11-23 14:29:51 +00:00
}
2011-05-20 04:10:46 +00:00
void MP_CvarChanged ( cvar_t * var )
{
2013-03-12 22:53:23 +00:00
if ( menu_world . progs )
2011-05-20 04:10:46 +00:00
{
2013-03-12 22:53:23 +00:00
PR_AutoCvar ( menu_world . progs , var ) ;
2011-05-20 04:10:46 +00:00
}
}
2014-10-05 20:04:11 +00:00
pbool PDECL Menu_CheckHeaderCrc ( pubprogfuncs_t * inst , progsnum_t idx , int crc )
{
return crc = = 10020 ;
}
2004-11-23 14:29:51 +00:00
double menutime ;
2010-07-12 22:46:37 +00:00
qboolean MP_Init ( void )
2004-11-23 14:29:51 +00:00
{
2010-02-06 01:25:04 +00:00
if ( qrenderer = = QR_NONE )
2004-11-23 14:29:51 +00:00
{
2010-07-12 22:46:37 +00:00
return false ;
2004-11-23 14:29:51 +00:00
}
2005-08-19 19:06:22 +00:00
if ( forceqmenu . value )
2014-05-18 23:02:04 +00:00
{
Con_DPrintf ( " menu.dat disabled \n " ) ;
2010-07-12 22:46:37 +00:00
return false ;
2014-05-18 23:02:04 +00:00
}
2004-11-23 14:29:51 +00:00
2013-03-12 22:35:33 +00:00
MP_SetupBuiltins ( ) ;
2014-05-30 03:57:30 +00:00
memset ( & menuc_eval , 0 , sizeof ( menuc_eval ) ) ;
2007-06-20 00:02:54 +00:00
2004-11-23 14:29:51 +00:00
menuprogparms . progsversion = PROGSTRUCT_VERSION ;
menuprogparms . ReadFile = COM_LoadStackFile ; //char *(*ReadFile) (char *fname, void *buffer, int *len);
menuprogparms . FileSize = COM_FileSize ; //int (*FileSize) (char *fname); //-1 if file does not exist
menuprogparms . WriteFile = QC_WriteFile ; //bool (*WriteFile) (char *name, void *data, int len);
------------------------------------------------------------------------
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
menuprogparms . Printf = ( void * ) Con_Printf ; //Con_Printf;//void (*printf) (char *, ...);
2004-11-23 14:29:51 +00:00
menuprogparms . Sys_Error = Sys_Error ;
menuprogparms . Abort = Menu_Abort ;
2014-10-05 20:04:11 +00:00
menuprogparms . CheckHeaderCrc = Menu_CheckHeaderCrc ;
2004-11-23 14:29:51 +00:00
menuprogparms . edictsize = sizeof ( menuedict_t ) ;
menuprogparms . entspawn = NULL ; //void (*entspawn) (struct edict_s *ent); //ent has been spawned, but may not have all the extra variables (that may need to be set) set
menuprogparms . entcanfree = NULL ; //bool (*entcanfree) (struct edict_s *ent); //return true to stop ent from being freed
menuprogparms . stateop = NULL ; //StateOp;//void (*stateop) (float var, func_t func);
menuprogparms . cstateop = NULL ; //CStateOp;
menuprogparms . cwstateop = NULL ; //CWStateOp;
menuprogparms . thinktimeop = NULL ; //ThinkTimeOp;
//used when loading a game
menuprogparms . builtinsfor = NULL ; //builtin_t *(*builtinsfor) (int num); //must return a pointer to the builtins that were used before the state was saved.
menuprogparms . loadcompleate = NULL ; //void (*loadcompleate) (int edictsize); //notification to reset any pointers.
2005-04-19 21:09:29 +00:00
menuprogparms . memalloc = PR_CB_Malloc ; //void *(*memalloc) (int size); //small string allocation malloced and freed randomly
menuprogparms . memfree = PR_CB_Free ; //void (*memfree) (void * mem);
2004-11-23 14:29:51 +00:00
menuprogparms . globalbuiltins = menu_builtins ; //builtin_t *globalbuiltins; //these are available to all progs
2013-03-12 22:35:33 +00:00
menuprogparms . numglobalbuiltins = sizeof ( menu_builtins ) / sizeof ( menu_builtins [ 0 ] ) ;
2004-11-23 14:29:51 +00:00
2009-04-01 22:03:56 +00:00
menuprogparms . autocompile = PR_COMPILEIGNORE ; //PR_COMPILEEXISTANDCHANGED;//enum {PR_NOCOMPILE, PR_COMPILENEXIST, PR_COMPILECHANGED, PR_COMPILEALWAYS} autocompile;
2004-11-23 14:29:51 +00:00
menuprogparms . gametime = & menutime ;
2008-11-09 22:29:28 +00:00
menuprogparms . sv_edicts = ( struct edict_s * * ) & menu_edicts ;
2004-11-23 14:29:51 +00:00
menuprogparms . sv_num_edicts = & num_menu_edicts ;
menuprogparms . useeditor = NULL ; //sorry... QCEditor;//void (*useeditor) (char *filename, int line, int nump, char **parms);
2012-11-27 03:23:19 +00:00
menuprogparms . useeditor = QCEditor ; //void (*useeditor) (char *filename, int line, int nump, char **parms);
2013-03-12 22:53:23 +00:00
menuprogparms . user = & menu_world ;
2013-10-08 14:28:11 +00:00
menu_world . keydestmask = kdm_menu ;
2004-11-23 14:29:51 +00:00
menutime = Sys_DoubleTime ( ) ;
2013-03-12 22:53:23 +00:00
if ( ! menu_world . progs )
2004-11-23 14:29:51 +00:00
{
2013-11-21 23:02:28 +00:00
int mprogs ;
2005-05-08 06:04:28 +00:00
Con_DPrintf ( " Initializing menu.dat \n " ) ;
2013-03-12 22:53:23 +00:00
menu_world . progs = InitProgs ( & menuprogparms ) ;
2014-04-24 01:53:01 +00:00
PR_Configure ( menu_world . progs , 64 * 1024 * 1024 , 1 , pr_enable_profiling . ival ) ;
2014-10-05 20:04:11 +00:00
mprogs = PR_LoadProgs ( menu_world . progs , " menu.dat " , NULL , 0 ) ;
2013-11-21 23:02:28 +00:00
if ( mprogs < 0 ) //no per-progs builtins.
2004-11-23 14:29:51 +00:00
{
//failed to load or something
2013-03-12 22:53:23 +00:00
// CloseProgs(menu_world.progs);
2005-05-08 06:04:28 +00:00
// menuprogs = NULL;
2010-07-12 22:46:37 +00:00
return false ;
2004-11-23 14:29:51 +00:00
}
if ( setjmp ( mp_abort ) )
{
2005-05-08 06:04:28 +00:00
Con_DPrintf ( " Failed to initialize menu.dat \n " ) ;
inmenuprogs = false ;
2010-07-12 22:46:37 +00:00
return false ;
2004-11-23 14:29:51 +00:00
}
inmenuprogs + + ;
2014-03-30 08:55:06 +00:00
M_DeInit_Internal ( ) ;
2013-03-12 22:53:23 +00:00
PF_InitTempStrings ( menu_world . progs ) ;
2005-05-20 03:32:53 +00:00
2014-05-18 23:02:04 +00:00
menu_world . g . time = ( float * ) PR_FindGlobal ( menu_world . progs , " time " , 0 , NULL ) ;
if ( menu_world . g . time )
* menu_world . g . time = Sys_DoubleTime ( ) ;
2014-05-30 03:57:30 +00:00
menu_world . g . frametime = ( float * ) PR_FindGlobal ( menu_world . progs , " frametime " , 0 , NULL ) ;
2004-11-23 14:29:51 +00:00
2013-03-12 22:53:23 +00:00
menu_world . g . drawfont = ( float * ) PR_FindGlobal ( menu_world . progs , " drawfont " , 0 , NULL ) ;
menu_world . g . drawfontscale = ( float * ) PR_FindGlobal ( menu_world . progs , " drawfontscale " , 0 , NULL ) ;
2011-05-20 04:10:46 +00:00
2013-11-21 23:02:28 +00:00
PR_ProgsAdded ( menu_world . progs , mprogs , " menu.dat " ) ;
2013-03-12 22:35:33 +00:00
2013-03-12 22:53:23 +00:00
menuentsize = PR_InitEnts ( menu_world . progs , 8192 ) ;
2004-11-23 14:29:51 +00:00
//'world' edict
2013-03-12 22:53:23 +00:00
// EDICT_NUM(menu_world.progs, 0)->readonly = true;
EDICT_NUM ( menu_world . progs , 0 ) - > isfree = false ;
2004-11-23 14:29:51 +00:00
2013-03-12 22:53:23 +00:00
mp_init_function = PR_FindFunction ( menu_world . progs , " m_init " , PR_ANY ) ;
mp_shutdown_function = PR_FindFunction ( menu_world . progs , " m_shutdown " , PR_ANY ) ;
mp_draw_function = PR_FindFunction ( menu_world . progs , " m_draw " , PR_ANY ) ;
mp_keydown_function = PR_FindFunction ( menu_world . progs , " m_keydown " , PR_ANY ) ;
mp_keyup_function = PR_FindFunction ( menu_world . progs , " m_keyup " , PR_ANY ) ;
mp_toggle_function = PR_FindFunction ( menu_world . progs , " m_toggle " , PR_ANY ) ;
2004-11-23 14:29:51 +00:00
if ( mp_init_function )
2013-03-12 22:53:23 +00:00
PR_ExecuteProgram ( menu_world . progs , mp_init_function ) ;
2004-11-23 14:29:51 +00:00
inmenuprogs - - ;
2005-05-08 06:04:28 +00:00
2013-12-08 20:06:55 +00:00
EDICT_NUM ( menu_world . progs , 0 ) - > readonly = true ;
2005-05-08 06:04:28 +00:00
Con_DPrintf ( " Initialized menu.dat \n " ) ;
2010-07-12 22:46:37 +00:00
return true ;
2004-11-23 14:29:51 +00:00
}
2010-07-13 09:49:38 +00:00
return false ;
2004-11-23 14:29:51 +00:00
}
2013-03-12 22:35:33 +00:00
static void MP_GameCommand_f ( void )
{
void * pr_globals ;
func_t gamecommand ;
2013-03-12 22:53:23 +00:00
if ( ! menu_world . progs )
2013-03-12 22:35:33 +00:00
return ;
2013-03-12 22:53:23 +00:00
gamecommand = PR_FindFunction ( menu_world . progs , " GameCommand " , PR_ANY ) ;
2013-03-12 22:35:33 +00:00
if ( ! gamecommand )
return ;
2013-12-07 00:30:48 +00:00
if ( setjmp ( mp_abort ) )
return ;
inmenuprogs + + ;
2013-03-12 22:53:23 +00:00
pr_globals = PR_globals ( menu_world . progs , PR_CURRENT ) ;
( ( ( string_t * ) pr_globals ) [ OFS_PARM0 ] = PR_TempString ( menu_world . progs , Cmd_Args ( ) ) ) ;
PR_ExecuteProgram ( menu_world . progs , gamecommand ) ;
2013-12-07 00:30:48 +00:00
inmenuprogs - - ;
2013-03-12 22:35:33 +00:00
}
2006-09-17 00:59:22 +00:00
void MP_CoreDump_f ( void )
2005-08-16 18:35:43 +00:00
{
2013-03-12 22:53:23 +00:00
if ( ! menu_world . progs )
2005-08-16 18:35:43 +00:00
{
Con_Printf ( " Can't core dump, you need to be running the CSQC progs first. " ) ;
return ;
}
{
int size = 1024 * 1024 * 8 ;
char * buffer = BZ_Malloc ( size ) ;
2013-08-21 07:14:39 +00:00
menu_world . progs - > save_ents ( menu_world . progs , buffer , & size , size , 3 ) ;
2005-08-16 18:35:43 +00:00
COM_WriteFile ( " menucore.txt " , buffer , size ) ;
BZ_Free ( buffer ) ;
}
}
2006-09-17 00:59:22 +00:00
void MP_Reload_f ( void )
{
2014-03-30 08:55:06 +00:00
M_Shutdown ( true ) ;
2013-03-12 22:35:33 +00:00
M_Reinit ( ) ;
2006-09-17 00:59:22 +00:00
}
2014-04-24 01:53:01 +00:00
static void MP_Poke_f ( void )
{
2014-10-05 20:04:11 +00:00
/*if (!SV_MayCheat())
2014-04-24 01:53:01 +00:00
Con_TPrintf ( " Please set sv_cheats 1 and restart the map first. \n " ) ;
2014-10-05 20:04:11 +00:00
else */ if ( menu_world . progs & & menu_world . progs - > EvaluateDebugString )
Con_TPrintf ( " Result: %s \n " , menu_world . progs - > EvaluateDebugString ( menu_world . progs , Cmd_Args ( ) ) ) ;
2014-04-24 01:53:01 +00:00
else
Con_TPrintf ( " not supported. \n " ) ;
}
2013-03-12 22:44:00 +00:00
void MP_Breakpoint_f ( void )
{
int wasset ;
int isset ;
char * filename = Cmd_Argv ( 1 ) ;
int line = atoi ( Cmd_Argv ( 2 ) ) ;
2013-03-12 22:53:23 +00:00
if ( ! menu_world . progs )
2013-03-12 22:44:00 +00:00
{
Con_Printf ( " Menu not running \n " ) ;
return ;
}
2013-03-12 22:53:23 +00:00
wasset = menu_world . progs - > ToggleBreak ( menu_world . progs , filename , line , 3 ) ;
isset = menu_world . progs - > ToggleBreak ( menu_world . progs , filename , line , 2 ) ;
2013-03-12 22:44:00 +00:00
if ( wasset = = isset )
Con_Printf ( " Breakpoint was not valid \n " ) ;
else if ( isset )
Con_Printf ( " Breakpoint has been set \n " ) ;
else
Con_Printf ( " Breakpoint has been cleared \n " ) ;
2014-05-10 13:42:13 +00:00
Cvar_Set ( Cvar_FindVar ( " pr_debugger " ) , " 1 " ) ;
2013-03-12 22:44:00 +00:00
}
2005-08-16 18:35:43 +00:00
void MP_RegisterCvarsAndCmds ( void )
{
2006-09-17 00:59:22 +00:00
Cmd_AddCommand ( " coredump_menuqc " , MP_CoreDump_f ) ;
2007-06-20 00:02:54 +00:00
Cmd_AddCommand ( " menu_restart " , MP_Reload_f ) ;
2013-03-12 22:35:33 +00:00
Cmd_AddCommand ( " menu_cmd " , MP_GameCommand_f ) ;
2013-03-12 22:44:00 +00:00
Cmd_AddCommand ( " breakpoint_menu " , MP_Breakpoint_f ) ;
2013-12-29 22:48:28 +00:00
Cmd_AddCommand ( " loadfont " , CL_LoadFont_f ) ;
2005-08-19 19:06:22 +00:00
2014-04-24 01:53:01 +00:00
Cmd_AddCommand ( " poke_menuqc " , MP_Poke_f ) ;
2005-08-19 19:06:22 +00:00
Cvar_Register ( & forceqmenu , MENUPROGSGROUP ) ;
Cvar_Register ( & pr_menuqc_coreonerror , MENUPROGSGROUP ) ;
if ( COM_CheckParm ( " -qmenu " ) )
Cvar_Set ( & forceqmenu , " 1 " ) ;
2005-08-16 18:35:43 +00:00
}
2004-11-23 14:29:51 +00:00
void MP_Draw ( void )
{
2013-03-12 22:53:23 +00:00
if ( ! menu_world . progs )
2007-06-20 00:02:54 +00:00
return ;
2004-11-23 14:29:51 +00:00
if ( setjmp ( mp_abort ) )
return ;
menutime = Sys_DoubleTime ( ) ;
2014-05-18 23:02:04 +00:00
if ( menu_world . g . time )
* menu_world . g . time = menutime ;
2014-05-30 03:57:30 +00:00
if ( menu_world . g . frametime )
* menu_world . g . frametime = host_frametime ;
2004-11-23 14:29:51 +00:00
inmenuprogs + + ;
if ( mp_draw_function )
2013-03-12 22:53:23 +00:00
PR_ExecuteProgram ( menu_world . progs , mp_draw_function ) ;
2004-11-23 14:29:51 +00:00
inmenuprogs - - ;
}
2009-07-25 11:05:06 +00:00
void MP_Keydown ( int key , int unicode )
2004-11-23 14:29:51 +00:00
{
2006-10-05 21:59:43 +00:00
extern qboolean keydown [ K_MAX ] ;
2012-11-27 03:23:19 +00:00
# ifdef TEXTEDITOR
if ( editormodal )
return ;
# endif
2004-11-23 14:29:51 +00:00
if ( setjmp ( mp_abort ) )
return ;
if ( key = = ' c ' )
{
2013-05-11 14:02:55 +00:00
if ( keydown [ K_LCTRL ] | | keydown [ K_RCTRL ] )
2004-11-23 14:29:51 +00:00
{
MP_Shutdown ( ) ;
2013-03-12 22:35:33 +00:00
M_Init_Internal ( ) ;
2004-11-23 14:29:51 +00:00
return ;
}
}
menutime = Sys_DoubleTime ( ) ;
2014-05-18 23:02:04 +00:00
if ( menu_world . g . time )
* menu_world . g . time = menutime ;
2004-11-23 14:29:51 +00:00
inmenuprogs + + ;
if ( mp_keydown_function )
{
2013-03-12 22:53:23 +00:00
void * pr_globals = PR_globals ( menu_world . progs , PR_CURRENT ) ;
2013-05-03 04:28:08 +00:00
G_FLOAT ( OFS_PARM0 ) = MP_TranslateFTEtoQCCodes ( key ) ;
2009-07-25 11:05:06 +00:00
G_FLOAT ( OFS_PARM1 ) = unicode ;
2013-03-12 22:53:23 +00:00
PR_ExecuteProgram ( menu_world . progs , mp_keydown_function ) ;
2004-11-23 14:29:51 +00:00
}
inmenuprogs - - ;
}
2009-07-25 11:05:06 +00:00
void MP_Keyup ( int key , int unicode )
2004-11-23 14:29:51 +00:00
{
2012-11-27 03:23:19 +00:00
# ifdef TEXTEDITOR
if ( editormodal )
return ;
# endif
2004-11-23 14:29:51 +00:00
if ( setjmp ( mp_abort ) )
return ;
menutime = Sys_DoubleTime ( ) ;
2014-05-18 23:02:04 +00:00
if ( menu_world . g . time )
* menu_world . g . time = menutime ;
2004-11-23 14:29:51 +00:00
inmenuprogs + + ;
if ( mp_keyup_function )
{
2013-03-12 22:53:23 +00:00
void * pr_globals = PR_globals ( menu_world . progs , PR_CURRENT ) ;
2013-05-03 04:28:08 +00:00
G_FLOAT ( OFS_PARM0 ) = MP_TranslateFTEtoQCCodes ( key ) ;
2009-07-25 11:05:06 +00:00
G_FLOAT ( OFS_PARM1 ) = unicode ;
2013-03-12 22:53:23 +00:00
PR_ExecuteProgram ( menu_world . progs , mp_keyup_function ) ;
2004-11-23 14:29:51 +00:00
}
inmenuprogs - - ;
}
qboolean MP_Toggle ( void )
{
2013-03-12 22:53:23 +00:00
if ( ! menu_world . progs )
2004-11-23 14:29:51 +00:00
return false ;
2012-11-27 03:23:19 +00:00
# ifdef TEXTEDITOR
if ( editormodal )
return false ;
# endif
2004-11-23 14:29:51 +00:00
if ( setjmp ( mp_abort ) )
return false ;
menutime = Sys_DoubleTime ( ) ;
2014-05-18 23:02:04 +00:00
if ( menu_world . g . time )
* menu_world . g . time = menutime ;
2004-11-23 14:29:51 +00:00
inmenuprogs + + ;
if ( mp_toggle_function )
2013-03-12 22:35:33 +00:00
{
2013-03-12 22:53:23 +00:00
void * pr_globals = PR_globals ( menu_world . progs , PR_CURRENT ) ;
2013-03-12 22:35:33 +00:00
G_FLOAT ( OFS_PARM0 ) = 1 ;
2013-03-12 22:53:23 +00:00
PR_ExecuteProgram ( menu_world . progs , mp_toggle_function ) ;
2013-03-12 22:35:33 +00:00
}
2004-11-23 14:29:51 +00:00
inmenuprogs - - ;
return true ;
2004-11-29 01:21:00 +00:00
}
# endif