]> git.xonotic.org Git - xonotic/xonotic-data.pk3dir.git/commitdiff
new toys: make the mutator compile mostly
authorRudolf Polzer <divverent@xonotic.org>
Mon, 5 Mar 2012 11:29:15 +0000 (12:29 +0100)
committerRudolf Polzer <divverent@xonotic.org>
Mon, 5 Mar 2012 11:29:15 +0000 (12:29 +0100)
12 files changed:
balanceXonotic.cfg
defaultXonotic.cfg
new_toys.cfg [new file with mode: 0644]
qcsrc/common/items.qh
qcsrc/server/cl_weapons.qc
qcsrc/server/miscfunctions.qc
qcsrc/server/mutators/base.qh
qcsrc/server/mutators/mutator_new_toys.qc
qcsrc/server/progs.src
qcsrc/server/t_items.qc
qcsrc/server/t_quake3.qc
qcsrc/server/w_minelayer.qc

index 193c7ed2cc6beb915cb2a0aed4bb650ff4f0a1ba..6ac9d7c8002b2f3ade192b3c920ba758b4ed72bf 100644 (file)
@@ -1,24 +1,20 @@
 g_mod_balance Xonotic
 
 // {{{ starting gear
-set g_start_weapon_laser -1 "0 = never provide the weapon, 1 = always provide the weapon, -1 = game mode default, -2 = provide the weapon in ca and lms"
-set g_start_weapon_shotgun -1 "0 = never provide the weapon, 1 = always provide the weapon, -1 = game mode default, -2 = provide the weapon in ca and lms"
-set g_start_weapon_uzi -1 "0 = never provide the weapon, 1 = always provide the weapon, -1 = game mode default, -2 = provide the weapon in ca and lms"
-set g_start_weapon_grenadelauncher -1 "0 = never provide the weapon, 1 = always provide the weapon, -1 = game mode default, -2 = provide the weapon in ca and lms"
-set g_start_weapon_minelayer -1 "0 = never provide the weapon, 1 = always provide the weapon, -1 = game mode default, -2 = provide the weapon in ca and lms"
-set g_start_weapon_electro -1 "0 = never provide the weapon, 1 = always provide the weapon, -1 = game mode default, -2 = provide the weapon in ca and lms"
-set g_start_weapon_crylink -1 "0 = never provide the weapon, 1 = always provide the weapon, -1 = game mode default, -2 = provide the weapon in ca and lms"
-set g_start_weapon_nex -1 "0 = never provide the weapon, 1 = always provide the weapon, -1 = game mode default, -2 = provide the weapon in ca and lms"
-set g_start_weapon_hagar -1 "0 = never provide the weapon, 1 = always provide the weapon, -1 = game mode default, -2 = provide the weapon in ca and lms" // UNTIL IT CAN BE REMOVED FROM CODE
-set g_start_weapon_rocketlauncher -1 "0 = never provide the weapon, 1 = always provide the weapon, -1 = game mode default, -2 = provide the weapon in ca and lms"
-set g_start_weapon_minstanex -1 "0 = never provide the weapon, 1 = always provide the weapon, -1 = game mode default, -2 = provide the weapon in ca and lms"
-set g_start_weapon_porto -1 "0 = never provide the weapon, 1 = always provide the weapon, -1 = game mode default, -2 = provide the weapon in ca and lms"
-set g_start_weapon_hook -1 "0 = never provide the weapon, 1 = always provide the weapon, -1 = game mode default, -2 = provide the weapon in ca and lms"
-set g_start_weapon_hlac -1 "0 = never provide the weapon, 1 = always provide the weapon, -1 = game mode default, -2 = provide the weapon in ca and lms" // UNTIL IT CAN BE REMOVED FROM CODE
-set g_start_weapon_rifle -1 "0 = never provide the weapon, 1 = always provide the weapon, -1 = game mode default, -2 = provide the weapon in ca and lms" // UNTIL IT CAN BE REMOVED FROM CODE
-set g_start_weapon_tuba -1 "0 = never provide the weapon, 1 = always provide the weapon, -1 = game mode default, -2 = provide the weapon in ca and lms"
-set g_start_weapon_fireball -1 "0 = never provide the weapon, 1 = always provide the weapon, -1 = game mode default, -2 = provide the weapon in ca and lms"
-set g_start_weapon_seeker -1 "0 = never provide the weapon, 1 = always provide the weapon, -1 = game mode default, -2 = provide the weapon in ca and lms"
+set g_start_weapon_laser -1 "0 = never provide the weapon, 1 = always provide the weapon, -1 = game mode default"
+set g_start_weapon_shotgun -1 "0 = never provide the weapon, 1 = always provide the weapon, -1 = game mode default"
+set g_start_weapon_uzi -1 "0 = never provide the weapon, 1 = always provide the weapon, -1 = game mode default"
+set g_start_weapon_grenadelauncher -1 "0 = never provide the weapon, 1 = always provide the weapon, -1 = game mode default"
+set g_start_weapon_electro -1 "0 = never provide the weapon, 1 = always provide the weapon, -1 = game mode default"
+set g_start_weapon_crylink -1 "0 = never provide the weapon, 1 = always provide the weapon, -1 = game mode default"
+set g_start_weapon_nex -1 "0 = never provide the weapon, 1 = always provide the weapon, -1 = game mode default"
+set g_start_weapon_hagar -1 "0 = never provide the weapon, 1 = always provide the weapon, -1 = game mode default" // UNTIL IT CAN BE REMOVED FROM CODE
+set g_start_weapon_rocketlauncher -1 "0 = never provide the weapon, 1 = always provide the weapon, -1 = game mode default"
+set g_start_weapon_minstanex -1 "0 = never provide the weapon, 1 = always provide the weapon, -1 = game mode default"
+set g_start_weapon_porto -1 "0 = never provide the weapon, 1 = always provide the weapon, -1 = game mode default"
+set g_start_weapon_hook -1 "0 = never provide the weapon, 1 = always provide the weapon, -1 = game mode default"
+set g_start_weapon_tuba -1 "0 = never provide the weapon, 1 = always provide the weapon, -1 = game mode default"
+set g_start_weapon_fireball -1 "0 = never provide the weapon, 1 = always provide the weapon, -1 = game mode default"
 set g_balance_health_start 100
 set g_balance_armor_start 0
 set g_start_ammo_shells 15
