From: Lyberta Date: Mon, 16 Oct 2017 11:00:29 +0000 (+0300) Subject: Renamed item_invincible to item_shield. X-Git-Tag: xonotic-v0.8.5~2426^2~19 X-Git-Url: https://git.rm.cloudns.org/?a=commitdiff_plain;h=129ec3b8db6102b5017f368af9df1b8b35f2cef2;p=xonotic%2Fxonotic-data.pk3dir.git Renamed item_invincible to item_shield. --- diff --git a/qcsrc/common/items/item/powerup.qh b/qcsrc/common/items/item/powerup.qh index fa14bdaf6..787a7c946 100644 --- a/qcsrc/common/items/item/powerup.qh +++ b/qcsrc/common/items/item/powerup.qh @@ -66,7 +66,7 @@ void powerup_shield_init(entity item) } #endif REGISTER_ITEM(Shield, Powerup) { - this.m_canonical_spawnfunc = "item_invincible"; + this.m_canonical_spawnfunc = "item_shield"; #ifdef GAMEQC this.m_model = MDL_Shield_ITEM; this.m_sound = SND_Shield; @@ -85,4 +85,5 @@ REGISTER_ITEM(Shield, Powerup) { #endif } +SPAWNFUNC_ITEM(item_shield, ITEM_Shield) SPAWNFUNC_ITEM(item_invincible, ITEM_Shield) diff --git a/qcsrc/common/mutators/mutator/buffs/sv_buffs.qc b/qcsrc/common/mutators/mutator/buffs/sv_buffs.qc index e039a96b9..6994c8176 100644 --- a/qcsrc/common/mutators/mutator/buffs/sv_buffs.qc +++ b/qcsrc/common/mutators/mutator/buffs/sv_buffs.qc @@ -750,7 +750,7 @@ MUTATOR_HOOKFUNCTION(buffs, OnEntityPreSpawn, CBC_ORDER_LAST) switch(ent.classname) { case "item_strength": - case "item_invincible": + case "item_shield": { entity e = spawn(); buff_SpawnReplacement(e, ent); diff --git a/qcsrc/common/mutators/mutator/instagib/sv_instagib.qc b/qcsrc/common/mutators/mutator/instagib/sv_instagib.qc index a81b4e795..c21623f0e 100644 --- a/qcsrc/common/mutators/mutator/instagib/sv_instagib.qc +++ b/qcsrc/common/mutators/mutator/instagib/sv_instagib.qc @@ -512,7 +512,7 @@ MUTATOR_HOOKFUNCTION(mutator_instagib, OnEntityPreSpawn) if (!autocvar_g_powerups) { return; } entity ent = M_ARGV(0, entity); // Can't use .itemdef here - if (!(ent.classname == "item_strength" || ent.classname == "item_invincible" || ent.classname == "item_health_mega")) + if (!(ent.classname == "item_strength" || ent.classname == "item_shield" || ent.classname == "item_health_mega")) return; entity e = spawn(); diff --git a/qcsrc/common/mutators/mutator/overkill/sv_overkill.qc b/qcsrc/common/mutators/mutator/overkill/sv_overkill.qc index 6b32ec352..120fabe56 100644 --- a/qcsrc/common/mutators/mutator/overkill/sv_overkill.qc +++ b/qcsrc/common/mutators/mutator/overkill/sv_overkill.qc @@ -193,7 +193,7 @@ MUTATOR_HOOKFUNCTION(ok, OnEntityPreSpawn) wep.nextthink = time + 0.1; return true; } - else if(ent.classname == "item_invincible") + else if(ent.classname == "item_shield") { entity wep = new(weapon_rpc); setorigin(wep, ent.origin); diff --git a/qcsrc/common/mutators/mutator/random_items/sv_random_items.qc b/qcsrc/common/mutators/mutator/random_items/sv_random_items.qc index 0c86c72ab..ad0d49c2c 100644 --- a/qcsrc/common/mutators/mutator/random_items/sv_random_items.qc +++ b/qcsrc/common/mutators/mutator/random_items/sv_random_items.qc @@ -112,7 +112,7 @@ string RandomItems_GetItemVarName(string class_name) X(item_fuel); X(item_strength); - case "item_invincible" : return "item_shield"; + X(item_shield); X(item_fuel_regen); X(item_jetpack); @@ -272,7 +272,7 @@ string RandomItems_GetRandomMapItemClassName() 1 \ ) X("item_strength"); - X("item_invincible"); + X("item_shield"); X("item_fuel_regen"); X("item_jetpack"); #undef X @@ -497,7 +497,7 @@ string RandomItems_GetRandomLootItemClassName() 1 \ ) X("item_strength"); - X("item_invincible"); + X("item_shield"); X("item_jetpack"); X("item_fuel_regen"); #undef X