compiles, doesn't link

This commit is contained in:
Bill Currie 2003-10-27 22:27:29 +00:00
parent 13ecbceba2
commit 60082be06f
36 changed files with 131 additions and 42 deletions

View File

@ -1,6 +1,10 @@
#include "common.qh"
#include "misc.qh"
#include "act.qh"
#include "server.qh"
#include "menu.qh"
#include "mdl.qh"
#include "weapon.qh"
void() PlayerPreThink = {
if (is_cl(self))

View File

@ -12,6 +12,6 @@
void() act_setup;
}
};
#endif

View File

@ -1,6 +1,11 @@
#include "common.qh"
#include "client.qh"
#include "server.qh"
#include "equip.qh"
#include "misc.qh"
#include "weapon.qh"
#include "damage.qh"

View File

@ -3,6 +3,7 @@
#include "damage.qh"
#include "mdl.qh"
#include "client.qh"
#include "server.qh"
#include "misc.qh"
#include "items.qh"
@ -593,8 +594,8 @@ float() player_takeitem = {
local float eid;
nitem = 0;
str1 = NULL_string;
str2 = NULL_string;
str1 = NIL;
str2 = NIL;
while ((eid = equip_iter(other)) != -1) {
if (equip_query(self, eid))
@ -619,7 +620,7 @@ float() player_takeitem = {
self.armortype = other.armortype;
_item_xprint_strs(nitem, str1, str2);
str2 = NULL_string;
str2 = NIL;
if (self.armortype >= 0.8)
str1 = "strong armor";
else if (self.armortype >= 0.6)

View File

@ -4,6 +4,8 @@
#include "effect.qh"
#include "mdl.qh"
#include "misc.qh"
#include "bodyque.qh"
float _bodyque_current;

View File

@ -3,6 +3,8 @@
#include "misc.qh"
#include "override.qh"
#include "mapents.qh"
#include "mdl.qh"
#include "mdl_player.qh"
#include "mdl_void.qh"
@ -225,6 +227,6 @@ void() ClientDisconnect = {
bprint(PRINT_HIGH, name(self), " disconnected with ", ftos(self.frags), " frags\n");
override_set_th_kill(self, NOTHING_function);
self.deathmsg1 = NULL_string;
self.deathmsg1 = NIL;
damage(self, self, self, DAMAGE_MUSTDIE, NOTHING_function);
};

View File

@ -3,6 +3,8 @@
#include "misc.qh"
#include "damage.qh"
#include "server.qh"
void() damage_init = {
ghost_inflictor = spawn("GHOST_INFLICTOR");
};
@ -41,8 +43,8 @@ void() _deathmsg_custom = {
};
void() deathmsg_nodisplay = {
refcount_dec(self.dmg_attacker);
refcount_dec(self.dmg_inflictor);
//XXX refcount_dec(self.dmg_attacker);
//XXX refcount_dec(self.dmg_inflictor);
self.dmg_attacker = world;
self.dmg_inflictor = world;
@ -127,8 +129,8 @@ damage = {
ent.dmg_attacker = attacker;
ent.dmg_inflictor = inflictor;
refcount_inc(ent.dmg_attacker);
refcount_inc(ent.dmg_inflictor);
//XXX refcount_inc(ent.dmg_attacker);
//XXX refcount_inc(ent.dmg_inflictor);
if (inflictor.deathmsg1)
ent.deathmsg = _deathmsg_custom;

View File

@ -30,6 +30,8 @@
.void() th_die;
.void() th_kill;
.float(entity missile) th_projectile;
/* ghost_inflictor is for radius and bullets...
Only guaranteed to have:
classname
@ -51,6 +53,8 @@ float(entity ent, entity attacker, entity inflictor, float d, void() deathmessag
/* Fill in appropriate fields, inflictor _WILL_ be modified. */
void(entity ignore, entity attacker, entity inflictor, void() deathmessage) damage_radius;
float(vector org, entity e) _damage_radius_can_hit;
};
#endif

View File

@ -1,4 +1,5 @@
#include "common.qh"
#include "misc.qh"
#include "server.qh"
#include "delays.qh"

View File

@ -1,5 +1,7 @@
#include "common.qh"
#include "misc.qh"
#include "mapents.qh"
#include "mapents_util.qh"
#include "items.qh"
#include "mapents_triggers.qh"
@ -256,7 +258,7 @@ Wait decrease count by 1 until it reaches 0, then activate targets.
void() trigger_counter = {
util_map_entity_init();
self.model = NULL_string;
self.model = NIL;
self.modelindex = 0;
if (!self.count)

View File

@ -1,10 +1,10 @@
#ifndef ITEMS_qh
#define ITEMS_qh 1
void() item_generic_touch;
void() item_generic;
void() item_remove_regen;
@extern void() item_generic_touch;
@extern void() item_generic;
@extern void() item_remove_regen;
.float() th_takeitem;
@extern .float() th_takeitem;
#endif

View File

@ -1,4 +1,6 @@
#include "common.qh"
#include "misc.qh"
#include "effect.qh"
#include "mapents_util.qh"
#include "damage.qh"

View File

@ -4,6 +4,10 @@
entity intermission_head;
entity spawn_head;
void() info_notnull;
void() light;
void() misc_explobox;
void() func_wall;
#ifndef IMPLEMENT_MAPENTS
};

View File

@ -1,4 +1,7 @@
#include "common.qh"
#include "server.qh"
#include "weapon.qh"
#include "misc.qh"
#include "mapents_util.qh"
#include "damage.qh"
@ -234,8 +237,8 @@ float(float d) _movewall_door_takedamage = {
/* Use target if you need it to go more
than once */
self.message = "";
self.noise1 = NULL_string;
self.noise2 = NULL_string;
self.noise1 = NIL;
self.noise2 = NIL;
}
self = self.enemy;
@ -272,8 +275,8 @@ void() _movewall_door_touch = {
/* Use target if you need it to go more
than once */
self.message = "";
self.noise1 = NULL_string;
self.noise2 = NULL_string;
self.noise1 = NIL;
self.noise2 = NIL;
}
self = self.enemy;
}
@ -323,12 +326,12 @@ void() _door_link = {
tail.message = "";
tail.noise1 = NULL_string;
tail.noise2 = NULL_string;
tail.noise3 = NULL_string;
tail.noise4 = NULL_string;
tail.noise5 = NULL_string;
tail.noise6 = NULL_string;
tail.noise1 = NIL;
tail.noise2 = NIL;
tail.noise3 = NIL;
tail.noise4 = NIL;
tail.noise5 = NIL;
tail.noise6 = NIL;
}
tail.enemy = world;
@ -673,8 +676,8 @@ void() _movewall_secret_use = {
void() _movewall_secret_think = {
if (floor(self.state) != self.state) {
if (self.count == 0 && self.state == 0.5) {
self.message = NULL_string;
self.noise2 = NULL_string;
self.message = NIL;
self.noise2 = NIL;
if (!util_use_targets()) {
self.velocity = '0 0 0';

View File

@ -1,6 +1,11 @@
#include "common.qh"
#include "mapents_util.qh"
#include "items.qh"
#include "weapon.qh"
#include "act.qh"
#include "misc.qh"
#include "mdl_player.qh"
#include "mdl_eyes.qh"
#include "override.qh"
#include "damage.qh"
@ -77,7 +82,7 @@ void() _powerup_think = {
if (powerup.noise) {
sound(self, CHAN_AUTO, powerup.noise, 1, ATTN_NORM);
powerup.noise = NULL_string;
powerup.noise = NIL;
}
powerup.air_finished += 1;
@ -405,7 +410,7 @@ void() _ring_think = {
if (powerup.noise) {
sound(self, CHAN_AUTO, powerup.noise, 1, ATTN_NORM);
powerup.noise = NULL_string;
powerup.noise = NIL;
}
powerup.air_finished += 1;

View File

@ -89,13 +89,13 @@ void() trap_spikeshooter = {
} else if (self.spawnflags & SPAWNFLAG_SUPERSPIKE) {
self.weaponmodel = "progs/s_spike.mdl";
self.noise1 = "weapons/spike2.wav";
self.noise2 = NULL_string;
self.noise2 = NIL;
self.speed = 1000;
self.dmg = 18;
} else {
self.weaponmodel = "progs/spike.mdl";
self.noise1 = "weapons/spike2.wav";
self.noise2 = NULL_string;
self.noise2 = NIL;
self.speed = 1000;
self.dmg = 9;
}

View File

@ -1,9 +1,14 @@
#include "common.qh"
#include "effect.qh"
#include "weapon.qh"
#include "misc.qh"
#include "mapents_util.qh"
#include "damage.qh"
#include "mapents_triggers.qh"
#include "mapents.qh"
#include "teleport.qh"
float(float d) _takedamage_use = {
if (time < self.attack_finished)
@ -148,7 +153,7 @@ void() trigger_teleport = {
self.noise = "ambience/hum1.wav";
setmodel(self, self.model);
self.model = NULL_string;
self.model = NIL;
self.modelindex = 0;
util_map_entity_init();

View File

@ -1,5 +1,6 @@
#include "common.qh"
#include "misc.qh"
#include "server.qh"
#include "mapents_util.qh"
@ -118,9 +119,9 @@ float() util_use_targets = {
if (self.count > 0) {
self.count--;
if (!self.count) {
self.targetname = NULL_string;
self.target = NULL_string;
self.killtarget = NULL_string;
self.targetname = NIL;
self.target = NIL;
self.killtarget = NIL;
self.use = NOTHING_function;
self.touch = NOTHING_function;

View File

@ -4,6 +4,8 @@
#define SPAWNFLAGS_CHECK_ITEMS 16384
#define SPAWNFLAGS_TAKE_ITEMS 32768
@extern {
.void() th_activate;
void() util_map_entity_init;
@ -21,4 +23,6 @@ float(entity e) is_teleportable;
float(entity ent1, entity ent2) util_entities_touch;
};
#endif

View File

@ -1,4 +1,5 @@
#include "math.qh"
#include "builtins.qh"
/* Ugh. QuakeC doesn't include these ops. */
float(float num, float bits) shl = {

View File

@ -1,6 +1,7 @@
#ifndef MDL_qh
#define MDL_qh 1
@extern {
.void(float func, float extra) mdl_func;
.float mdl_mod;
@ -8,6 +9,8 @@
.float mdl_thought;
.float mdl_var;
};
#define MDL_FUNC_IDLE 0
#define MDL_FUNC_JUMP 1
#define MDL_FUNC_PAIN 2
@ -29,8 +32,9 @@
#define MDL_MOD_SWIM_IN 512
#define MDL_MOD_SWIM (MDL_MOD_SWIM_IN|MDL_MOD_SWIM_OVER)
@extern {
void(float func, float extra) mdl_func_void;
entity(float func, float extra) mdl_bodyque_and_func;
};
#endif

View File

@ -1,4 +1,7 @@
#include "common.qh"
#include "effect.qh"
#include "misc.qh"
#include "mdl.qh"
#include "mdl_player.qh"

View File

@ -1,7 +1,11 @@
#ifndef MDL_PLAYER_qh
#define MDL_PLAYER_qh 1
@extern {
void() mdl_player_init;
void() mdl_setup_player;
};
#endif

View File

@ -3,11 +3,11 @@
#include "menus.qh"
.float menu_state;
.float menu_time;
.void() menu_think;
@extern .float menu_state;
@extern .float menu_time;
@extern .void() menu_think;
void(void() menu_func) menu_set;
float() util_menu_needs_print;
@extern void(void() menu_func) menu_set;
@extern float() util_menu_needs_print;
#endif

View File

@ -1,5 +1,7 @@
#include "client.qh"
#include "common.qh"
#include "menu.qh"
#include "misc.qh"
/*
void() menu_team = {

View File

@ -1,6 +1,6 @@
#ifndef MENUS_qh
#define MENUS_qh 1
void() menu_intro;
@extern void() menu_intro;
#endif

View File

@ -1,7 +1,9 @@
#include "common.qh"
#include "protocol.qh"
#include "misc.qh"
#include "server.qh"
#include "teleport.qh"
#include "weapon.qh"
// ===================================================================== //
@ -21,7 +23,7 @@ void() SUB_remove = { remove(self); };
void(entity e) safe_remove = {
e.takedamage = DAMAGE_NO;
e.solid = SOLID_NOT;
e.model = NULL_string;
e.model = NIL;
e.modelindex = 0;
e.think = SUB_remove;

View File

@ -1,7 +1,10 @@
#include "act.qh"
#include "common.qh"
#include "items.qh"
#include "damage.qh"
#include "misc.qh"
#include "teleport.qh"
#include "override.qh"

View File

@ -1,6 +1,8 @@
#ifndef SZ_WATCH_qh
#define SZ_WATCH_qh 1
@extern {
float sv_spawning;
void() SZ_init;
@ -9,4 +11,6 @@ void() SZ_frame;
void(entity e) makestatic;
void(vector pos, string samp, float vol, float atten) ambientsound;
};
#endif

View File

@ -2,6 +2,7 @@
#include "mapents_util.qh"
#include "damage.qh"
#include "effect.qh"
#include "misc.qh"
#include "teleport.qh"
void() _deathmsg_teleport = {

View File

@ -1,4 +1,5 @@
#include "common.qh"
#include "misc.qh"
#include "weapon.qh"
#include "damage.qh"

View File

@ -1,4 +1,5 @@
#include "common.qh"
#include "effect.qh"
#include "weapon.qh"
#include "equip.qh"

View File

@ -1,4 +1,5 @@
#include "common.qh"
#include "misc.qh"
#include "weapon.qh"
#include "equip.qh"

View File

@ -1,5 +1,7 @@
#include "common.qh"
#include "misc.qh"
#include "weapon.qh"
.float weapon_imp;

View File

@ -4,8 +4,14 @@
#include "weapon_g.qh"
#include "mdl.qh"
@extern {
.void() w_think;
.float(float action) w_func;
.float attack_finished;
.float weapon_imp;
.float weapons;
.float w_thought;
#define WEAPON_INIT 0
#define WEAPON_AMMO 1
@ -33,5 +39,8 @@ float(float impluse) util_impulse_to_IT;
float(.float ammo_field, float ammo) util_weapon_use_ammo;
float(.float ammo_field, float max_ammo, float ammo) util_weapon_give_ammo;
void(float imp, float idx, float(float action) func) _weapon_select;
};
#endif

View File

@ -1,6 +1,8 @@
#ifndef WEAPON_G_qh
#define WEAPON_G_qh 1
@extern {
void() weapon_init_weapons;
void() weapon_select_best;
@ -8,4 +10,6 @@ void(float imp) weapon_select_by_impulse;
void() update_weapon_flags;
};
#endif