@@ -374,31 +370,6 @@ set g_balance_grenadelauncher_bouncestop 0.075
 set g_balance_grenadelauncher_reload_ammo 0 //default: 12
 set g_balance_grenadelauncher_reload_time 2
 // }}}
-// {{{ minelayer
-set g_balance_minelayer_damage 40
-set g_balance_minelayer_edgedamage 20
-set g_balance_minelayer_force 250
-set g_balance_minelayer_radius 175
-set g_balance_minelayer_proximityradius 150
-set g_balance_minelayer_speed 1000
-set g_balance_minelayer_lifetime 10
-set g_balance_minelayer_lifetime_countdown 0.5
-set g_balance_minelayer_refire 1.5
-set g_balance_minelayer_animtime 0.4
-set g_balance_minelayer_ammo 4
-set g_balance_minelayer_health 15
-set g_balance_minelayer_limit 3 // 0 disables the limit
-set g_balance_minelayer_protection 0 // don't explode if the mine would hurt the owner or a team mate
-set g_balance_minelayer_damageforcescale 0
-set g_balance_minelayer_detonatedelay -1 // positive: timer till detonation is allowed, negative: "security device" that prevents ANY remote detonation if it could hurt its owner, zero: detonatable at any time
-set g_balance_minelayer_time 0.5
-set g_balance_minelayer_remote_damage 45
-set g_balance_minelayer_remote_edgedamage 40
-set g_balance_minelayer_remote_radius 200
-set g_balance_minelayer_remote_force 300
-set g_balance_minelayer_reload_ammo 0 //default: 15
-set g_balance_minelayer_reload_time 2
-// }}}
 // {{{ electro
 set g_balance_electro_lightning 0
 set g_balance_electro_primary_damage 40
@@ -659,77 +630,6 @@ set g_balance_hook_secondary_duration 1.5 // effect runs for three seconds
 set g_balance_hook_secondary_health 15
 set g_balance_hook_secondary_damageforcescale 0 
 // }}}
