Bill Currie
c52ce7f202
slight optimisation
2003-03-03 21:41:13 +00:00
Bill Currie
1a40e5b6b4
implement WriteBytes for qc
2003-03-02 03:25:47 +00:00
Bill Currie
d2edce37a4
give qc access to WriteCoordV and WriteAngleV
2003-02-28 04:59:40 +00:00
Bill Currie
761a7546dd
re-arrange things so __attribute__ and __builtin_expect are properly
...
autoconfiscated so rcsid will continue to work with gcc 3.3
2003-01-15 15:31:36 +00:00
Bill Currie
71196fedf6
make gcc more anal about prototypes, string constants and function
...
visibility (ie, global functions must have a prototype)
2003-01-06 18:28:13 +00:00
Bill Currie
ca4b3acd6c
big protototype cleanup. Now, except for a few cases, all non-static
...
prototypes are in headers files.
2002-11-05 19:12:51 +00:00
Bill Currie
cfffd05c71
missed these for mvd writing :P
2002-10-23 02:44:42 +00:00
Bill Currie
212e40b54a
mvd recording :) (thanks to qwex 0.165b and highlander)
2002-10-04 02:29:03 +00:00
Jeff Teunissen
510ac98c9b
PF_Fixme(): better error message.
2002-09-30 16:47:41 +00:00
Bill Currie
7af8e2952e
zinx' klik mod makes heavy use of makestatic and that was causing the
...
singon buffer to overflow. call SV_FlushSignon before writing the static
entity data.
2002-09-04 15:12:05 +00:00
Bill Currie
0ebaa9834b
fix a vim snafu
2002-08-15 03:22:58 +00:00
Bill Currie
bfd02b6412
mess around with the builtin comments
2002-08-14 22:33:10 +00:00
Bill Currie
ad6e025a91
take cmd.[ch] back to basics. the gib code is temporarily gone pending
...
renovations. cmd_source handling is a little hacky in nq, but it's working.
2002-07-31 05:19:03 +00:00
Bill Currie
de22355371
use P_* for params and R_* for return values in builtins code
2002-07-24 21:42:33 +00:00
Ragnvald Maartmann-Moe IV
5e5fdb7bc2
Kill MSG_WriteChar.
2002-07-02 19:13:53 +00:00
Bill Currie
5e9baaa7c2
optimise PF_aim for when sv_aim is >= 1 or when the client's noaim is 1
2002-06-19 16:03:01 +00:00
Bill Currie
c25051e60e
link the obj runtime into the servers' progs engines
2002-05-31 15:04:23 +00:00
Bill Currie
33e055209e
Semi-major (more than minor:) progs convenience macro cleanup. There will
...
be more to come.
2002-05-22 22:35:37 +00:00
Jeff Teunissen
13071a2d23
Clear up some comments.
2002-04-25 12:53:42 +00:00
Bill Currie
8ee5acb208
redo Sys_Error so it's more usable throughout quake
2002-02-20 19:22:52 +00:00
Bill Currie
2e8f780e03
return "" from PF_infokey when the client the key is being requested from
...
has been dropped. This fixes a nasty crash at the end of a match in tf 2.8+
2002-02-13 05:49:24 +00:00
Bill Currie
6af9a5d8e6
make the builtins an array of pointers so the hash table doesn't get royally
...
screwed up
2002-01-19 03:31:51 +00:00
Ragnvald Maartmann-Moe IV
2db08923e8
MSG_(Read|Write)(Coord|Angle|CoordAngle)V. Cleanups, and preparation for use of vector ops in msg.c.
2001-12-12 21:56:09 +00:00
Bill Currie
d222f25f0b
correct some error messages
2001-12-07 17:24:16 +00:00
Bill Currie
8c9daf023e
possible optimisation for PF_findradius. needs more testing
2001-12-05 19:59:55 +00:00
Bill Currie
c5aec15569
This prepares for moving the net_svc code to a branch allowing both network
...
code cleanups and general performance work to be developed in relative peace.
While cleaning up the networking code /is/ important, fixing QF's perfomance
issues is of much higher priority.
2001-11-07 08:24:56 +00:00
Bill Currie
ac93a620d7
remove instead of set "" info keys for localinfo
2001-11-05 02:03:37 +00:00
Bill Currie
dcd9b0040e
rewrite the info strings to use hash tables instead of a static string.
...
This required changes to the api (info_t instead of char *) but should be
a net gain in speed (not a lot, admittedly: it was pretty fast to begin
with, but this paves the way for some other changes I have in mind).
2001-11-04 07:50:39 +00:00
Adam Olsen
d7e5f88ee3
- conver svc_spawnstaticsound, svc_updateuserinfo, svc_setinfo,
...
svc_serverinfo, and svc_download
I havn't tested svc_download, since I don't want to play with having
seperate dirs for the client vs server on one computer.
2001-11-02 14:52:29 +00:00
Adam Olsen
9f088567d1
- convert svc_sound, svc_spawnbaseline, svc_spawnstatic, and
...
svc_tempentity
there isn't actually anything in the server that uses svc_tempentity,
only the progs do, so it's currently unused.
2001-11-02 10:40:20 +00:00
Bill Currie
d62c381262
Con_Printf -> SV_Printf for some cases that should be
2001-10-27 22:33:42 +00:00
Bill Currie
4ae92c8d42
new cvar: sv_hide_version_info. This hides QuakeForge specific info strings
...
from progs.
2001-10-24 02:50:11 +00:00
Adam Olsen
9f7e1f864e
- add a pr_double_remove cvar, that either ignores (0), warns about
...
(1), or causes a fatal error (2) when the progs remove an already
removed entity. default is 1.
- fix a segfault in FFnickFF parsing that causes a segfault
2001-10-09 22:47:14 +00:00
Bill Currie
b1f4a778f9
the rcsid commit from hell }:>
2001-09-28 06:26:31 +00:00
Adam Olsen
7ff069c931
- when the progs cache a model, copy it onto the hunk, so the gc can't
...
squash it
- ditto for sounds, just in case
2001-09-23 15:14:08 +00:00
Bill Currie
410783025e
misc fixes forwarded from 0.3
2001-09-11 06:04:10 +00:00
Adam Olsen
65e5a7a4fc
fix userinfo filtering in PF_setinfokey
2001-09-11 04:52:29 +00:00
Bill Currie
74e9f89e8c
forward port the client info string filtering from 0.3 and remove info.h from
...
a couple of c files that no longer need it.
2001-09-11 03:10:29 +00:00
Ragnvald Maartmann-Moe IV
f4fd3178f4
More header and whitespace horror reduction.
2001-08-28 02:43:24 +00:00
Adam Olsen
3177d9c7eb
Readd the aim builtin, which I must have accidentally removed earlier.
...
Ooops :)
2001-08-22 21:13:04 +00:00
Adam Olsen
ea063a1e0f
having duplicate functions is bad.
2001-08-22 05:50:01 +00:00
Adam Olsen
17ba7ef92f
- move alot of the builtins to libQFgamecode_builtins
...
- move the init into qw and nq
2001-08-22 03:24:25 +00:00
Bill Currie
7047f2da36
fix some missing ()s that got lost due to the () forrest that got chainsawed
...
(ie, the previous code was /a mess/)
2001-08-16 02:08:22 +00:00
Zephaniah E. Hull
eab8ff6e25
Just some MASSIVE speed boost for PF_findradius.
2001-08-15 23:03:37 +00:00
Bill Currie
a290afd2b5
back out the dynamic allocation so prozac will still work
2001-08-12 19:50:23 +00:00
Adam Olsen
0c63c11b4b
diff noise reduction. mostly just "progs_t * pr" to "progs_t *pr".
...
Only code change is copying qw's variable-size PF_VarString in place
of nq's 256 char "I wanna be a buffer-overflow exploit!" version.
2001-08-09 06:05:43 +00:00
Bill Currie
fb42199637
change all the SVFIELD calls to SVtype. this should make the code a little
...
easier to read.
2001-08-08 20:28:53 +00:00
Adam Olsen
9f00601b82
change checkfunction and getfunction to checkbuiltin and getbuiltin
2001-08-05 06:02:33 +00:00
Adam Olsen
040345bc60
Change all our new functions to use dynamically allocated builtin
...
numbers, except checkextension, checkfunction, and getfunction. Yes,
this may break some stuff. :)
2001-08-04 23:58:03 +00:00
Adam Olsen
dc98a63098
Add a getfunction, which gives an error if it's not found
2001-08-04 23:44:50 +00:00
Adam Olsen
d241e8dd64
Make sure all the function names passed to PR_AddBuiltin are
...
lowercase, for sanity reasons.
2001-08-04 22:14:45 +00:00
Adam Olsen
c218ede288
Add support for checkfunction, which is a builtin that searches for
...
another builtin by name, and returns it.
Soon I'll change all our new builtins to by allocated dynamically, as
well as changing the number checkfunction uses, and happily break
everything that uses them :D
2001-08-04 09:11:50 +00:00
Adam Olsen
484edfde55
Some of an aforementioned function to search for functions by name.
...
Guess it's not as trivial as I thought.
2001-08-03 07:37:21 +00:00
Adam Olsen
ae133d0a90
Modify progs to add builtins at runtime. It should be trivial to
...
lookup functions by name, and make all our new QC builtins allocate
numbers automatically.
2001-08-03 06:40:28 +00:00
Adam Olsen
19387f0801
diff noise reduction, cleaned up the comments somewhat
2001-08-02 23:27:45 +00:00
Bill Currie
fb26d8b18a
make Info_Set* take flags indicating wether funchars should be stripped or not
2001-07-31 18:27:49 +00:00
Bill Currie
2b19252d73
fix PF_hullpointcontents and the clip_mins/maxs setting in PF_rotate_bbox
...
NOTE: the api to PF_hullpointcontents has changed!!!
2001-07-31 17:09:42 +00:00
Bill Currie
c3e3f8182d
the hull growing seems to work now.
2001-07-30 22:53:01 +00:00
Bill Currie
6cb2cb5bdc
start making the rotated bounding box (really dynamic clipping huls) more
...
generice, and also more in line with the rest of quake's clipping system
(ie, support the entity size selected hulls). I'm not /entirly happy with
what's here, but it's a start, and the force fields in customtf work /much/
better :)
2001-07-30 04:33:59 +00:00
Bill Currie
dbb339651d
make the hull plane setup a loop
2001-07-29 00:12:14 +00:00
Bill Currie
097f38d594
return a null edict properly
2001-07-27 23:22:21 +00:00
Bill Currie
e69c1e8918
correct a typo in a comment
2001-07-27 23:07:38 +00:00
Bill Currie
219c58bd98
wrappers for SV_TestEntityPosition and SV_HullPointContents
2001-07-27 23:05:58 +00:00
Bill Currie
0b576e42a1
fix a small bug
2001-07-27 19:48:46 +00:00
Bill Currie
27dde8cefe
sv_pr_cmds.c:
...
find the full bounding box for the rotated bounding box and put this
into hull's clip_mins and clip_maxs. Also, provide:
vector (integer hull, integer max) getboxbounds = #94
to retrieve these values (max != 0 for clip_maxs, max == 0 for clip_mins)
world.c:
SV_TestPlayerPosition now checks for a rotated_bbox hull
2001-07-27 06:39:06 +00:00
Bill Currie
df2f517146
put in a couple of comments
2001-07-26 17:36:57 +00:00
Bill Currie
517be0adbb
change rotate_bbox's `prototype'
...
void (integer hull, vector right, vector forward, vector up,
vector mins, vector maxs) rotate_bbox = #97
2001-07-26 16:32:01 +00:00
Bill Currie
a44da38e04
rotate the bounding box points, not just the planes
...
fix a really nasty bug with allocating a hull
2001-07-26 16:24:47 +00:00
Bill Currie
88eb9e118a
forgot to subtract 1 from the incoming hull `handle'
2001-07-26 15:33:55 +00:00
Bill Currie
5ebee4a28b
rotated bounding box support. this is so totally untested it's not funny
...
(though it does compile). Keeps things simple and only checks touched.
.integer rotated_bbox;
ent.rotated_bbox = getboxhull ();// be sure to check for failure (0)
rotate_bbox (ent.rotated_bbox, ent.angles, ent.mins, ent.maxs);
...
freeboxhull (ent.rotated_bbox); // when freeing entity. box hulls are limited
integer () getboxhull = #95
void (integer hull) freeboxhull = #96
void (integer hull, vector angles, vector mins, vector maxs) rotate_bbox = #97
2001-07-26 04:26:54 +00:00
Bill Currie
64a2f8d277
rearrange the comments for the builtins table, and put a comment with the
...
builtin number (and prototype where appropriate) on every element
2001-07-25 23:33:06 +00:00
Zephaniah E. Hull
08bc0e987b
New PF_checkmove! A direct interface to SV_Move, but named better.
...
(This is #98.)
2001-07-25 22:14:42 +00:00
Bill Currie
d12a0a930d
return of UserInfoCallback is now ignored and SV_Userinfo_f just returns as
...
PR_setuserinfo now does the extract from userinfo.
2001-07-24 22:11:44 +00:00
Bill Currie
22c9716b56
rename int_var to integer_var
2001-07-22 20:20:46 +00:00
Adam Olsen
2f223924f4
Add a set of "crudefile" file io functions. Reads or writes an
...
entire C string (including terminating nul). Read the source for
more details :)
2001-07-22 19:03:26 +00:00
Bill Currie
abf34ac2d3
send the right one
2001-07-20 05:30:51 +00:00
Bill Currie
a09705953f
forgot to send the updates to the clients
2001-07-20 05:29:45 +00:00
Bill Currie
743fd9cc19
rename SetUserInfo to UserInfoCallback.
...
set self to the client entity for UserInfoCallback.
add void (entity ent, string key, string value) setinfokey = #102 ;
similar usage to infokey.
2001-07-20 05:05:47 +00:00
Adam Olsen
a771b5bd6c
Make edicts command support a search string, so it only prints edicts
...
with matching classnames. Makes it easy to print out the type you want
for debugging :)
2001-07-19 03:18:11 +00:00
Bill Currie
1c9e1b176f
fear the mighty const correct patch
2001-07-15 07:04:17 +00:00
Adam Olsen
484f5494b8
Add my strlen and charcount functions as quakec builtins. strlen
...
returns the total string length, and charcount returns the number of
times the given character appears.
2001-07-13 22:58:31 +00:00
Bill Currie
7a06a2254a
rename the Con_Printf in sv_send.c to SV_Printf and change all the calls to
...
Con_Printf in the server code to SV_Printf.
nuke Con_DPrintf from sv_send.c
2001-07-11 23:11:29 +00:00
Adam Olsen
29188c9f33
typo
2001-06-14 17:31:53 +00:00
Bill Currie
4c8f84adc5
fix for CustomTF menu truncation
2001-06-03 01:28:11 +00:00
Bill Currie
323015b11a
include/QF header cleanup. including config.h (or any file from include) is
...
a nono because headers in include/QF get installed, but include don't and thus
would break quakeforge-dev.
2001-05-31 05:33:13 +00:00
Bill Currie
6bf58ab1af
no header includes cvar.h now
2001-05-31 03:41:35 +00:00
Bill Currie
dfbfd9463c
mingw cross compile fixes. qw-server (only, so far) compiles but does not
...
yet link due to Sys_Error :/
2001-04-10 20:07:11 +00:00
Bill Currie
067db089a2
make edict pruning, field parsing and the builtins part of progs_t like they
...
should have been
2001-03-27 22:39:21 +00:00
Bill Currie
f78b973978
move the api headers into include/QF and clean up (most of) the resulting mess.
...
target specific files that I don't build won't compile yet. just put QF/
infront of the offending headers.
Also move ver_check into libqfutils
2001-03-27 20:33:07 +00:00
Bill Currie
53c9732303
add PF_checkextension for later use. The pr_checkextension cvar will come
...
when I've had some sleep.
2001-03-07 10:22:51 +00:00
Bill Currie
10e6b7af84
edict field access type checking :) Currently forced on, but it will become a
...
configure option in the future
2001-03-01 21:11:35 +00:00
Bill Currie
ef38fd2e79
progsdef.h is now used only for the PROGHEADER_CRC def. Much of the protocol
...
still seems to be broken :(
2001-03-01 18:44:19 +00:00
Bill Currie
ad18afaa3c
really clean up global and function access. Unfortunatly, frames are still
...
borked, at least for the view entity.
2001-03-01 08:34:30 +00:00
Bill Currie
63b990cd30
qw-server builds, but dies a sad death. I REALLY REALLY NEED to clean up my
...
progs globals and edict fields accessors, but I'm not so sure that's the cause
of the run-time error:
SV_Error: SV_ModelIndex: model progs/player.mdl not precached
Fatal error: SV_Error: SV_ModelIndex: model progs/player.mdl not precached
I suspect I failed to find the spawn function.
2001-02-28 22:44:38 +00:00
Bill Currie
7e14a0fbf3
clean up RETURN_EDICT and RETURN_STRING definitions to be both easier to read
...
and more correct for aliasing (and int size dependence, too:).
2001-02-27 19:05:05 +00:00
Ragnvald Maartmann-Moe IV
a0565418d9
Stomped out lots of typos and case inconsistencies. fixme, Fixme, FIXME!
2001-02-21 23:45:49 +00:00
Bill Currie
87854e1a0c
initial checkin of most recent newtree and nuq(?) source
2001-02-19 21:15:25 +00:00