Commit Graph

111 Commits

Author SHA1 Message Date
Bill Currie 23e3fc0cb8 document most of obj_file.h (and a few other doc tweaks) 2008-08-01 00:47:38 +00:00
Bill Currie 3e50aae01f "print" command for dumping values in the progs and add return type info to the debugging information 2007-09-15 07:47:31 +00:00
Bill Currie ca0bbd909c correctly save and restore the parameters when calling +initialize. fixes the segfault in the qwaq test. 2007-06-09 13:44:06 +00:00
Bill Currie 57bd43fc52 make the watchpoint (optionally) conditional 2007-05-08 02:25:01 +00:00
Bill Currie fe4a4a9e55 "hardware" (haha) watch points (one!) in progs. only catches changes done by progs, and the expression parser is as flaky as anything, but it's better than nothing :) 2007-05-08 02:04:47 +00:00
Bill Currie 59498cd5e7 make the edict macros consistent in return type 2007-04-09 08:55:05 +00:00
Bill Currie b5e6aa4519 for pr_debug 1, don't dump disassembly when tracing, just source lines. pr_debug >= 2 forces disassembly. detailed disassembly now on pr_debug >= 3 figure out the types of arguments in a function call 2007-04-09 06:16:03 +00:00
Bill Currie 124506fda2 Fix the access alignment bug on 64 bit archs. 2007-04-07 01:41:23 +00:00
Bill Currie 5b761bac83 make progs related code a little more consistent with its int type usage 2007-04-06 00:47:41 +00:00
Bill Currie 38254186da other than floats, progs should now be int size safe 2007-04-04 12:30:49 +00:00
Bill Currie c290e9a988 use plists for save-games. old save-games can still be read, but new ones will always be in the new format. might be a good idea to back up any old saves until more testing has been done. 2006-12-09 02:35:44 +00:00
Bill Currie 2a79f42eb5 progs now internally uses plists for entity/global initialization, with support for direct conversion from id's format. This means that the entity string in a map (or the external ent file) can be a plist. 2006-12-09 00:02:57 +00:00
Bill Currie 6fbddc3d43 so that's the right way to do groups and subgroups... 2006-12-05 11:40:00 +00:00
Bill Currie 42f1334b87 I've discovered \par :) 2006-12-04 13:08:52 +00:00
Bill Currie d28952dfcc fix a bunch of gcc-4.1 warnings (thanks for the heads up, jordi) 2006-11-30 22:52:36 +00:00
Bill Currie e3c9cfd3d2 some documentation work 2005-07-27 12:14:35 +00:00
Bill Currie 762aefc9b1 implement Raven's calling convention (rcall: first 2 params in opb and
opc). should give a general speedup to most progs.
2005-06-12 09:54:01 +00:00
Bill Currie b7def83d19 patch from raorn ("Alexey I. Froloff" <sir_raorn@immo.ru>) to fix
interaction between -hipnotic (etc) and -game
2005-02-14 09:08:32 +00:00
Bill Currie 23f71485d1 more tree recovering. This includes Despair's anisotropy support work. 2005-01-02 14:23:20 +00:00
Bill Currie 0e324d1851 use the script api for parsing ent data and savegames
This is an imperfect revision of history.
2004-11-12 02:39:00 +00:00
Bill Currie 64cc8c60d2 compile time protocol support seems to be complete now. fortunatly, protocols had never been written out so the corrections to the protocol related stuctures do not need a progs version bump. runtime protocol support hasn't been fully tested yet.
+load runtime support seems to be working.

This is an imperfect revision of history.
2004-11-11 00:34:00 +00:00
Bill Currie b35561504c do proper selector registration. unfortunatly, I discovered I'd created pr_method_t incorrectly and so had to bump the progs version again
This is an imperfect revision of history.
2004-11-10 05:37:00 +00:00
Bill Currie 78d98ea787 remove the time pointer (not really needed)
This is an imperfect revision of history.
2004-11-09 22:32:00 +00:00
Bill Currie 8770df39e5 start documenting things (progs building still borked)
This is an imperfect revision of history.
2004-11-08 23:27:00 +00:00
Bill Currie f5bc90a53a clean up some redundant progs functions (may be broken for a while)
This is an imperfect revision of history.
2004-11-05 11:49:00 +00:00
Bill Currie 33bc7858f7 avoid using the hunk in the progs engine (except for the override-able load and alloc functions) so tools (qfprogs and qwaq) don't need to create it.
register only the first instance of a progs provided string