-// {{{ hlac // TO BE REMOVED
-set g_balance_hlac_primary_spread_min 0.01
-set g_balance_hlac_primary_spread_max 0.25
-set g_balance_hlac_primary_spread_add 0.0045
-set g_balance_hlac_primary_spread_crouchmod 0.25
-
-set g_balance_hlac_primary_damage 18
-set g_balance_hlac_primary_edgedamage 9
-set g_balance_hlac_primary_force 90
-set g_balance_hlac_primary_radius 70
-set g_balance_hlac_primary_speed 9000
-set g_balance_hlac_primary_lifetime 5
-
-set g_balance_hlac_primary_refire 0.15
-set g_balance_hlac_primary_animtime 0.4
-set g_balance_hlac_primary_ammo 1
-
-set g_balance_hlac_secondary 1
-set g_balance_hlac_secondary_spread 0.15
-set g_balance_hlac_secondary_spread_crouchmod 0.5
-
-set g_balance_hlac_secondary_damage 15
-set g_balance_hlac_secondary_edgedamage 7.5
-set g_balance_hlac_secondary_force 90
-set g_balance_hlac_secondary_radius 70
-set g_balance_hlac_secondary_speed 9000
-set g_balance_hlac_secondary_lifetime 5
-
-set g_balance_hlac_secondary_refire 1
-set g_balance_hlac_secondary_animtime 0.3
-set g_balance_hlac_secondary_ammo 10
-set g_balance_hlac_secondary_shots 6
-
-set g_balance_hlac_reload_ammo 0 //default: 20
-set g_balance_hlac_reload_time 2
-// }}}
-// {{{ rifle
-set g_balance_rifle_bursttime 0
-set g_balance_rifle_primary_tracer 1
-set g_balance_rifle_primary_shots 1
-set g_balance_rifle_primary_damage 40
-set g_balance_rifle_primary_headshotaddeddamage 40
-set g_balance_rifle_primary_spread 0
-set g_balance_rifle_primary_force 100
-set g_balance_rifle_primary_speed 40000
-set g_balance_rifle_primary_lifetime 5
-set g_balance_rifle_primary_refire 1.2
-set g_balance_rifle_primary_animtime 0.4
-set g_balance_rifle_primary_ammo 10
-set g_balance_rifle_primary_bulletconstant 110 // 62.2qu
-set g_balance_rifle_primary_burstcost 0
-set g_balance_rifle_primary_bullethail 0 // empty magazine on shot
-set g_balance_rifle_secondary 1
-set g_balance_rifle_secondary_reload 0
-set g_balance_rifle_secondary_tracer 0
-set g_balance_rifle_secondary_shots 4
-set g_balance_rifle_secondary_damage 10
-set g_balance_rifle_secondary_headshotaddeddamage 20
-set g_balance_rifle_secondary_spread 0.04
-set g_balance_rifle_secondary_force 50
-set g_balance_rifle_secondary_speed 20000
-set g_balance_rifle_secondary_lifetime 5
-set g_balance_rifle_secondary_refire 0.9
-set g_balance_rifle_secondary_animtime 0.3
-set g_balance_rifle_secondary_ammo 10
-set g_balance_rifle_secondary_bulletconstant 110 // 15.5qu
-set g_balance_rifle_secondary_burstcost 0
-set g_balance_rifle_secondary_bullethail 0 // empty magazine on shot
-set g_balance_rifle_reload_ammo 80 //default: 80
-set g_balance_rifle_reload_time 2
-// }}}
 // {{{ tuba
 set g_balance_tuba_refire 0.05
 set g_balance_tuba_animtime 0.05
@@ -778,57 +678,3 @@ set g_balance_fireball_secondary_speed_up 100
 set g_balance_fireball_secondary_speed_z 0
 set g_balance_fireball_secondary_spread 0
 // }}}
-// {{{ seeker
-set g_balance_seeker_type 1 // 0 = old seeker, 1 = new seeker. THIS IS A TEMPORARY CVAR FOR TESTING, will be removed later.
-set g_balance_seeker_flac_ammo 0.5
-set g_balance_seeker_flac_animtime 0.1
-set g_balance_seeker_flac_damage 15
-set g_balance_seeker_flac_edgedamage 10
-set g_balance_seeker_flac_force 50
-set g_balance_seeker_flac_lifetime 0.1
-set g_balance_seeker_flac_lifetime_rand 0.05
-set g_balance_seeker_flac_radius 100
-set g_balance_seeker_flac_refire 0.1
-set g_balance_seeker_flac_speed 3000
-set g_balance_seeker_flac_speed_up 1000
-set g_balance_seeker_flac_speed_z 0
-set g_balance_seeker_flac_spread 0.4
-set g_balance_seeker_tag_ammo 1
-set g_balance_seeker_tag_animtime 0.2
-set g_balance_seeker_tag_damageforcescale 0
-set g_balance_seeker_tag_health 0
-set g_balance_seeker_tag_lifetime 15
-set g_balance_seeker_tag_refire 0.75 // LOG: 0.7 -> 0.75
-set g_balance_seeker_tag_speed 5000
-set g_balance_seeker_tag_spread 0
-set g_balance_seeker_tag_tracker_lifetime 10
-set g_balance_seeker_missile_accel 1500
-set g_balance_seeker_missile_ammo 2
-set g_balance_seeker_missile_animtime 0.2
-set g_balance_seeker_missile_count 3 // LOG: 8 -> 3
-set g_balance_seeker_missile_damage 16 // LOG: 15 -> 30
-set g_balance_seeker_missile_damageforcescale 4
-set g_balance_seeker_missile_decel 6000
-set g_balance_seeker_missile_delay 0.25
-set g_balance_seeker_missile_edgedamage 8
-set g_balance_seeker_missile_force 50 // LOG: 100 -> 150
-set g_balance_seeker_missile_health 1
-set g_balance_seeker_missile_lifetime 15
-set g_balance_seeker_missile_proxy 0
-set g_balance_seeker_missile_proxy_delay 0.2
-set g_balance_seeker_missile_proxy_maxrange 45
-set g_balance_seeker_missile_radius 70
-set g_balance_seeker_missile_refire 0.25
-set g_balance_seeker_missile_smart 0
-set g_balance_seeker_missile_smart_mindist 800
-set g_balance_seeker_missile_smart_trace_max 2500
-set g_balance_seeker_missile_smart_trace_min 1000
-set g_balance_seeker_missile_speed 1500
-set g_balance_seeker_missile_speed_up 0
-set g_balance_seeker_missile_speed_z 0
-set g_balance_seeker_missile_speed_max 2000 // LOG: 1400 -> 1300
-set g_balance_seeker_missile_spread 0
-set g_balance_seeker_missile_turnrate 0.15
-set g_balance_seeker_reload_ammo 0 //default: 15
-set g_balance_seeker_reload_time 2
-// End new seeker
index 2c17e78a57b761b0886eec1bab209e1168949325..d256fa99e004bfcd807054c988f18874b46ea4d5 100644 (file)
@@ -1743,7 +1743,6 @@ cl_decals_newsystem 1
 set g_weaponreplace_laser ""
 set g_weaponreplace_shotgun ""
 set g_weaponreplace_uzi ""
