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
Brian Koropoff
c522970a88
Added a GIB event system for registering GIB callback functions to be
...
started when a named event occurs. Added a few test events to the qw
client and server. Cleaned up the range GIB builtin a bit.
2003-01-03 04:30:38 +00:00
Brian Koropoff
86d73f1577
Include protection.
2003-01-03 04:12:27 +00:00
Bill Currie
637de7b687
chage PL_ObjectForKey to take a plitem directly and typecheck the item
2002-12-18 16:09:47 +00:00
Bill Currie
a84b6bba5d
make stuff static that can be and nuke some useless stuff
2002-12-16 23:26:14 +00:00
Brian Koropoff
32e5e6ef0b
Numerous GIB bug fixes and optimizations. Fixed/updated some GIB scripts
...
as well.
2002-12-13 23:36:05 +00:00
Brian Koropoff
74ee0cfd0e
Changed the behavior of field::get with a null field separator to match
...
that of for loops. Added support for var++, var--, var += foo, var -= foo,
var *= foo, and var /= foo.
2002-12-10 00:04:15 +00:00
Bill Currie
92ea1de504
apply Kaare Slettnes' key name extention patch ( Closes : #62 )
2002-12-02 16:26:18 +00:00
Bill Currie
ee30860cef
fix a bunch of ;; typos
2002-11-20 21:44:04 +00:00
Brian Koropoff
854f6d9054
Created gib_regex.[ch] to manage regular expressions in GIB. Regexs are
...
now cached and only recompiled when compile flags change. Changed regex
builtins to take an options string argument after the regular expression.
2002-11-19 06:24:29 +00:00
Brian Koropoff
860306e324
Oops, forgot these.
2002-11-19 04:24:09 +00:00
Brian Koropoff
d4b1c74866
Added the string::findsub builtin. Added a reset function to the cbuf
...
interpreter struct so that custom cbuf data can be reset after an error.
This fixes a bug where GIB would think it was still waiting for a return
value after an error occurred in an embedded command.
2002-11-16 20:56:04 +00:00
Brian Koropoff
625e1e36d6
Added Sys_PathType, which reports whether a path is absolute, relative
...
below, or relative above (uses .. to ascend the filesystem). Changed
file functions in GIB to use this. GIB can now be initialized in a
non-sandboxed mode, which at the moment means that GIB scripts run with
carne can access the entire filesystem.
2002-11-14 05:28:54 +00:00
Brian Koropoff
7b0c24a386
Added carne, the stand-alone GIB interpreter. Made a few changes to GIB
...
to accommodate it. Added the strict flag to cbufs, which causes an error
to be generated when a command is not found instead of just warning the
user. GIB buffers have the strict flag set by default.
2002-11-14 02:10:55 +00:00
Bill Currie
836c469737
sys.[ch]:
...
handle SIGFPE and allow the registered signal handler to do recovery
rather than bail
progs.h, pr_exec.c, pr_load.c:
if pr_faultchecks is 1 (0 is default), handle division by 0 gracefully
by loading the maximum representable number into the answer
Closes : #58
the rest:
kill the SIGFPE stuff
2002-11-13 19:26:44 +00:00
Bill Currie
77288fe90b
make dist fix
2002-11-09 21:56:13 +00:00
Brian Koropoff
b40400d59c
Moved GIB into libs/gib and made util no longer depend on it. Cleaned up
...
some cruft from a previous incarnation of GIB.
2002-11-09 07:13:52 +00:00
Bill Currie
3d44623b57
change Cmd_Exec_File's api so it can conditionally use normal or quake
...
file system accesses. fixes the map.cfg exec problem
2002-11-08 16:39:28 +00:00
Bill Currie
62bbd0228a
prototype Com_CollapsePath
2002-11-08 03:12:22 +00:00
Bill Currie
eeb4e4f9a9
how that got past my compile tests is beyond me
2002-11-06 14:56:39 +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
aa36b85ba6
add PR_StringValid and PR_EdictValid to check the validity of progs string
...
and entity values without crashing.
2002-10-29 05:07:10 +00:00
Brian Koropoff
01a7740f1b
Added bind.get builtin that returns the command currently bound to a key.
...
Fixed gib_builtin.h to include another needed header.
2002-10-25 06:33:16 +00:00
Brian Koropoff
20d47cde2f
Added the global.delete builtin to clean up old global variables. Updated
...
cb.gib to use it.
2002-10-23 03:56:57 +00:00
Bill Currie
80e85226b9
pr_xstatement now always reflects the currently executing statement making
...
debugging easier in the event of a segfault
2002-10-22 15:07:54 +00:00
Bill Currie
b345f510fa
provide Hash_Buffer so buffers can be hashed
2002-10-20 03:30:22 +00:00
Bill Currie
4da662eb47
implement pr_obj_msg_sendv
2002-10-16 22:17:26 +00:00
Bill Currie
be4b8096d4
two new instructions: move and movep: basicly memmove. qfcc support coming
...
as soon as I get it working :)
2002-10-16 06:44:41 +00:00
Brian Koropoff
8c2afef44c
Changed GIB_Arg* into macros. Cleaned up GIB file access a bit and added
...
file.move and file.delete builtins. Added Qremove to quakeio.[ch]. Did
a little cleaning and commenting in gib_parse.c. Added support for \t
and \r escape characters.
2002-10-16 04:59:34 +00:00
Bill Currie
68b41f9b44
make dstring_adjust `grow' in increments of 1024. this should speed up
...
multiple appends nicely.
also create davsprintf and dasprintf to /append/ the printed strings to the
dstring rather than overwriting it as is done with dvsprintf and dsprintf.
2002-10-15 19:52:46 +00:00
Bill Currie
1f0b6e84a5
change pr_obj_msgSend and pr_obj_msgSend_super so they either call builtin
...
methods directly or setup the progs struct for a normal function call to
call a progs method rather than recursively calling PR_ExecuteProgram. This
will reduce method call overhead (both cpu and stack usage), fix the loss
of tracing when calling a method and makes it possible to break out of the
progs engine simply if threaded progs are ever implemented.
2002-10-15 18:53:33 +00:00
Brian Koropoff
72e1ab0c57
Added the sleep console command that waits for a specified amount of time.
...
Note that this isn't a GIB-specific command but is very useful in GIB
threads. Fixed the range GIB command to respect the ifs local variable.
2002-10-13 19:46:47 +00:00
Brian Koropoff
8b31103e6f
Var substitution is now handled in the same pass as embedded return values.
...
This prevents var substitution from being performed on the return value
of a function. The local variable ifs can now be set to specify a custom
field separator for use in for loops. file.find will also insert ifs
between file names instead of a space if it is set. file.find will also
no longer put . and .. in a list of file names.
2002-10-13 05:52:06 +00:00
Bill Currie
9d8d570269
using Qseek on a pak sub-file should work better. this should make oggs in
...
paks work.
2002-09-27 04:27:19 +00:00
Bill Currie
d25ee82838
provide a tighter accuracy (but slower) _VectorNormalize for the tools
2002-09-25 21:35:49 +00:00
Bill Currie
56843557f6
make _VectorCompare use EQUAL_EPSILON (VectorCompare is still the fast
...
macro) and use it instead of VectorCompare in the map tools. This (and, it
seems, RINT) fixes qfbsp on spc. Also, jump /all/ entities that get hit
by the filler in qfbsp
2002-09-20 17:02:53 +00:00
Bill Currie
0cd34d155f
qfbsp now mostly works. only known issue is multiple texture wads don't
...
load properly and possibly a "reached occupant" issue (dunno if it's the
map or qfbsp)
2002-09-19 20:39:33 +00:00
Bill Currie
24a9b48127
rewrite bspfile.[ch] so they work off an object rather than global data.
...
The direct filesystem access is also removed. Fix up qfvis and qflight to
compile with the new bspfile. qfvis seems to work, qflight probably doesn't
2002-09-19 05:35:17 +00:00
Bill Currie
86f542a971
kill the last VFile ref and make the calculate the file size on opening for
...
reading (Qfilesize works only when Qopen is used in read mode).
2002-09-19 05:11:42 +00:00
Bill Currie
599fea0edb
redo bspfile to use dynamic allocation for the arrays to avoid buffer
...
overflows. also fix up the verbosity levels in qfvis.c
2002-09-18 06:07:38 +00:00
Bill Currie
eec3b7d8bc
fix missed header commit
2002-09-14 07:51:53 +00:00
Bill Currie
f7b4dffcc0
get larger player skins working in gl
2002-09-13 05:32:28 +00:00
Bill Currie
ecdd537183
beat sw gamma handling till GL works. after a fasion. it /looks/ like it was
...
beaten on.
2002-09-10 06:35:32 +00:00
Bill Currie
9f6f50699d
remove vid_basepal, creating vid.palette (current palette) and host_basepal
2002-09-10 03:51:10 +00:00
Brian Koropoff
11293819a5
Comments are now stripped out when a script is loaded instead of during
...
execution.
2002-09-10 01:26:02 +00:00
Bill Currie
5597dc2408
make maplist work over rcon
2002-09-04 18:56:53 +00:00
Bill Currie
246ab0009c
Change Con_ClearTyping to take a save flag that will cause the current line
...
(if not empty) to be saved in the inputline history.
Clear the input (but put in history) of say or say team when pressing escape.
Don't say or say_team if the text is empty.
2002-08-28 16:02:43 +00:00
Brian Koropoff
33d132fc4e
Added initial support for newline-delimeted lists to GIB, including a for
...
loop that takes a variable through all elements of such a list.
2002-08-28 08:00:35 +00:00
Bill Currie
ec47e08e1c
go back to using QFile, quakeio.h and quakefs.h
2002-08-27 07:16:28 +00:00
Brian Koropoff
98fc04e041
Added threads and callbacks to GIB, as well as several QW callbacks dealing
...
with player status.
2002-08-27 04:47:49 +00:00