From: TimePath Date: Mon, 28 Mar 2016 03:05:09 +0000 (+1100) Subject: #define use use1 X-Git-Tag: xonotic-v0.8.2~945^2~2 X-Git-Url: https://git.rm.cloudns.org/?a=commitdiff_plain;h=847371860eeb17f6a51aa1fa532aa997cb2d760b;p=xonotic%2Fxonotic-data.pk3dir.git #define use use1 --- diff --git a/qcsrc/common/debug.qh b/qcsrc/common/debug.qh index e20139aac..40b2b3547 100644 --- a/qcsrc/common/debug.qh +++ b/qcsrc/common/debug.qh @@ -116,7 +116,7 @@ bool autocvar_debugdraw; // if (it.maxs) break; // if (it.size) break; // if (it.touch) break; -// if (it.use1) break; +// if (it.use) break; // if (it.think) break; // if (it.blocked) break; // if (it.nextthink) break; diff --git a/qcsrc/common/gamemodes/gamemode/onslaught/onslaught.qc b/qcsrc/common/gamemodes/gamemode/onslaught/onslaught.qc index 056d33a03..ec69def5e 100644 --- a/qcsrc/common/gamemodes/gamemode/onslaught/onslaught.qc +++ b/qcsrc/common/gamemodes/gamemode/onslaught/onslaught.qc @@ -1954,7 +1954,7 @@ void ons_MonsterSpawn_Delayed(entity this) { own.team = e.team; - own.use1(own, e, NULL); + own.use(own, e, NULL); } } @@ -1984,7 +1984,7 @@ void ons_TurretSpawn_Delayed(entity this) own.team = e.team; own.active = ACTIVE_NOT; - own.use1(own, e, NULL); + own.use(own, e, NULL); } } diff --git a/qcsrc/common/minigames/cl_minigames_hud.qc b/qcsrc/common/minigames/cl_minigames_hud.qc index 23ac4539f..56cae3c22 100644 --- a/qcsrc/common/minigames/cl_minigames_hud.qc +++ b/qcsrc/common/minigames/cl_minigames_hud.qc @@ -115,7 +115,7 @@ void HUD_MinigameMenu_Click(entity menuitem) { if ( menuitem ) { - menuitem.use1(menuitem, NULL, NULL); + menuitem.use(menuitem, NULL, NULL); } } @@ -154,7 +154,7 @@ entity HUD_MinigameMenu_SpawnEntry(string s, vector offset, vector fontsize, vec entry.size = fontsize; entry.colormod = color; entry.flags = 0; - entry.use1 = click; + entry.use = click; panel_pos_y += fontsize_y; return entry; } diff --git a/qcsrc/common/monsters/monster/shambler.qc b/qcsrc/common/monsters/monster/shambler.qc index eb3dfba98..139967a2c 100644 --- a/qcsrc/common/monsters/monster/shambler.qc +++ b/qcsrc/common/monsters/monster/shambler.qc @@ -128,7 +128,7 @@ void M_Shambler_Attack_Lightning_Touch() {SELFPARAM(); PROJECTILE_TOUCH; - self.use1(this, NULL, NULL); + self.use(this, NULL, NULL); } void M_Shambler_Attack_Lightning_Think() @@ -162,7 +162,7 @@ void M_Shambler_Attack_Lightning(entity this) gren.cnt = time + 5; gren.nextthink = time; gren.think = M_Shambler_Attack_Lightning_Think; - gren.use1 = M_Shambler_Attack_Lightning_Explode_use; + gren.use = M_Shambler_Attack_Lightning_Explode_use; gren.touch = M_Shambler_Attack_Lightning_Touch; gren.takedamage = DAMAGE_YES; diff --git a/qcsrc/common/monsters/monster/spider.qc b/qcsrc/common/monsters/monster/spider.qc index c477d3ea6..0b2e3650b 100644 --- a/qcsrc/common/monsters/monster/spider.qc +++ b/qcsrc/common/monsters/monster/spider.qc @@ -173,7 +173,7 @@ void M_Spider_Attack_Web(entity this) entity proj = new(plasma); proj.owner = proj.realowner = this; - proj.use1 = M_Spider_Attack_Web_Explode_use; + proj.use = M_Spider_Attack_Web_Explode_use; proj.think = adaptor_think2use_hittype_splash; proj.bot_dodge = true; proj.bot_dodgerating = 0; diff --git a/qcsrc/common/monsters/sv_monsters.qc b/qcsrc/common/monsters/sv_monsters.qc index d1276fa52..def29e969 100644 --- a/qcsrc/common/monsters/sv_monsters.qc +++ b/qcsrc/common/monsters/sv_monsters.qc @@ -946,7 +946,7 @@ bool Monster_Appear_Check(entity this, int monster_id) this.think = func_null; this.monsterid = monster_id; // set so this monster is properly registered (otherwise, normal initialization is used) this.nextthink = 0; - this.use1 = Monster_Appear; + this.use = Monster_Appear; this.flags = FL_MONSTER; // set so this monster can get butchered return true; @@ -1332,7 +1332,7 @@ bool Monster_Spawn(entity this, int mon_id) this.monsterid = mon_id; this.event_damage = Monster_Damage; this.touch = Monster_Touch; - this.use1 = Monster_Use; + this.use = Monster_Use; this.solid = SOLID_BBOX; this.movetype = MOVETYPE_WALK; this.spawnshieldtime = time + autocvar_g_monsters_spawnshieldtime; diff --git a/qcsrc/common/t_items.qc b/qcsrc/common/t_items.qc index 2c1b2a8dd..957a6fcc7 100644 --- a/qcsrc/common/t_items.qc +++ b/qcsrc/common/t_items.qc @@ -1453,7 +1453,7 @@ spawnfunc(target_items) float n, i; string s; - self.use1 = target_items_use; + self.use = target_items_use; if(!self.strength_finished) self.strength_finished = autocvar_g_balance_powerup_strength_time; if(!self.invincible_finished) diff --git a/qcsrc/common/triggers/func/breakable.qc b/qcsrc/common/triggers/func/breakable.qc index 112d7ccf1..34a048c6a 100644 --- a/qcsrc/common/triggers/func/breakable.qc +++ b/qcsrc/common/triggers/func/breakable.qc @@ -137,7 +137,7 @@ void func_breakable_behave_destroyed() self.event_damage = func_null; self.state = 1; if(self.spawnflags & 4) - self.use1 = func_null; + self.use = func_null; func_breakable_colormod(); if (self.noise1) stopsound (self, CH_TRIGGER_SINGLE); @@ -322,9 +322,9 @@ spawnfunc(func_breakable) SetBrushEntityModel(); if(this.spawnflags & 4) - this.use1 = func_breakable_destroy; + this.use = func_breakable_destroy; else - this.use1 = func_breakable_restore; + this.use = func_breakable_restore; if(this.spawnflags & 4) { diff --git a/qcsrc/common/triggers/func/button.qc b/qcsrc/common/triggers/func/button.qc index ba612713c..a1cabdc6c 100644 --- a/qcsrc/common/triggers/func/button.qc +++ b/qcsrc/common/triggers/func/button.qc @@ -120,7 +120,7 @@ spawnfunc(func_button) self.effects |= EF_LOWPRECISION; self.blocked = button_blocked; - self.use1 = button_use; + self.use = button_use; // if (self.health == 0) // all buttons are now shootable // self.health = 10; diff --git a/qcsrc/common/triggers/func/conveyor.qc b/qcsrc/common/triggers/func/conveyor.qc index 93b6502de..5cd17e7bf 100644 --- a/qcsrc/common/triggers/func/conveyor.qc +++ b/qcsrc/common/triggers/func/conveyor.qc @@ -116,7 +116,7 @@ void conveyor_init() this.nextthink = time; IFTARGETED { - this.use1 = conveyor_use; + this.use = conveyor_use; this.reset = conveyor_reset; this.reset(this); } diff --git a/qcsrc/common/triggers/func/door.qc b/qcsrc/common/triggers/func/door.qc index 0546b2eae..30de40fa9 100644 --- a/qcsrc/common/triggers/func/door.qc +++ b/qcsrc/common/triggers/func/door.qc @@ -738,7 +738,7 @@ spawnfunc(func_door) precache_sound(self.noise3); self.blocked = door_blocked; - self.use1 = door_use; + self.use = door_use; if(self.dmg && (self.message == "")) self.message = "was squished"; @@ -842,7 +842,7 @@ NET_HANDLE(ENT_CLIENT_DOOR, bool isnew) this.trigger_touch = door_touch; this.draw = door_draw; this.drawmask = MASK_NORMAL; - this.use1 = door_use; + this.use = door_use; LinkDoors(this); diff --git a/qcsrc/common/triggers/func/door_rotating.qc b/qcsrc/common/triggers/func/door_rotating.qc index f552090e9..4c97fe6a8 100644 --- a/qcsrc/common/triggers/func/door_rotating.qc +++ b/qcsrc/common/triggers/func/door_rotating.qc @@ -72,7 +72,7 @@ spawnfunc(func_door_rotating) self.classname = "door_rotating"; self.blocked = door_blocked; - self.use1 = door_use; + self.use = door_use; if(self.spawnflags & 8) self.dmg = 10000; diff --git a/qcsrc/common/triggers/func/door_secret.qc b/qcsrc/common/triggers/func/door_secret.qc index 0091448af..3e4530204 100644 --- a/qcsrc/common/triggers/func/door_secret.qc +++ b/qcsrc/common/triggers/func/door_secret.qc @@ -216,7 +216,7 @@ spawnfunc(func_door_secret) this.touch = secret_touch; this.blocked = secret_blocked; this.speed = 50; - this.use1 = fd_secret_use; + this.use = fd_secret_use; IFTARGETED { } diff --git a/qcsrc/common/triggers/func/plat.qc b/qcsrc/common/triggers/func/plat.qc index badddf4cc..14cfa5641 100644 --- a/qcsrc/common/triggers/func/plat.qc +++ b/qcsrc/common/triggers/func/plat.qc @@ -171,7 +171,7 @@ NET_HANDLE(ENT_CLIENT_PLAT, bool isnew) this.movetype = MOVETYPE_PUSH; this.drawmask = MASK_NORMAL; this.draw = plat_draw; - this.use1 = plat_use; + this.use = plat_use; this.entremove = trigger_remove_generic; plat_reset(this); // also called here diff --git a/qcsrc/common/triggers/func/pointparticles.qc b/qcsrc/common/triggers/func/pointparticles.qc index 6c2bb43cb..9cec88f99 100644 --- a/qcsrc/common/triggers/func/pointparticles.qc +++ b/qcsrc/common/triggers/func/pointparticles.qc @@ -137,7 +137,7 @@ spawnfunc(func_pointparticles) IFTARGETED { - this.use1 = pointparticles_use; + this.use = pointparticles_use; this.reset = pointparticles_reset; this.reset(this); } diff --git a/qcsrc/common/triggers/func/train.qc b/qcsrc/common/triggers/func/train.qc index 0fa3ed601..013d4597f 100644 --- a/qcsrc/common/triggers/func/train.qc +++ b/qcsrc/common/triggers/func/train.qc @@ -43,7 +43,7 @@ void train_wait() entity tg = find(world, targetname, self.target); if(tg.spawnflags & 4) { - self.use1 = train_use; + self.use = train_use; self.SUB_THINK = func_null; self.SUB_NEXTTHINK = 0; } @@ -180,7 +180,7 @@ void train_use(entity this, entity actor, entity trigger) { this.SUB_NEXTTHINK = this.SUB_LTIME + 1; this.SUB_THINK = train_next; - this.use1 = func_null; // not again + this.use = func_null; // not again } void func_train_find(entity this) @@ -224,7 +224,7 @@ spawnfunc(func_train) self.effects |= EF_LOWPRECISION; if(self.spawnflags & 4) - self.use1 = train_use; + self.use = train_use; if (self.spawnflags & 2) { diff --git a/qcsrc/common/triggers/misc/laser.qc b/qcsrc/common/triggers/misc/laser.qc index 9c388f6fc..6e589eddf 100644 --- a/qcsrc/common/triggers/misc/laser.qc +++ b/qcsrc/common/triggers/misc/laser.qc @@ -244,7 +244,7 @@ spawnfunc(misc_laser) { this.reset = laser_reset; this.reset(this); - this.use1 = laser_use; + this.use = laser_use; } else this.state = 1; diff --git a/qcsrc/common/triggers/platforms.qc b/qcsrc/common/triggers/platforms.qc index b9937f04d..7429f2b35 100644 --- a/qcsrc/common/triggers/platforms.qc +++ b/qcsrc/common/triggers/platforms.qc @@ -178,7 +178,7 @@ void plat_crush() void plat_use(entity this, entity actor, entity trigger) { - this.use1 = func_null; + this.use = func_null; if (this.state != 4) objerror ("plat_use: not in up state"); WITHSELF(this, plat_go_down()); @@ -192,13 +192,13 @@ void plat_reset(entity this) { setorigin (this, this.pos1); this.state = 4; - this.use1 = plat_use; + this.use = plat_use; } else { setorigin (this, this.pos2); this.state = 2; - this.use1 = plat_trigger_use; + this.use = plat_trigger_use; } #ifdef SVQC diff --git a/qcsrc/common/triggers/target/changelevel.qc b/qcsrc/common/triggers/target/changelevel.qc index 3962957b3..d4bc850de 100644 --- a/qcsrc/common/triggers/target/changelevel.qc +++ b/qcsrc/common/triggers/target/changelevel.qc @@ -34,7 +34,7 @@ void target_changelevel_use(entity this, entity actor, entity trigger) spawnfunc(target_changelevel) { - this.use1 = target_changelevel_use; + this.use = target_changelevel_use; if(!this.count) { this.count = 0.7; } } diff --git a/qcsrc/common/triggers/target/music.qc b/qcsrc/common/triggers/target/music.qc index 0b06efb26..c48a0ba26 100644 --- a/qcsrc/common/triggers/target/music.qc +++ b/qcsrc/common/triggers/target/music.qc @@ -60,7 +60,7 @@ void target_music_use(entity this, entity actor, entity trigger) } spawnfunc(target_music) { - self.use1 = target_music_use; + self.use = target_music_use; self.reset = target_music_reset; if(!self.volume) self.volume = 1; @@ -148,7 +148,7 @@ spawnfunc(trigger_music) } trigger_music_reset(this); - this.use1 = trigger_music_use; + this.use = trigger_music_use; this.reset = trigger_music_reset; Net_LinkEntity(this, false, 0, trigger_music_SendEntity); diff --git a/qcsrc/common/triggers/target/spawn.qc b/qcsrc/common/triggers/target/spawn.qc index e6114a520..74ac8fd99 100644 --- a/qcsrc/common/triggers/target/spawn.qc +++ b/qcsrc/common/triggers/target/spawn.qc @@ -330,7 +330,7 @@ void initialize_field_db() spawnfunc(target_spawn) { initialize_field_db(); - self.use1 = target_spawn_use; + self.use = target_spawn_use; self.message = strzone(strreplace("'", "\"", self.message)); self.target_spawn_id = ++target_spawn_count; InitializeEntity(self, target_spawn_spawnfirst, INITPRIO_LAST); diff --git a/qcsrc/common/triggers/target/speaker.qc b/qcsrc/common/triggers/target/speaker.qc index c095597e5..046128f79 100644 --- a/qcsrc/common/triggers/target/speaker.qc +++ b/qcsrc/common/triggers/target/speaker.qc @@ -54,23 +54,23 @@ void target_speaker_use_on(entity this, entity actor, entity trigger) snd = this.noise; _sound(this, CH_TRIGGER_SINGLE, snd, VOL_BASE * this.volume, this.atten); if(this.spawnflags & 3) - this.use1 = target_speaker_use_off; + this.use = target_speaker_use_off; } void target_speaker_use_off(entity this, entity actor, entity trigger) { sound(this, CH_TRIGGER_SINGLE, SND_Null, VOL_BASE * this.volume, this.atten); - this.use1 = target_speaker_use_on; + this.use = target_speaker_use_on; } void target_speaker_reset(entity this) { if(this.spawnflags & 1) // LOOPED_ON { - if(this.use1 == target_speaker_use_on) + if(this.use == target_speaker_use_on) target_speaker_use_on(this, NULL, NULL); } else if(this.spawnflags & 2) { - if(this.use1 == target_speaker_use_off) + if(this.use == target_speaker_use_off) target_speaker_use_off(this, NULL, NULL); } } @@ -98,7 +98,7 @@ spawnfunc(target_speaker) IFTARGETED { if(self.spawnflags & 8) // ACTIVATOR - self.use1 = target_speaker_use_activator; + self.use = target_speaker_use_activator; else if(self.spawnflags & 1) // LOOPED_ON { target_speaker_use_on(self, NULL, NULL); @@ -106,11 +106,11 @@ spawnfunc(target_speaker) } else if(self.spawnflags & 2) // LOOPED_OFF { - self.use1 = target_speaker_use_on; + self.use = target_speaker_use_on; self.reset = target_speaker_reset; } else - self.use1 = target_speaker_use_on; + self.use = target_speaker_use_on; } else if(self.spawnflags & 1) // LOOPED_ON { diff --git a/qcsrc/common/triggers/target/voicescript.qc b/qcsrc/common/triggers/target/voicescript.qc index b6ed6dcff..e84331770 100644 --- a/qcsrc/common/triggers/target/voicescript.qc +++ b/qcsrc/common/triggers/target/voicescript.qc @@ -84,7 +84,7 @@ spawnfunc(target_voicescript) // delay: initial delay before the first message float i, n; - self.use1 = target_voicescript_use; + self.use = target_voicescript_use; n = tokenize_console(self.message); self.cnt = n / 2; diff --git a/qcsrc/common/triggers/trigger/counter.qc b/qcsrc/common/triggers/trigger/counter.qc index 07e5de68c..5ada6805f 100644 --- a/qcsrc/common/triggers/trigger/counter.qc +++ b/qcsrc/common/triggers/trigger/counter.qc @@ -43,7 +43,7 @@ spawnfunc(trigger_counter) self.count = 2; self.cnt = self.count; - self.use1 = counter_use; + self.use = counter_use; self.reset = counter_reset; } #endif diff --git a/qcsrc/common/triggers/trigger/delay.qc b/qcsrc/common/triggers/trigger/delay.qc index 3329fc37a..02c1aa968 100644 --- a/qcsrc/common/triggers/trigger/delay.qc +++ b/qcsrc/common/triggers/trigger/delay.qc @@ -16,7 +16,7 @@ spawnfunc(trigger_delay) if(!self.wait) self.wait = 1; - self.use1 = delay_use; + self.use = delay_use; self.reset = delay_reset; } #endif diff --git a/qcsrc/common/triggers/trigger/disablerelay.qc b/qcsrc/common/triggers/trigger/disablerelay.qc index 137213f34..a09e0ba09 100644 --- a/qcsrc/common/triggers/trigger/disablerelay.qc +++ b/qcsrc/common/triggers/trigger/disablerelay.qc @@ -5,14 +5,14 @@ void trigger_disablerelay_use(entity this, entity actor, entity trigger) for(entity e = world; (e = find(e, targetname, this.target)); ) { - if(e.use1 == SUB_UseTargets) + if(e.use == SUB_UseTargets) { - e.use1 = SUB_DontUseTargets; + e.use = SUB_DontUseTargets; ++a; } - else if(e.use1 == SUB_DontUseTargets) + else if(e.use == SUB_DontUseTargets) { - e.use1 = SUB_UseTargets; + e.use = SUB_UseTargets; ++b; } } @@ -23,6 +23,6 @@ void trigger_disablerelay_use(entity this, entity actor, entity trigger) spawnfunc(trigger_disablerelay) { - this.use1 = trigger_disablerelay_use; + this.use = trigger_disablerelay_use; } #endif diff --git a/qcsrc/common/triggers/trigger/flipflop.qc b/qcsrc/common/triggers/trigger/flipflop.qc index 8265d1235..e4923bdf5 100644 --- a/qcsrc/common/triggers/trigger/flipflop.qc +++ b/qcsrc/common/triggers/trigger/flipflop.qc @@ -13,7 +13,7 @@ spawnfunc(trigger_flipflop) { if(this.spawnflags & 1) this.state = 1; - this.use1 = flipflop_use; + this.use = flipflop_use; this.reset = spawnfunc_trigger_flipflop; // perfect resetter } diff --git a/qcsrc/common/triggers/trigger/gamestart.qc b/qcsrc/common/triggers/trigger/gamestart.qc index 9e2cc26e1..5f3206a2a 100644 --- a/qcsrc/common/triggers/trigger/gamestart.qc +++ b/qcsrc/common/triggers/trigger/gamestart.qc @@ -13,7 +13,7 @@ void gamestart_use_this(entity this) void self_spawnfunc_trigger_gamestart(); spawnfunc(trigger_gamestart) { - this.use1 = gamestart_use; + this.use = gamestart_use; this.reset2 = self_spawnfunc_trigger_gamestart; if(this.wait) diff --git a/qcsrc/common/triggers/trigger/gravity.qc b/qcsrc/common/triggers/trigger/gravity.qc index 1f61e50ac..c7dd586cb 100644 --- a/qcsrc/common/triggers/trigger/gravity.qc +++ b/qcsrc/common/triggers/trigger/gravity.qc @@ -98,7 +98,7 @@ spawnfunc(trigger_gravity) self.state = true; IFTARGETED { - self.use1 = trigger_gravity_use; + self.use = trigger_gravity_use; if(self.spawnflags & 2) self.state = false; } diff --git a/qcsrc/common/triggers/trigger/hurt.qc b/qcsrc/common/triggers/trigger/hurt.qc index 1e29bf8d2..a7ee567eb 100644 --- a/qcsrc/common/triggers/trigger/hurt.qc +++ b/qcsrc/common/triggers/trigger/hurt.qc @@ -62,7 +62,7 @@ spawnfunc(trigger_hurt) EXACTTRIGGER_INIT; self.active = ACTIVE_ACTIVE; self.touch = trigger_hurt_touch; - self.use1 = trigger_hurt_use; + self.use = trigger_hurt_use; self.enemy = world; // I hate you all if (!self.dmg) self.dmg = 1000; diff --git a/qcsrc/common/triggers/trigger/jumppads.qc b/qcsrc/common/triggers/trigger/jumppads.qc index db3905b64..e52e7c2f9 100644 --- a/qcsrc/common/triggers/trigger/jumppads.qc +++ b/qcsrc/common/triggers/trigger/jumppads.qc @@ -381,7 +381,7 @@ spawnfunc(trigger_push) trigger_init(this); this.active = ACTIVE_ACTIVE; - this.use1 = trigger_push_use; + this.use = trigger_push_use; this.touch = trigger_push_touch; // normal push setup diff --git a/qcsrc/common/triggers/trigger/keylock.qc b/qcsrc/common/triggers/trigger/keylock.qc index cc45e2490..311075aa0 100644 --- a/qcsrc/common/triggers/trigger/keylock.qc +++ b/qcsrc/common/triggers/trigger/keylock.qc @@ -4,8 +4,8 @@ void trigger_keylock_trigger(entity this, entity actor, string s) { for(entity t = world; (t = find(t, targetname, s)); ) - if(t.use1) - t.use1(t, actor, this); + if(t.use) + t.use(t, actor, this); } /** diff --git a/qcsrc/common/triggers/trigger/monoflop.qc b/qcsrc/common/triggers/trigger/monoflop.qc index 4c0e27c75..994d498c1 100644 --- a/qcsrc/common/triggers/trigger/monoflop.qc +++ b/qcsrc/common/triggers/trigger/monoflop.qc @@ -38,9 +38,9 @@ spawnfunc(trigger_monoflop) if(!this.wait) this.wait = 1; if(this.spawnflags & 1) - this.use1 = monoflop_fixed_use; + this.use = monoflop_fixed_use; else - this.use1 = monoflop_use; + this.use = monoflop_use; this.think = monoflop_think; this.state = 0; this.reset = monoflop_reset; diff --git a/qcsrc/common/triggers/trigger/multi.qc b/qcsrc/common/triggers/trigger/multi.qc index 5576e5468..ce7bba673 100644 --- a/qcsrc/common/triggers/trigger/multi.qc +++ b/qcsrc/common/triggers/trigger/multi.qc @@ -158,7 +158,7 @@ spawnfunc(trigger_multiple) self.wait = 0.2; else if(self.wait < -1) self.wait = 0; - self.use1 = multi_use; + self.use = multi_use; EXACTTRIGGER_INIT; diff --git a/qcsrc/common/triggers/trigger/multivibrator.qc b/qcsrc/common/triggers/trigger/multivibrator.qc index 886bed55c..a50f62b7a 100644 --- a/qcsrc/common/triggers/trigger/multivibrator.qc +++ b/qcsrc/common/triggers/trigger/multivibrator.qc @@ -62,7 +62,7 @@ spawnfunc(trigger_multivibrator) self.respawntime = self.wait; self.state = 0; - self.use1 = multivibrator_toggle; + self.use = multivibrator_toggle; self.think = multivibrator_send; self.nextthink = max(1, time); diff --git a/qcsrc/common/triggers/trigger/relay.qc b/qcsrc/common/triggers/trigger/relay.qc index a3fcb9512..1df446ba3 100644 --- a/qcsrc/common/triggers/trigger/relay.qc +++ b/qcsrc/common/triggers/trigger/relay.qc @@ -4,7 +4,7 @@ This fixed size trigger cannot be touched, it can only be fired by other events. */ spawnfunc(trigger_relay) { - this.use1 = SUB_UseTargets; + this.use = SUB_UseTargets; this.reset = spawnfunc_trigger_relay; // this spawnfunc resets fully } #endif diff --git a/qcsrc/common/triggers/trigger/relay_activators.qc b/qcsrc/common/triggers/trigger/relay_activators.qc index f47e4ae33..dabbbd2d9 100644 --- a/qcsrc/common/triggers/trigger/relay_activators.qc +++ b/qcsrc/common/triggers/trigger/relay_activators.qc @@ -22,18 +22,18 @@ void relay_activators_use(entity this, entity actor, entity trigger) spawnfunc(relay_activate) { this.cnt = ACTIVE_ACTIVE; - this.use1 = relay_activators_use; + this.use = relay_activators_use; } spawnfunc(relay_deactivate) { this.cnt = ACTIVE_NOT; - this.use1 = relay_activators_use; + this.use = relay_activators_use; } spawnfunc(relay_activatetoggle) { this.cnt = ACTIVE_TOGGLE; - this.use1 = relay_activators_use; + this.use = relay_activators_use; } #endif diff --git a/qcsrc/common/triggers/trigger/relay_if.qc b/qcsrc/common/triggers/trigger/relay_if.qc index 1d7991cba..ea90a06cb 100644 --- a/qcsrc/common/triggers/trigger/relay_if.qc +++ b/qcsrc/common/triggers/trigger/relay_if.qc @@ -14,6 +14,6 @@ void trigger_relay_if_use(entity this, entity actor, entity trigger) spawnfunc(trigger_relay_if) { - this.use1 = trigger_relay_if_use; + this.use = trigger_relay_if_use; } #endif diff --git a/qcsrc/common/triggers/trigger/relay_teamcheck.qc b/qcsrc/common/triggers/trigger/relay_teamcheck.qc index 289371fcc..2972d32bb 100644 --- a/qcsrc/common/triggers/trigger/relay_teamcheck.qc +++ b/qcsrc/common/triggers/trigger/relay_teamcheck.qc @@ -29,7 +29,7 @@ void trigger_relay_teamcheck_reset(entity this) spawnfunc(trigger_relay_teamcheck) { this.team_saved = this.team; - this.use1 = trigger_relay_teamcheck_use; + this.use = trigger_relay_teamcheck_use; this.reset = trigger_relay_teamcheck_reset; } #endif diff --git a/qcsrc/common/triggers/trigger/secret.qc b/qcsrc/common/triggers/trigger/secret.qc index cb64f9602..f94cd00ad 100644 --- a/qcsrc/common/triggers/trigger/secret.qc +++ b/qcsrc/common/triggers/trigger/secret.qc @@ -82,6 +82,6 @@ spawnfunc(trigger_secret) // take over the touch() function, so we can mark secret as found self.touch = trigger_secret_touch; // ignore triggering; - self.use1 = func_null; + self.use = func_null; } #endif diff --git a/qcsrc/common/triggers/trigger/teleport.qc b/qcsrc/common/triggers/trigger/teleport.qc index 49e8cdb55..c9b814713 100644 --- a/qcsrc/common/triggers/trigger/teleport.qc +++ b/qcsrc/common/triggers/trigger/teleport.qc @@ -84,7 +84,7 @@ spawnfunc(trigger_teleport) self.active = ACTIVE_ACTIVE; //trigger_init(self); // only for predicted triggers? EXACTTRIGGER_INIT; - self.use1 = trigger_teleport_use; + self.use = trigger_teleport_use; if(self.noise != "") FOREACH_WORD(self.noise, true, precache_sound(it)); diff --git a/qcsrc/common/triggers/triggers.qc b/qcsrc/common/triggers/triggers.qc index 691aea505..4493138d0 100644 --- a/qcsrc/common/triggers/triggers.qc +++ b/qcsrc/common/triggers/triggers.qc @@ -254,7 +254,7 @@ void SUB_UseTargets(entity this, entity actor, entity trigger) int aw_flag = this.antiwall_flag; for(entity t = world; (t = find(t, targetname, s)); ) { - if(t.use1) + if(t.use) { if(this.target_random) { @@ -265,7 +265,7 @@ void SUB_UseTargets(entity this, entity actor, entity trigger) if (t.classname == "func_clientwall" || t.classname == "func_clientillusionary") t.antiwall_flag = aw_flag; - t.use1(t, actor, this); + t.use(t, actor, this); } } } @@ -273,7 +273,7 @@ void SUB_UseTargets(entity this, entity actor, entity trigger) } if(this.target_random && RandomSelection_chosen_ent) - RandomSelection_chosen_ent.use1(RandomSelection_chosen_ent, actor, this); + RandomSelection_chosen_ent.use(RandomSelection_chosen_ent, actor, this); } void SUB_UseTargets_self() diff --git a/qcsrc/common/turrets/sv_turrets.qc b/qcsrc/common/turrets/sv_turrets.qc index c226a9867..2578c1e6d 100644 --- a/qcsrc/common/turrets/sv_turrets.qc +++ b/qcsrc/common/turrets/sv_turrets.qc @@ -1341,7 +1341,7 @@ float turret_initialize(Turret tur) self.view_ofs = '0 0 0'; self.turret_firecheckfunc = turret_firecheck; self.event_damage = turret_damage; - self.use1 = turret_use; + self.use = turret_use; self.bot_attack = true; self.nextthink = time + 1; self.nextthink += turret_count * sys_frametime; diff --git a/qcsrc/common/turrets/turret/ewheel.qc b/qcsrc/common/turrets/turret/ewheel.qc index 1c3d5731f..0bdfca46e 100644 --- a/qcsrc/common/turrets/turret/ewheel.qc +++ b/qcsrc/common/turrets/turret/ewheel.qc @@ -49,8 +49,8 @@ void ewheel_move_path() if (self.pathgoal) { - if (self.pathgoal.use1) - self.pathgoal.use1(self.pathgoal, NULL, NULL); + if (self.pathgoal.use) + self.pathgoal.use(self.pathgoal, NULL, NULL); if (self.pathgoal.enemy) { diff --git a/qcsrc/common/turrets/turret/walker.qc b/qcsrc/common/turrets/turret/walker.qc index d99479cb1..51ace9a7d 100644 --- a/qcsrc/common/turrets/turret/walker.qc +++ b/qcsrc/common/turrets/turret/walker.qc @@ -312,8 +312,8 @@ void walker_move_path() if (self.pathgoal) { - if (self.pathgoal.use1) - self.pathgoal.use1(self, NULL, NULL); + if (self.pathgoal.use) + self.pathgoal.use(self, NULL, NULL); if (self.pathgoal.enemy) { diff --git a/qcsrc/common/util.qh b/qcsrc/common/util.qh index 36bd8b59d..ef36eb230 100644 --- a/qcsrc/common/util.qh +++ b/qcsrc/common/util.qh @@ -2,7 +2,6 @@ #define COMMON_UTIL_H #ifndef MENUQC -.void(entity this, entity actor, entity trigger) use1; vector real_origin(entity ent); #endif diff --git a/qcsrc/common/vehicles/sv_vehicles.qc b/qcsrc/common/vehicles/sv_vehicles.qc index 69907c04b..fc44613e5 100644 --- a/qcsrc/common/vehicles/sv_vehicles.qc +++ b/qcsrc/common/vehicles/sv_vehicles.qc @@ -262,7 +262,7 @@ entity vehicles_projectile(entity this, string _mzlfx, Sound _mzlsound, proj.bot_dodgerating = _dmg; proj.velocity = _vel; proj.touch = vehicles_projectile_explode; - proj.use1 = vehicles_projectile_explode_use; + proj.use = vehicles_projectile_explode_use; proj.owner = this; proj.realowner = _owner; proj.think = SUB_Remove_self; @@ -1184,7 +1184,7 @@ bool vehicle_initialize(entity this, Vehicle info, bool nodrop) else { this.team = this.vehicle_controller.team; - this.use1 = vehicle_use; + this.use = vehicle_use; if(teamplay) { diff --git a/qcsrc/common/vehicles/vehicle/racer_weapon.qc b/qcsrc/common/vehicles/vehicle/racer_weapon.qc index 65f82459b..36655fd1d 100644 --- a/qcsrc/common/vehicles/vehicle/racer_weapon.qc +++ b/qcsrc/common/vehicles/vehicle/racer_weapon.qc @@ -74,7 +74,7 @@ void racer_rocket_tracker() if (IS_DEAD(self.owner) || self.cnt < time) { - self.use1(self, NULL, NULL); + self.use(self, NULL, NULL); return; } @@ -126,7 +126,7 @@ void racer_rocket_groundhugger() if(IS_DEAD(self.owner) || self.cnt < time) { - self.use1(self, NULL, NULL); + self.use(self, NULL, NULL); return; } diff --git a/qcsrc/common/vehicles/vehicle/spiderbot_weapons.qc b/qcsrc/common/vehicles/vehicle/spiderbot_weapons.qc index caf64c068..dd209676d 100644 --- a/qcsrc/common/vehicles/vehicle/spiderbot_weapons.qc +++ b/qcsrc/common/vehicles/vehicle/spiderbot_weapons.qc @@ -23,7 +23,7 @@ void spiderbot_rocket_unguided() UpdateCSQCProjectile(self); if (IS_DEAD(self.owner) || self.cnt < time || vdist(self.pos1 - self.origin, <, 16)) - self.use1(self, NULL, NULL); + self.use(self, NULL, NULL); } void spiderbot_rocket_guided() @@ -43,7 +43,7 @@ void spiderbot_rocket_guided() UpdateCSQCProjectile(self); if (IS_DEAD(self.owner) || self.cnt < time) - self.use1(self, NULL, NULL); + self.use(self, NULL, NULL); } void spiderbot_guide_release(entity this) diff --git a/qcsrc/common/weapons/weapon/arc.qc b/qcsrc/common/weapons/weapon/arc.qc index 804a24fb7..cf391b034 100644 --- a/qcsrc/common/weapons/weapon/arc.qc +++ b/qcsrc/common/weapons/weapon/arc.qc @@ -262,7 +262,7 @@ void W_Arc_Bolt_Damage(entity this, entity inflictor, entity attacker, float dam void W_Arc_Bolt_Touch() {SELFPARAM(); PROJECTILE_TOUCH; - self.use1(this, NULL, NULL); + self.use(this, NULL, NULL); } void W_Arc_Attack_Bolt(Weapon thiswep) @@ -287,7 +287,7 @@ void W_Arc_Attack_Bolt(Weapon thiswep) missile.damagedbycontents = true; missile.touch = W_Arc_Bolt_Touch; - missile.use1 = W_Arc_Bolt_Explode_use; + missile.use = W_Arc_Bolt_Explode_use; missile.think = adaptor_think2use_hittype_splash; missile.nextthink = time + WEP_CVAR(arc, bolt_lifetime); PROJECTILE_MAKETRIGGER(missile); diff --git a/qcsrc/common/weapons/weapon/electro.qc b/qcsrc/common/weapons/weapon/electro.qc index 71ce3cb94..315ea5a5a 100644 --- a/qcsrc/common/weapons/weapon/electro.qc +++ b/qcsrc/common/weapons/weapon/electro.qc @@ -206,7 +206,7 @@ void W_Electro_Bolt_Think() {SELFPARAM(); if(time >= self.ltime) { - this.use1(this, NULL, NULL); + this.use(this, NULL, NULL); return; } @@ -247,7 +247,7 @@ void W_Electro_Bolt_Think() // if we triggered an orb, should we explode? if not, lets try again next time if(found && WEP_CVAR_PRI(electro, midaircombo_explode)) - { this.use1(this, NULL, NULL); } + { this.use(this, NULL, NULL); } else { self.nextthink = min(time + WEP_CVAR_PRI(electro, midaircombo_interval), self.ltime); } } @@ -277,7 +277,7 @@ void W_Electro_Attack_Bolt(Weapon thiswep) proj.owner = proj.realowner = self; proj.bot_dodge = true; proj.bot_dodgerating = WEP_CVAR_PRI(electro, damage); - proj.use1 = W_Electro_Explode_use; + proj.use = W_Electro_Explode_use; proj.think = W_Electro_Bolt_Think; proj.nextthink = time; proj.ltime = time + WEP_CVAR_PRI(electro, lifetime); @@ -347,7 +347,7 @@ void W_Electro_Orb_Damage(entity this, entity inflictor, entity attacker, float } else { - this.use1 = W_Electro_Explode_use; + this.use = W_Electro_Explode_use; this.think = adaptor_think2use; // not _hittype_splash, as this runs "immediately" } } @@ -374,7 +374,7 @@ void W_Electro_Attack_Orb(Weapon thiswep) entity proj = new(electro_orb); proj.owner = proj.realowner = self; - proj.use1 = W_Electro_Explode_use; + proj.use = W_Electro_Explode_use; proj.think = adaptor_think2use_hittype_splash; proj.bot_dodge = true; proj.bot_dodgerating = WEP_CVAR_SEC(electro, damage); diff --git a/qcsrc/common/weapons/weapon/fireball.qc b/qcsrc/common/weapons/weapon/fireball.qc index a86def7d3..4bbcdb68e 100644 --- a/qcsrc/common/weapons/weapon/fireball.qc +++ b/qcsrc/common/weapons/weapon/fireball.qc @@ -201,7 +201,7 @@ void W_Fireball_Attack1() proj.bot_dodge = true; proj.bot_dodgerating = WEP_CVAR_PRI(fireball, damage); proj.pushltime = time + WEP_CVAR_PRI(fireball, lifetime); - proj.use1 = W_Fireball_Explode_use; + proj.use = W_Fireball_Explode_use; proj.think = W_Fireball_Think; proj.nextthink = time; proj.health = WEP_CVAR_PRI(fireball, health); diff --git a/qcsrc/common/weapons/weapon/hagar.qc b/qcsrc/common/weapons/weapon/hagar.qc index 94d3e5f66..2e648f780 100644 --- a/qcsrc/common/weapons/weapon/hagar.qc +++ b/qcsrc/common/weapons/weapon/hagar.qc @@ -116,7 +116,7 @@ void W_Hagar_Damage(entity this, entity inflictor, entity attacker, float damage void W_Hagar_Touch() {SELFPARAM(); PROJECTILE_TOUCH; - this.use1(this, NULL, NULL); + this.use(this, NULL, NULL); } void W_Hagar_Touch2() @@ -124,7 +124,7 @@ void W_Hagar_Touch2() PROJECTILE_TOUCH; if(self.cnt > 0 || other.takedamage == DAMAGE_AIM) { - this.use1(this, NULL, NULL); + this.use(this, NULL, NULL); } else { self.cnt++; Send_Effect(EFFECT_HAGAR_BOUNCE, self.origin, self.velocity, 1); @@ -156,7 +156,7 @@ void W_Hagar_Attack(Weapon thiswep) missile.damagedbycontents = true; missile.touch = W_Hagar_Touch; - missile.use1 = W_Hagar_Explode_use; + missile.use = W_Hagar_Explode_use; missile.think = adaptor_think2use_hittype_splash; missile.nextthink = time + WEP_CVAR_PRI(hagar, lifetime); PROJECTILE_MAKETRIGGER(missile); @@ -199,7 +199,7 @@ void W_Hagar_Attack2(Weapon thiswep) missile.touch = W_Hagar_Touch2; missile.cnt = 0; - missile.use1 = W_Hagar_Explode2_use; + missile.use = W_Hagar_Explode2_use; missile.think = adaptor_think2use_hittype_splash; missile.nextthink = time + WEP_CVAR_SEC(hagar, lifetime_min) + random() * WEP_CVAR_SEC(hagar, lifetime_rand); PROJECTILE_MAKETRIGGER(missile); @@ -257,7 +257,7 @@ void W_Hagar_Attack2_Load_Release(.entity weaponentity) missile.damagedbycontents = true; missile.touch = W_Hagar_Touch; // not bouncy - missile.use1 = W_Hagar_Explode2_use; + missile.use = W_Hagar_Explode2_use; missile.think = adaptor_think2use_hittype_splash; missile.nextthink = time + WEP_CVAR_SEC(hagar, lifetime_min) + random() * WEP_CVAR_SEC(hagar, lifetime_rand); PROJECTILE_MAKETRIGGER(missile); diff --git a/qcsrc/common/weapons/weapon/hook.qc b/qcsrc/common/weapons/weapon/hook.qc index da14caac9..fac16c487 100644 --- a/qcsrc/common/weapons/weapon/hook.qc +++ b/qcsrc/common/weapons/weapon/hook.qc @@ -140,7 +140,7 @@ void W_Hook_Damage(entity this, entity inflictor, entity attacker, float damage, void W_Hook_Touch2() {SELFPARAM(); PROJECTILE_TOUCH; - this.use1(this, NULL, NULL); + this.use(this, NULL, NULL); } void W_Hook_Attack2(Weapon thiswep, entity actor) @@ -160,7 +160,7 @@ void W_Hook_Attack2(Weapon thiswep, entity actor) gren.nextthink = time + WEP_CVAR_SEC(hook, lifetime); gren.think = adaptor_think2use_hittype_splash; - gren.use1 = W_Hook_Explode2_use; + gren.use = W_Hook_Explode2_use; gren.touch = W_Hook_Touch2; gren.takedamage = DAMAGE_YES; diff --git a/qcsrc/common/weapons/weapon/mortar.qc b/qcsrc/common/weapons/weapon/mortar.qc index f871da725..5fbacc7ba 100644 --- a/qcsrc/common/weapons/weapon/mortar.qc +++ b/qcsrc/common/weapons/weapon/mortar.qc @@ -147,7 +147,7 @@ void W_Mortar_Grenade_Touch1() PROJECTILE_TOUCH; if(other.takedamage == DAMAGE_AIM || WEP_CVAR_PRI(mortar, type) == 0) // always explode when hitting a player, or if normal mortar projectile { - this.use1(this, NULL, NULL); + this.use(this, NULL, NULL); } else if(WEP_CVAR_PRI(mortar, type) == 1) // bounce { @@ -179,7 +179,7 @@ void W_Mortar_Grenade_Touch2() PROJECTILE_TOUCH; if(other.takedamage == DAMAGE_AIM || WEP_CVAR_SEC(mortar, type) == 0) // always explode when hitting a player, or if normal mortar projectile { - this.use1(this, NULL, NULL); + this.use(this, NULL, NULL); } else if(WEP_CVAR_SEC(mortar, type) == 1) // bounce { @@ -236,7 +236,7 @@ void W_Mortar_Attack(Weapon thiswep) gren.cnt = time + WEP_CVAR_PRI(mortar, lifetime); gren.nextthink = time; gren.think = W_Mortar_Grenade_Think1; - gren.use1 = W_Mortar_Grenade_Explode_use; + gren.use = W_Mortar_Grenade_Explode_use; gren.touch = W_Mortar_Grenade_Touch1; gren.takedamage = DAMAGE_YES; @@ -283,7 +283,7 @@ void W_Mortar_Attack2(Weapon thiswep) gren.nextthink = time + WEP_CVAR_SEC(mortar, lifetime); gren.think = adaptor_think2use_hittype_splash; - gren.use1 = W_Mortar_Grenade_Explode2_use; + gren.use = W_Mortar_Grenade_Explode2_use; gren.touch = W_Mortar_Grenade_Touch2; gren.takedamage = DAMAGE_YES; diff --git a/qcsrc/common/weapons/weapon/seeker.qc b/qcsrc/common/weapons/weapon/seeker.qc index 86ea7d1f5..6dffec39d 100644 --- a/qcsrc/common/weapons/weapon/seeker.qc +++ b/qcsrc/common/weapons/weapon/seeker.qc @@ -360,7 +360,7 @@ void W_Seeker_Fire_Flac(Weapon thiswep) missile.bot_dodge = true; missile.bot_dodgerating = WEP_CVAR(seeker, flac_damage); missile.touch = W_Seeker_Flac_Explode; - missile.use1 = W_Seeker_Flac_Explode_use; + missile.use = W_Seeker_Flac_Explode_use; missile.think = adaptor_think2use_hittype_splash; missile.nextthink = time + WEP_CVAR(seeker, flac_lifetime) + WEP_CVAR(seeker, flac_lifetime_rand); missile.solid = SOLID_BBOX; diff --git a/qcsrc/common/weapons/weapon/vaporizer.qc b/qcsrc/common/weapons/weapon/vaporizer.qc index f9cdc00e9..8ce6caadd 100644 --- a/qcsrc/common/weapons/weapon/vaporizer.qc +++ b/qcsrc/common/weapons/weapon/vaporizer.qc @@ -263,7 +263,7 @@ void W_RocketMinsta_Attack2() proj.owner = proj.realowner = self; proj.bot_dodge = true; proj.bot_dodgerating = autocvar_g_rm_laser_damage; - proj.use1 = W_RocketMinsta_Laser_Explode_use; + proj.use = W_RocketMinsta_Laser_Explode_use; proj.think = adaptor_think2use_hittype_splash; proj.nextthink = time + autocvar_g_rm_laser_lifetime; PROJECTILE_MAKETRIGGER(proj); @@ -315,7 +315,7 @@ void W_RocketMinsta_Attack3 () proj.owner = proj.realowner = self; proj.bot_dodge = true; proj.bot_dodgerating = autocvar_g_rm_laser_damage; - proj.use1 = W_RocketMinsta_Laser_Explode_use; + proj.use = W_RocketMinsta_Laser_Explode_use; proj.think = adaptor_think2use_hittype_splash; proj.nextthink = time + autocvar_g_rm_laser_lifetime; PROJECTILE_MAKETRIGGER(proj); diff --git a/qcsrc/dpdefs/csprogsdefs.qh b/qcsrc/dpdefs/csprogsdefs.qh index ce39bca1b..d0125b5e3 100644 --- a/qcsrc/dpdefs/csprogsdefs.qh +++ b/qcsrc/dpdefs/csprogsdefs.qh @@ -41,4 +41,7 @@ #pragma noref 0 +#define use use1 +.void(entity this, entity actor, entity trigger) use; + #endif diff --git a/qcsrc/dpdefs/progsdefs.qh b/qcsrc/dpdefs/progsdefs.qh index 783ac036f..e2668a54b 100644 --- a/qcsrc/dpdefs/progsdefs.qh +++ b/qcsrc/dpdefs/progsdefs.qh @@ -28,4 +28,7 @@ MACRO_END #pragma noref 0 +#define use use1 +.void(entity this, entity actor, entity trigger) use; + #endif diff --git a/qcsrc/lib/warpzone/server.qc b/qcsrc/lib/warpzone/server.qc index d9d4b6222..f8260b5ad 100644 --- a/qcsrc/lib/warpzone/server.qc +++ b/qcsrc/lib/warpzone/server.qc @@ -919,7 +919,7 @@ void trigger_warpzone_reconnect_use(entity this, entity actor, entity trigger) spawnfunc(trigger_warpzone_reconnect) { - this.use1 = trigger_warpzone_reconnect_use; + this.use = trigger_warpzone_reconnect_use; } spawnfunc(target_warpzone_reconnect) diff --git a/qcsrc/server/g_lights.qc b/qcsrc/server/g_lights.qc index 218f21964..352f0be43 100644 --- a/qcsrc/server/g_lights.qc +++ b/qcsrc/server/g_lights.qc @@ -96,7 +96,7 @@ spawnfunc(dynlight) if (!self.color) self.color = '1 1 1'; self.lefty = self.light_lev; - self.use1 = dynlight_use; + self.use = dynlight_use; setsize (self, '0 0 0', '0 0 0'); setorigin (self, self.origin); //self.pflags = PFLAGS_FULLDYNAMIC; diff --git a/qcsrc/server/g_models.qc b/qcsrc/server/g_models.qc index 003b2efa9..6623a0778 100644 --- a/qcsrc/server/g_models.qc +++ b/qcsrc/server/g_models.qc @@ -168,7 +168,7 @@ bool g_clientmodel_genericsendentity(entity this, entity to, int sf) if(self.geomtype) if(autocvar_physics_ode && checkextension("DP_PHYSICS_ODE")) self.movetype = MOVETYPE_PHYSICS; \ if(!self.scale) self.scale = self.modelscale; \ SetBrushEntityModel(); \ - self.use1 = g_model_setcolormaptoactivator; \ + self.use = g_model_setcolormaptoactivator; \ InitializeEntity(self, g_model_dropbyspawnflags, INITPRIO_DROPTOFLOOR); \ if(!self.solid) self.solid = (sol); else if(self.solid < 0) self.solid = SOLID_NOT; @@ -176,7 +176,7 @@ bool g_clientmodel_genericsendentity(entity this, entity to, int sf) if(self.geomtype) if(autocvar_physics_ode && checkextension("DP_PHYSICS_ODE")) self.movetype = MOVETYPE_PHYSICS; \ if(!self.scale) self.scale = self.modelscale; \ SetBrushEntityModel(); \ - self.use1 = g_clientmodel_use; \ + self.use = g_clientmodel_use; \ InitializeEntity(self, g_clientmodel_dropbyspawnflags, INITPRIO_DROPTOFLOOR); \ if(!self.solid) self.solid = (sol); else if(self.solid < 0) self.solid = SOLID_NOT; \ if(!self.bgmscriptsustain) self.bgmscriptsustain = 1; else if(self.bgmscriptsustain < 0) self.bgmscriptsustain = 0; \ diff --git a/qcsrc/server/miscfunctions.qc b/qcsrc/server/miscfunctions.qc index ab3c204a3..9b5a279d5 100644 --- a/qcsrc/server/miscfunctions.qc +++ b/qcsrc/server/miscfunctions.qc @@ -969,8 +969,8 @@ void adaptor_think2touch() void adaptor_think2use() {SELFPARAM(); - if(this.use1) - this.use1(this, NULL, NULL); + if(this.use) + this.use(this, NULL, NULL); } void adaptor_think2use_hittype_splash() // for timed projectile detonation diff --git a/qcsrc/server/mutators/mutator/gamemode_assault.qc b/qcsrc/server/mutators/mutator/gamemode_assault.qc index cb6d55829..7d2b31c89 100644 --- a/qcsrc/server/mutators/mutator/gamemode_assault.qc +++ b/qcsrc/server/mutators/mutator/gamemode_assault.qc @@ -361,7 +361,7 @@ spawnfunc(target_objective) if (!g_assault) { remove(this); return; } this.classname = "target_objective"; - this.use1 = assault_objective_use; + this.use = assault_objective_use; this.reset = assault_objective_reset; this.reset(this); this.spawn_evalfunc = target_objective_spawn_evalfunc; @@ -376,7 +376,7 @@ spawnfunc(target_objective_decrease) if(!self.dmg) self.dmg = 101; - self.use1 = assault_objective_decrease_use; + self.use = assault_objective_decrease_use; self.health = ASSAULT_VALUE_INACTIVE; self.max_health = ASSAULT_VALUE_INACTIVE; self.enemy = world; @@ -420,7 +420,7 @@ spawnfunc(target_assault_roundend) self.winning = 0; // round not yet won by attackers self.classname = "target_assault_roundend"; - self.use1 = target_assault_roundend_use; + self.use = target_assault_roundend_use; self.cnt = 0; // first round self.reset = target_assault_roundend_reset; } @@ -431,7 +431,7 @@ spawnfunc(target_assault_roundstart) assault_attacker_team = NUM_TEAM_1; self.classname = "target_assault_roundstart"; - self.use1 = assault_roundstart_use; + self.use = assault_roundstart_use; self.reset2 = assault_roundstart_use_self; InitializeEntity(self, assault_roundstart_use_this, INITPRIO_FINDTARGET); } diff --git a/qcsrc/server/race.qc b/qcsrc/server/race.qc index 5a023a1dc..d24a0769b 100644 --- a/qcsrc/server/race.qc +++ b/qcsrc/server/race.qc @@ -912,7 +912,7 @@ spawnfunc(trigger_race_checkpoint) EXACTTRIGGER_INIT; - self.use1 = checkpoint_use; + self.use = checkpoint_use; if (!(self.spawnflags & 1)) self.touch = checkpoint_touch; @@ -961,7 +961,7 @@ spawnfunc(target_checkpoint) // defrag entity EXACTTRIGGER_INIT; - self.use1 = checkpoint_use; + self.use = checkpoint_use; if (!(self.spawnflags & 1)) self.touch = checkpoint_touch; @@ -1117,7 +1117,7 @@ spawnfunc(trigger_race_penalty) EXACTTRIGGER_INIT; - self.use1 = penalty_use; + self.use = penalty_use; if (!(self.spawnflags & 1)) self.touch = penalty_touch; diff --git a/qcsrc/server/spawnpoints.qc b/qcsrc/server/spawnpoints.qc index 31e941ad4..711b15df5 100644 --- a/qcsrc/server/spawnpoints.qc +++ b/qcsrc/server/spawnpoints.qc @@ -102,7 +102,7 @@ void relocate_spawnpoint() } } - self.use1 = spawnpoint_use; + self.use = spawnpoint_use; self.think = spawnpoint_think; self.nextthink = time + 0.5 + random() * 2; // shouldn't need it for a little second self.team_saved = self.team;