-set g_weaponreplace_minelayer ""
 set g_weaponreplace_grenadelauncher ""
 set g_weaponreplace_electro ""
 set g_weaponreplace_crylink ""
@@ -1753,11 +1752,8 @@ set g_weaponreplace_rocketlauncher ""
 set g_weaponreplace_porto ""
 set g_weaponreplace_minstanex ""
 set g_weaponreplace_hook ""
-set g_weaponreplace_hlac ""
-set g_weaponreplace_rifle ""
 set g_weaponreplace_tuba ""
 set g_weaponreplace_fireball ""
-set g_weaponreplace_seeker ""
 set sv_q3acompat_machineshotgunswap 0 "shorthand for swapping uzi and shotgun (for Q3A map compatibility in mapinfo files)"
 
 set g_movement_highspeed 1 "movement speed modification factor (only changes movement when above maxspeed)"
@@ -1908,6 +1904,7 @@ scr_loadingscreen_scale_base 1
 scr_loadingscreen_scale_limit 2
 
 // other config files
+exec new_toys.cfg // run BEFORE balance to make sure balance wins
 exec balanceXonotic.cfg
 exec ctfscoring-ai.cfg
 exec effects-normal.cfg
diff --git a/new_toys.cfg b/new_toys.cfg
new file mode 100644 (file)
index 0000000..fbe4734
--- /dev/null
@@ -0,0 +1,163 @@
+set g_new_toys 0 "Mutator 'New Toys': enable extra fun guns"
+set g_new_toys_autoreplace 2 "0: never replace, 1: always auto replace guns by available new toys, 2: randomly auto replace guns by available new toys"
+
+set g_weaponreplace_hlac ""
+set g_weaponreplace_minelayer ""
+set g_weaponreplace_rifle ""
+set g_weaponreplace_seeker ""
+
+set g_start_weapon_hlac -1 "0 = never provide the weapon, 1 = always provide the weapon, -1 = game mode default, -2 = provide the weapon in ca and lms" // UNTIL IT CAN BE REMOVED FROM CODE
+set g_start_weapon_minelayer -1 "0 = never provide the weapon, 1 = always provide the weapon, -1 = game mode default, -2 = provide the weapon in ca and lms"
+set g_start_weapon_rifle -1 "0 = never provide the weapon, 1 = always provide the weapon, -1 = game mode default, -2 = provide the weapon in ca and lms" // UNTIL IT CAN BE REMOVED FROM CODE
+set g_start_weapon_seeker -1 "0 = never provide the weapon, 1 = always provide the weapon, -1 = game mode default, -2 = provide the weapon in ca and lms"
+
+// {{{ hlac
+set g_balance_hlac_primary_spread_min 0.01
+set g_balance_hlac_primary_spread_max 0.25
+set g_balance_hlac_primary_spread_add 0.0045
+set g_balance_hlac_primary_spread_crouchmod 0.25
+
+set g_balance_hlac_primary_damage 18
+set g_balance_hlac_primary_edgedamage 9
+set g_balance_hlac_primary_force 90
+set g_balance_hlac_primary_radius 70
+set g_balance_hlac_primary_speed 9000
+set g_balance_hlac_primary_lifetime 5
+
+set g_balance_hlac_primary_refire 0.15
+set g_balance_hlac_primary_animtime 0.4
+set g_balance_hlac_primary_ammo 1
+
+set g_balance_hlac_secondary 1
+set g_balance_hlac_secondary_spread 0.15
+set g_balance_hlac_secondary_spread_crouchmod 0.5
+
+set g_balance_hlac_secondary_damage 15
+set g_balance_hlac_secondary_edgedamage 7.5
+set g_balance_hlac_secondary_force 90
+set g_balance_hlac_secondary_radius 70
+set g_balance_hlac_secondary_speed 9000
+set g_balance_hlac_secondary_lifetime 5
+
+set g_balance_hlac_secondary_refire 1
+set g_balance_hlac_secondary_animtime 0.3
+set g_balance_hlac_secondary_ammo 10
+set g_balance_hlac_secondary_shots 6
+
+set g_balance_hlac_reload_ammo 0 //default: 20
+set g_balance_hlac_reload_time 2
+// }}}
+// {{{ minelayer
+set g_balance_minelayer_damage 40
+set g_balance_minelayer_edgedamage 20
+set g_balance_minelayer_force 250
+set g_balance_minelayer_radius 175
+set g_balance_minelayer_proximityradius 150
+set g_balance_minelayer_speed 1000
+set g_balance_minelayer_lifetime 10
+set g_balance_minelayer_lifetime_countdown 0.5
+set g_balance_minelayer_refire 1.5
+set g_balance_minelayer_animtime 0.4
+set g_balance_minelayer_ammo 4
+set g_balance_minelayer_health 15
+set g_balance_minelayer_limit 3 // 0 disables the limit
+set g_balance_minelayer_protection 0 // don't explode if the mine would hurt the owner or a team mate
+set g_balance_minelayer_damageforcescale 0
+set g_balance_minelayer_detonatedelay -1 // positive: timer till detonation is allowed, negative: "security device" that prevents ANY remote detonation if it could hurt its owner, zero: detonatable at any time
+set g_balance_minelayer_time 0.5
+set g_balance_minelayer_remote_damage 45
+set g_balance_minelayer_remote_edgedamage 40
+set g_balance_minelayer_remote_radius 200
+set g_balance_minelayer_remote_force 300
+set g_balance_minelayer_reload_ammo 0 //default: 15
+set g_balance_minelayer_reload_time 2
+// }}}
+// {{{ rifle
+set g_balance_rifle_bursttime 0
+set g_balance_rifle_primary_tracer 1
+set g_balance_rifle_primary_shots 1
+set g_balance_rifle_primary_damage 40
+set g_balance_rifle_primary_headshotaddeddamage 40
+set g_balance_rifle_primary_spread 0
+set g_balance_rifle_primary_force 100
+set g_balance_rifle_primary_speed 40000
+set g_balance_rifle_primary_lifetime 5
+set g_balance_rifle_primary_refire 1.2
+set g_balance_rifle_primary_animtime 0.4
+set g_balance_rifle_primary_ammo 10
+set g_balance_rifle_primary_bulletconstant 110 // 62.2qu
+set g_balance_rifle_primary_burstcost 0
+set g_balance_rifle_primary_bullethail 0 // empty magazine on shot
+set g_balance_rifle_secondary 1
+set g_balance_rifle_secondary_reload 0
+set g_balance_rifle_secondary_tracer 0
+set g_balance_rifle_secondary_shots 4
+set g_balance_rifle_secondary_damage 10
+set g_balance_rifle_secondary_headshotaddeddamage 20
+set g_balance_rifle_secondary_spread 0.04
+set g_balance_rifle_secondary_force 50
+set g_balance_rifle_secondary_speed 20000
+set g_balance_rifle_secondary_lifetime 5
+set g_balance_rifle_secondary_refire 0.9
+set g_balance_rifle_secondary_animtime 0.3
+set g_balance_rifle_secondary_ammo 10
+set g_balance_rifle_secondary_bulletconstant 110 // 15.5qu
+set g_balance_rifle_secondary_burstcost 0
+set g_balance_rifle_secondary_bullethail 0 // empty magazine on shot
+set g_balance_rifle_reload_ammo 80 //default: 80
+set g_balance_rifle_reload_time 2
+// }}}
+// {{{ seeker
+set g_balance_seeker_type 1 // 0 = old seeker, 1 = new seeker. THIS IS A TEMPORARY CVAR FOR TESTING, will be removed later.
+set g_balance_seeker_flac_ammo 0.5
+set g_balance_seeker_flac_animtime 0.1
+set g_balance_seeker_flac_damage 15
+set g_balance_seeker_flac_edgedamage 10
+set g_balance_seeker_flac_force 50
+set g_balance_seeker_flac_lifetime 0.1
+set g_balance_seeker_flac_lifetime_rand 0.05
+set g_balance_seeker_flac_radius 100
+set g_balance_seeker_flac_refire 0.1
+set g_balance_seeker_flac_speed 3000
+set g_balance_seeker_flac_speed_up 1000
+set g_balance_seeker_flac_speed_z 0
+set g_balance_seeker_flac_spread 0.4
+set g_balance_seeker_tag_ammo 1
+set g_balance_seeker_tag_animtime 0.2
+set g_balance_seeker_tag_damageforcescale 0
+set g_balance_seeker_tag_health 0
+set g_balance_seeker_tag_lifetime 15
+set g_balance_seeker_tag_refire 0.75 // LOG: 0.7 -> 0.75
+set g_balance_seeker_tag_speed 5000
+set g_balance_seeker_tag_spread 0
+set g_balance_seeker_tag_tracker_lifetime 10
+set g_balance_seeker_missile_accel 1500
+set g_balance_seeker_missile_ammo 2
+set g_balance_seeker_missile_animtime 0.2
+set g_balance_seeker_missile_count 3 // LOG: 8 -> 3
+set g_balance_seeker_missile_damage 16 // LOG: 15 -> 30
+set g_balance_seeker_missile_damageforcescale 4
+set g_balance_seeker_missile_decel 6000
+set g_balance_seeker_missile_delay 0.25
+set g_balance_seeker_missile_edgedamage 8
+set g_balance_seeker_missile_force 50 // LOG: 100 -> 150
+set g_balance_seeker_missile_health 1
+set g_balance_seeker_missile_lifetime 15
+set g_balance_seeker_missile_proxy 0
+set g_balance_seeker_missile_proxy_delay 0.2
+set g_balance_seeker_missile_proxy_maxrange 45
+set g_balance_seeker_missile_radius 70
+set g_balance_seeker_missile_refire 0.25
+set g_balance_seeker_missile_smart 0
+set g_balance_seeker_missile_smart_mindist 800
+set g_balance_seeker_missile_smart_trace_max 2500
+set g_balance_seeker_missile_smart_trace_min 1000
+set g_balance_seeker_missile_speed 1500
+set g_balance_seeker_missile_speed_up 0
+set g_balance_seeker_missile_speed_z 0
+set g_balance_seeker_missile_speed_max 2000 // LOG: 1400 -> 1300
+set g_balance_seeker_missile_spread 0
+set g_balance_seeker_missile_turnrate 0.15
+set g_balance_seeker_reload_ammo 0 //default: 15
+set g_balance_seeker_reload_time 2
+// End new seeker
index 81f49a47653035d8ab36ae21637a63f0da8aa3e5..f8419aa08acf935ae95648103131b839f5543b2f 100644 (file)
@@ -103,7 +103,7 @@ void register_weapons_done();
 # define WEPSET_COPY_EE(e,o) ((e)._WS_weapons = (o)._WS_weapons)
 # define WEPSET_EQ_EE(e,o) ((e)._WS_weapons == (o)._WS_weapons)
 # define WEPSET_OR_EE(e,o) ((e)._WS_weapons |= (o)._WS_weapons)
