From f649e0568d317ee84e695b96a23e56b80486864d Mon Sep 17 00:00:00 2001 From: Lyberta Date: Wed, 25 Apr 2018 01:04:17 +0300 Subject: [PATCH] Renamed rpc to okrpc. --- bal-wep-mario.cfg | 57 +++-- bal-wep-nexuiz25.cfg | 57 +++-- bal-wep-overkill.cfg | 57 +++-- bal-wep-samual.cfg | 57 +++-- bal-wep-xdf.cfg | 57 +++-- bal-wep-xonotic.cfg | 70 +++--- bal-wep-xpm.cfg | 57 +++-- .../common/mutators/mutator/overkill/_mod.inc | 2 +- .../common/mutators/mutator/overkill/_mod.qh | 2 +- .../common/mutators/mutator/overkill/okrpc.qc | 219 ++++++++++++++++++ .../mutator/overkill/{rpc.qh => okrpc.qh} | 37 +-- qcsrc/common/mutators/mutator/overkill/rpc.qc | 219 ------------------ .../mutators/mutator/overkill/sv_overkill.qc | 14 +- .../mutator/random_items/sv_random_items.qc | 4 +- qcsrc/common/notifications/all.inc | 17 +- randomitems-xonotic.cfg | 6 +- 16 files changed, 506 insertions(+), 426 deletions(-) create mode 100644 qcsrc/common/mutators/mutator/overkill/okrpc.qc rename qcsrc/common/mutators/mutator/overkill/{rpc.qh => okrpc.qh} (50%) delete mode 100644 qcsrc/common/mutators/mutator/overkill/rpc.qc diff --git a/bal-wep-mario.cfg b/bal-wep-mario.cfg index 37ad0b459..94579c398 100644 --- a/bal-wep-mario.cfg +++ b/bal-wep-mario.cfg @@ -809,26 +809,39 @@ set g_balance_okhmg_weaponstart 0 set g_balance_okhmg_weaponstartoverride 0 set g_balance_okhmg_weaponthrowable 0 // }}} -// {{{ #22: Rocket Propelled Chainsaw -set g_balance_rpc_ammo 10 -set g_balance_rpc_animtime 1 -set g_balance_rpc_damage 150 -set g_balance_rpc_damage2 500 -set g_balance_rpc_damageforcescale 2 -set g_balance_rpc_edgedamage 50 -set g_balance_rpc_force 400 -set g_balance_rpc_health 25 -set g_balance_rpc_lifetime 30 -set g_balance_rpc_radius 300 -set g_balance_rpc_refire 1 -set g_balance_rpc_reload_ammo 10 -set g_balance_rpc_reload_time 1 -set g_balance_rpc_speed 2500 -set g_balance_rpc_speedaccel 5000 -set g_balance_rpc_switchdelay_drop 0.2 -set g_balance_rpc_switchdelay_raise 0.2 -set g_balance_rpc_weaponreplace "" -set g_balance_rpc_weaponstart 0 -set g_balance_rpc_weaponstartoverride 0 -set g_balance_rpc_weaponthrowable 0 +// {{{ #22: Overkill Rocket Propelled Chainsaw +set g_balance_okrpc_primary_ammo 10 +set g_balance_okrpc_primary_animtime 1 +set g_balance_okrpc_primary_damage 150 +set g_balance_okrpc_primary_damage2 500 +set g_balance_okrpc_primary_damageforcescale 2 +set g_balance_okrpc_primary_edgedamage 50 +set g_balance_okrpc_primary_force 400 +set g_balance_okrpc_primary_health 25 +set g_balance_okrpc_primary_lifetime 30 +set g_balance_okrpc_primary_radius 300 +set g_balance_okrpc_primary_refire 1 +set g_balance_okrpc_primary_speed 2500 +set g_balance_okrpc_primary_speedaccel 5000 +set g_balance_okrpc_reload_ammo 10 +set g_balance_okrpc_reload_time 1 +set g_balance_okrpc_secondary_ammo 0 +set g_balance_okrpc_secondary_animtime 0.2 +set g_balance_okrpc_secondary_damage 25 +set g_balance_okrpc_secondary_delay 0 +set g_balance_okrpc_secondary_edgedamage 12.5 +set g_balance_okrpc_secondary_force 300 +set g_balance_okrpc_secondary_lifetime 5 +set g_balance_okrpc_secondary_radius 70 +set g_balance_okrpc_secondary_refire 0.7 +set g_balance_okrpc_secondary_refire_type 1 +set g_balance_okrpc_secondary_shotangle 0 +set g_balance_okrpc_secondary_speed 6000 +set g_balance_okrpc_secondary_spread 0 +set g_balance_okrpc_switchdelay_drop 0.2 +set g_balance_okrpc_switchdelay_raise 0.2 +set g_balance_okrpc_weaponreplace "" +set g_balance_okrpc_weaponstart 0 +set g_balance_okrpc_weaponstartoverride 0 +set g_balance_okrpc_weaponthrowable 0 // }}} diff --git a/bal-wep-nexuiz25.cfg b/bal-wep-nexuiz25.cfg index 554d5ea84..c7935e0e3 100644 --- a/bal-wep-nexuiz25.cfg +++ b/bal-wep-nexuiz25.cfg @@ -809,26 +809,39 @@ set g_balance_okhmg_weaponstart 0 set g_balance_okhmg_weaponstartoverride 0 set g_balance_okhmg_weaponthrowable 0 // }}} -// {{{ #22: Rocket Propelled Chainsaw -set g_balance_rpc_ammo 10 -set g_balance_rpc_animtime 1 -set g_balance_rpc_damage 150 -set g_balance_rpc_damage2 500 -set g_balance_rpc_damageforcescale 2 -set g_balance_rpc_edgedamage 50 -set g_balance_rpc_force 400 -set g_balance_rpc_health 25 -set g_balance_rpc_lifetime 30 -set g_balance_rpc_radius 300 -set g_balance_rpc_refire 1 -set g_balance_rpc_reload_ammo 10 -set g_balance_rpc_reload_time 1 -set g_balance_rpc_speed 2500 -set g_balance_rpc_speedaccel 5000 -set g_balance_rpc_switchdelay_drop 0.2 -set g_balance_rpc_switchdelay_raise 0.2 -set g_balance_rpc_weaponreplace "" -set g_balance_rpc_weaponstart 0 -set g_balance_rpc_weaponstartoverride 0 -set g_balance_rpc_weaponthrowable 0 +// {{{ #22: Overkill Rocket Propelled Chainsaw +set g_balance_okrpc_primary_ammo 10 +set g_balance_okrpc_primary_animtime 1 +set g_balance_okrpc_primary_damage 150 +set g_balance_okrpc_primary_damage2 500 +set g_balance_okrpc_primary_damageforcescale 2 +set g_balance_okrpc_primary_edgedamage 50 +set g_balance_okrpc_primary_force 400 +set g_balance_okrpc_primary_health 25 +set g_balance_okrpc_primary_lifetime 30 +set g_balance_okrpc_primary_radius 300 +set g_balance_okrpc_primary_refire 1 +set g_balance_okrpc_primary_speed 2500 +set g_balance_okrpc_primary_speedaccel 5000 +set g_balance_okrpc_reload_ammo 10 +set g_balance_okrpc_reload_time 1 +set g_balance_okrpc_secondary_ammo 0 +set g_balance_okrpc_secondary_animtime 0.2 +set g_balance_okrpc_secondary_damage 25 +set g_balance_okrpc_secondary_delay 0 +set g_balance_okrpc_secondary_edgedamage 12.5 +set g_balance_okrpc_secondary_force 300 +set g_balance_okrpc_secondary_lifetime 5 +set g_balance_okrpc_secondary_radius 70 +set g_balance_okrpc_secondary_refire 0.7 +set g_balance_okrpc_secondary_refire_type 1 +set g_balance_okrpc_secondary_shotangle 0 +set g_balance_okrpc_secondary_speed 6000 +set g_balance_okrpc_secondary_spread 0 +set g_balance_okrpc_switchdelay_drop 0.2 +set g_balance_okrpc_switchdelay_raise 0.2 +set g_balance_okrpc_weaponreplace "" +set g_balance_okrpc_weaponstart 0 +set g_balance_okrpc_weaponstartoverride 0 +set g_balance_okrpc_weaponthrowable 0 // }}} diff --git a/bal-wep-overkill.cfg b/bal-wep-overkill.cfg index 2564e700c..d62ab3b82 100644 --- a/bal-wep-overkill.cfg +++ b/bal-wep-overkill.cfg @@ -809,28 +809,41 @@ set g_balance_okhmg_weaponstart 0 set g_balance_okhmg_weaponstartoverride 0 set g_balance_okhmg_weaponthrowable 0 // }}} -// {{{ #22: Rocket Propelled Chainsaw -set g_balance_rpc_primary_ammo 10 -set g_balance_rpc_primary_animtime 1 -set g_balance_rpc_primary_damage 150 -set g_balance_rpc_primary_damage2 500 -set g_balance_rpc_primary_damageforcescale 2 -set g_balance_rpc_primary_edgedamage 50 -set g_balance_rpc_primary_force 400 -set g_balance_rpc_primary_health 25 -set g_balance_rpc_primary_lifetime 30 -set g_balance_rpc_primary_radius 300 -set g_balance_rpc_primary_refire 1 -set g_balance_rpc_primary_speed 2500 -set g_balance_rpc_primary_speedaccel 5000 -set g_balance_rpc_reload_ammo 10 -set g_balance_rpc_reload_time 1 -set g_balance_rpc_switchdelay_drop 0.2 -set g_balance_rpc_switchdelay_raise 0.2 -set g_balance_rpc_weaponreplace "" -set g_balance_rpc_weaponstart 0 -set g_balance_rpc_weaponstartoverride 0 -set g_balance_rpc_weaponthrowable 0 +// {{{ #22: Overkill Rocket Propelled Chainsaw +set g_balance_okrpc_primary_ammo 10 +set g_balance_okrpc_primary_animtime 1 +set g_balance_okrpc_primary_damage 150 +set g_balance_okrpc_primary_damage2 500 +set g_balance_okrpc_primary_damageforcescale 2 +set g_balance_okrpc_primary_edgedamage 50 +set g_balance_okrpc_primary_force 400 +set g_balance_okrpc_primary_health 25 +set g_balance_okrpc_primary_lifetime 30 +set g_balance_okrpc_primary_radius 300 +set g_balance_okrpc_primary_refire 1 +set g_balance_okrpc_primary_speed 2500 +set g_balance_okrpc_primary_speedaccel 5000 +set g_balance_okrpc_reload_ammo 10 +set g_balance_okrpc_reload_time 1 +set g_balance_okrpc_secondary_ammo 0 +set g_balance_okrpc_secondary_animtime 0.2 +set g_balance_okrpc_secondary_damage 25 +set g_balance_okrpc_secondary_delay 0 +set g_balance_okrpc_secondary_edgedamage 12.5 +set g_balance_okrpc_secondary_force 300 +set g_balance_okrpc_secondary_lifetime 5 +set g_balance_okrpc_secondary_radius 70 +set g_balance_okrpc_secondary_refire 0.7 +set g_balance_okrpc_secondary_refire_type 1 +set g_balance_okrpc_secondary_shotangle 0 +set g_balance_okrpc_secondary_speed 6000 +set g_balance_okrpc_secondary_spread 0 +set g_balance_okrpc_switchdelay_drop 0.2 +set g_balance_okrpc_switchdelay_raise 0.2 +set g_balance_okrpc_weaponreplace "" +set g_balance_okrpc_weaponstart 0 +set g_balance_okrpc_weaponstartoverride 0 +set g_balance_okrpc_weaponthrowable 0 // }}} // {{{ Overkill Shotgun set g_balance_okshotgun_primary_ammo 3 diff --git a/bal-wep-samual.cfg b/bal-wep-samual.cfg index 9fa51afb7..f5becd0df 100644 --- a/bal-wep-samual.cfg +++ b/bal-wep-samual.cfg @@ -807,26 +807,39 @@ set g_balance_okhmg_weaponstart 0 set g_balance_okhmg_weaponstartoverride 0 set g_balance_okhmg_weaponthrowable 0 // }}} -// {{{ #22: Rocket Propelled Chainsaw -set g_balance_rpc_ammo 10 -set g_balance_rpc_animtime 1 -set g_balance_rpc_damage 150 -set g_balance_rpc_damage2 500 -set g_balance_rpc_damageforcescale 2 -set g_balance_rpc_edgedamage 50 -set g_balance_rpc_force 400 -set g_balance_rpc_health 25 -set g_balance_rpc_lifetime 30 -set g_balance_rpc_radius 300 -set g_balance_rpc_refire 1 -set g_balance_rpc_reload_ammo 10 -set g_balance_rpc_reload_time 1 -set g_balance_rpc_speed 2500 -set g_balance_rpc_speedaccel 5000 -set g_balance_rpc_switchdelay_drop 0.2 -set g_balance_rpc_switchdelay_raise 0.2 -set g_balance_rpc_weaponreplace "" -set g_balance_rpc_weaponstart 0 -set g_balance_rpc_weaponstartoverride 0 -set g_balance_rpc_weaponthrowable 0 +// {{{ #22: Overkill Rocket Propelled Chainsaw +set g_balance_okrpc_primary_ammo 10 +set g_balance_okrpc_primary_animtime 1 +set g_balance_okrpc_primary_damage 150 +set g_balance_okrpc_primary_damage2 500 +set g_balance_okrpc_primary_damageforcescale 2 +set g_balance_okrpc_primary_edgedamage 50 +set g_balance_okrpc_primary_force 400 +set g_balance_okrpc_primary_health 25 +set g_balance_okrpc_primary_lifetime 30 +set g_balance_okrpc_primary_radius 300 +set g_balance_okrpc_primary_refire 1 +set g_balance_okrpc_primary_speed 2500 +set g_balance_okrpc_primary_speedaccel 5000 +set g_balance_okrpc_reload_ammo 10 +set g_balance_okrpc_reload_time 1 +set g_balance_okrpc_secondary_ammo 0 +set g_balance_okrpc_secondary_animtime 0.2 +set g_balance_okrpc_secondary_damage 25 +set g_balance_okrpc_secondary_delay 0 +set g_balance_okrpc_secondary_edgedamage 12.5 +set g_balance_okrpc_secondary_force 300 +set g_balance_okrpc_secondary_lifetime 5 +set g_balance_okrpc_secondary_radius 70 +set g_balance_okrpc_secondary_refire 0.7 +set g_balance_okrpc_secondary_refire_type 1 +set g_balance_okrpc_secondary_shotangle 0 +set g_balance_okrpc_secondary_speed 6000 +set g_balance_okrpc_secondary_spread 0 +set g_balance_okrpc_switchdelay_drop 0.2 +set g_balance_okrpc_switchdelay_raise 0.2 +set g_balance_okrpc_weaponreplace "" +set g_balance_okrpc_weaponstart 0 +set g_balance_okrpc_weaponstartoverride 0 +set g_balance_okrpc_weaponthrowable 0 // }}} diff --git a/bal-wep-xdf.cfg b/bal-wep-xdf.cfg index 7e5a465ba..ebf1a91b5 100644 --- a/bal-wep-xdf.cfg +++ b/bal-wep-xdf.cfg @@ -809,26 +809,39 @@ set g_balance_okhmg_weaponstart 0 set g_balance_okhmg_weaponstartoverride 0 set g_balance_okhmg_weaponthrowable 0 // }}} -// {{{ #22: Rocket Propelled Chainsaw -set g_balance_rpc_ammo 10 -set g_balance_rpc_animtime 1 -set g_balance_rpc_damage 150 -set g_balance_rpc_damage2 500 -set g_balance_rpc_damageforcescale 2 -set g_balance_rpc_edgedamage 50 -set g_balance_rpc_force 400 -set g_balance_rpc_health 25 -set g_balance_rpc_lifetime 30 -set g_balance_rpc_radius 300 -set g_balance_rpc_refire 1 -set g_balance_rpc_reload_ammo 10 -set g_balance_rpc_reload_time 1 -set g_balance_rpc_speed 2500 -set g_balance_rpc_speedaccel 5000 -set g_balance_rpc_switchdelay_drop 0.2 -set g_balance_rpc_switchdelay_raise 0.2 -set g_balance_rpc_weaponreplace "" -set g_balance_rpc_weaponstart 0 -set g_balance_rpc_weaponstartoverride 0 -set g_balance_rpc_weaponthrowable 0 +// {{{ #22: Overkill Rocket Propelled Chainsaw +set g_balance_okrpc_primary_ammo 10 +set g_balance_okrpc_primary_animtime 1 +set g_balance_okrpc_primary_damage 150 +set g_balance_okrpc_primary_damage2 500 +set g_balance_okrpc_primary_damageforcescale 2 +set g_balance_okrpc_primary_edgedamage 50 +set g_balance_okrpc_primary_force 400 +set g_balance_okrpc_primary_health 25 +set g_balance_okrpc_primary_lifetime 30 +set g_balance_okrpc_primary_radius 300 +set g_balance_okrpc_primary_refire 1 +set g_balance_okrpc_primary_speed 2500 +set g_balance_okrpc_primary_speedaccel 5000 +set g_balance_okrpc_reload_ammo 10 +set g_balance_okrpc_reload_time 1 +set g_balance_okrpc_secondary_ammo 0 +set g_balance_okrpc_secondary_animtime 0.2 +set g_balance_okrpc_secondary_damage 25 +set g_balance_okrpc_secondary_delay 0 +set g_balance_okrpc_secondary_edgedamage 12.5 +set g_balance_okrpc_secondary_force 300 +set g_balance_okrpc_secondary_lifetime 5 +set g_balance_okrpc_secondary_radius 70 +set g_balance_okrpc_secondary_refire 0.7 +set g_balance_okrpc_secondary_refire_type 1 +set g_balance_okrpc_secondary_shotangle 0 +set g_balance_okrpc_secondary_speed 6000 +set g_balance_okrpc_secondary_spread 0 +set g_balance_okrpc_switchdelay_drop 0.2 +set g_balance_okrpc_switchdelay_raise 0.2 +set g_balance_okrpc_weaponreplace "" +set g_balance_okrpc_weaponstart 0 +set g_balance_okrpc_weaponstartoverride 0 +set g_balance_okrpc_weaponthrowable 0 // }}} diff --git a/bal-wep-xonotic.cfg b/bal-wep-xonotic.cfg index 217705cd5..dd4b9af17 100644 --- a/bal-wep-xonotic.cfg +++ b/bal-wep-xonotic.cfg @@ -809,41 +809,41 @@ set g_balance_okhmg_weaponstart 0 set g_balance_okhmg_weaponstartoverride 0 set g_balance_okhmg_weaponthrowable 0 // }}} -// {{{ #22: Rocket Propelled Chainsaw -set g_balance_rpc_primary_ammo 10 -set g_balance_rpc_primary_animtime 1 -set g_balance_rpc_primary_damage 150 -set g_balance_rpc_primary_damage2 500 -set g_balance_rpc_primary_damageforcescale 2 -set g_balance_rpc_primary_edgedamage 50 -set g_balance_rpc_primary_force 400 -set g_balance_rpc_primary_health 25 -set g_balance_rpc_primary_lifetime 30 -set g_balance_rpc_primary_radius 300 -set g_balance_rpc_primary_refire 1 -set g_balance_rpc_primary_speed 2500 -set g_balance_rpc_primary_speedaccel 5000 -set g_balance_rpc_reload_ammo 10 -set g_balance_rpc_reload_time 1 -set g_balance_rpc_secondary_ammo 0 -set g_balance_rpc_secondary_animtime 0.2 -set g_balance_rpc_secondary_damage 25 -set g_balance_rpc_secondary_delay 0 -set g_balance_rpc_secondary_edgedamage 12.5 -set g_balance_rpc_secondary_force 300 -set g_balance_rpc_secondary_lifetime 5 -set g_balance_rpc_secondary_radius 70 -set g_balance_rpc_secondary_refire 0.7 -set g_balance_rpc_secondary_refire_type 1 -set g_balance_rpc_secondary_shotangle 0 -set g_balance_rpc_secondary_speed 6000 -set g_balance_rpc_secondary_spread 0 -set g_balance_rpc_switchdelay_drop 0.2 -set g_balance_rpc_switchdelay_raise 0.2 -set g_balance_rpc_weaponreplace "" -set g_balance_rpc_weaponstart 0 -set g_balance_rpc_weaponstartoverride 0 -set g_balance_rpc_weaponthrowable 0 +// {{{ #22: Overkill Rocket Propelled Chainsaw +set g_balance_okrpc_primary_ammo 10 +set g_balance_okrpc_primary_animtime 1 +set g_balance_okrpc_primary_damage 150 +set g_balance_okrpc_primary_damage2 500 +set g_balance_okrpc_primary_damageforcescale 2 +set g_balance_okrpc_primary_edgedamage 50 +set g_balance_okrpc_primary_force 400 +set g_balance_okrpc_primary_health 25 +set g_balance_okrpc_primary_lifetime 30 +set g_balance_okrpc_primary_radius 300 +set g_balance_okrpc_primary_refire 1 +set g_balance_okrpc_primary_speed 2500 +set g_balance_okrpc_primary_speedaccel 5000 +set g_balance_okrpc_reload_ammo 10 +set g_balance_okrpc_reload_time 1 +set g_balance_okrpc_secondary_ammo 0 +set g_balance_okrpc_secondary_animtime 0.2 +set g_balance_okrpc_secondary_damage 25 +set g_balance_okrpc_secondary_delay 0 +set g_balance_okrpc_secondary_edgedamage 12.5 +set g_balance_okrpc_secondary_force 300 +set g_balance_okrpc_secondary_lifetime 5 +set g_balance_okrpc_secondary_radius 70 +set g_balance_okrpc_secondary_refire 0.7 +set g_balance_okrpc_secondary_refire_type 1 +set g_balance_okrpc_secondary_shotangle 0 +set g_balance_okrpc_secondary_speed 6000 +set g_balance_okrpc_secondary_spread 0 +set g_balance_okrpc_switchdelay_drop 0.2 +set g_balance_okrpc_switchdelay_raise 0.2 +set g_balance_okrpc_weaponreplace "" +set g_balance_okrpc_weaponstart 0 +set g_balance_okrpc_weaponstartoverride 0 +set g_balance_okrpc_weaponthrowable 0 // }}} // {{{ Overkill Shotgun set g_balance_okshotgun_primary_ammo 3 diff --git a/bal-wep-xpm.cfg b/bal-wep-xpm.cfg index e0b3e2833..03e003c12 100644 --- a/bal-wep-xpm.cfg +++ b/bal-wep-xpm.cfg @@ -809,26 +809,39 @@ set g_balance_okhmg_weaponstart 0 set g_balance_okhmg_weaponstartoverride 0 set g_balance_okhmg_weaponthrowable 0 // }}} -// {{{ #22: Rocket Propelled Chainsaw -set g_balance_rpc_ammo 10 -set g_balance_rpc_animtime 1 -set g_balance_rpc_damage 150 -set g_balance_rpc_damage2 500 -set g_balance_rpc_damageforcescale 2 -set g_balance_rpc_edgedamage 50 -set g_balance_rpc_force 400 -set g_balance_rpc_health 25 -set g_balance_rpc_lifetime 30 -set g_balance_rpc_radius 300 -set g_balance_rpc_refire 1 -set g_balance_rpc_reload_ammo 10 -set g_balance_rpc_reload_time 1 -set g_balance_rpc_speed 2500 -set g_balance_rpc_speedaccel 5000 -set g_balance_rpc_switchdelay_drop 0.2 -set g_balance_rpc_switchdelay_raise 0.2 -set g_balance_rpc_weaponreplace "" -set g_balance_rpc_weaponstart 0 -set g_balance_rpc_weaponstartoverride 0 -set g_balance_rpc_weaponthrowable 0 +// {{{ #22: Overkill Rocket Propelled Chainsaw +set g_balance_okrpc_primary_ammo 10 +set g_balance_okrpc_primary_animtime 1 +set g_balance_okrpc_primary_damage 150 +set g_balance_okrpc_primary_damage2 500 +set g_balance_okrpc_primary_damageforcescale 2 +set g_balance_okrpc_primary_edgedamage 50 +set g_balance_okrpc_primary_force 400 +set g_balance_okrpc_primary_health 25 +set g_balance_okrpc_primary_lifetime 30 +set g_balance_okrpc_primary_radius 300 +set g_balance_okrpc_primary_refire 1 +set g_balance_okrpc_primary_speed 2500 +set g_balance_okrpc_primary_speedaccel 5000 +set g_balance_okrpc_reload_ammo 10 +set g_balance_okrpc_reload_time 1 +set g_balance_okrpc_secondary_ammo 0 +set g_balance_okrpc_secondary_animtime 0.2 +set g_balance_okrpc_secondary_damage 25 +set g_balance_okrpc_secondary_delay 0 +set g_balance_okrpc_secondary_edgedamage 12.5 +set g_balance_okrpc_secondary_force 300 +set g_balance_okrpc_secondary_lifetime 5 +set g_balance_okrpc_secondary_radius 70 +set g_balance_okrpc_secondary_refire 0.7 +set g_balance_okrpc_secondary_refire_type 1 +set g_balance_okrpc_secondary_shotangle 0 +set g_balance_okrpc_secondary_speed 6000 +set g_balance_okrpc_secondary_spread 0 +set g_balance_okrpc_switchdelay_drop 0.2 +set g_balance_okrpc_switchdelay_raise 0.2 +set g_balance_okrpc_weaponreplace "" +set g_balance_okrpc_weaponstart 0 +set g_balance_okrpc_weaponstartoverride 0 +set g_balance_okrpc_weaponthrowable 0 // }}} diff --git a/qcsrc/common/mutators/mutator/overkill/_mod.inc b/qcsrc/common/mutators/mutator/overkill/_mod.inc index 959902fd9..57fb6c246 100644 --- a/qcsrc/common/mutators/mutator/overkill/_mod.inc +++ b/qcsrc/common/mutators/mutator/overkill/_mod.inc @@ -8,5 +8,5 @@ #include #include #include +#include #include -#include diff --git a/qcsrc/common/mutators/mutator/overkill/_mod.qh b/qcsrc/common/mutators/mutator/overkill/_mod.qh index afe93c9f0..7731f17e1 100644 --- a/qcsrc/common/mutators/mutator/overkill/_mod.qh +++ b/qcsrc/common/mutators/mutator/overkill/_mod.qh @@ -8,5 +8,5 @@ #include #include #include +#include #include -#include diff --git a/qcsrc/common/mutators/mutator/overkill/okrpc.qc b/qcsrc/common/mutators/mutator/overkill/okrpc.qc new file mode 100644 index 000000000..c06ca5b78 --- /dev/null +++ b/qcsrc/common/mutators/mutator/overkill/okrpc.qc @@ -0,0 +1,219 @@ +#include "okrpc.qh" + +#ifdef SVQC + +void W_OverkillRocketPropelledChainsaw_Explode(entity this, entity directhitentity) +{ + this.event_damage = func_null; + this.takedamage = DAMAGE_NO; + + RadiusDamage(this, this.realowner, WEP_CVAR_PRI(okrpc, damage), WEP_CVAR_PRI(okrpc, edgedamage), WEP_CVAR_PRI(okrpc, radius), NULL, NULL, WEP_CVAR_PRI(okrpc, force), this.projectiledeathtype, this.weaponentity_fld, directhitentity); + + delete(this); +} + +void W_OverkillRocketPropelledChainsaw_Explode_think(entity this) +{ + W_OverkillRocketPropelledChainsaw_Explode(this, NULL); +} + +void W_OverkillRocketPropelledChainsaw_Touch (entity this, entity toucher) +{ + if(WarpZone_Projectile_Touch(this, toucher)) + if(wasfreed(this)) + return; + + W_OverkillRocketPropelledChainsaw_Explode(this, toucher); +} + +void W_OverkillRocketPropelledChainsaw_Damage(entity this, entity inflictor, entity attacker, float damage, int deathtype, .entity weaponentity, vector hitloc, vector force) +{ + if (this.health <= 0) + return; + + if (!W_CheckProjectileDamage(inflictor.realowner, this.realowner, deathtype, -1)) // no exceptions + return; // g_projectiles_damage says to halt + + this.health = this.health - damage; + + if (this.health <= 0) + W_PrepareExplosionByDamage(this, attacker, W_OverkillRocketPropelledChainsaw_Explode_think); +} + +void W_OverkillRocketPropelledChainsaw_Think(entity this) +{ + if(this.cnt <= time) + { + delete(this); + return; + } + + float myspeed = vlen(this.velocity); + float myspeed_accel = myspeed * sys_frametime; + vector mydir = normalize(this.velocity); + + tracebox(this.origin, this.mins, this.maxs, this.origin + mydir * (2 * myspeed_accel), MOVE_NORMAL, this); + if(IS_PLAYER(trace_ent)) + Damage(trace_ent, this, this.realowner, WEP_CVAR_PRI(okrpc, damage2), this.projectiledeathtype, this.weaponentity_fld, this.origin, normalize(this.origin - trace_ent.origin) * WEP_CVAR_PRI(okrpc, force)); + + this.velocity = mydir * (myspeed + (WEP_CVAR_PRI(okrpc, speedaccel) * sys_frametime)); + + UpdateCSQCProjectile(this); + this.nextthink = time; +} + +void W_OverkillRocketPropelledChainsaw_Attack (Weapon thiswep, entity actor, .entity weaponentity) +{ + entity missile = spawn(); //WarpZone_RefSys_SpawnSameRefSys(actor); + entity flash = spawn (); + + W_DecreaseAmmo(thiswep, actor, WEP_CVAR_PRI(okrpc, ammo), weaponentity); + W_SetupShot_ProjectileSize(actor, weaponentity, '-3 -3 -3', '3 3 3', false, 5, SND_ROCKET_FIRE, CH_WEAPON_A, WEP_CVAR_PRI(okrpc, damage), WEP_OVERKILL_RPC.m_id); + Send_Effect(EFFECT_ROCKET_MUZZLEFLASH, w_shotorg, w_shotdir * 1000, 1); + PROJECTILE_MAKETRIGGER(missile); + + missile.owner = missile.realowner = actor; + missile.bot_dodge = true; + missile.bot_dodgerating = WEP_CVAR_PRI(okrpc, damage) * 2; + + missile.takedamage = DAMAGE_YES; + missile.damageforcescale = WEP_CVAR_PRI(okrpc, damageforcescale); + missile.health = WEP_CVAR_PRI(okrpc, health); + missile.event_damage = W_OverkillRocketPropelledChainsaw_Damage; + missile.damagedbycontents = true; + IL_PUSH(g_damagedbycontents, missile); + set_movetype(missile, MOVETYPE_FLY); + + missile.projectiledeathtype = WEP_OVERKILL_RPC.m_id; + missile.weaponentity_fld = weaponentity; + setsize (missile, '-3 -3 -3', '3 3 3'); // give it some size so it can be shot + + setorigin(missile, w_shotorg - v_forward * 3); // move it back so it hits the wall at the right point + W_SetupProjVelocity_Basic(missile, WEP_CVAR_PRI(okrpc, speed), 0); + + settouch(missile, W_OverkillRocketPropelledChainsaw_Touch); + + setthink(missile, W_OverkillRocketPropelledChainsaw_Think); + missile.cnt = time + WEP_CVAR_PRI(okrpc, lifetime); + missile.nextthink = time; + missile.flags = FL_PROJECTILE; + IL_PUSH(g_projectiles, missile); + IL_PUSH(g_bot_dodge, missile); + + CSQCProjectile(missile, true, PROJECTILE_RPC, false); + + setmodel(flash, MDL_RPC_MUZZLEFLASH); // precision set below + SUB_SetFade (flash, time, 0.1); + flash.effects = EF_ADDITIVE | EF_FULLBRIGHT | EF_LOWPRECISION; + W_AttachToShotorg(actor, weaponentity, flash, '5 0 0'); + + MUTATOR_CALLHOOK(EditProjectile, actor, missile); +} + +METHOD(OverkillRocketPropelledChainsaw, wr_aim, void(entity thiswep, entity actor, .entity weaponentity)) +{ + PHYS_INPUT_BUTTON_ATCK(actor) = bot_aim(actor, weaponentity, WEP_CVAR_PRI(okrpc, speed), 0, WEP_CVAR_PRI(okrpc, lifetime), false); +} + +METHOD(OverkillRocketPropelledChainsaw, wr_think, void(entity thiswep, entity actor, .entity weaponentity, int fire)) +{ + if ((WEP_CVAR_SEC(okrpc, refire_type) == 1) && (fire & 2) && (time >= actor.jump_interval)) + { + // Secondary uses it's own refire timer if refire_type is 1. + actor.jump_interval = time + WEP_CVAR_SEC(okrpc, refire) * W_WeaponRateFactor(actor); + BLASTER_SECONDARY_ATTACK(okrpc, actor, weaponentity); + if ((actor.(weaponentity).wframe == WFRAME_IDLE) || + (actor.(weaponentity).wframe == WFRAME_FIRE2)) + { + // Set secondary fire animation. + vector a = '0 0 0'; + actor.(weaponentity).wframe = WFRAME_FIRE2; + a = actor.(weaponentity).anim_fire2; + a.z *= g_weaponratefactor; + FOREACH_CLIENT(true, LAMBDA( + if (it == actor || (IS_SPEC(it) && it.enemy == actor)) + { + wframe_send(it, actor.(weaponentity), a, true); + } + )); + animdecide_setaction(actor, ANIMACTION_SHOOT, true); + } + } + if (WEP_CVAR(okrpc, reload_ammo) && actor.(weaponentity).clip_load < WEP_CVAR_PRI(okrpc, ammo)) + { + // Forced reload + thiswep.wr_reload(thiswep, actor, weaponentity); + return; + } + if (fire & 1) // Primary attack + { + if (!weapon_prepareattack(thiswep, actor, weaponentity, false, WEP_CVAR_PRI(okrpc, refire))) + { + return; + } + W_OverkillRocketPropelledChainsaw_Attack(thiswep, actor, weaponentity); + weapon_thinkf(actor, weaponentity, WFRAME_FIRE1, WEP_CVAR_PRI(okrpc, animtime), w_ready); + return; + } + if ((fire & 2) && (WEP_CVAR_SEC(okrpc, refire_type) == 0)) // Secondary attack + { + if (!weapon_prepareattack(thiswep, actor, weaponentity, false, WEP_CVAR_SEC(okrpc, refire))) + { + return; + } + BLASTER_SECONDARY_ATTACK(okrpc, actor, weaponentity); + weapon_thinkf(actor, weaponentity, WFRAME_FIRE2, WEP_CVAR_SEC(okrpc, animtime), w_ready); + } +} + +METHOD(OverkillRocketPropelledChainsaw, wr_checkammo1, bool(entity thiswep, entity actor, .entity weaponentity)) +{ + float ammo_amount = GetResourceAmount(actor, thiswep.ammo_type) >= WEP_CVAR_PRI(okrpc, ammo); + ammo_amount += actor.(weaponentity).(weapon_load[WEP_OVERKILL_RPC.m_id]) >= WEP_CVAR_PRI(okrpc, ammo); + return ammo_amount; +} + +METHOD(OverkillRocketPropelledChainsaw, wr_checkammo2, bool(entity thiswep, entity actor, .entity weaponentity)) +{ + float ammo_amount = GetResourceAmount(actor, thiswep.ammo_type) >= WEP_CVAR_SEC(okrpc, ammo); + ammo_amount += actor.(weaponentity).(weapon_load[WEP_OVERKILL_RPC.m_id]) >= WEP_CVAR_SEC(okrpc, ammo); + return ammo_amount; +} + +METHOD(OverkillRocketPropelledChainsaw, wr_reload, void(entity thiswep, entity actor, .entity weaponentity)) +{ + W_Reload(actor, weaponentity, WEP_CVAR_PRI(okrpc, ammo), SND_RELOAD); +} + +METHOD(OverkillRocketPropelledChainsaw, wr_suicidemessage, Notification(entity thiswep)) +{ + if((w_deathtype & HITTYPE_BOUNCE) || (w_deathtype & HITTYPE_SPLASH)) + return WEAPON_OVERKILL_RPC_SUICIDE_SPLASH; + else + return WEAPON_OVERKILL_RPC_SUICIDE_DIRECT; +} + +METHOD(OverkillRocketPropelledChainsaw, wr_killmessage, Notification(entity thiswep)) +{ + if(w_deathtype & HITTYPE_SECONDARY) + return WEAPON_BLASTER_MURDER; + else if((w_deathtype & HITTYPE_BOUNCE) || (w_deathtype & HITTYPE_SPLASH)) + return WEAPON_OVERKILL_RPC_MURDER_SPLASH; + else + return WEAPON_OVERKILL_RPC_MURDER_DIRECT; +} + +#endif + +#ifdef CSQC + +METHOD(OverkillRocketPropelledChainsaw, wr_impacteffect, void(entity thiswep, entity actor)) +{ + vector org2; + org2 = w_org + w_backoff * 12; + pointparticles(EFFECT_ROCKET_EXPLODE, org2, '0 0 0', 1); + if(!w_issilent) + sound(actor, CH_SHOTS, SND_ROCKET_IMPACT, VOL_BASE, ATTEN_NORM); +} + +#endif diff --git a/qcsrc/common/mutators/mutator/overkill/rpc.qh b/qcsrc/common/mutators/mutator/overkill/okrpc.qh similarity index 50% rename from qcsrc/common/mutators/mutator/overkill/rpc.qh rename to qcsrc/common/mutators/mutator/overkill/okrpc.qh index e7ab6cb6b..cf2194825 100644 --- a/qcsrc/common/mutators/mutator/overkill/rpc.qh +++ b/qcsrc/common/mutators/mutator/overkill/okrpc.qh @@ -2,22 +2,22 @@ #include -CLASS(RocketPropelledChainsaw, Weapon) -/* spawnfunc */ ATTRIB(RocketPropelledChainsaw, m_canonical_spawnfunc, string, "weapon_rpc"); -/* ammotype */ ATTRIB(RocketPropelledChainsaw, ammo_type, int, RESOURCE_ROCKETS); -/* impulse */ ATTRIB(RocketPropelledChainsaw, impulse, int, 9); -/* flags */ ATTRIB(RocketPropelledChainsaw, spawnflags, int, WEP_FLAG_MUTATORBLOCKED | WEP_FLAG_HIDDEN | WEP_FLAG_NORMAL | WEP_FLAG_CANCLIMB | WEP_FLAG_RELOADABLE | WEP_TYPE_SPLASH | WEP_FLAG_SUPERWEAPON); -/* rating */ ATTRIB(RocketPropelledChainsaw, bot_pickupbasevalue, float, 10000); -/* color */ ATTRIB(RocketPropelledChainsaw, wpcolor, vector, '0.5 0.5 0'); -/* modelname */ ATTRIB(RocketPropelledChainsaw, mdl, string, "ok_rl"); +CLASS(OverkillRocketPropelledChainsaw, Weapon) +/* spawnfunc */ ATTRIB(OverkillRocketPropelledChainsaw, m_canonical_spawnfunc, string, "weapon_okrpc"); +/* ammotype */ ATTRIB(OverkillRocketPropelledChainsaw, ammo_type, int, RESOURCE_ROCKETS); +/* impulse */ ATTRIB(OverkillRocketPropelledChainsaw, impulse, int, 9); +/* flags */ ATTRIB(OverkillRocketPropelledChainsaw, spawnflags, int, WEP_FLAG_MUTATORBLOCKED | WEP_FLAG_HIDDEN | WEP_FLAG_NORMAL | WEP_FLAG_CANCLIMB | WEP_FLAG_RELOADABLE | WEP_TYPE_SPLASH | WEP_FLAG_SUPERWEAPON); +/* rating */ ATTRIB(OverkillRocketPropelledChainsaw, bot_pickupbasevalue, float, 10000); +/* color */ ATTRIB(OverkillRocketPropelledChainsaw, wpcolor, vector, '0.5 0.5 0'); +/* modelname */ ATTRIB(OverkillRocketPropelledChainsaw, mdl, string, "ok_rl"); #ifdef GAMEQC -/* model */ ATTRIB(RocketPropelledChainsaw, m_model, Model, MDL_RPC_ITEM); +/* model */ ATTRIB(OverkillRocketPropelledChainsaw, m_model, Model, MDL_RPC_ITEM); #endif -/* crosshair */ ATTRIB(RocketPropelledChainsaw, w_crosshair, string, "gfx/crosshairrocketlauncher"); -/* crosshair */ ATTRIB(RocketPropelledChainsaw, w_crosshair_size, float, 0.6); -/* wepimg */ ATTRIB(RocketPropelledChainsaw, model2, string, "weaponrpc"); -/* refname */ ATTRIB(RocketPropelledChainsaw, netname, string, "rpc"); -/* wepname */ ATTRIB(RocketPropelledChainsaw, m_name, string, _("Rocket Propelled Chainsaw")); +/* crosshair */ ATTRIB(OverkillRocketPropelledChainsaw, w_crosshair, string, "gfx/crosshairrocketlauncher"); +/* crosshair */ ATTRIB(OverkillRocketPropelledChainsaw, w_crosshair_size, float, 0.6); +/* wepimg */ ATTRIB(OverkillRocketPropelledChainsaw, model2, string, "weaponrpc"); +/* refname */ ATTRIB(OverkillRocketPropelledChainsaw, netname, string, "okrpc"); +/* wepname */ ATTRIB(OverkillRocketPropelledChainsaw, m_name, string, _("Overkill Rocket Propelled Chainsaw")); #define X(BEGIN, P, END, class, prefix) \ BEGIN(class) \ @@ -56,10 +56,11 @@ CLASS(RocketPropelledChainsaw, Weapon) P(class, prefix, weaponstart, float, NONE) \ P(class, prefix, weaponthrowable, float, NONE) \ END() - W_PROPS(X, RocketPropelledChainsaw, rpc) + W_PROPS(X, OverkillRocketPropelledChainsaw, okrpc) #undef X -ENDCLASS(RocketPropelledChainsaw) -REGISTER_WEAPON(RPC, rpc, NEW(RocketPropelledChainsaw)); +ENDCLASS(OverkillRocketPropelledChainsaw) +REGISTER_WEAPON(OVERKILL_RPC, okrpc, NEW(OverkillRocketPropelledChainsaw)); -SPAWNFUNC_WEAPON(weapon_rpc, WEP_RPC) +SPAWNFUNC_WEAPON(weapon_okrpc, WEP_OVERKILL_RPC) +SPAWNFUNC_WEAPON(weapon_rpc, WEP_OVERKILL_RPC) diff --git a/qcsrc/common/mutators/mutator/overkill/rpc.qc b/qcsrc/common/mutators/mutator/overkill/rpc.qc deleted file mode 100644 index ceb4563b8..000000000 --- a/qcsrc/common/mutators/mutator/overkill/rpc.qc +++ /dev/null @@ -1,219 +0,0 @@ -#include "rpc.qh" - -#ifdef SVQC - -void W_RocketPropelledChainsaw_Explode(entity this, entity directhitentity) -{ - this.event_damage = func_null; - this.takedamage = DAMAGE_NO; - - RadiusDamage(this, this.realowner, WEP_CVAR_PRI(rpc, damage), WEP_CVAR_PRI(rpc, edgedamage), WEP_CVAR_PRI(rpc, radius), NULL, NULL, WEP_CVAR_PRI(rpc, force), this.projectiledeathtype, this.weaponentity_fld, directhitentity); - - delete(this); -} - -void W_RocketPropelledChainsaw_Explode_think(entity this) -{ - W_RocketPropelledChainsaw_Explode(this, NULL); -} - -void W_RocketPropelledChainsaw_Touch (entity this, entity toucher) -{ - if(WarpZone_Projectile_Touch(this, toucher)) - if(wasfreed(this)) - return; - - W_RocketPropelledChainsaw_Explode(this, toucher); -} - -void W_RocketPropelledChainsaw_Damage(entity this, entity inflictor, entity attacker, float damage, int deathtype, .entity weaponentity, vector hitloc, vector force) -{ - if (this.health <= 0) - return; - - if (!W_CheckProjectileDamage(inflictor.realowner, this.realowner, deathtype, -1)) // no exceptions - return; // g_projectiles_damage says to halt - - this.health = this.health - damage; - - if (this.health <= 0) - W_PrepareExplosionByDamage(this, attacker, W_RocketPropelledChainsaw_Explode_think); -} - -void W_RocketPropelledChainsaw_Think(entity this) -{ - if(this.cnt <= time) - { - delete(this); - return; - } - - float myspeed = vlen(this.velocity); - float myspeed_accel = myspeed * sys_frametime; - vector mydir = normalize(this.velocity); - - tracebox(this.origin, this.mins, this.maxs, this.origin + mydir * (2 * myspeed_accel), MOVE_NORMAL, this); - if(IS_PLAYER(trace_ent)) - Damage(trace_ent, this, this.realowner, WEP_CVAR_PRI(rpc, damage2), this.projectiledeathtype, this.weaponentity_fld, this.origin, normalize(this.origin - trace_ent.origin) * WEP_CVAR_PRI(rpc, force)); - - this.velocity = mydir * (myspeed + (WEP_CVAR_PRI(rpc, speedaccel) * sys_frametime)); - - UpdateCSQCProjectile(this); - this.nextthink = time; -} - -void W_RocketPropelledChainsaw_Attack (Weapon thiswep, entity actor, .entity weaponentity) -{ - entity missile = spawn(); //WarpZone_RefSys_SpawnSameRefSys(actor); - entity flash = spawn (); - - W_DecreaseAmmo(thiswep, actor, WEP_CVAR_PRI(rpc, ammo), weaponentity); - W_SetupShot_ProjectileSize(actor, weaponentity, '-3 -3 -3', '3 3 3', false, 5, SND_ROCKET_FIRE, CH_WEAPON_A, WEP_CVAR_PRI(rpc, damage), WEP_RPC.m_id); - Send_Effect(EFFECT_ROCKET_MUZZLEFLASH, w_shotorg, w_shotdir * 1000, 1); - PROJECTILE_MAKETRIGGER(missile); - - missile.owner = missile.realowner = actor; - missile.bot_dodge = true; - missile.bot_dodgerating = WEP_CVAR_PRI(rpc, damage) * 2; - - missile.takedamage = DAMAGE_YES; - missile.damageforcescale = WEP_CVAR_PRI(rpc, damageforcescale); - missile.health = WEP_CVAR_PRI(rpc, health); - missile.event_damage = W_RocketPropelledChainsaw_Damage; - missile.damagedbycontents = true; - IL_PUSH(g_damagedbycontents, missile); - set_movetype(missile, MOVETYPE_FLY); - - missile.projectiledeathtype = WEP_RPC.m_id; - missile.weaponentity_fld = weaponentity; - setsize (missile, '-3 -3 -3', '3 3 3'); // give it some size so it can be shot - - setorigin(missile, w_shotorg - v_forward * 3); // move it back so it hits the wall at the right point - W_SetupProjVelocity_Basic(missile, WEP_CVAR_PRI(rpc, speed), 0); - - settouch(missile, W_RocketPropelledChainsaw_Touch); - - setthink(missile, W_RocketPropelledChainsaw_Think); - missile.cnt = time + WEP_CVAR_PRI(rpc, lifetime); - missile.nextthink = time; - missile.flags = FL_PROJECTILE; - IL_PUSH(g_projectiles, missile); - IL_PUSH(g_bot_dodge, missile); - - CSQCProjectile(missile, true, PROJECTILE_RPC, false); - - setmodel(flash, MDL_RPC_MUZZLEFLASH); // precision set below - SUB_SetFade (flash, time, 0.1); - flash.effects = EF_ADDITIVE | EF_FULLBRIGHT | EF_LOWPRECISION; - W_AttachToShotorg(actor, weaponentity, flash, '5 0 0'); - - MUTATOR_CALLHOOK(EditProjectile, actor, missile); -} - -METHOD(RocketPropelledChainsaw, wr_aim, void(entity thiswep, entity actor, .entity weaponentity)) -{ - PHYS_INPUT_BUTTON_ATCK(actor) = bot_aim(actor, weaponentity, WEP_CVAR_PRI(rpc, speed), 0, WEP_CVAR_PRI(rpc, lifetime), false); -} - -METHOD(RocketPropelledChainsaw, wr_think, void(entity thiswep, entity actor, .entity weaponentity, int fire)) -{ - if ((WEP_CVAR_SEC(rpc, refire_type) == 1) && (fire & 2) && (time >= actor.jump_interval)) - { - // Secondary uses it's own refire timer if refire_type is 1. - actor.jump_interval = time + WEP_CVAR_SEC(rpc, refire) * W_WeaponRateFactor(actor); - BLASTER_SECONDARY_ATTACK(rpc, actor, weaponentity); - if ((actor.(weaponentity).wframe == WFRAME_IDLE) || - (actor.(weaponentity).wframe == WFRAME_FIRE2)) - { - // Set secondary fire animation. - vector a = '0 0 0'; - actor.(weaponentity).wframe = WFRAME_FIRE2; - a = actor.(weaponentity).anim_fire2; - a.z *= g_weaponratefactor; - FOREACH_CLIENT(true, LAMBDA( - if (it == actor || (IS_SPEC(it) && it.enemy == actor)) - { - wframe_send(it, actor.(weaponentity), a, true); - } - )); - animdecide_setaction(actor, ANIMACTION_SHOOT, true); - } - } - if (WEP_CVAR(rpc, reload_ammo) && actor.(weaponentity).clip_load < WEP_CVAR_PRI(rpc, ammo)) - { - // Forced reload - thiswep.wr_reload(thiswep, actor, weaponentity); - return; - } - if (fire & 1) // Primary attack - { - if (!weapon_prepareattack(thiswep, actor, weaponentity, false, WEP_CVAR_PRI(rpc, refire))) - { - return; - } - W_RocketPropelledChainsaw_Attack(thiswep, actor, weaponentity); - weapon_thinkf(actor, weaponentity, WFRAME_FIRE1, WEP_CVAR_PRI(rpc, animtime), w_ready); - return; - } - if ((fire & 2) && (WEP_CVAR_SEC(rpc, refire_type) == 0)) // Secondary attack - { - if (!weapon_prepareattack(thiswep, actor, weaponentity, false, WEP_CVAR_SEC(rpc, refire))) - { - return; - } - BLASTER_SECONDARY_ATTACK(rpc, actor, weaponentity); - weapon_thinkf(actor, weaponentity, WFRAME_FIRE2, WEP_CVAR_SEC(rpc, animtime), w_ready); - } -} - -METHOD(RocketPropelledChainsaw, wr_checkammo1, bool(entity thiswep, entity actor, .entity weaponentity)) -{ - float ammo_amount = GetResourceAmount(actor, thiswep.ammo_type) >= WEP_CVAR_PRI(rpc, ammo); - ammo_amount += actor.(weaponentity).(weapon_load[WEP_RPC.m_id]) >= WEP_CVAR_PRI(rpc, ammo); - return ammo_amount; -} - -METHOD(RocketPropelledChainsaw, wr_checkammo2, bool(entity thiswep, entity actor, .entity weaponentity)) -{ - float ammo_amount = GetResourceAmount(actor, thiswep.ammo_type) >= WEP_CVAR_SEC(rpc, ammo); - ammo_amount += actor.(weaponentity).(weapon_load[WEP_RPC.m_id]) >= WEP_CVAR_SEC(rpc, ammo); - return ammo_amount; -} - -METHOD(RocketPropelledChainsaw, wr_reload, void(entity thiswep, entity actor, .entity weaponentity)) -{ - W_Reload(actor, weaponentity, WEP_CVAR_PRI(rpc, ammo), SND_RELOAD); -} - -METHOD(RocketPropelledChainsaw, wr_suicidemessage, Notification(entity thiswep)) -{ - if((w_deathtype & HITTYPE_BOUNCE) || (w_deathtype & HITTYPE_SPLASH)) - return WEAPON_RPC_SUICIDE_SPLASH; - else - return WEAPON_RPC_SUICIDE_DIRECT; -} - -METHOD(RocketPropelledChainsaw, wr_killmessage, Notification(entity thiswep)) -{ - if(w_deathtype & HITTYPE_SECONDARY) - return WEAPON_BLASTER_MURDER; - else if((w_deathtype & HITTYPE_BOUNCE) || (w_deathtype & HITTYPE_SPLASH)) - return WEAPON_RPC_MURDER_SPLASH; - else - return WEAPON_RPC_MURDER_DIRECT; -} - -#endif - -#ifdef CSQC - -METHOD(RocketPropelledChainsaw, wr_impacteffect, void(entity thiswep, entity actor)) -{ - vector org2; - org2 = w_org + w_backoff * 12; - pointparticles(EFFECT_ROCKET_EXPLODE, org2, '0 0 0', 1); - if(!w_issilent) - sound(actor, CH_SHOTS, SND_ROCKET_IMPACT, VOL_BASE, ATTEN_NORM); -} - -#endif diff --git a/qcsrc/common/mutators/mutator/overkill/sv_overkill.qc b/qcsrc/common/mutators/mutator/overkill/sv_overkill.qc index 4459541ef..510b9213a 100644 --- a/qcsrc/common/mutators/mutator/overkill/sv_overkill.qc +++ b/qcsrc/common/mutators/mutator/overkill/sv_overkill.qc @@ -2,7 +2,7 @@ #include "okshotgun.qh" #include "okhmg.qh" -#include "rpc.qh" +#include "okrpc.qh" string autocvar_g_overkill; @@ -35,7 +35,7 @@ REGISTER_MUTATOR(ok, expr_evaluate(autocvar_g_overkill) && !autocvar_g_instagib ITEM_ArmorMega.spawnflags |= ITEM_FLAG_MUTATORBLOCKED; } - WEP_RPC.spawnflags &= ~WEP_FLAG_MUTATORBLOCKED; + WEP_OVERKILL_RPC.spawnflags &= ~WEP_FLAG_MUTATORBLOCKED; WEP_OVERKILL_HMG.spawnflags &= ~WEP_FLAG_MUTATORBLOCKED; //WEP_SHOTGUN.mdl = "ok_shotgun"; @@ -50,7 +50,7 @@ REGISTER_MUTATOR(ok, expr_evaluate(autocvar_g_overkill) && !autocvar_g_instagib ITEM_ArmorBig.spawnflags &= ~ITEM_FLAG_MUTATORBLOCKED; ITEM_ArmorMega.spawnflags &= ~ITEM_FLAG_MUTATORBLOCKED; - WEP_RPC.spawnflags |= WEP_FLAG_MUTATORBLOCKED; + WEP_OVERKILL_RPC.spawnflags |= WEP_FLAG_MUTATORBLOCKED; WEP_OVERKILL_HMG.spawnflags |= WEP_FLAG_MUTATORBLOCKED; } } @@ -170,7 +170,7 @@ MUTATOR_HOOKFUNCTION(ok, PlayerWeaponSelect) Weapon newwep = player.ok_lastwep[slot]; if(player.ok_lastwep[slot] == WEP_OVERKILL_HMG) newwep = WEP_OVERKILL_MACHINEGUN; - if(player.ok_lastwep[slot] == WEP_RPC) + if(player.ok_lastwep[slot] == WEP_OVERKILL_RPC) newwep = WEP_OVERKILL_NEX; thiswep.m_switchweapon = newwep; player.ok_lastwep[slot] = WEP_Null; @@ -241,7 +241,7 @@ MUTATOR_HOOKFUNCTION(ok, FilterItem) } else if (item.classname == "item_shield") { - entity wep = new(weapon_rpc); + entity wep = new(weapon_okrpc); setorigin(wep, item.origin); wep.ok_item = true; wep.noalign = Item_ShouldKeepPosition(item); @@ -250,7 +250,7 @@ MUTATOR_HOOKFUNCTION(ok, FilterItem) wep.respawntime = g_pickup_respawntime_superweapon; wep.pickup_anyway = true; wep.spawnfunc_checked = true; - Item_Initialize(wep, "weapon_rpc"); + Item_Initialize(wep, "weapon_okrpc"); return true; } return true; @@ -260,7 +260,7 @@ MUTATOR_HOOKFUNCTION(ok, SetStartItems, CBC_ORDER_LAST) { WepSet ok_start_items = (WEPSET(OVERKILL_MACHINEGUN) | WEPSET(OVERKILL_NEX) | WEPSET(OVERKILL_SHOTGUN)); - if(WEP_RPC.weaponstart > 0) { ok_start_items |= WEPSET(RPC); } + if(WEP_OVERKILL_RPC.weaponstart > 0) { ok_start_items |= WEPSET(OVERKILL_RPC); } if(WEP_OVERKILL_HMG.weaponstart > 0) { ok_start_items |= WEPSET(OVERKILL_HMG); } start_items |= IT_UNLIMITED_WEAPON_AMMO; 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 e22a02a9e..6afcd72e9 100644 --- a/qcsrc/common/mutators/mutator/random_items/sv_random_items.qc +++ b/qcsrc/common/mutators/mutator/random_items/sv_random_items.qc @@ -241,14 +241,14 @@ string RandomItems_GetRandomOverkillItemClassName(string prefix) { RandomSelection_AddString("weapon_okhmg", cvar(cvar_name), 1); } - cvar_name = sprintf("g_%s_overkill_weapon_rpc_probability", prefix); + cvar_name = sprintf("g_%s_overkill_weapon_okrpc_probability", prefix); if (!(cvar_type(cvar_name) & CVAR_TYPEFLAG_EXISTS)) { LOG_WARNF("Random items: cvar %s doesn't exist.", cvar_name); } else { - RandomSelection_AddString("weapon_rpc", cvar(cvar_name), 1); + RandomSelection_AddString("weapon_okrpc", cvar(cvar_name), 1); } return RandomSelection_chosen_string; } diff --git a/qcsrc/common/notifications/all.inc b/qcsrc/common/notifications/all.inc index a41979bed..50d048540 100644 --- a/qcsrc/common/notifications/all.inc +++ b/qcsrc/common/notifications/all.inc @@ -493,15 +493,16 @@ MSG_INFO_NOTIF(WEAPON_OVERKILL_HMG_MURDER_SPRAY, N_CONSOLE, 3, 2, "spree_inf s1 s2 s3loc spree_end", "s2 s1", "weaponhmg", _("^BG%s%s^K1 was torn to bits by ^BG%s^K1's Overkill Heavy Machine Gun%s%s"), "") MSG_INFO_NOTIF(WEAPON_OVERKILL_MACHINEGUN_MURDER, N_CONSOLE, 3, 2, "spree_inf s1 s2 s3loc spree_end", "s2 s1", "weaponokmachinegun", _("^BG%s%s^K1 was riddled full of holes by ^BG%s^K1's Overkill Machine Gun%s%s"), "") MSG_INFO_NOTIF(WEAPON_OVERKILL_NEX_MURDER, N_CONSOLE, 3, 2, "spree_inf s1 s2 s3loc spree_end", "s2 s1", "weaponoknex", _("^BG%s%s^K1 has been vaporized by ^BG%s^K1's Overkill Nex%s%s"), "") + MSG_INFO_NOTIF(WEAPON_OVERKILL_RPC_MURDER_DIRECT, N_CONSOLE, 3, 2, "spree_inf s1 s2 s3loc spree_end", "s2 s1", "weaponrpc", _("^BG%s%s^K1 was sawn in half by ^BG%s^K1's Overkill Rocket Propelled Chainsaw%s%s"), "") + MSG_INFO_NOTIF(WEAPON_OVERKILL_RPC_MURDER_SPLASH, N_CONSOLE, 3, 2, "spree_inf s1 s2 s3loc spree_end", "s2 s1", "weaponrpc", _("^BG%s%s^K1 almost dodged ^BG%s^K1's Overkill Rocket Propelled Chainsaw%s%s"), "") + MSG_INFO_NOTIF(WEAPON_OVERKILL_RPC_SUICIDE_DIRECT, N_CONSOLE, 2, 1, "s1 s2loc spree_lost", "s1", "weaponrpc", _("^BG%s^K1 was sawn in half by their own Overkill Rocket Propelled Chainsaw%s%s"), "") + MSG_INFO_NOTIF(WEAPON_OVERKILL_RPC_SUICIDE_SPLASH, N_CONSOLE, 2, 1, "s1 s2loc spree_lost", "s1", "weaponrpc", _("^BG%s^K1 blew themself up with their Overkill Rocket Propelled Chainsaw%s%s"), "") + MSG_INFO_NOTIF(WEAPON_OVERKILL_SHOTGUN_MURDER, N_CONSOLE, 3, 2, "spree_inf s1 s2 s3loc spree_end", "s2 s1", "weaponokshotgun", _("^BG%s%s^K1 was gunned down by ^BG%s^K1's Overkill Shotgun%s%s"), "") MSG_INFO_NOTIF(WEAPON_RIFLE_MURDER, N_CONSOLE, 3, 2, "spree_inf s1 s2 s3loc spree_end", "s2 s1", "weaponrifle", _("^BG%s%s^K1 was sniped with a Rifle by ^BG%s^K1%s%s"), "") MSG_INFO_NOTIF(WEAPON_RIFLE_MURDER_HAIL, N_CONSOLE, 3, 2, "spree_inf s1 s2 s3loc spree_end", "s2 s1", "weaponrifle", _("^BG%s%s^K1 died in ^BG%s^K1's Rifle bullet hail%s%s"), "") MSG_INFO_NOTIF(WEAPON_RIFLE_MURDER_HAIL_PIERCING, N_CONSOLE, 3, 2, "spree_inf s1 s2 s3loc spree_end", "s2 s1", "weaponrifle", _("^BG%s%s^K1 failed to hide from ^BG%s^K1's Rifle bullet hail%s%s"), "") MSG_INFO_NOTIF(WEAPON_RIFLE_MURDER_PIERCING, N_CONSOLE, 3, 2, "spree_inf s1 s2 s3loc spree_end", "s2 s1", "weaponrifle", _("^BG%s%s^K1 failed to hide from ^BG%s^K1's Rifle%s%s"), "") - MSG_INFO_NOTIF(WEAPON_RPC_MURDER_DIRECT, N_CONSOLE, 3, 2, "spree_inf s1 s2 s3loc spree_end", "s2 s1", "weaponrpc", _("^BG%s%s^K1 was sawn in half by ^BG%s^K1's Rocket Propelled Chainsaw%s%s"), "") - MSG_INFO_NOTIF(WEAPON_RPC_MURDER_SPLASH, N_CONSOLE, 3, 2, "spree_inf s1 s2 s3loc spree_end", "s2 s1", "weaponrpc", _("^BG%s%s^K1 almost dodged ^BG%s^K1's Rocket Propelled Chainsaw%s%s"), "") - MSG_INFO_NOTIF(WEAPON_RPC_SUICIDE_DIRECT, N_CONSOLE, 2, 1, "s1 s2loc spree_lost", "s1", "weaponrpc", _("^BG%s^K1 was sawn in half by their own Rocket Propelled Chainsaw%s%s"), "") - MSG_INFO_NOTIF(WEAPON_RPC_SUICIDE_SPLASH, N_CONSOLE, 2, 1, "s1 s2loc spree_lost", "s1", "weaponrpc", _("^BG%s^K1 blew themself up with their Rocket Propelled Chainsaw%s%s"), "") MSG_INFO_NOTIF(WEAPON_SEEKER_MURDER_SPRAY, N_CONSOLE, 3, 2, "spree_inf s1 s2 s3loc spree_end", "s2 s1", "weaponseeker", _("^BG%s%s^K1 was pummeled by ^BG%s^K1's Seeker rockets%s%s"), "") MSG_INFO_NOTIF(WEAPON_SEEKER_MURDER_TAG, N_CONSOLE, 3, 2, "spree_inf s1 s2 s3loc spree_end", "s2 s1", "weaponseeker", _("^BG%s%s^K1 was tagged by ^BG%s^K1's Seeker%s%s"), "") MSG_INFO_NOTIF(WEAPON_SEEKER_SUICIDE, N_CONSOLE, 2, 1, "s1 s2loc spree_lost", "s1", "weaponseeker", _("^BG%s^K1 played with tiny Seeker rockets%s%s"), "") @@ -953,15 +954,15 @@ MSG_MULTI_NOTIF(WEAPON_OVERKILL_HMG_MURDER_SPRAY, N_ENABLE, NULL, INFO_WEAPON_OVERKILL_HMG_MURDER_SPRAY, NULL) MSG_MULTI_NOTIF(WEAPON_OVERKILL_MACHINEGUN_MURDER, N_ENABLE, NULL, INFO_WEAPON_OVERKILL_MACHINEGUN_MURDER, NULL) MSG_MULTI_NOTIF(WEAPON_OVERKILL_NEX_MURDER, N_ENABLE, NULL, INFO_WEAPON_OVERKILL_NEX_MURDER, NULL) + MSG_MULTI_NOTIF(WEAPON_OVERKILL_RPC_MURDER_DIRECT, N_ENABLE, NULL, INFO_WEAPON_OVERKILL_RPC_MURDER_DIRECT, NULL) + MSG_MULTI_NOTIF(WEAPON_OVERKILL_RPC_MURDER_SPLASH, N_ENABLE, NULL, INFO_WEAPON_OVERKILL_RPC_MURDER_SPLASH, NULL) + MSG_MULTI_NOTIF(WEAPON_OVERKILL_RPC_SUICIDE_DIRECT, N_ENABLE, NULL, INFO_WEAPON_OVERKILL_RPC_SUICIDE_DIRECT,NULL) + MSG_MULTI_NOTIF(WEAPON_OVERKILL_RPC_SUICIDE_SPLASH, N_ENABLE, NULL, INFO_WEAPON_OVERKILL_RPC_SUICIDE_SPLASH,CENTER_DEATH_SELF_GENERIC) MSG_MULTI_NOTIF(WEAPON_OVERKILL_SHOTGUN_MURDER, N_ENABLE, NULL, INFO_WEAPON_OVERKILL_SHOTGUN_MURDER, NULL) MSG_MULTI_NOTIF(WEAPON_RIFLE_MURDER, N_ENABLE, NULL, INFO_WEAPON_RIFLE_MURDER, NULL) MSG_MULTI_NOTIF(WEAPON_RIFLE_MURDER_HAIL, N_ENABLE, NULL, INFO_WEAPON_RIFLE_MURDER_HAIL, NULL) MSG_MULTI_NOTIF(WEAPON_RIFLE_MURDER_HAIL_PIERCING, N_ENABLE, NULL, INFO_WEAPON_RIFLE_MURDER_HAIL_PIERCING, NULL) MSG_MULTI_NOTIF(WEAPON_RIFLE_MURDER_PIERCING, N_ENABLE, NULL, INFO_WEAPON_RIFLE_MURDER_PIERCING, NULL) - MSG_MULTI_NOTIF(WEAPON_RPC_MURDER_DIRECT, N_ENABLE, NULL, INFO_WEAPON_RPC_MURDER_DIRECT, NULL) - MSG_MULTI_NOTIF(WEAPON_RPC_MURDER_SPLASH, N_ENABLE, NULL, INFO_WEAPON_RPC_MURDER_SPLASH, NULL) - MSG_MULTI_NOTIF(WEAPON_RPC_SUICIDE_DIRECT, N_ENABLE, NULL, INFO_WEAPON_RPC_SUICIDE_DIRECT, NULL) - MSG_MULTI_NOTIF(WEAPON_RPC_SUICIDE_SPLASH, N_ENABLE, NULL, INFO_WEAPON_RPC_SUICIDE_SPLASH, CENTER_DEATH_SELF_GENERIC) MSG_MULTI_NOTIF(WEAPON_SEEKER_MURDER_SPRAY, N_ENABLE, NULL, INFO_WEAPON_SEEKER_MURDER_SPRAY, NULL) MSG_MULTI_NOTIF(WEAPON_SEEKER_MURDER_TAG, N_ENABLE, NULL, INFO_WEAPON_SEEKER_MURDER_TAG, NULL) MSG_MULTI_NOTIF(WEAPON_SEEKER_SUICIDE, N_ENABLE, NULL, INFO_WEAPON_SEEKER_SUICIDE, CENTER_DEATH_SELF_GENERIC) diff --git a/randomitems-xonotic.cfg b/randomitems-xonotic.cfg index c5d1ff7ad..1491ffd0c 100644 --- a/randomitems-xonotic.cfg +++ b/randomitems-xonotic.cfg @@ -40,7 +40,7 @@ set g_random_items_replace_weapon_rifle "random" "Classnames to replace rifle wi set g_random_items_replace_weapon_seeker "random" "Classnames to replace TAG seeker with." set g_random_items_replace_weapon_vaporizer "random" "Classnames to replace vaporizer with." set g_random_items_replace_weapon_okhmg "random" "Classnames to replace overkill HMG with." -set g_random_items_replace_weapon_rpc "random" "Classnames to replace RPC with." +set g_random_items_replace_weapon_okrpc "random" "Classnames to replace overkill RPC with." set g_random_items_replace_item_strength "random" "Classnames to replace strength with." set g_random_items_replace_item_shield "random" "Classnames to replace shield with." set g_random_items_replace_item_fuel_regen "random" "Classnames to replace fuel regeneration with." @@ -105,7 +105,7 @@ set g_random_items_overkill_item_armor_medium_probability 4 "Probability of rand set g_random_items_overkill_item_armor_big_probability 2 "Probability of random big armor spawning in the map during overkill." set g_random_items_overkill_item_armor_mega_probability 1 "Probability of random mega armor spawning in the map during overkill." set g_random_items_overkill_weapon_okhmg_probability 0.5 "Probability of random overkill HMG spawning in the map during overkill." -set g_random_items_overkill_weapon_rpc_probability 0.5 "Probability of random RPC spawning in the map during overkill." +set g_random_items_overkill_weapon_okrpc_probability 0.5 "Probability of random overkill RPC spawning in the map during overkill." // Loot @@ -169,4 +169,4 @@ set g_random_loot_overkill_item_armor_medium_probability 4 "Probability of rando set g_random_loot_overkill_item_armor_big_probability 2 "Probability of random big armor spawning as loot during overkill." set g_random_loot_overkill_item_armor_mega_probability 1 "Probability of random mega armor spawning as loot during overkill." set g_random_loot_overkill_weapon_okhmg_probability 1 "Probability of random overkill HMG spawning as loot during overkill." -set g_random_loot_overkill_weapon_rpc_probability 1 "Probability of random RPC spawning as loot during overkill." +set g_random_loot_overkill_weapon_okrpc_probability 1 "Probability of random overkill RPC spawning as loot during overkill." -- 2.39.2