This is an imperfect revision of history.
2004-11-02 04:59:00 +00:00
Bill Currie ff5b215c13 multi statement macro fixes as pointed out by Grievre 2004-03-16 04:15:07 +00:00
Bill Currie 24294c8778 make printing of global contents in PR_PrintStatement optional so
disassembly output is cleaner
2004-01-31 04:26:01 +00:00
Bill Currie 390ca99a92 first step to making qfdefs redundant. "standard" progs now get resolved
staticly rather than looking up the defs. "broken" progs should now work.
2004-01-21 08:09:47 +00:00
Bill Currie 249aee2e9f move the OO runtime support code from libQFgamecode to libQFruamoko where
it really belongs :)
2004-01-16 08:02:31 +00:00
Bill Currie c5c5c33e7d I had forgotten the free string refs list /had/ to be in the progs vm 2004-01-08 04:03:47 +00:00
Bill Currie e455b760ca use a cycled pool of "return strings". I'd love to come up with something
better, but this will do (similar to what qwe does, but qf style:)
2004-01-07 05:22:57 +00:00
Bill Currie 133879f8fa provide builtin mappings for id (none, really), qf and ktpro/qwe (qw only),
add qwe builtin extensions to qw-server. provide sv_progs_ext to control
the builtin mapping. valid values are "id", "qf" (our old static builtins),
"qwe"/"ktpro" (either works. for ktpro mod support) and "none" (no
mapping). any other value is equivalent to "none".
2004-01-06 07:00:39 +00:00
Bill Currie d7592781d7 add builtin mapping support (not used yet) and fix an uninitialized
variable
2004-01-06 06:08:59 +00:00
Bill Currie acd54afff7 move to using a hash table for builtin number -> builtin lookup so sparse
ranges can be used efficiently. move the auto-allocated builtins to
0x10000000-0x7fffffff. should be more than enough :)

use static builtin tables ("nul" terminated) instead of a series of
function calls to add builtins to a vm. should be more memory efficient.
2004-01-06 05:51:09 +00:00
Bill Currie 595280decb do the builtin function lookup at load time rather than runtime and store
the function address in the progs function descriptor. this will speed up
calls to builtin functions, especially when ranges get introduced.
2004-01-05 08:08:46 +00:00
Bill Currie dfc83c1f5f add PR_PushFrame and PR_PopFrame so temp strings are easy to use for
parameters to progs functions.

double the progs stack sizes (call depth of 32? eek)

allow one extra call on the progs stack :)

misc minor cleanups
2004-01-05 07:10:32 +00:00
Bill Currie dfe7f263c7 new internal printf engine for progs, mostly thanks to Deek.
also a few cleanup bits
2004-01-04 07:42:43 +00:00
Bill Currie a533761770 Nuke PR_GarbageCollect as it's both redundant with the new temp strings
and wrong anyway (could free strings it wasn't supposed to).

Don't free the string pointed to by a strref since it's already been
implicity freed (whole memory space nuked). Fixes new map crash.
2004-01-04 02:03:30 +00:00
Bill Currie bd561fafc3 o all progs strings are now stored in progs memory
o  temporary strings automaticly get freed when the function they're
    created in (results of str + str and most strings returned from
	builtins). a way to keep temp strings will be provided later
 o	fix up qwaq to test the temp strings
2004-01-03 08:43:57 +00:00
Bill Currie 09143b7fb1 more whitespace 2003-12-06 22:49:18 +00:00
Bill Currie 4d3ca27227 white space 2003-12-05 22:33:11 +00:00
Bill Currie cd8035319d PR_GetString should have been returning const char *. now does 2003-11-21 21:34:53 +00:00
Bill Currie 5f5662a063 PF_VarString return a plain char * and make it easier to add "at load" init
functions
2003-11-20 07:46:56 +00:00
Bill Currie 84ea81a770 fix E_POINTER and E_FUNCTION 2003-09-12 23:12:21 +00:00
Bill Currie b50d283b28 make sel_get_uid and class_get_instance_method work 2003-08-23 22:16:42 +00:00
Bill Currie 0806fc33dd debugging improvements. opcodes now sport an optional format specifier for
printing their args (default is "%Ga, %Gb, %gc") and PR_ValueString will
try to print what a pointer points to
2003-07-30 22:24:16 +00:00
Bill Currie cb6bf2e2ae minor house-keeping 2003-07-15 16:34:43 +00:00
Bill Currie f7d806e8d5 can now handle > vector sized parameters 2003-04-22 20:11:16 +00:00
Bill Currie e732cf591d remove all references to OFS_* from the C code. only the macros in progs.h
use them now
2003-04-22 18:20:15 +00:00