-# define WEPSET_AND_EE(e,o) ((e)._WS_weapons &= (o)._WS_weapons)
+# define WEPSET_AND_EE(e,o) ((e)._WS_weapons = (e)._WS_weapons & (o)._WS_weapons)
 # define WEPSET_ANDNOT_EE(e,o) ((e)._WS_weapons &~= (o)._WS_weapons)
 # define WEPSET_CONTAINS_ANY_EE(e,o) !!((e)._WS_weapons & (o)._WS_weapons)
 # define WEPSET_CONTAINS_ALL_EE(e,o) !!(((e)._WS_weapons & (o)._WS_weapons) == (e)._WS_weapons)
@@ -111,7 +111,7 @@ void register_weapons_done();
 # define WEPSET_COPY_EA(e,a) ((e)._WS_weapons = (_WS_##a))
 # define WEPSET_EQ_EA(e,a) ((e)._WS_weapons == (_WS_##a))
 # define WEPSET_OR_EA(e,a) ((e)._WS_weapons |= (_WS_##a))
-# define WEPSET_AND_EA(e,a) ((e)._WS_weapons &= (_WS_##a))
+# define WEPSET_AND_EA(e,a) ((e)._WS_weapons = (e)._WS_weapons & (_WS_##a))
 # define WEPSET_ANDNOT_EA(e,a) ((e)._WS_weapons &~= (_WS_##a))
 # define WEPSET_CONTAINS_ANY_EA(e,a) !!((e)._WS_weapons & (_WS_##a))
 # define WEPSET_CONTAINS_ALL_EA(e,a) !!(((e)._WS_weapons & (_WS_##a)) == (_WS_##a))
@@ -119,14 +119,14 @@ void register_weapons_done();
 # define WEPSET_COPY_EW(e,w) ((e)._WS_weapons = power2of((w) - WEP_FIRST))
 # define WEPSET_EQ_EW(e,w) ((e)._WS_weapons == power2of((w) - WEP_FIRST))
 # define WEPSET_OR_EW(e,w) ((e)._WS_weapons |= power2of((w) - WEP_FIRST))
-# define WEPSET_AND_EW(e,w) ((e)._WS_weapons &= power2of((w) - WEP_FIRST))
+# define WEPSET_AND_EW(e,w) ((e)._WS_weapons = (e)._WS_weapons & power2of((w) - WEP_FIRST))
 # define WEPSET_ANDNOT_EW(e,w) ((e)._WS_weapons &~= power2of((w) - WEP_FIRST))
 # define WEPSET_CONTAINS_EW(e,w) !!((e)._WS_weapons & power2of((w) - WEP_FIRST))
 
 # define WEPSET_COPY_AE(a,e) ((_WS_##a) = (e)._WS_weapons)
 # define WEPSET_EQ_AE(a,e) ((_WS_##a) == (e)._WS_weapons)
 # define WEPSET_OR_AE(a,e) ((_WS_##a) |= (e)._WS_weapons)
-# define WEPSET_AND_AE(a,e) ((_WS_##a) &= (e)._WS_weapons)
+# define WEPSET_AND_AE(a,e) ((_WS_##a) = (_WS_##a) & (e)._WS_weapons)
 # define WEPSET_ANDNOT_AE(a,e) ((_WS_##a) &~= (e)._WS_weapons)
 # define WEPSET_CONTAINS_ANY_AE(a,e) !!((_WS_##a) & (e)._WS_weapons)
 # define WEPSET_CONTAINS_ALL_AE(a,e) !!(((_WS_##a) & (e)._WS_weapons) == (e))
@@ -134,7 +134,7 @@ void register_weapons_done();
 # define WEPSET_COPY_AA(a,b) ((_WS_##a) = (_WS_##b))
 # define WEPSET_EQ_AA(a,b) ((_WS_##a) == (_WS_##b))
 # define WEPSET_OR_AA(a,b) ((_WS_##a) |= (_WS_##b))
-# define WEPSET_AND_AA(a,b) ((_WS_##a) &= (_WS_##b))
+# define WEPSET_AND_AA(a,b) ((_WS_##a) = (_WS_##a) & (_WS_##b))
 # define WEPSET_ANDNOT_AA(a,b) ((_WS_##a) &~= (_WS_##b))
 # define WEPSET_CONTAINS_ANY_AA(a,b) !!((_WS_##a) & (_WS_##b))
 # define WEPSET_CONTAINS_ALL_AA(a,b) !!(((_WS_##a) & (_WS_##b)) == (_WS_##b))
@@ -142,7 +142,7 @@ void register_weapons_done();
 # define WEPSET_COPY_AW(a,w) ((_WS_##a) = power2of((w) - WEP_FIRST))
 # define WEPSET_EQ_AW(a,w) ((_WS_##a) == power2of((w) - WEP_FIRST))
 # define WEPSET_OR_AW(a,w) ((_WS_##a) |= power2of((w) - WEP_FIRST))
-# define WEPSET_AND_AW(a,w) ((_WS_##a) &= power2of((w) - WEP_FIRST))
+# define WEPSET_AND_AW(a,w) ((_WS_##a) = (_WS_##a) & power2of((w) - WEP_FIRST))
 # define WEPSET_ANDNOT_AW(a,w) ((_WS_##a) &~= power2of((w) - WEP_FIRST))
 # define WEPSET_CONTAINS_AW(a,w) !!((_WS_##a) & power2of((w) - WEP_FIRST))
 
index 078455a123a8290f062b4bfce89f20d00419c884..737ab23d8368c9a385247879da0a98c184f0a24f 100644 (file)
@@ -516,9 +516,9 @@ void W_WeaponFrame()
 
 string W_Apply_Weaponreplace(string in)
 {
-       string newlist;
        float n = tokenize_console(in);
        string out = "";
+       float i;
        for(i = 0; i < n; ++i)
        {
                string s = argv(i);
@@ -528,5 +528,5 @@ string W_Apply_Weaponreplace(string in)
                else if(r != "0")
                        out = strcat(out, " ", r);
        }
-       return substring(out, 1);
+       return substring(out, 1, -1);
 }
index d754352bf85cd23aee1192d629342fa7b90e1eda..0b17144ea7cbeafd43ef735b299991f67a00280b 100644 (file)
@@ -786,8 +786,6 @@ float want_weapon(string cvarprefix, entity weaponinfo, float allguns)
 
        if (g_lms || g_ca || allguns)
                d = (weaponinfo.spawnflags & WEP_FLAG_NORMAL);
-       else if(t < -1)
-               d = 0;
        else if (g_cts)
                d = (i == WEP_SHOTGUN);
        else if (g_nexball)
@@ -934,7 +932,7 @@ void readplayerstartcvars()
                for (i = WEP_FIRST; i <= WEP_LAST; ++i)
                {
                        e = get_weaponinfo(i);
-                       w = want_weapon("g_start_weapon_", e, FALSE);
+                       float w = want_weapon("g_start_weapon_", e, FALSE);
                        if(w & 1)
                                WEPSET_OR_AW(start_weapons, i);
                        if(w & 2)
@@ -1015,7 +1013,7 @@ void readplayerstartcvars()
                        for (i = WEP_FIRST; i <= WEP_LAST; ++i)
                        {
                                e = get_weaponinfo(i);
-                               w = want_weapon("g_start_weapon_", e, cvar("g_warmup_allguns"));
+                               float w = want_weapon("g_start_weapon_", e, cvar("g_warmup_allguns"));
                                if(w & 1)
                                        WEPSET_OR_AW(warmup_start_weapons, i);
                                if(w & 2)
index 09e27038987b2f915b425de5bdcfed20bce694a6..236e311b6a0cb8c0fa7fa39631678b8b46f6ab64 100644 (file)
@@ -206,7 +206,7 @@ MUTATOR_HOOKABLE(SetModname);
        // OUT
        string modname; // name of the mutator/mod if it warrants showing as such in the server browser
 
-MUTATOR_HOOKABLE(SetDefaultWeaponreplace);
+MUTATOR_HOOKABLE(SetWeaponreplace);
        // IN
                entity self; // map entity
                entity other; // weapon info
index 461272e7e9f63b976b5e7b6cde3694ee71db9096..bdd214739cc5f493118a5ad001171337d62045c7 100644 (file)
@@ -66,7 +66,12 @@ start weapon selection.
 
 */
 
-float autocvar_g_new_toys_autoreplace = 2; // 0 = never, 1 = always, 2 = random
+.string new_toys;
+
+float autocvar_g_new_toys_autoreplace;
+#define NT_AUTOREPLACE_NEVER 0
+#define NT_AUTOREPLACE_ALWAYS 1
+#define NT_AUTOREPLACE_RANDOM 2
 
 MUTATOR_HOOKFUNCTION(nt_SetModname)
 {
@@ -88,12 +93,12 @@ string nt_GetFullReplacement(string w)
 
 string nt_GetReplacement(string w, float m)
 {
-       if(m == 0)
+       if(m == NT_AUTOREPLACE_NEVER)
                return w;
        string s = nt_GetFullReplacement(w);
        if not(s)
                return w;
-       if(m == 2)
+       if(m == NT_AUTOREPLACE_RANDOM)
                s = strcat(w, " ", s);
        return s;
 }
@@ -150,15 +155,11 @@ MUTATOR_HOOKFUNCTION(nt_SetWeaponreplace)
                // map defined replacement:
                ret_string = self.new_toys;
        }
-       else if(autocvar_g_new_toys_autoreplace)
+       else
        {
                // auto replacement:
                ret_string = nt_GetReplacement(other.netname, autocvar_g_new_toys_autoreplace);
        }
-       else
-       {
-               ret_string = other.netname;
-       }
 
        // apply regular weaponreplace
        ret_string = W_Apply_Weaponreplace(ret_string);
index 0dbe5378186ab296c6cff094d0dfce718d9dfdd4..1890eddd97a679ae3f279e258dcfe0eb55c6c9f4 100644 (file)
@@ -210,6 +210,7 @@ mutators/gamemode_keyhunt.qc
 mutators/gamemode_freezetag.qc
 mutators/gamemode_keepaway.qc
 mutators/mutator_invincibleproj.qc
+mutators/mutator_new_toys.qc
 mutators/mutator_nix.qc
 mutators/mutator_dodging.qc
 mutators/mutator_rocketflying.qc
index d72cfef87bab5754af8e332bbedb11bbaee299e3..344c3c77ce7fec3b0a66b2e4a72d6c328681a10b 100644 (file)
@@ -991,7 +991,7 @@ void weapon_defaultspawnfunc(float wpn)
                s = W_Apply_Weaponreplace(e.netname);
                ret_string = s;
                other = e;
-               MUTATOR_CALLHOOK(SetDefaultWeaponreplace);
+               MUTATOR_CALLHOOK(SetWeaponreplace);
                s = ret_string;
                if(s == "")
                {
index f415e1fd1d397ad2a632c78648054d70c1f3ffaa..82b5f4457a9b8c5aeea05b5e185085a72fb5160b 100644 (file)
@@ -22,9 +22,9 @@ void spawnfunc_ammo_lightning()      { spawnfunc_item_cells();          }
 void spawnfunc_weapon_plasmagun()    { spawnfunc_weapon_hagar();        }
 void spawnfunc_ammo_cells()          { spawnfunc_item_rockets();        }
 
-// Rail -> Rifle
-void spawnfunc_weapon_railgun()      { spawnfunc_weapon_rifle();  }
-void spawnfunc_ammo_slugs()          { spawnfunc_item_bullets();        }
+// Rail -> Nex
+void spawnfunc_weapon_railgun()      { spawnfunc_weapon_nex();          }
+void spawnfunc_ammo_slugs()          { spawnfunc_item_cells();          }
 
 // BFG -> Crylink
 void spawnfunc_weapon_bfg()          { spawnfunc_weapon_crylink();      }
index 33b4a89ebace441669d7f1118f4cdc43c97141b5..a3036af81db635f26e6c2c316b0cc0c031a25f76 100644 (file)
@@ -327,8 +327,6 @@ void W_Mine_Attack (void)
        self.minelayer_mines = W_Mine_Count(self);
 }
 
-void spawnfunc_weapon_minelayer (void); // defined in t_items.qc
-
 float W_PlacedMines(float detonate)
 {
        entity mine;