]> de.git.xonotic.org Git - xonotic/xonotic-data.pk3dir.git/commitdiff
Merge remote branch 'origin/master' into divVerent/crypto2
authorRudolf Polzer <divverent@alientrap.org>
Fri, 15 Oct 2010 13:16:19 +0000 (15:16 +0200)
committerRudolf Polzer <divverent@alientrap.org>
Fri, 15 Oct 2010 13:16:19 +0000 (15:16 +0200)
107 files changed:
balance25.cfg
balanceLeeStricklin.cfg
balanceNexSVN.cfg
balanceSamual.cfg
balanceXonotic.cfg
defaultXonotic.cfg
effectinfo.txt
gfx/crosshair1.tga [new file with mode: 0644]
gfx/crosshair10.tga
gfx/crosshair11.tga
gfx/crosshair12.tga
gfx/crosshair13.tga
gfx/crosshair14.tga
gfx/crosshair16.tga
gfx/crosshair17.tga
gfx/crosshair2.tga [new file with mode: 0644]
gfx/crosshair3.tga [new file with mode: 0644]
gfx/crosshair4.tga [new file with mode: 0644]
gfx/crosshair5.tga [new file with mode: 0644]
gfx/crosshair6.tga [new file with mode: 0644]
gfx/crosshair7.tga
gfx/crosshair8.tga
gfx/crosshair9.tga
gfx/crosshair_ring.tga [new file with mode: 0644]
gfx/crosshairdot.tga [new file with mode: 0644]
gfx/crosshairminelayer.tga [new file with mode: 0644]
gfx/hud/default/weaponminelayer.tga [new file with mode: 0644]
gfx/hud/luminos/weaponminelayer.tga [new file with mode: 0644]
gfx/hud/old/weaponminelayer.tga [new file with mode: 0644]
gfx/loading.tga
gfx/nex_ring.tga [deleted file]
models/keyhunt/key.tga
models/mine.md3 [new file with mode: 0644]
models/weapons/g_minelayer.md3 [new file with mode: 0644]
models/weapons/h_minelayer.iqm [new file with mode: 0644]
models/weapons/h_minelayer.iqm.framegroups [new file with mode: 0644]
models/weapons/v_minelayer.md3 [new file with mode: 0644]
particles/lgbeam.tga
qcsrc/client/Defs.qc
qcsrc/client/Main.qc
qcsrc/client/View.qc
qcsrc/client/hud.qc
qcsrc/client/projectile.qc
qcsrc/client/wall.qc
qcsrc/common/constants.qh
qcsrc/common/util.qc
qcsrc/common/util.qh
qcsrc/menu/xonotic/crosshairbutton.c
qcsrc/menu/xonotic/dialog_multiplayer_create_mutators.c
qcsrc/menu/xonotic/dialog_multiplayer_playersetup.c
qcsrc/qc-server.cbp
qcsrc/server/bot/havocbot/havocbot.qc
qcsrc/server/cl_client.qc
qcsrc/server/cl_physics.qc
qcsrc/server/cl_weapons.qc
qcsrc/server/cl_weaponsystem.qc
qcsrc/server/defs.qh
qcsrc/server/g_damage.qc
qcsrc/server/g_models.qc
qcsrc/server/g_subs.qc
qcsrc/server/g_triggers.qc
qcsrc/server/miscfunctions.qc
qcsrc/server/monsters/mode_management.qc
qcsrc/server/t_plats.qc
qcsrc/server/w_all.qc
qcsrc/server/w_campingrifle.qc
qcsrc/server/w_electro.qc
qcsrc/server/w_fireball.qc
qcsrc/server/w_minelayer.qc [new file with mode: 0644]
qcsrc/server/w_nex.qc
qcsrc/warpzonelib/server.qc
sound/weapons/campingrifle_fire2.ogg
sound/weapons/mine_det.ogg [new file with mode: 0644]
sound/weapons/mine_exp.ogg [new file with mode: 0644]
sound/weapons/mine_fire.ogg [new file with mode: 0644]
sound/weapons/mine_stick.wav [new file with mode: 0644]
sound/weapons/mine_trigger.wav [new file with mode: 0644]
textures/gakarmor_glow.tga [new file with mode: 0644]
textures/gakarmor_pants.tga [deleted file]
textures/items/a_bullets.jpg [deleted file]
textures/items/a_bullets.tga [new file with mode: 0644]
textures/pickups.tga
textures/pickups_bump.tga
textures/pickups_gloss.tga
textures/pickups_glow.tga
textures/portals/portals_blue.tga
textures/portals/portals_blue_gloss.tga
textures/portals/portals_blue_glow.tga
textures/portals/portals_blue_norm.tga
textures/portals/portals_red.tga
textures/portals/portals_red_gloss.tga
textures/portals/portals_red_glow.tga
textures/portals/portals_red_norm.tga
textures/pyria_glow.jpg [deleted file]
textures/pyria_glow.tga
textures/pyria_pants.tga [deleted file]
textures/pyria_shirt.tga
textures/reptile.tga [deleted file]
textures/reptile_bump.tga [deleted file]
textures/reptile_gloss.tga [deleted file]
textures/reptile_glow.tga [deleted file]
textures/reptile_pants.tga [deleted file]
textures/reptile_shirt.tga [deleted file]
textures/umbra_glow.jpg [deleted file]
textures/umbra_glow.tga [new file with mode: 0644]
textures/umbra_pants.tga [deleted file]
textures/umbra_shirt.tga

index 6287460ca329849a946f1ac2e5839451f2fabb1d..90751d279d6d0d18744618855fd2aa187adfe49e 100644 (file)
@@ -3,6 +3,7 @@ set g_start_weapon_laser -1 "0 = never provide the weapon, 1 = always provide th
 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"
@@ -308,6 +309,28 @@ set g_balance_grenadelauncher_secondary_bouncefactor 0.5
 set g_balance_grenadelauncher_secondary_bouncestop 0.075
 set g_balance_grenadelauncher_secondary_remote_detonateprimary 0
 // }}}
+// {{{ minelayer // TODO
+set g_balance_minelayer_damage 35
+set g_balance_minelayer_edgedamage 30
+set g_balance_minelayer_force 250
+set g_balance_minelayer_radius 175
+set g_balance_minelayer_proximityradius 150
+set g_balance_minelayer_speed 750
+set g_balance_minelayer_lifetime 60
+set g_balance_minelayer_refire 1.5
+set g_balance_minelayer_animtime 0.4
+set g_balance_minelayer_ammo 5
+set g_balance_minelayer_health 15
+set g_balance_minelayer_limit 4 // 0 disables the limit
+set g_balance_minelayer_protection 1 // 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
+// }}}
 // {{{ electro
 set g_balance_electro_lightning 0
 set g_balance_electro_primary_damage 65
@@ -401,6 +424,9 @@ set g_balance_nex_primary_damagefalloff_halflife 0
 set g_balance_nex_primary_damagefalloff_forcehalflife 0
 
 set g_balance_nex_secondary 0
+set g_balance_nex_secondary_charge 0
+set g_balance_nex_secondary_charge_rate 200
+set g_balance_nex_secondary_charge_ammo 10
 set g_balance_nex_secondary_damage 100
 set g_balance_nex_secondary_force 600
 set g_balance_nex_secondary_refire 1.5
@@ -414,6 +440,7 @@ set g_balance_nex_secondary_damagefalloff_forcehalflife 0
 set g_balance_nex_velocitydependent_halflife 0
 set g_balance_nex_velocitydependent_minspeed 400
 set g_balance_nex_velocitydependent_maxspeed 1000
+set g_balance_nex_velocitydependent_falloff_rate 0.001
 // }}}
 // {{{ minstanex
 set g_balance_minstanex_refire 1
@@ -538,7 +565,7 @@ set g_balance_campingrifle_magazinecapacity 8
 set g_balance_campingrifle_reloadtime 2 // matches reload anim
 set g_balance_campingrifle_auto_reload_after_changing_weapons 0
 set g_balance_campingrifle_bursttime 0
-set g_balance_campingrifle_tracer 0
+set g_balance_campingrifle_primary_tracer 0
 set g_balance_campingrifle_primary_damage 60
 set g_balance_campingrifle_primary_headshotaddeddamage 100
 set g_balance_campingrifle_primary_spread 0
@@ -552,6 +579,7 @@ set g_balance_campingrifle_primary_bulletconstant 130 // 56.3qu
 set g_balance_campingrifle_primary_burstcost 0
 set g_balance_campingrifle_primary_bullethail 0 // empty magazine on shot
 set g_balance_campingrifle_secondary 1
+set g_balance_campingrifle_secondary_tracer 0
 set g_balance_campingrifle_secondary_damage 35
 set g_balance_campingrifle_secondary_headshotaddeddamage 15 // 50 damage only on head
 set g_balance_campingrifle_secondary_spread 0.008
index 8a0ae6c46224929acbb9574496eb204d40f22db6..36d5435e1b9cf4d8055bb9a5a15084c3c1574b56 100644 (file)
@@ -13,6 +13,7 @@ set g_start_weapon_laser -1 "0 = never provide the weapon, 1 = always provide th
 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"
@@ -319,6 +320,28 @@ set g_balance_grenadelauncher_secondary_bouncefactor 0.7
 set g_balance_grenadelauncher_secondary_bouncestop 0.12
 set g_balance_grenadelauncher_secondary_remote_detonateprimary 0
 // }}}
+// {{{ minelayer // TODO
+set g_balance_minelayer_damage 35
+set g_balance_minelayer_edgedamage 30
+set g_balance_minelayer_force 250
+set g_balance_minelayer_radius 175
+set g_balance_minelayer_proximityradius 150
+set g_balance_minelayer_speed 750
+set g_balance_minelayer_lifetime 60
+set g_balance_minelayer_refire 1.5
+set g_balance_minelayer_animtime 0.4
+set g_balance_minelayer_ammo 5
+set g_balance_minelayer_health 15
+set g_balance_minelayer_limit 4 // 0 disables the limit
+set g_balance_minelayer_protection 1 // 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
+// }}}
 // {{{ electro
 set g_balance_electro_lightning 0
 set g_balance_electro_primary_damage 55
@@ -412,6 +435,9 @@ set g_balance_nex_primary_damagefalloff_halflife 9999999
 set g_balance_nex_primary_damagefalloff_forcehalflife 9999999
 
 set g_balance_nex_secondary 0
+set g_balance_nex_secondary_charge 0
+set g_balance_nex_secondary_charge_rate 200
+set g_balance_nex_secondary_charge_ammo 10
 set g_balance_nex_secondary_damage 80
 set g_balance_nex_secondary_force -500
 set g_balance_nex_secondary_refire 1.25
@@ -425,6 +451,7 @@ set g_balance_nex_secondary_damagefalloff_forcehalflife 9999999
 set g_balance_nex_velocitydependent_halflife 0
 set g_balance_nex_velocitydependent_minspeed 400
 set g_balance_nex_velocitydependent_maxspeed 1000
+set g_balance_nex_velocitydependent_falloff_rate 0.001
 // }}}
 // {{{ minstanex
 set g_balance_minstanex_refire 1
@@ -549,7 +576,7 @@ set g_balance_campingrifle_magazinecapacity 8
 set g_balance_campingrifle_reloadtime 2 // matches reload anim
 set g_balance_campingrifle_auto_reload_after_changing_weapons 0
 set g_balance_campingrifle_bursttime 0.85 // 0.35 - 0.1 + 0.35 - 0.1 + 0.35 = three secondaries
-set g_balance_campingrifle_tracer 1
+set g_balance_campingrifle_primary_tracer 0
 set g_balance_campingrifle_primary_damage 75
 set g_balance_campingrifle_primary_headshotaddeddamage 90
 set g_balance_campingrifle_primary_spread 0
@@ -563,6 +590,7 @@ set g_balance_campingrifle_primary_bulletconstant 130 // 56.3qu
 set g_balance_campingrifle_primary_burstcost 0 // require same cooldown as secondary, note it's smaller than primary refire time
 set g_balance_campingrifle_primary_bullethail 0 // empty magazine on shot
 set g_balance_campingrifle_secondary 1
+set g_balance_campingrifle_secondary_tracer 0
 set g_balance_campingrifle_secondary_damage 40
 set g_balance_campingrifle_secondary_headshotaddeddamage 20
 set g_balance_campingrifle_secondary_spread 0.008
index 36615d790cbb7c6d12e55c5ba3ac076b61d6fb75..966d58cbffaf6842582cf9877c9f0f008811f5ef 100644 (file)
@@ -3,6 +3,7 @@ set g_start_weapon_laser -1 "0 = never provide the weapon, 1 = always provide th
 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"
@@ -307,6 +308,28 @@ set g_balance_grenadelauncher_secondary_bouncefactor 0.5
 set g_balance_grenadelauncher_secondary_bouncestop 0.075
 set g_balance_grenadelauncher_secondary_remote_detonateprimary 0
 // }}}
+// {{{ minelayer // TODO
+set g_balance_minelayer_damage 35
+set g_balance_minelayer_edgedamage 30
+set g_balance_minelayer_force 250
+set g_balance_minelayer_radius 175
+set g_balance_minelayer_proximityradius 150
+set g_balance_minelayer_speed 750
+set g_balance_minelayer_lifetime 60
+set g_balance_minelayer_refire 1.5
+set g_balance_minelayer_animtime 0.4
+set g_balance_minelayer_ammo 5
+set g_balance_minelayer_health 15
+set g_balance_minelayer_limit 4 // 0 disables the limit
+set g_balance_minelayer_protection 1 // 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
+// }}}
 // {{{ electro
 set g_balance_electro_lightning 0
 set g_balance_electro_primary_damage 65
@@ -400,6 +423,9 @@ set g_balance_nex_primary_damagefalloff_halflife 1500
 set g_balance_nex_primary_damagefalloff_forcehalflife 1500
 
 set g_balance_nex_secondary 0
+set g_balance_nex_secondary_charge 0
+set g_balance_nex_secondary_charge_rate 200
+set g_balance_nex_secondary_charge_ammo 10
 set g_balance_nex_secondary_damage 90
 set g_balance_nex_secondary_force 200
 set g_balance_nex_secondary_refire 1.5
@@ -413,6 +439,7 @@ set g_balance_nex_secondary_damagefalloff_forcehalflife 1500
 set g_balance_nex_velocitydependent_halflife 0
 set g_balance_nex_velocitydependent_minspeed 400
 set g_balance_nex_velocitydependent_maxspeed 1000
+set g_balance_nex_velocitydependent_falloff_rate 0.001
 // }}}
 // {{{ minstanex
 set g_balance_minstanex_refire 1
@@ -537,7 +564,7 @@ set g_balance_campingrifle_magazinecapacity 0
 set g_balance_campingrifle_reloadtime 2 // matches reload anim
 set g_balance_campingrifle_auto_reload_after_changing_weapons 0
 set g_balance_campingrifle_bursttime 0.85 // 0.35 - 0.1 + 0.35 - 0.1 + 0.35 = three secondaries
-set g_balance_campingrifle_tracer 1
+set g_balance_campingrifle_primary_tracer 0
 set g_balance_campingrifle_primary_damage 50
 set g_balance_campingrifle_primary_headshotaddeddamage 50
 set g_balance_campingrifle_primary_spread 0
@@ -551,6 +578,7 @@ set g_balance_campingrifle_primary_bulletconstant 130 // 56.3qu
 set g_balance_campingrifle_primary_burstcost 0.35 // require same cooldown as secondary, note it's smaller than primary refire time
 set g_balance_campingrifle_primary_bullethail 0
 set g_balance_campingrifle_secondary 1
+set g_balance_campingrifle_secondary_tracer 0
 set g_balance_campingrifle_secondary_damage 15
 set g_balance_campingrifle_secondary_headshotaddeddamage 25
 set g_balance_campingrifle_secondary_spread 0.02
index aeed47e8986b05e972cc96bc387cf511d8a20a7d..966f0b2dd0ee3f165c264f706d9d558cce72a66a 100644 (file)
@@ -3,6 +3,7 @@ set g_start_weapon_laser -1 "0 = never provide the weapon, 1 = always provide th
 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"
@@ -308,6 +309,28 @@ set g_balance_grenadelauncher_secondary_bouncefactor 0.5
 set g_balance_grenadelauncher_secondary_bouncestop 0.075
 set g_balance_grenadelauncher_secondary_remote_detonateprimary 1
 // }}}
+// {{{ minelayer // TODO
+set g_balance_minelayer_damage 35
+set g_balance_minelayer_edgedamage 30
+set g_balance_minelayer_force 250
+set g_balance_minelayer_radius 175
+set g_balance_minelayer_proximityradius 150
+set g_balance_minelayer_speed 750
+set g_balance_minelayer_lifetime 60
+set g_balance_minelayer_refire 1.5
+set g_balance_minelayer_animtime 0.4
+set g_balance_minelayer_ammo 5
+set g_balance_minelayer_health 15
+set g_balance_minelayer_limit 4 // 0 disables the limit
+set g_balance_minelayer_protection 1 // 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
+// }}}
 // {{{ electro
 set g_balance_electro_lightning 0
 set g_balance_electro_primary_damage 65
@@ -401,6 +424,9 @@ set g_balance_nex_primary_damagefalloff_halflife 1500
 set g_balance_nex_primary_damagefalloff_forcehalflife 1500
 
 set g_balance_nex_secondary 0
+set g_balance_nex_secondary_charge 0
+set g_balance_nex_secondary_charge_rate 200
+set g_balance_nex_secondary_charge_ammo 10
 set g_balance_nex_secondary_damage 90
 set g_balance_nex_secondary_force 300
 set g_balance_nex_secondary_refire 1.5
@@ -414,6 +440,7 @@ set g_balance_nex_secondary_damagefalloff_forcehalflife 1500
 set g_balance_nex_velocitydependent_halflife 0
 set g_balance_nex_velocitydependent_minspeed 400
 set g_balance_nex_velocitydependent_maxspeed 1000
+set g_balance_nex_velocitydependent_falloff_rate 0.001
 // }}}
 // {{{ minstanex
 set g_balance_minstanex_refire 1
@@ -538,7 +565,7 @@ set g_balance_campingrifle_magazinecapacity 0
 set g_balance_campingrifle_reloadtime 2 // matches reload anim
 set g_balance_campingrifle_auto_reload_after_changing_weapons 0
 set g_balance_campingrifle_bursttime 0.85 // 0.35 - 0.1 + 0.35 - 0.1 + 0.35 = three secondaries
-set g_balance_campingrifle_tracer 1
+set g_balance_campingrifle_primary_tracer 0
 set g_balance_campingrifle_primary_damage 50
 set g_balance_campingrifle_primary_headshotaddeddamage 50
 set g_balance_campingrifle_primary_spread 0
@@ -552,6 +579,7 @@ set g_balance_campingrifle_primary_bulletconstant 130 // 56.3qu
 set g_balance_campingrifle_primary_burstcost 0.35 // require same cooldown as secondary, note it's smaller than primary refire time
 set g_balance_campingrifle_primary_bullethail 0
 set g_balance_campingrifle_secondary 1
+set g_balance_campingrifle_secondary_tracer 0
 set g_balance_campingrifle_secondary_damage 15
 set g_balance_campingrifle_secondary_headshotaddeddamage 25
 set g_balance_campingrifle_secondary_spread 0.02
index e28bd844dec4d0d9214cdd7f5bdaa54f4c522232..08ee53140d88a60323a6fa79b6cc28acedc27c21 100644 (file)
@@ -3,6 +3,7 @@ set g_start_weapon_laser -1 "0 = never provide the weapon, 1 = always provide th
 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"
@@ -254,12 +255,12 @@ set g_balance_shotgun_secondary_animtime 1
 // }}}
 // {{{ uzi
 set g_balance_uzi_first 1
-set g_balance_uzi_first_damage 17
+set g_balance_uzi_first_damage 16
 set g_balance_uzi_first_force 35
 set g_balance_uzi_first_spread 0.03
 set g_balance_uzi_first_refire 0.2
 set g_balance_uzi_first_ammo 2
-set g_balance_uzi_sustained_damage 12
+set g_balance_uzi_sustained_damage 9
 set g_balance_uzi_sustained_force 7.5
 set g_balance_uzi_sustained_spread 0.1
 set g_balance_uzi_sustained_refire 0.1
@@ -268,12 +269,12 @@ set g_balance_uzi_speed 18000
 set g_balance_uzi_bulletconstant 115 // 13.1qu
 // }}}
 // {{{ mortar // TODO
-set g_balance_grenadelauncher_primary_type 1
+set g_balance_grenadelauncher_primary_type 0
 set g_balance_grenadelauncher_primary_damage 60
 set g_balance_grenadelauncher_primary_edgedamage 25
 set g_balance_grenadelauncher_primary_force 300
 set g_balance_grenadelauncher_primary_radius 100
-set g_balance_grenadelauncher_primary_speed 1000
+set g_balance_grenadelauncher_primary_speed 1200
 set g_balance_grenadelauncher_primary_speed_up 225
 set g_balance_grenadelauncher_primary_speed_z 0
 set g_balance_grenadelauncher_primary_spread 0
@@ -282,23 +283,23 @@ set g_balance_grenadelauncher_primary_lifetime2 0.65
 set g_balance_grenadelauncher_primary_refire 0.8
 set g_balance_grenadelauncher_primary_animtime 0.4
 set g_balance_grenadelauncher_primary_ammo 2
-set g_balance_grenadelauncher_primary_health 72
+set g_balance_grenadelauncher_primary_health 80
 set g_balance_grenadelauncher_primary_damageforcescale 0
 set g_balance_grenadelauncher_primary_bouncefactor 0.5
 set g_balance_grenadelauncher_primary_bouncestop 0.12
-set g_balance_grenadelauncher_primary_remote_minbouncecnt 1
+set g_balance_grenadelauncher_primary_remote_minbouncecnt 0
 
-set g_balance_grenadelauncher_secondary_type 0
-set g_balance_grenadelauncher_secondary_damage 90
+set g_balance_grenadelauncher_secondary_type 1
+set g_balance_grenadelauncher_secondary_damage 80
 set g_balance_grenadelauncher_secondary_edgedamage 32
 set g_balance_grenadelauncher_secondary_force 300
 set g_balance_grenadelauncher_secondary_radius 150
-set g_balance_grenadelauncher_secondary_speed 1400
+set g_balance_grenadelauncher_secondary_speed 1200
 set g_balance_grenadelauncher_secondary_speed_up 225
 set g_balance_grenadelauncher_secondary_speed_z 0
 set g_balance_grenadelauncher_secondary_spread 0
-set g_balance_grenadelauncher_secondary_lifetime 5
-set g_balance_grenadelauncher_secondary_lifetime2 1
+set g_balance_grenadelauncher_secondary_lifetime 3
+set g_balance_grenadelauncher_secondary_lifetime2 0.65
 set g_balance_grenadelauncher_secondary_refire 0.8
 set g_balance_grenadelauncher_secondary_animtime 0.4
 set g_balance_grenadelauncher_secondary_ammo 2
@@ -306,7 +307,29 @@ set g_balance_grenadelauncher_secondary_health 40
 set g_balance_grenadelauncher_secondary_damageforcescale 0
 set g_balance_grenadelauncher_secondary_bouncefactor 0.5
 set g_balance_grenadelauncher_secondary_bouncestop 0.12
-set g_balance_grenadelauncher_secondary_remote_detonateprimary 1
+set g_balance_grenadelauncher_secondary_remote_detonateprimary 0
+// }}}
+// {{{ minelayer // TODO
+set g_balance_minelayer_damage 35
+set g_balance_minelayer_edgedamage 30
+set g_balance_minelayer_force 250
+set g_balance_minelayer_radius 175
+set g_balance_minelayer_proximityradius 150
+set g_balance_minelayer_speed 750
+set g_balance_minelayer_lifetime 60
+set g_balance_minelayer_refire 1.5
+set g_balance_minelayer_animtime 0.4
+set g_balance_minelayer_ammo 5
+set g_balance_minelayer_health 15
+set g_balance_minelayer_limit 4 // 0 disables the limit
+set g_balance_minelayer_protection 1 // 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
 // }}}
 // {{{ electro // TODO
 set g_balance_electro_lightning 1
@@ -390,7 +413,7 @@ set g_balance_crylink_secondary_line_lifetime 2 // range: 4000 full, fades to 80
 set g_balance_crylink_secondary_line_fadetime 2
 // }}}
 // {{{ nex
-set g_balance_nex_primary_damage 125
+set g_balance_nex_primary_damage 120
 set g_balance_nex_primary_force 500
 set g_balance_nex_primary_refire 1
 set g_balance_nex_primary_animtime 0.75
@@ -401,6 +424,9 @@ set g_balance_nex_primary_damagefalloff_halflife 2000
 set g_balance_nex_primary_damagefalloff_forcehalflife 2000
 
 set g_balance_nex_secondary 1
+set g_balance_nex_secondary_charge 1
+set g_balance_nex_secondary_charge_rate 200
+set g_balance_nex_secondary_charge_ammo 10
 set g_balance_nex_secondary_damage 125
 set g_balance_nex_secondary_force -700
 set g_balance_nex_secondary_refire 1
@@ -408,12 +434,13 @@ set g_balance_nex_secondary_animtime 0.75
 set g_balance_nex_secondary_ammo 5
 set g_balance_nex_secondary_damagefalloff_mindist 500
 set g_balance_nex_secondary_damagefalloff_maxdist 4500
-set g_balance_nex_secondary_damagefalloff_halflife 2000
-set g_balance_nex_secondary_damagefalloff_forcehalflife 2000
+set g_balance_nex_secondary_damagefalloff_halflife 4000
+set g_balance_nex_secondary_damagefalloff_forcehalflife 4000
 
 set g_balance_nex_velocitydependent_halflife -500
 set g_balance_nex_velocitydependent_minspeed 400
 set g_balance_nex_velocitydependent_maxspeed 1000
+set g_balance_nex_velocitydependent_falloff_rate 40
 // }}}
 // {{{ minstanex
 set g_balance_minstanex_refire 1.25
@@ -538,7 +565,7 @@ set g_balance_campingrifle_magazinecapacity 8 // make it pretty much useless in
 set g_balance_campingrifle_reloadtime 2 // matches reload anim
 set g_balance_campingrifle_auto_reload_after_changing_weapons 0
 set g_balance_campingrifle_bursttime 0
-set g_balance_campingrifle_tracer 1
+set g_balance_campingrifle_primary_tracer 1
 set g_balance_campingrifle_primary_damage 75
 set g_balance_campingrifle_primary_headshotaddeddamage 75
 set g_balance_campingrifle_primary_spread 0
@@ -552,14 +579,15 @@ set g_balance_campingrifle_primary_bulletconstant 130 // 56.3qu
 set g_balance_campingrifle_primary_burstcost 0
 set g_balance_campingrifle_primary_bullethail 0 // empty magazine on shot
 set g_balance_campingrifle_secondary 1
-set g_balance_campingrifle_secondary_damage 25
-set g_balance_campingrifle_secondary_headshotaddeddamage 25 // 50 damage only on head
-set g_balance_campingrifle_secondary_spread 0.008
-set g_balance_campingrifle_secondary_force 1
-set g_balance_campingrifle_secondary_speed 20000
+set g_balance_campingrifle_secondary_tracer 0
+set g_balance_campingrifle_secondary_damage 50
+set g_balance_campingrifle_secondary_headshotaddeddamage 50 // 50 damage only on head
+set g_balance_campingrifle_secondary_spread 0
+set g_balance_campingrifle_secondary_force 2
+set g_balance_campingrifle_secondary_speed 30000
 set g_balance_campingrifle_secondary_lifetime 5
-set g_balance_campingrifle_secondary_refire 0.15
-set g_balance_campingrifle_secondary_animtime 0.1
+set g_balance_campingrifle_secondary_refire 1.5
+set g_balance_campingrifle_secondary_animtime 1.4
 set g_balance_campingrifle_secondary_ammo 10
 set g_balance_campingrifle_secondary_bulletconstant 130 // 18.3qu
 set g_balance_campingrifle_secondary_burstcost 0
index 7312a34e4aed51515b0c52ef1c62b623f97a0a58..49e65928478fabb3c41eaee1961258baafc60b0f 100644 (file)
@@ -87,7 +87,15 @@ _cl_color 102
 _cl_name Player
 _cl_playermodel models/player/umbra.iqm
 _cl_playerskin 0
-crosshair 1
+seta crosshair 3
+seta crosshair_color_red 0.6
+seta crosshair_color_green 0.8
+seta crosshair_color_blue 1
+seta crosshair_alpha 1
+seta crosshair_size 0.35
+seta crosshair_dot 1
+seta crosshair_dot_alpha 1
+seta crosshair_dot_size 1
 seta crosshair_per_weapon 0    "when 1, each gun will display a different crosshair"
 seta crosshair_color_override 0        "when 1, crosshair_color_* overrides the per-weapon color"
 seta crosshair_effect_speed -1 "how fast (in seconds) some crosshair effects should take place, 0 = instant, -1 = 2x weapon switch time"
@@ -119,6 +127,12 @@ seta crosshair_grenadelauncher_color_green 0.15    "crosshair color green component
 seta crosshair_grenadelauncher_color_blue 0    "crosshair color blue component to display when wielding the mortar"
 seta crosshair_grenadelauncher_color_alpha 1.15        "crosshair alpha value to display when wielding the mortar"
 seta crosshair_grenadelauncher_size 0.7        "crosshair size when wielding the mortar"
+seta crosshair_minelayer ""    "crosshair to display when wielding the mortar"
+seta crosshair_minelayer_color_red 0.75        "crosshair color red component to display when wielding the mortar"
+seta crosshair_minelayer_color_green 0.75      "crosshair color green component to display when wielding the mortar"
+seta crosshair_minelayer_color_blue 0  "crosshair color blue component to display when wielding the mortar"
+seta crosshair_minelayer_color_alpha 1.15      "crosshair alpha value to display when wielding the mortar"
+seta crosshair_minelayer_size 0.9      "crosshair size when wielding the mortar"
 seta crosshair_electro ""      "crosshair to display when wielding the electro"
 seta crosshair_electro_color_red 0.35  "crosshair color red component to display when wielding the electro"
 seta crosshair_electro_color_green 0.5 "crosshair color green component to display when wielding the electro"
@@ -185,7 +199,6 @@ seta crosshair_campingrifle_color_green 0.5 "crosshair color green component to
 seta crosshair_campingrifle_color_blue 0.25    "crosshair color blue component to display when wielding the campingrifle"
 seta crosshair_campingrifle_color_alpha 1      "crosshair alpha value to display when wielding the campingrifle"
 seta crosshair_campingrifle_size 0.65  "crosshair size when wielding the campingrifle"
-seta crosshair_campingrifle_ring_size 1.5      "bullet counter ring size around campingrifle crosshair, multiple of crosshair_campingrifle_size"
 seta crosshair_tuba "" "crosshair to display when wielding the tuba"
 seta crosshair_tuba_color_red 0.85     "crosshair color red component to display when wielding the tuba"
 seta crosshair_tuba_color_green 0.5    "crosshair color green component to display when wielding the tuba"
@@ -198,10 +211,9 @@ seta crosshair_fireball_color_green 1.0    "crosshair color green component to disp
 seta crosshair_fireball_color_blue 0.2 "crosshair color blue component to display when wielding the fireball"
 seta crosshair_fireball_color_alpha 1  "crosshair alpha value to display when wielding the fireball"
 seta crosshair_fireball_size 1 "crosshair size when wielding the fireball"
-seta crosshair_nexvelocity_color_red 0.8
-seta crosshair_nexvelocity_color_green 0
-seta crosshair_nexvelocity_color_blue 0
-seta crosshair_nexvelocity_alpha 0.25
+seta crosshair_ring_size 3     "bullet counter ring size for Rifle, velocity ring for Nex"
+seta crosshair_campingrifle_bulletcounter_alpha 0.15
+seta crosshair_nexvelocity_alpha 0.15
 seta cl_reticle_stretch 0 "whether to stretch reticles so they fit the screen (brakes image proportions)"
 seta cl_reticle_item_nex 1 "draw aiming recticle for the nex weapon's zoom, 0 disables and values between 0 and 1 change alpha"
 seta cl_reticle_item_normal 1 "draw recticle when zooming with the zoom button, 0 disables and values between 0 and 1 change alpha"
@@ -342,10 +354,10 @@ set sv_fragmessage_information_typefrag 1 "Enable typefrag display information,
 set sv_friction_on_land 0
 exec physicsNoQWBunny-xpmbased.cfg
 
-set sv_player_viewoffset "0 0 35" "view offset of the player model"
+set sv_player_viewoffset "0 0 42" "view offset of the player model"
 set sv_player_mins "-16 -16 -24" "playermodel mins"
 set sv_player_maxs "16 16 45" "playermodel maxs"
-set sv_player_crouch_viewoffset "0 0 15" "view offset of the player model when crouched"
+set sv_player_crouch_viewoffset "0 0 20" "view offset of the player model when crouched"
 set sv_player_crouch_mins "-16 -16 -24" "mins of a crouched playermodel"
 set sv_player_crouch_maxs "16 16 25" "maxs of a crouched playermodel"
 
@@ -430,9 +442,9 @@ set bot_ai_keyboard_treshold 0.57
 set bot_ai_aimskill_offset 0.3 "Amount of error induced to the bots aim"
 set bot_ai_aimskill_think 1 "Aiming velocity. Use values below 1 for slower aiming"
 set bot_ai_custom_weapon_priority_distances "300 850"  "Define close and far distances in any order. Based on the distance to the enemy bots will choose different weapons"
-set bot_ai_custom_weapon_priority_far   "minstanex nex campingrifle rocketlauncher grenadelauncher electro hagar hlac crylink laser uzi fireball seeker shotgun tuba"  "Desired weapons for far distances ordered by priority"
-set bot_ai_custom_weapon_priority_mid   "minstanex rocketlauncher nex fireball seeker grenadelauncher electro uzi campingrifle crylink hlac hagar shotgun laser tuba"  "Desired weapons for middle distances ordered by priority"
-set bot_ai_custom_weapon_priority_close "minstanex nex uzi hlac tuba seeker hagar crylink grenadelauncher shotgun electro campingrifle rocketlauncher laser fireball"  "Desired weapons for close distances ordered by priority"
+set bot_ai_custom_weapon_priority_far   "minstanex nex campingrifle rocketlauncher minelayer grenadelauncher electro hagar hlac crylink laser uzi fireball seeker shotgun tuba"        "Desired weapons for far distances ordered by priority"
+set bot_ai_custom_weapon_priority_mid   "minstanex rocketlauncher nex fireball seeker minelayer grenadelauncher electro uzi campingrifle crylink hlac hagar shotgun laser tuba"        "Desired weapons for middle distances ordered by priority"
+set bot_ai_custom_weapon_priority_close "minstanex nex uzi hlac tuba seeker hagar crylink minelayer grenadelauncher shotgun electro campingrifle rocketlauncher laser fireball"        "Desired weapons for close distances ordered by priority"
 set bot_ai_weapon_combo 1      "Enable bots to do weapon combos"
 set bot_ai_weapon_combo_threshold 0.3  "Try to make a combo N seconds after the last attack"
 set bot_ai_friends_aware_pickup_radius "500"   "Bots will not pickup items if a team mate is this distance near the item"
@@ -1054,13 +1066,13 @@ set rcon_restricted_commands "restart fraglimit chmap gotomap endmatch reducemat
 set sv_vote_call 1     "users can call a vote for the above commands"
 set sv_vote_master 1   "users can call a vote to become master"
 set sv_vote_master_password "" "when set, users can use \"vlogin PASSWORD\" to log in as master"
-set sv_vote_change 0   "set to 1 to allow to change you vote/mind"
+set sv_vote_change 1   "set to 1 to allow to change you vote/mind"
 set sv_vote_singlecount 0      "set to 1 to count votes once after timeout or to 0 to count with every vote"
-set sv_vote_timeout 60 "a vote will timeout after this many seconds"
+set sv_vote_timeout 30 "a vote will timeout after this many seconds"
 set sv_vote_wait 120   "a player can not call a vote again for this many seconds when his vote was not accepted"
 set sv_vote_stop 15    "a player can not call a vote again for this many seconds when he stopped this vote (e.g. to correct it)"
 set sv_vote_majority_factor 0.5        "which quotient of the PLAYERS constitute a majority? (try: 0.667, 0.75 when using the above)"
-set sv_vote_simple_majority_factor 0   "which quotient of the VOTERS constitute a majority too? (0 = off, otherwise it must be higher than or equal to sv_vote_majority_factor)"
+set sv_vote_simple_majority_factor 0.667       "which quotient of the VOTERS constitute a majority too? (0 = off, otherwise it must be higher than or equal to sv_vote_majority_factor)"
 // when disabled, don't allow game type changes "note: set these two equal to JUST support simple majorities"
 set sv_vote_override_mostrecent 0
 alias vhelp "cmd vote help"
@@ -1323,7 +1335,9 @@ seta menu_sounds 0 "enables menu sound effects. 1 enables click sounds, 2 also e
 
 r_textbrightness 0.2
 r_textcontrast 0.8
-r_textshadow 1
+r_textshadow 0
+r_font_postprocess_blur 1
+r_font_postprocess_outline 1
 
 // good settings for these fonts
 con_chat 5
@@ -1392,8 +1406,8 @@ seta scoreboard_accuracy_border_thickness 1 "accuracy stats border thickness"
 seta scoreboard_accuracy_doublerows 0 "use two rows instead of one"
 seta scoreboard_accuracy 1 "0 = no weapon accuracy stats panel on scoreboard"
 seta scoreboard_color_bg_r 0 "red color component of the HUD background"
-seta scoreboard_color_bg_g 0.25 "green color component of the HUD background"
-seta scoreboard_color_bg_b 0.17 "blue color component of the HUD background"
+seta scoreboard_color_bg_g 0.4 "green color component of the HUD background"
+seta scoreboard_color_bg_b 0.6 "blue color component of the HUD background"
 seta scoreboard_color_bg_team 0.5 "team color multiplier of the HUD background"
 seta scoreboard_alpha_bg 0.6 "scoreboard background alpha"
 seta scoreboard_alpha_fg 1 "scoreboard foreground alpha"
@@ -1549,13 +1563,13 @@ set g_jump_grunt 0      "Do you make a grunting noise every time you jump? Is it the
 
 alias allready "sv_cmd allready"
 
-seta cl_weaponpriority "minstanex rocketlauncher nex grenadelauncher fireball hlac hagar seeker crylink campingrifle uzi electro tuba shotgun laser hook porto" "weapon priority list"
+seta cl_weaponpriority "minstanex rocketlauncher nex minelayer grenadelauncher fireball hlac hagar seeker crylink campingrifle uzi electro tuba shotgun laser hook porto" "weapon priority list"
 seta cl_weaponpriority_useforcycling 0 "when set, weapon cycling by the mouse wheel makes use of the weapon priority list (the special value 2 uses the weapon ID list for cycling)"
 seta cl_weaponpriority0 "rocketlauncher grenadelauncher hagar seeker fireball" "use impulse 200 for prev gun from this list, 210 for best gun, 220 for next gun.  Default value: explosives"
 seta cl_weaponpriority1 "minstanex nex crylink hlac electro laser"             "use impulse 201 for prev gun from this list, 211 for best gun, 221 for next gun.  Default value: energy"
 seta cl_weaponpriority2 "minstanex nex campingrifle"                           "use impulse 202 for prev gun from this list, 212 for best gun, 222 for next gun.  Default value: hitscan exact"
 seta cl_weaponpriority3 "minstanex nex campingrifle uzi shotgun"               "use impulse 203 for prev gun from this list, 213 for best gun, 223 for next gun.  Default value: hitscan all"
-seta cl_weaponpriority4 "grenadelauncher hlac hagar crylink seeker shotgun"    "use impulse 204 for prev gun from this list, 214 for best gun, 224 for next gun.  Default value: spam weapons"
+seta cl_weaponpriority4 "minelayer grenadelauncher hlac hagar crylink seeker shotgun"    "use impulse 204 for prev gun from this list, 214 for best gun, 224 for next gun.  Default value: spam weapons"
 seta cl_weaponpriority5 "laser hook porto"                                     "use impulse 205 for prev gun from this list, 215 for best gun, 225 for next gun.  Default value: weapons for moving"
 seta cl_weaponpriority6 "" "use impulse 206 for prev gun from this list, 216 for best gun, 226 for next gun"
 seta cl_weaponpriority7 "" "use impulse 207 for prev gun from this list, 217 for best gun, 227 for next gun"
@@ -1895,6 +1909,7 @@ 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 ""
@@ -1928,6 +1943,11 @@ scr_conscroll3_y 0
 scr_conscroll_x -0.1
 scr_conscroll_y -0.3
 
+scr_loadingscreen_background 0
+scr_loadingscreen_barcolor "0 0.5 1"
+scr_loadingscreen_barheight 20
+scr_loadingscreen_count 1
+
 // DP cannot properly detect this, so rather turn off the detection
 r_texture_dds_load_dxt1_noalpha 1
 
index 4116ae438241bf98c1d92ae2002bd69999262615..e78e636a4501e04e2e69c69259a01d415e1e06c3 100644 (file)
@@ -4988,7 +4988,8 @@ lightcolor 3.125 4.375 10
 effect electro_lightning
 count 300
 type spark
-color 0x501860 0x501860 // 0x202020 0x404040
+// color 0x501860 0x501860 // 0x202020 0x404040
+color 0x2030FF 0x80C0FF
 tex 65 65
 size 6 6
 alpha 100 206 1724
diff --git a/gfx/crosshair1.tga b/gfx/crosshair1.tga
new file mode 100644 (file)
index 0000000..d6c09e9
Binary files /dev/null and b/gfx/crosshair1.tga differ
index e9648b1e629cb6bbdc8d260ea9fd216cf6809f69..e7b5774e6f127cbf8a770c14a6a4c74c49f2c4ef 100644 (file)
Binary files a/gfx/crosshair10.tga and b/gfx/crosshair10.tga differ
index 8718e907fcbf110b19aed20a76e4c8f612dd8995..d1486adbe1a6bfb1c07e015b51d79780824cdf36 100644 (file)
Binary files a/gfx/crosshair11.tga and b/gfx/crosshair11.tga differ
index 4edabeaaafecdde4a9b5bf704c493d358522e7e8..95892abd6cb0279d62b8ebb27e38664885143262 100644 (file)
Binary files a/gfx/crosshair12.tga and b/gfx/crosshair12.tga differ
index 4a546781fa66184670478e309568e84e52f0b825..e9f17a796c51ff3c6d134fd4ffc964f1aa2c0cfe 100644 (file)
Binary files a/gfx/crosshair13.tga and b/gfx/crosshair13.tga differ
index df8136f1774e7c0c5ed25d63aedc5a0afa8d2379..b03e14d47a434da58ee829f2a7b9db5ef5115825 100644 (file)
Binary files a/gfx/crosshair14.tga and b/gfx/crosshair14.tga differ
index dc36814a7f388766988ff1536d370d457ad2f5a2..8e9d2d9fab481cbe5a6d82dd49c1f0305570e940 100644 (file)
Binary files a/gfx/crosshair16.tga and b/gfx/crosshair16.tga differ
index dc36814a7f388766988ff1536d370d457ad2f5a2..c22551aa09a2aafdb255423d2a4fdc9cee1b51b6 100644 (file)
Binary files a/gfx/crosshair17.tga and b/gfx/crosshair17.tga differ
diff --git a/gfx/crosshair2.tga b/gfx/crosshair2.tga
new file mode 100644 (file)
index 0000000..4e2bd79
Binary files /dev/null and b/gfx/crosshair2.tga differ
diff --git a/gfx/crosshair3.tga b/gfx/crosshair3.tga
new file mode 100644 (file)
index 0000000..db5f2cc
Binary files /dev/null and b/gfx/crosshair3.tga differ
diff --git a/gfx/crosshair4.tga b/gfx/crosshair4.tga
new file mode 100644 (file)
index 0000000..2c4f312
Binary files /dev/null and b/gfx/crosshair4.tga differ
diff --git a/gfx/crosshair5.tga b/gfx/crosshair5.tga
new file mode 100644 (file)
index 0000000..905045f
Binary files /dev/null and b/gfx/crosshair5.tga differ
diff --git a/gfx/crosshair6.tga b/gfx/crosshair6.tga
new file mode 100644 (file)
index 0000000..b005d96
Binary files /dev/null and b/gfx/crosshair6.tga differ
index dc7fe43db49927a7aee3c86b992d5c5af6cbf592..64f6d5d07ac0ba241cfebc30b0c496b0c8140b26 100644 (file)
Binary files a/gfx/crosshair7.tga and b/gfx/crosshair7.tga differ
index 06028298fac23095696ea822ef8f3b86eb390dbd..df9e414f7c73cbda181a75b94dc1334b1044e925 100644 (file)
Binary files a/gfx/crosshair8.tga and b/gfx/crosshair8.tga differ
index 75e033960f0f58373ec416b4441073a18ab09efc..a1e76940a7ffa0000fa2e2f4c7712dae1c667952 100644 (file)
Binary files a/gfx/crosshair9.tga and b/gfx/crosshair9.tga differ
diff --git a/gfx/crosshair_ring.tga b/gfx/crosshair_ring.tga
new file mode 100644 (file)
index 0000000..970ba15
Binary files /dev/null and b/gfx/crosshair_ring.tga differ
diff --git a/gfx/crosshairdot.tga b/gfx/crosshairdot.tga
new file mode 100644 (file)
index 0000000..a2ffef2
Binary files /dev/null and b/gfx/crosshairdot.tga differ
diff --git a/gfx/crosshairminelayer.tga b/gfx/crosshairminelayer.tga
new file mode 100644 (file)
index 0000000..e869ab5
Binary files /dev/null and b/gfx/crosshairminelayer.tga differ
diff --git a/gfx/hud/default/weaponminelayer.tga b/gfx/hud/default/weaponminelayer.tga
new file mode 100644 (file)
index 0000000..3fbccf9
Binary files /dev/null and b/gfx/hud/default/weaponminelayer.tga differ
diff --git a/gfx/hud/luminos/weaponminelayer.tga b/gfx/hud/luminos/weaponminelayer.tga
new file mode 100644 (file)
index 0000000..3fbccf9
Binary files /dev/null and b/gfx/hud/luminos/weaponminelayer.tga differ
diff --git a/gfx/hud/old/weaponminelayer.tga b/gfx/hud/old/weaponminelayer.tga
new file mode 100644 (file)
index 0000000..444247f
Binary files /dev/null and b/gfx/hud/old/weaponminelayer.tga differ
index a5d35489ac6f47c6556fd91bf47b63c2f3586034..2b6e22ce76fb1ba1ebfa8009a4cc5abb435f4be1 100644 (file)
Binary files a/gfx/loading.tga and b/gfx/loading.tga differ
diff --git a/gfx/nex_ring.tga b/gfx/nex_ring.tga
deleted file mode 100644 (file)
index 22e3514..0000000
Binary files a/gfx/nex_ring.tga and /dev/null differ
index c7343071e2c53282d033e343bb92e90a6e628480..5e70fa304ad29b6a10a792d6f4cd07bbcabccfbd 100644 (file)
Binary files a/models/keyhunt/key.tga and b/models/keyhunt/key.tga differ
diff --git a/models/mine.md3 b/models/mine.md3
new file mode 100644 (file)
index 0000000..7758e3e
Binary files /dev/null and b/models/mine.md3 differ
diff --git a/models/weapons/g_minelayer.md3 b/models/weapons/g_minelayer.md3
new file mode 100644 (file)
index 0000000..5fce1ef
Binary files /dev/null and b/models/weapons/g_minelayer.md3 differ
diff --git a/models/weapons/h_minelayer.iqm b/models/weapons/h_minelayer.iqm
new file mode 100644 (file)
index 0000000..0c6ed41
Binary files /dev/null and b/models/weapons/h_minelayer.iqm differ
diff --git a/models/weapons/h_minelayer.iqm.framegroups b/models/weapons/h_minelayer.iqm.framegroups
new file mode 100644 (file)
index 0000000..0a59625
--- /dev/null
@@ -0,0 +1,4 @@
+1 8 20 0 // fire
+9 5 20 0 // fire2
+15 200 20 1 // idle
+215 40 20 0 // reload
diff --git a/models/weapons/v_minelayer.md3 b/models/weapons/v_minelayer.md3
new file mode 100644 (file)
index 0000000..4c7d449
Binary files /dev/null and b/models/weapons/v_minelayer.md3 differ
index 15064cec481a97b3be4b6bf9871b6d3467e80079..2aa34493554455e14dc8bddf5fe7b5556350ed8f 100644 (file)
Binary files a/particles/lgbeam.tga and b/particles/lgbeam.tga differ
index 1bd911aafb12b890f30152d8a1e17ead239fd11c..59a7074d7243578d95cd32b57918c9c3cd9a84c5 100644 (file)
@@ -261,5 +261,12 @@ vector w_org, w_backoff;
 float campingrifle_scope;
 float nex_scope;
 
+float nex_velocitydependent;
 float nex_minvelocity;
 float nex_maxvelocity;
+float nex_speed_falloff_rate;
+float nex_speed;
+float nex_charge;
+float nex_charge_rate;
+
+float cr_maxbullets;
index 8b053cfd38fd553477a140ade161e159aef20dff..780609d5a9e507bc2ea8899ba4b0f2e9152ba0e1 100644 (file)
@@ -1335,8 +1335,16 @@ float CSQC_Parse_TempEntity()
                        bHandled = true;
                        break;
                case TE_CSQC_NEX_VELOCITY:
+                       nex_velocitydependent = ReadByte();
                        nex_minvelocity = ReadShort();
                        nex_maxvelocity = ReadShort();
+                       nex_speed_falloff_rate = ReadByte();
+                       nex_charge = ReadByte();
+                       nex_charge_rate = ReadByte();
+                       bHandled = true;
+                       break;
+               case TE_CSQC_CR_MAXBULLETS:
+                       cr_maxbullets = ReadByte();
                        bHandled = true;
                        break;
                default:
index 6fc94ca4346d1ebfa395510f9270ad9234ad841b..5f422a03eb0a4b3db660a7ce8b6e13b66ee8acbf 100644 (file)
@@ -382,7 +382,7 @@ void CSQC_UpdateView(float w, float h)
        input_angles = warpzone_fixview_cl_viewangles;
        view_angles = warpzone_fixview_angles;
 
-       if(cvar("cl_lockview") || autocvar__hud_configure)
+       if(cvar("cl_lockview") || (autocvar__hud_configure && spectatee_status <= 0))
        {
                pmove_org = freeze_pmove_org;
                input_angles = view_angles = freeze_input_angles;
@@ -622,6 +622,8 @@ void CSQC_UpdateView(float w, float h)
        // the view to go back to normal, so reticle_type would become 0 as we fade out)
        if(spectatee_status || getstati(STAT_HEALTH) <= 0)
                reticle_type = 0; // prevent reticle from showing during the respawn zoom effect or for spectators
+       else if(activeweapon == WEP_NEX && (button_zoom || zoomscript_caught) || activeweapon == WEP_CAMPINGRIFLE && (button_zoom || zoomscript_caught) || activeweapon == WEP_MINSTANEX && (button_zoom || zoomscript_caught))
+               reticle_type = 2; // nex zoom
        else if(button_zoom || zoomscript_caught)
                reticle_type = 1; // normal zoom
        else if(activeweapon == WEP_NEX && button_attack2 || activeweapon == WEP_CAMPINGRIFLE && button_attack2)
@@ -697,24 +699,6 @@ void CSQC_UpdateView(float w, float h)
                        if(cvar("viewsize") < 120)
                                CSQC_common_hud();
 
-
-               // ring around crosshair representing velocity-dependent damage for the nex
-               if (activeweapon == WEP_NEX)
-               {
-                       float f, a, curvel;
-                       vector rgb;
-
-                       rgb_x = cvar("crosshair_nexvelocity_color_red");
-                       rgb_y = cvar("crosshair_nexvelocity_color_green");
-                       rgb_z = cvar("crosshair_nexvelocity_color_blue");
-                       a = cvar("crosshair_nexvelocity_alpha");
-
-                       curvel = vlen('1 0 0' * pmove_vel_x + '0 1 0' * pmove_vel_y);
-                       f = bound(0, (curvel - nex_minvelocity) / (nex_maxvelocity - nex_minvelocity), 1);
-
-                       DrawCircleClippedPic('0.5 0 0' * vid_conwidth + '0 0.5 0' * vid_conheight, 0.1 * vid_conheight, "gfx/nex_ring.tga", f, rgb, a, DRAWFLAG_ADDITIVE);
-               }
-
                // crosshair goes VERY LAST
                if(!scoreboard_active && !camera_active && intermission != 2) {
                        // TrueAim check
@@ -842,17 +826,37 @@ void CSQC_UpdateView(float w, float h)
                                wcross_scale *= 1 - cvar("_menu_alpha");
                                wcross_alpha *= 1 - cvar("_menu_alpha");
 
+                               ring_scale = cvar("crosshair_ring_size");
+
+                               float f, a;
+                               wcross_size = drawgetimagesize(wcross_name) * wcross_scale;
+
+                               float xyspeed;
+                               xyspeed = vlen('1 0 0' * pmove_vel_x + '0 1 0' * pmove_vel_y);
+                               if(xyspeed > nex_speed)
+                                       nex_speed = min(xyspeed, nex_maxvelocity);
+                               else
+                                       nex_speed = max(nex_minvelocity, nex_speed - nex_speed_falloff_rate * frametime);
+
+                               if (activeweapon == WEP_NEX && button_attack2 && nex_charge && getstati(GetAmmoStat(3)))
+                                       nex_speed = min(nex_maxvelocity, nex_speed + nex_charge_rate * frametime);
+
                                // ring around crosshair representing bullets left in camping rifle clip
-                               if (activeweapon == WEP_CAMPINGRIFLE)
+                               if (activeweapon == WEP_CAMPINGRIFLE && cr_maxbullets)
                                {
-                                       ring_scale = cvar("crosshair_campingrifle_ring_size");
-                                       bullets = bound(0, getstati(STAT_BULLETS_LOADED), 4);
+                                       bullets = getstati(STAT_BULLETS_LOADED);
+                                       f = bound(0, bullets / cr_maxbullets, 1);
+
+                                       a = cvar("crosshair_campingrifle_bulletcounter_alpha");
+                                       DrawCircleClippedPic(wcross_origin, wcross_size_x * ring_scale, "gfx/crosshair_ring.tga", f, wcross_color, wcross_alpha * a, DRAWFLAG_ADDITIVE);
                                }
-                               else
-                                       bullets = 0;
+                               else if (activeweapon == WEP_NEX && nex_velocitydependent && nex_speed > nex_minvelocity) // ring around crosshair representing velocity-dependent damage for the nex
+                               {
+                                       f = bound(0, (nex_speed - nex_minvelocity) / (nex_maxvelocity - nex_minvelocity), 1);
 
-#define CROSSHAIR_DRAW_RING(i,j,sz,wcross_name,wcross_alpha) \
-                               drawpic(wcross_origin - ('0.5 0 0' * (sz * wcross_size_x * ring_scale + i * wcross_blur) + '0 0.5 0' * (sz * wcross_size_y * ring_scale + j * wcross_blur)), strcat("gfx/rifle_ring_", ftos(bullets)), sz * wcross_size * ring_scale, wcross_color, wcross_alpha, DRAWFLAG_NORMAL)
+                                       a = cvar("crosshair_nexvelocity_alpha");
+                                       DrawCircleClippedPic(wcross_origin, wcross_size_x * ring_scale, "gfx/crosshair_ring.tga", f, wcross_color, wcross_alpha * a, DRAWFLAG_ADDITIVE);
+                               }
 
 #define CROSSHAIR_DO_BLUR(M,sz,wcross_name,wcross_alpha) \
                                do \
@@ -889,11 +893,11 @@ void CSQC_UpdateView(float w, float h)
                                }
 
                                wcross_size = drawgetimagesize(wcross_name) * wcross_scale;
-                               if(bullets)
-                               {
-                                       CROSSHAIR_DO_BLUR(CROSSHAIR_DRAW_RING, wcross_resolution, wcross_name, wcross_alpha);
-                               }
                                CROSSHAIR_DRAW(wcross_resolution, wcross_name, wcross_alpha * f);
+
+                               if(cvar("crosshair_dot"))
+                                       CROSSHAIR_DRAW(wcross_resolution * cvar("crosshair_dot_size"), "gfx/crosshairdot.tga", wcross_alpha * f * cvar("crosshair_dot_alpha"));
+
                                wcross_name_alpha_goal_prev = f;
                        }
                }
index c1dbede921a44231d5f157cf383d697b23dd248d..69459256f0a22acd972fa7aea299402905a518e9 100644 (file)
@@ -1419,13 +1419,13 @@ void HUD_Panel_Mouse()
        cursorsize = '32 32 0';
 
        if(highlightcheck == 0)
-               drawpic(mousepos, strcat("gfx/menu/", cvar_string("menu_skin"), "/cursor.tga"), '32 32 0', '1 1 1', 1, DRAWFLAG_NORMAL);
+               drawpic(mousepos, strcat("gfx/menu/", cvar_string("menu_skin"), "/cursor.tga"), '32 32 0', '1 1 1', hud_fade_alpha, DRAWFLAG_NORMAL);
        else if(highlightcheck == 1)
-               drawpic(mousepos - cursorsize * 0.5, strcat("gfx/menu/", cvar_string("menu_skin"), "/cursor_move.tga"), '32 32 0', '1 1 1', 1, DRAWFLAG_NORMAL);
+               drawpic(mousepos - cursorsize * 0.5, strcat("gfx/menu/", cvar_string("menu_skin"), "/cursor_move.tga"), '32 32 0', '1 1 1', hud_fade_alpha, DRAWFLAG_NORMAL);
        else if(highlightcheck == 2)
-               drawpic(mousepos - cursorsize * 0.5, strcat("gfx/menu/", cvar_string("menu_skin"), "/cursor_resize.tga"), '32 32 0', '1 1 1', 1, DRAWFLAG_NORMAL);
+               drawpic(mousepos - cursorsize * 0.5, strcat("gfx/menu/", cvar_string("menu_skin"), "/cursor_resize.tga"), '32 32 0', '1 1 1', hud_fade_alpha, DRAWFLAG_NORMAL);
        else
-               drawpic(mousepos - cursorsize * 0.5, strcat("gfx/menu/", cvar_string("menu_skin"), "/cursor_resize2.tga"), '32 32 0', '1 1 1', 1, DRAWFLAG_NORMAL);
+               drawpic(mousepos - cursorsize * 0.5, strcat("gfx/menu/", cvar_string("menu_skin"), "/cursor_resize2.tga"), '32 32 0', '1 1 1', hud_fade_alpha, DRAWFLAG_NORMAL);
 
        prevMouseClicked = mouseClicked;
 }
@@ -1478,6 +1478,7 @@ float GetAmmoTypeForWep(float i)
                case WEP_UZI: return 1;
                case WEP_CAMPINGRIFLE: return 1;
                case WEP_GRENADE_LAUNCHER: return 2;
+               case WEP_MINE_LAYER: return 2;
                case WEP_ELECTRO: return 3;
                case WEP_CRYLINK: return 3;
                case WEP_HLAC: return 3;
@@ -2255,12 +2256,10 @@ void HUD_HealthArmor(void)
                mySize -= '2 2 0' * panel_bg_padding;
        }
 
-       float armor, health;
+       float armor, health, fuel;
        armor = getstati(STAT_ARMOR);
        health = getstati(STAT_HEALTH);
-
-       float fuel;
-       fuel = getstati(GetAmmoStat(4)); // how much fuel do we have?
+       fuel = getstati(STAT_FUEL);
 
        if(autocvar__hud_configure)
        {
index 9a773379b5d6eed97a57ae1189f2651ffc6c67d8..39aabc44adf4a430f357c0e6e82d4a6d07e596ef 100644 (file)
@@ -279,6 +279,7 @@ void Ent_Projectile()
                        case PROJECTILE_ELECTRO_BEAM: setmodel(self, "models/elaser.mdl");self.traileffect = particleeffectnum("TR_NEXUIZPLASMA"); break;
                        case PROJECTILE_GRENADE: setmodel(self, "models/grenademodel.md3");self.traileffect = particleeffectnum("TR_GRENADE"); break;
                        case PROJECTILE_GRENADE_BOUNCING: setmodel(self, "models/grenademodel.md3");self.traileffect = particleeffectnum("TR_GRENADE"); break;
+                       case PROJECTILE_MINE: setmodel(self, "models/mine.md3");self.traileffect = particleeffectnum(""); break;
                        case PROJECTILE_LASER: setmodel(self, "models/laser.mdl");self.traileffect = particleeffectnum(""); break;
                        case PROJECTILE_HLAC: setmodel(self, "models/hlac_bullet.md3");self.traileffect = particleeffectnum(""); break;
                        case PROJECTILE_PORTO_RED: setmodel(self, "models/grenademodel.md3");self.traileffect = particleeffectnum("TR_WIZSPIKE"); self.scale = 4; break;
@@ -330,6 +331,10 @@ void Ent_Projectile()
                                self.move_bounce_factor = g_balance_grenadelauncher_secondary_bouncefactor;
                                self.move_bounce_stopspeed = g_balance_grenadelauncher_secondary_bouncestop;
                                break;
+                       case PROJECTILE_MINE:
+                               self.mins = '-4 -4 -4';
+                               self.maxs = '4 4 4';
+                               break;
                        case PROJECTILE_PORTO_RED:
                                self.colormod = '2 1 1';
                                self.alphamod = 0.5;
@@ -407,6 +412,7 @@ void Projectile_Precache()
        precache_model("models/ebomb.mdl");
        precache_model("models/elaser.mdl");
        precache_model("models/grenademodel.md3");
+       precache_model("models/mine.md3");
        precache_model("models/hagarmissile.mdl");
        precache_model("models/hlac_bullet.md3");
        precache_model("models/laser.mdl");
index 7690c05f8d1f10006e898c4644f7f686732b53ca..1c30f4eec289b6b3cedd9aefc6b08390cbc52373 100644 (file)
@@ -1,20 +1,52 @@
 .float lip;
 .float bgmscriptangular;
+.float lodmodelindex0, lodmodelindex1, lodmodelindex2;
+.float loddistance1, loddistance2;
+.vector saved;
 
 void Ent_Wall_Draw()
 {
        float f;
+       float d;
        vector save;
        var .vector fld;
 
+       if(self.bgmscriptangular)
+               self.angles = self.saved;
+       else
+               self.origin = self.saved;
+
+       if(self.lodmodelindex1)
+       {
+               d = cvar("loddebug");
+               if(d > 0)
+               {
+                       if(d == 1)
+                               self.modelindex = self.lodmodelindex0;
+                       else if(d == 2 || !self.lodmodelindex2)
+                               self.modelindex = self.lodmodelindex1;
+                       else // if(d == 3)
+                               self.modelindex = self.lodmodelindex2;
+               }
+               else
+               {
+                       d = vlen(NearestPointOnBox(self, view_origin) - view_origin);
+                       if(d < self.loddistance1)
+                               self.modelindex = self.lodmodelindex0;
+                       else if(!self.lodmodelindex2 || d < self.loddistance2)
+                               self.modelindex = self.lodmodelindex1;
+                       else
+                               self.modelindex = self.lodmodelindex2;
+               }
+       }
+
        InterpolateOrigin_Do();
 
        if(self.bgmscriptangular)
-               fld = angles;
+               self.saved = self.angles;
        else
-               fld = origin;
-       
-       save = self.fld;
+               self.saved = self.origin;
+
        f = BGMScript(self);
        if(f >= 0)
        {
@@ -28,9 +60,9 @@ void Ent_Wall_Draw()
                self.alpha = 1;
 
        if(self.alpha >= ALPHA_MIN_VISIBLE)
-               R_AddEntity(self);
-
-       self.fld = save;
+               self.drawmask = MASK_NORMAL;
+       else
+               self.drawmask = 0;
 }
 
 void Ent_Wall_Remove()
@@ -46,6 +78,11 @@ void Ent_Wall()
        InterpolateOrigin_Undo();
        self.iflags = IFLAG_ANGLES;
 
+       if(self.bgmscriptangular)
+               self.angles = self.saved;
+       else
+               self.origin = self.saved;
+
        f = ReadByte();
 
        if(f & 1)
@@ -77,7 +114,20 @@ void Ent_Wall()
 
        if(f & 8)
        {
-               self.modelindex = ReadShort();
+               if(f & 0x80)
+               {
+                       self.lodmodelindex0 = ReadShort();
+                       self.loddistance1 = ReadShort();
+                       self.lodmodelindex1 = ReadShort();
+                       self.loddistance2 = ReadShort();
+                       self.lodmodelindex2 = ReadShort();
+               }
+               else
+               {
+                       self.modelindex = ReadShort();
+                       self.loddistance1 = 0;
+                       self.loddistance2 = 0;
+               }
                self.solid = ReadByte();
                self.scale = ReadShort() / 256.0;
                if(f & 0x20)
@@ -121,6 +171,11 @@ void Ent_Wall()
 
        InterpolateOrigin_Note();
 
+       if(self.bgmscriptangular)
+               self.saved = self.angles;
+       else
+               self.saved = self.origin;
+
        self.entremove = Ent_Wall_Remove;
        self.draw = Ent_Wall_Draw;
 }
index ddd24ed6bc887322941d6503ab314f0f9a0b7ab4..5e8dff7dca2645fb81564d3c243c09381ca15a9d 100644 (file)
@@ -62,6 +62,7 @@ const float TE_CSQC_WEAPONCOMPLAIN = 113;
 const float TE_CSQC_CAMPINGRIFLE_SCOPE = 115;
 const float TE_CSQC_NEX_SCOPE = 116;
 const float TE_CSQC_NEX_VELOCITY = 117;
+const float TE_CSQC_CR_MAXBULLETS = 118;
 
 const float RACE_NET_CHECKPOINT_HIT_QUALIFYING = 0; // byte checkpoint, short time, short recordtime, string recordholder
 const float RACE_NET_CHECKPOINT_CLEAR = 1;
@@ -455,20 +456,21 @@ float PROJECTILE_CRYLINK = 5;
 float PROJECTILE_ELECTRO_BEAM = 6;
 float PROJECTILE_GRENADE = 7;
 float PROJECTILE_GRENADE_BOUNCING = 8;
-float PROJECTILE_LASER = 9;
-float PROJECTILE_HLAC = 10;
-float PROJECTILE_SEEKER = 11;
-float PROJECTILE_FLAC = 12;
-float PROJECTILE_PORTO_RED = 13;
-float PROJECTILE_PORTO_BLUE = 14;
-float PROJECTILE_HOOKBOMB = 15;
-float PROJECTILE_HAGAR = 16;
-float PROJECTILE_HAGAR_BOUNCING = 17;
-float PROJECTILE_BULLET_GLOWING = 18;
-float PROJECTILE_CRYLINK_BOUNCING = 19;
-float PROJECTILE_FIREBALL = 20;
-float PROJECTILE_FIREMINE = 21;
-float PROJECTILE_BULLET_GLOWING_TRACER = 22;
+float PROJECTILE_MINE = 9;
+float PROJECTILE_LASER = 10;
+float PROJECTILE_HLAC = 11;
+float PROJECTILE_SEEKER = 12;
+float PROJECTILE_FLAC = 13;
+float PROJECTILE_PORTO_RED = 14;
+float PROJECTILE_PORTO_BLUE = 15;
+float PROJECTILE_HOOKBOMB = 16;
+float PROJECTILE_HAGAR = 17;
+float PROJECTILE_HAGAR_BOUNCING = 18;
+float PROJECTILE_BULLET_GLOWING = 19;
+float PROJECTILE_CRYLINK_BOUNCING = 20;
+float PROJECTILE_FIREBALL = 21;
+float PROJECTILE_FIREMINE = 22;
+float PROJECTILE_BULLET_GLOWING_TRACER = 23;
 
 float SPECIES_HUMAN        =  0;
 float SPECIES_ROBOT_SOLID  =  1;
index f33512f2355f8823669f1140b691dfe779be7282..1efc0e3738a06a4d9e5c33cd5681571c0d1b0444 100644 (file)
@@ -1919,3 +1919,19 @@ vector vec2(vector v)
        v_z = 0;
        return v;
 }
+
+#ifndef MENUQC
+vector NearestPointOnBox(entity box, vector org)
+{
+       vector m1, m2, nearest;
+
+       m1 = box.mins + box.origin;
+       m2 = box.maxs + box.origin;
+
+       nearest_x = bound(m1_x, org_x, m2_x);
+       nearest_y = bound(m1_y, org_y, m2_y);
+       nearest_z = bound(m1_z, org_z, m2_z);
+
+       return nearest;
+}
+#endif
index 767092cc7532c689710cc82421abd15497d5d146..77b3e03202817a61ef6325761c764ce0de357aff 100644 (file)
@@ -238,3 +238,7 @@ switch(id) { \
 HUD_Panel_GetName_Part2(id)
 
 vector vec2(vector v);
+
+#ifndef MENUQC
+vector NearestPointOnBox(entity box, vector org);
+#endif
index b290f3d218b1faab5a5ee5de4e8ff7770a827a09..058bfd7eb16638eb4722631ce48d2f022685050d 100644 (file)
@@ -8,6 +8,7 @@ CLASS(XonoticCrosshairButton) EXTENDS(RadioButton)
 
        ATTRIB(XonoticCrosshairButton, useDownAsChecked, float, 1)
        ATTRIB(XonoticCrosshairButton, src3, string, string_null)
+       ATTRIB(XonoticCrosshairButton, src4, string, string_null)
 
        ATTRIB(XonoticCrosshairButton, cvarName, string, string_null)
        ATTRIB(XonoticCrosshairButton, cvarValueFloat, float, 0)
@@ -33,6 +34,7 @@ void XonoticCrosshairButton_configureXonoticCrosshairButton(entity me, float the
        me.configureRadioButton(me, string_null, me.fontSize, me.image, theGroup, 0);
        me.srcMulti = 1;
        me.src3 = strzone(strcat("/gfx/crosshair", ftos(me.cvarValueFloat)));
+       me.src4 = "/gfx/crosshairdot";
 }
 void XonoticCrosshairButton_setChecked(entity me, float val)
 {
@@ -76,12 +78,14 @@ void XonoticCrosshairButton_draw(entity me)
 
        sz = draw_PictureSize(me.src3);
        sz = globalToBoxSize(sz, draw_scale);
-       sz = sz * cvar("crosshair_size");
+       sz = (10 * '1 1 0' + sz * cvar("crosshair_size")) * 0.05; // (10 * '1 1 0' + ...) * 0.05 here to make visible size changes happen also at bigger sizes
        if(sz_x > 0.95)
                sz = sz * (0.95 / sz_x);
        if(sz_y > 0.95)
                sz = sz * (0.95 / sz_y);
 
        draw_Picture('0.5 0.5 0' - 0.5 * sz, me.src3, sz, rgb, a);
+       if(cvar("crosshair_dot"))
+               draw_Picture('0.5 0.5 0' - 0.5 * sz * cvar("crosshair_dot_size"), me.src4, sz * cvar("crosshair_dot_size"), rgb, a * cvar("crosshair_dot_alpha"));
 }
 #endif
index 517f68bd311b7ee10176b8f8ab1e9b8a65127905..c0d16a959727cb2c7bf3de5b980153b7eba124ea 100644 (file)
@@ -268,7 +268,7 @@ void XonoticMutatorsDialog_fill(entity me)
                me.TDempty(me, 0.2);
                me.TD(me, 1, 2, e = makeXonoticRadioButton(1, "g_start_weapon_laser", "0", "No start weapons"));
                        e.cvarOffValue = "-1";
-                       makeMulti(e, "g_start_weapon_shotgun g_start_weapon_uzi g_start_weapon_grenadelauncher g_start_weapon_electro g_start_weapon_crylink g_start_weapon_nex g_start_weapon_hagar g_start_weapon_rocketlauncher g_start_weapon_campingrifle g_start_weapon_hlac g_start_weapon_seeker g_start_weapon_minstanex g_start_weapon_hook g_start_weapon_porto g_start_weapon_tuba");
+                       makeMulti(e, "g_start_weapon_shotgun g_start_weapon_uzi g_start_weapon_grenadelauncher g_start_weapon_minelayer g_start_weapon_electro g_start_weapon_crylink g_start_weapon_nex g_start_weapon_hagar g_start_weapon_rocketlauncher g_start_weapon_campingrifle g_start_weapon_hlac g_start_weapon_seeker g_start_weapon_minstanex g_start_weapon_hook g_start_weapon_porto g_start_weapon_tuba");
 
        me.gotoRC(me, me.rows - 1, 0);
                me.TD(me, 1, me.columns, e = makeXonoticButton("OK", '0 0 0'));
index 754da256a9ffc3f44a2165339fc62aec8f6140c1..751c5559180c592e5ac2b350dea2ad1b00afb0d6 100644 (file)
@@ -84,7 +84,7 @@ void XonoticPlayerSettingsTab_fill(entity me)
                }
 
        me.gotoRC(me, 0, 3.5); me.setFirstColumn(me, me.currentColumn);
-               me.TD(me, 1, 1, e = makeXonoticTextLabel(0, "Field of View:"));
+               me.TD(me, 1, 1, e = makeXonoticTextLabel(0, "Field of view:"));
                me.TD(me, 1, 2, e = makeXonoticSlider(60, 130, 1, "fov"));
        me.TR(me);
                me.TD(me, 1, 1, e = makeXonoticTextLabel(0, "Damage kick:"));
@@ -92,11 +92,9 @@ void XonoticPlayerSettingsTab_fill(entity me)
        me.TR(me);
                sl = makeXonoticSlider(0.45, 0.75, 0.01, "cl_bobcycle");
                me.TD(me, 1, 1, e = makeXonoticSliderCheckBox(0, 1, sl, "View bobbing:"));
-               me.TD(me, 1, 2, sl);
-       
-       me.TR(me);
+               me.TD(me, 1, 2, sl);    
        me.TR(me);
-               me.TD(me, 1, 1, e = makeXonoticTextLabel(0, "Zoom Factor:"));
+               me.TD(me, 1, 1, e = makeXonoticTextLabel(0, "Zoom factor:"));
                me.TD(me, 1, 2, e = makeXonoticSlider(2, 16, 0.5, "cl_zoomfactor"));
        me.TR(me);
                sl = makeXonoticSlider(1, 8, 0.5, "cl_zoomspeed");
@@ -110,40 +108,55 @@ void XonoticPlayerSettingsTab_fill(entity me)
                        e0.textEntity = main.weaponsDialog;
                        e0.allowCut = 1;
        me.TR(me);
-       me.TR(me);
-               me.TD(me, 1, 2, e = makeXonoticCheckBox(0, "crosshair_per_weapon", "Per weapon crosshairs"));
-               me.TD(me, 1, 1.3, e = makeXonoticCheckBox(1, "crosshair_color_override", "& crosshair colors"));
+               me.TD(me, 1, 0.75, e = makeXonoticTextLabel(0, "Crosshair:"));
+               me.TD(me, 1, 1.00, e = makeXonoticCheckBox(0, "crosshair_per_weapon", "Per weapon"));
+               me.TD(me, 1, 1.25, e = makeXonoticCheckBox(1, "crosshair_color_override", "& Per weapon colors"));
                setDependent(e, "crosshair_per_weapon", 1, 1);
        me.TR(me);
-               me.TD(me, 1, 1, e = makeXonoticTextLabel(0, "Crosshair:"));
+               me.TDempty(me, 0.5);
                for(i = 1; i <= 10; ++i) {
                        me.TDNoMargin(me, 1, 2 / 10, e = makeXonoticCrosshairButton(3, i), '1 1 0');
                        setDependent(e, "crosshair_per_weapon", 0, 0);
                }
        me.TR(me);
-               me.TDempty(me, 1);
+               me.TDempty(me, 0.5);
                for(i = 11; i <= 20; ++i) {
                        me.TDNoMargin(me, 1, 2 / 10, e = makeXonoticCrosshairButton(3, i), '1 1 0');
                        setDependent(e, "crosshair_per_weapon", 0, 0);
                }
        me.TR(me);
-               me.TD(me, 1, 1, e = makeXonoticTextLabel(0, "Crosshair Size:"));
-               me.TD(me, 1, 2, e = makeXonoticSlider(0.40, 2, 0.05, "crosshair_size"));
+               me.TDempty(me, 0.2);
+               me.TD(me, 1, 1, e = makeXonoticTextLabel(0, "Crosshair size:"));
+               me.TD(me, 1, 1.8, e = makeXonoticSlider(0.10, 1.5, 0.05, "crosshair_size"));
        me.TR(me);
-               me.TD(me, 1, 1, e = makeXonoticTextLabel(0, "Crosshair Alpha:"));
-               me.TD(me, 1, 2, e = makeXonoticSlider(0, 1, 0.01, "crosshair_color_alpha"));
+               me.TDempty(me, 0.2);
+               me.TD(me, 1, 1, e = makeXonoticTextLabel(0, "Crosshair alpha:"));
+               me.TD(me, 1, 1.8, e = makeXonoticSlider(0, 1, 0.1, "crosshair_color_alpha"));
        me.TR(me);
-               me.TD(me, 1, 1, e = makeXonoticTextLabel(0, "Crosshair Red:"));
-               me.TD(me, 1, 2, e = makeXonoticSlider(0, 1, 0.01, "crosshair_color_red"));
+               me.TDempty(me, 0.2);
+               me.TD(me, 1, 1, e = makeXonoticTextLabel(0, "Crosshair red:"));
+               me.TD(me, 1, 1.8, e = makeXonoticSlider(0, 1, 0.01, "crosshair_color_red"));
                setDependentOR(e, "crosshair_per_weapon", 0, 0, "crosshair_color_override", 1, 1);
        me.TR(me);
-               me.TD(me, 1, 1, e = makeXonoticTextLabel(0, "Crosshair Green:"));
-               me.TD(me, 1, 2, e = makeXonoticSlider(0, 1, 0.01, "crosshair_color_green"));
+               me.TDempty(me, 0.2);
+               me.TD(me, 1, 1, e = makeXonoticTextLabel(0, "Crosshair green:"));
+               me.TD(me, 1, 1.8, e = makeXonoticSlider(0, 1, 0.01, "crosshair_color_green"));
                setDependentOR(e, "crosshair_per_weapon", 0, 0, "crosshair_color_override", 1, 1);
        me.TR(me);
-               me.TD(me, 1, 1, e = makeXonoticTextLabel(0, "Crosshair Blue:"));
-               me.TD(me, 1, 2, e = makeXonoticSlider(0, 1, 0.01, "crosshair_color_blue"));
+               me.TDempty(me, 0.2);
+               me.TD(me, 1, 1, e = makeXonoticTextLabel(0, "Crosshair blue:"));
+               me.TD(me, 1, 1.8, e = makeXonoticSlider(0, 1, 0.01, "crosshair_color_blue"));
                setDependentOR(e, "crosshair_per_weapon", 0, 0, "crosshair_color_override", 1, 1);
+       me.TR(me);
+               me.TD(me, 1, 3, e = makeXonoticCheckBox(0, "crosshair_dot", "Enable centered dot"));
+       me.TR(me);
+               me.TDempty(me, 0.2);
+               me.TD(me, 1, 0.5, e = makeXonoticTextLabel(0, "Size:"));
+               me.TD(me, 1, 0.9, e = makeXonoticSlider(0.2, 2, 0.1, "crosshair_dot_size"));
+                       setDependent(e, "crosshair_dot", 1, 1);
+               me.TD(me, 1, 0.5, e = makeXonoticTextLabel(0, "Alpha:"));
+               me.TD(me, 1, 0.9, e = makeXonoticSlider(0.10, 1, 0.1, "crosshair_dot_alpha"));
+                       setDependent(e, "crosshair_dot", 1, 1);
        me.TR(me);
                me.TD(me, 1, 1, e = makeXonoticTextLabel(0, "Hit test:"));
                me.TD(me, 1, 2/3, e = makeXonoticRadioButton(1, "crosshair_hittest", "0",    "None"));
@@ -157,13 +170,13 @@ void XonoticPlayerSettingsTab_fill(entity me)
                me.TDempty(me, 0.5);
        me.TR(me);
                me.TDempty(me, 0.4);
-               me.TD(me, 1, 2.2, e = makeXonoticButton("HUD Setup", '0 0 0'));
+               me.TD(me, 1, 2.2, e = makeXonoticButton("Enter HUD editor", '0 0 0'));
                        e.onClick = HUDSetup_Join_Click;
                        e.onClickEntity = me;
                me.TDempty(me, 0.5);
        me.TR(me);
        #ifdef ALLOW_FORCEMODELS
-               me.TD(me, 1, 1, e = makeXonoticTextLabel(0, "Force Models:"));
+               me.TD(me, 1, 1, e = makeXonoticTextLabel(0, "Force models:"));
                me.TD(me, 1, 2/3, e = makeXonoticRadioButton(2, string_null, string_null, "None"));
                me.TD(me, 1, 2/3, e = makeXonoticRadioButton(2, "cl_forceplayermodelsfromxonotic", string_null, "Custom"));
                me.TD(me, 1, 2/3, e = makeXonoticRadioButton(2, "cl_forceplayermodels", string_null, "All"));
index 00912bea3389eb6347f9f18bd68416a2ea975f99..eaa30d2d46ae4ca1d4936fe77220542541c1dad9 100644 (file)
                <Unit filename="w_electro.qc" />
                <Unit filename="w_fireball.qc" />
                <Unit filename="w_grenadelauncher.qc" />
+               <Unit filename="w_minelayer.qc" />
                <Unit filename="w_hagar.qc" />
                <Unit filename="w_hlac.qc" />
                <Unit filename="w_hook.qc" />
index 2b86c27ad0b3c6949c4f1ccc109260d601737edb..934aba87ddc6fd2f175fcbde18459dc3de57f694 100644 (file)
@@ -950,6 +950,7 @@ void havocbot_chooseweapon()
        local float nex     ; nex      =-1000;
        local float hagar   ; hagar    =-1000;
        local float grenade ; grenade  =-1000;
+       local float mine    ; mine     =-1000;
        local float electro ; electro  =-1000;
        local float crylink ; crylink  =-1000;
        local float uzi     ; uzi      =-1000;
@@ -1077,6 +1078,15 @@ void havocbot_chooseweapon()
                grenade = (cvar("g_balance_grenadelauncher_primary_damage")/cvar("g_balance_grenadelauncher_primary_refire")*1.0)
                        * bound(0,(cvar("g_balance_grenadelauncher_primary_speed")/distance*maxdelaytime),1)*1.1;
 
+       if (client_hasweapon(self, WEP_MINE_LAYER, TRUE, FALSE) &&
+               !(
+                       cvar("bot_ai_weapon_combo") && self.weapon == WEP_MINE_LAYER &&
+                       af > combo_time
+               )
+       )
+               mine = (cvar("g_balance_minelayer_damage")/cvar("g_balance_minelayer_refire")*1.0)
+                       * bound(0,(cvar("g_balance_minelayer_speed")/distance*maxdelaytime),1)*1.1;
+
        if (client_hasweapon(self, WEP_ELECTRO, TRUE, FALSE) &&
                !(      cvar("bot_ai_weapon_combo") && self.weapon == WEP_ELECTRO &&
                        af > combo_time
@@ -1123,6 +1133,7 @@ void havocbot_chooseweapon()
        dprint("Nex: "    , ftos(nex     ), "\n");
        dprint("Hagar: "  , ftos(hagar   ), "\n");
        dprint("Grenade: ", ftos(grenade ), "\n");
+       dprint("Mine: "   , ftos(mine    ), "\n");
        dprint("Electro: ", ftos(electro ), "\n");
        dprint("Crylink: ", ftos(crylink ), "\n");
        dprint("Uzi: "    , ftos(uzi     ), "\n");
@@ -1135,6 +1146,7 @@ void havocbot_chooseweapon()
        w = WEP_NEX              ;s = nex      ;if (s > bestscore){bestscore = s;bestweapon = w;} if (self.switchweapon == w) currentscore = s;
        w = WEP_HAGAR            ;s = hagar    ;if (s > bestscore){bestscore = s;bestweapon = w;} if (self.switchweapon == w) currentscore = s;
        w = WEP_GRENADE_LAUNCHER ;s = grenade  ;if (s > bestscore){bestscore = s;bestweapon = w;} if (self.switchweapon == w) currentscore = s;
+       w = WEP_MINE_LAYER       ;s = mine     ;if (s > bestscore){bestscore = s;bestweapon = w;} if (self.switchweapon == w) currentscore = s;
        w = WEP_ELECTRO          ;s = electro  ;if (s > bestscore){bestscore = s;bestweapon = w;} if (self.switchweapon == w) currentscore = s;
        w = WEP_CRYLINK          ;s = crylink  ;if (s > bestscore){bestscore = s;bestweapon = w;} if (self.switchweapon == w) currentscore = s;
        w = WEP_UZI              ;s = uzi      ;if (s > bestscore){bestscore = s;bestweapon = w;} if (self.switchweapon == w) currentscore = s;
index bf542ab34f8a4f8dc012a369d0dcf41a684a9dd0..068912d6589f0f94df85fcb6f02d280a821aedbc 100644 (file)
@@ -10,8 +10,19 @@ void send_CSQC_nexvelocity(entity e) {
        msg_entity = e;
        WriteByte(MSG_ONE, SVC_TEMPENTITY);
        WriteByte(MSG_ONE, TE_CSQC_NEX_VELOCITY);
+       WriteByte(MSG_ONE, bound(0, fabs(cvar("g_balance_nex_velocitydependent_halflife")), 1));
        WriteShort(MSG_ONE, cvar("g_balance_nex_velocitydependent_minspeed"));
        WriteShort(MSG_ONE, cvar("g_balance_nex_velocitydependent_maxspeed"));
+       WriteByte(MSG_ONE, cvar("g_balance_nex_velocitydependent_falloff_rate"));
+       WriteByte(MSG_ONE, cvar("g_balance_nex_secondary_charge"));
+       WriteByte(MSG_ONE, cvar("g_balance_nex_secondary_charge_rate"));
+}
+
+void send_CSQC_cr_maxbullets(entity e) {
+       msg_entity = e;
+       WriteByte(MSG_ONE, SVC_TEMPENTITY);
+       WriteByte(MSG_ONE, TE_CSQC_CR_MAXBULLETS);
+       WriteByte(MSG_ONE, cvar("g_balance_campingrifle_magazinecapacity"));
 }
 
 void Announce(string snd) {
@@ -1597,6 +1608,7 @@ void ClientConnect (void)
                send_CSQC_teamnagger();
 
        send_CSQC_nexvelocity(self);
+       send_CSQC_cr_maxbullets(self);
 
        CheatInitClient();
 }
index 2df6c1c4fefb2ffbad069cb587cd27e82f22bdff..d9394deaf26a968573d2331a5c78d87d227a5ccd 100644 (file)
@@ -37,6 +37,8 @@ float sv_airspeedlimit_nonqw;
 .float multijump_ready;
 .float prevjumpbutton;
 
+.float nexspeed;
+
 /*
 =============
 PlayerJump
@@ -1323,6 +1325,15 @@ void SV_PlayerPhysics()
                        }
                }
        }
+
+       float f;
+       float xyspeed;
+       f = cvar("g_balance_nex_velocitydependent_falloff_rate");
+       xyspeed = vlen('1 0 0' * self.velocity_x + '0 1 0' * self.velocity_y);
+       if(xyspeed > self.nexspeed)
+               self.nexspeed = min(xyspeed, cvar("g_balance_nex_velocitydependent_maxspeed"));
+       else
+               self.nexspeed = max(cvar("g_balance_nex_velocitydependent_minspeed"), self.nexspeed - f * frametime);
 :end
        if(self.flags & FL_ONGROUND)
                self.lastground = time;
index 9530f9a5192a0cf6da6d9ae56e001a55422d8e75..540e3f84acbba076156d31ddbe8cb20f54a6339f 100644 (file)
@@ -385,7 +385,7 @@ void W_WeaponFrame()
        // server framerate is very low and the weapon fire rate very high
        local float c;
        c = 0;
-       while (c < 5)
+       while (c < W_TICSPERFRAME)
        {
                c = c + 1;
                if(wb && ((self.weapons & wb) == 0))
index 925d53fa7e3cc218cfeba460f432969db25d7a47..c9a5dfc4aa1b9d61236355e94824506004053edb 100644 (file)
@@ -981,6 +981,13 @@ float client_hasweapon(entity cl, float wpn, float andammo, float complain)
                                self = cl;
                                f = weapon_action(wpn, WR_CHECKAMMO1);
                                f = f + weapon_action(wpn, WR_CHECKAMMO2);
+
+                               // always allow selecting the Mine Layer if we placed mines, so that we can detonate them
+                               local entity mine;
+                               if(wpn == WEP_MINE_LAYER)
+                               for(mine = world; (mine = find(mine, classname, "mine")); ) if(mine.owner == self)
+                                       f = 1;
+
                                self = oldself;
                        }
                        if (!f)
@@ -1093,6 +1100,12 @@ float weapon_prepareattack_checkammo(float secondary)
        if not(self.items & IT_UNLIMITED_WEAPON_AMMO)
        if (!weapon_action(self.weapon, WR_CHECKAMMO1 + secondary))
        {
+               // always keep the Mine Layer if we placed mines, so that we can detonate them
+               local entity mine;
+               if(self.weapon == WEP_MINE_LAYER)
+               for(mine = world; (mine = find(mine, classname, "mine")); ) if(mine.owner == self)
+                       return FALSE;
+
                W_SwitchToOtherWeapon(self);
                return FALSE;
        }
index f084e18d4b0b69f6a92b5009321e419e583145c5..679a1b445b019aadc29bdc713730910a617084ee 100644 (file)
@@ -221,6 +221,9 @@ float WS_DROP                       = 2; // deselecting frame
 float WS_INUSE                 = 3; // fire state
 float WS_READY                 = 4; // idle frame
 
+// there is 2 weapon tics that can run in one server frame
+#define W_TICSPERFRAME 2
+
 void weapon_defaultspawnfunc(float wpn);
 
 string w_deathtypestring;
@@ -294,6 +297,7 @@ string getTimeoutText(float addOneSecond);
 .entity flagcarried;
 
 .entity lastrocket;
+.entity lastmine;
 
 .float playerid;
 float playerid_last;
index 7108fd3dbea18530d278c237c753405fe912db39..76cb7861498c7820ea603c9ad2b118b4f8f48951 100644 (file)
@@ -850,20 +850,6 @@ void Damage (entity targ, entity inflictor, entity attacker, float damage, float
        }
 }
 
-vector NearestPointOnBox(entity box, vector org)
-{
-       vector m1, m2, nearest;
-
-       m1 = box.mins + box.origin;
-       m2 = box.maxs + box.origin;
-
-       nearest_x = bound(m1_x, org_x, m2_x);
-       nearest_y = bound(m1_y, org_y, m2_y);
-       nearest_z = bound(m1_z, org_z, m2_z);
-
-       return nearest;
-}
-
 void Damage_RecordDamage(entity attacker, float deathtype, float damage)
 {
        float weaponid;
index 0f0bba6e6d36fb335a5afa4485d6b2fd79e373f2..bc996fd321647183b1824eb233d052dae33e69a9 100644 (file)
@@ -57,6 +57,8 @@ float g_clientmodel_genericsendentity (entity to, float sf)
                sf |= 0x20;
        if(self.colormap != 0)
                sf |= 0x40;
+       if(self.lodmodelindex1)
+               sf |= 0x80;
        
        WriteByte(MSG_ENTITY, ENT_CLIENT_WALL);
        WriteByte(MSG_ENTITY, sf);
@@ -86,7 +88,16 @@ float g_clientmodel_genericsendentity (entity to, float sf)
 
        if(sf & 8)
        {
-               WriteShort(MSG_ENTITY, self.modelindex);
+               if(sf & 0x80)
+               {
+                       WriteShort(MSG_ENTITY, self.lodmodelindex0);
+                       WriteShort(MSG_ENTITY, bound(0, self.loddistance1, 65535));
+                       WriteShort(MSG_ENTITY, self.lodmodelindex1);
+                       WriteShort(MSG_ENTITY, bound(0, self.loddistance2, 65535));
+                       WriteShort(MSG_ENTITY, self.lodmodelindex2);
+               }
+               else
+                       WriteShort(MSG_ENTITY, self.modelindex);
                WriteByte(MSG_ENTITY, self.solid);
                WriteShort(MSG_ENTITY, floor(self.scale * 256));
                if(sf & 0x20)
@@ -124,7 +135,7 @@ float g_clientmodel_genericsendentity (entity to, float sf)
        if(!self.solid) self.solid = (sol); else if(self.solid < 0) self.solid = SOLID_NOT;
 
 #define G_CLIENTMODEL_INIT(sol) \
-       SetBrushEntityModelNoLOD(); \
+       SetBrushEntityModel(); \
        if(!self.scale) self.scale = self.modelscale; \
        self.use = g_clientmodel_setcolormaptoactivator; \
        InitializeEntity(self, g_clientmodel_dropbyspawnflags, INITPRIO_DROPTOFLOOR); \
index 1d1f0bb9bd0f1bfee26d37846ad17085026bbdb4..5d8401df98e934d637822e419582270db3484c14 100644 (file)
@@ -605,7 +605,6 @@ float angc (float a1, float a2)
 .float loddistance1;
 .float loddistance2;
 
-vector NearestPointOnBox(entity box, vector org);
 float LOD_customize()
 {
        float d;
@@ -615,7 +614,7 @@ float LOD_customize()
                d = cvar("loddebug");
                if(d == 1)
                        self.modelindex = self.lodmodelindex0;
-               else if(d == 2)
+               else if(d == 2 || !self.lodmodelindex2)
                        self.modelindex = self.lodmodelindex1;
                else // if(d == 3)
                        self.modelindex = self.lodmodelindex2;
@@ -695,7 +694,8 @@ void LODmodel_attach()
        }
 
        if(self.lodmodelindex1)
-               SetCustomizer(self, LOD_customize, LOD_uncustomize);
+               if not(self.SendEntity)
+                       SetCustomizer(self, LOD_customize, LOD_uncustomize);
 }
 
 void SetBrushEntityModel()
index c582594693dcbcec79372490c49eddfcbc1bc91b..a1ee74d4300439589790a925384997779f6c7de0 100644 (file)
@@ -1996,3 +1996,20 @@ void spawnfunc_relay_activatetoggle()
        self.cnt = ACTIVE_TOGGLE;
        self.use = relay_activators_use;        
 }
+
+.string chmap, gametype;
+void spawnfunc_target_changelevel_use()
+{
+       if(self.gametype != "")
+               MapInfo_SwitchGameType(MapInfo_Type_FromString(self.gametype));
+
+       if (self.chmap == "")
+               localcmd("endmatch\n");
+       else
+               localcmd(strcat("changelevel ", self.chmap, "\n"));
+};
+
+void spawnfunc_target_changelevel()
+{
+       self.use = spawnfunc_target_changelevel_use;
+};
index 3db4e47be8d2e154732916bda9d1de44bee0cad8..d4232424072f84aa90d2c7fd220371e4a91aa923 100644 (file)
@@ -989,7 +989,7 @@ void readplayerstartcvars()
        if (g_weaponarena)
        {
                start_weapons = g_weaponarena;
-               if (g_weaponarena & (WEPBIT_GRENADE_LAUNCHER | WEPBIT_HAGAR | WEPBIT_ROCKET_LAUNCHER))
+               if (g_weaponarena & (WEPBIT_GRENADE_LAUNCHER | WEPBIT_MINE_LAYER | WEPBIT_HAGAR | WEPBIT_ROCKET_LAUNCHER))
                        start_ammo_rockets = 999;
                if (g_weaponarena & WEPBIT_SHOTGUN)
                        start_ammo_shells = 999;
index b9ebf9183ba4913e3bb162444495888771c5822c..9f3770ff26bf068a47e7998c0a0f0cba683a1e81 100644 (file)
@@ -491,11 +491,11 @@ void() deathmatch7update =
                if (time >= 2)
                {
                        spawnedexitmonsters = TRUE;
-                       e = find(world, classname, "trigger_changelevel");
+                       e = find(world, classname, "target_changelevel");
                        while (e)
                        {
                                spawnmonster(e.origin + (e.mins + e.maxs) * 0.5, 8, 8, "monster_hellfish", monster_hellfish, '-16 -16 -24', '16 16 32');
-                               e = find(e, classname, "trigger_changelevel");
+                               e = find(e, classname, "target_changelevel");
                        }
                }
                return;
index 583fc735966d68c1de4b22cce08c6fc084f4c295..d338cf637dd156e811409064ff0133dda7468140 100644 (file)
@@ -418,8 +418,9 @@ void func_bobbing_controller_think()
        // calculate sinewave using makevectors
        makevectors((self.nextthink * self.owner.cnt + self.owner.phase * 360) * '0 1 0');
        v = self.owner.destvec + self.owner.movedir * v_forward_y;
-       // * 10 so it will arrive in 0.1 sec
-       self.owner.velocity = (v - self.owner.origin) * 10;
+       if(self.owner.classname == "func_bobbing") // don't brake stuff if the func_bobbing was killtarget'ed
+               // * 10 so it will arrive in 0.1 sec
+               self.owner.velocity = (v - self.owner.origin) * 10;
 };
 
 void bobbing_blocked()
@@ -1694,8 +1695,9 @@ void func_fourier_controller_think()
                v = v + ('1 0 0' * stof(argv(i*5+2)) + '0 1 0' * stof(argv(i*5+3)) + '0 0 1' * stof(argv(i*5+4))) * self.owner.height * v_forward_y;
        }
 
-       // * 10 so it will arrive in 0.1 sec
-       self.owner.velocity = (v - self.owner.origin) * 10;
+       if(self.owner.classname == "func_fourier") // don't brake stuff if the func_fourier was killtarget'ed
+               // * 10 so it will arrive in 0.1 sec
+               self.owner.velocity = (v - self.owner.origin) * 10;
 };
 
 void spawnfunc_func_fourier()
@@ -1814,7 +1816,8 @@ void func_vectormamamam_controller_think()
                return;
        }
 
-       self.owner.velocity = (self.owner.destvec + func_vectormamamam_origin(self.owner, 0.1) - self.owner.origin) * 10;
+       if(self.owner.classname == "func_vectormamamam") // don't brake stuff if the func_vectormamamam was killtarget'ed
+               self.owner.velocity = (self.owner.destvec + func_vectormamamam_origin(self.owner, 0.1) - self.owner.origin) * 10;
 }
 
 void func_vectormamamam_findtarget()
index 9a9b3830244602e00861704efe6716a2229f6304..83fc8acb5de47e9f58406588fdebce20099ba899 100644 (file)
@@ -2,6 +2,7 @@
 #include "w_shotgun.qc"
 #include "w_uzi.qc"
 #include "w_grenadelauncher.qc"
+#include "w_minelayer.qc"
 #include "w_electro.qc"
 #include "w_crylink.qc"
 #include "w_nex.qc"
index 1cd280e007b531f7f23122fbde2c16890e7fa9f3..d0b6f4ed8836b449143539af5d3c0e6a3dbe8b93 100644 (file)
@@ -96,7 +96,10 @@ void W_CampingRifle_FireBullet(float pSpread, float pDamage, float pHeadshotAdde
                w_shotorg = self.origin + self.view_ofs + ((w_shotorg - self.origin - self.view_ofs) * v_forward) * v_forward;
        }
 
-       fireBallisticBullet(w_shotorg, w_shotdir, pSpread, pSpeed, pLifetime, pDamage, pHeadshotAddedDamage / pDamage, pForce, deathtype, (cvar("g_balance_campingrifle_tracer") ? EF_RED : EF_BLUE), 1, pBulletConstant);
+       if(deathtype & HITTYPE_SECONDARY)
+               fireBallisticBullet(w_shotorg, w_shotdir, pSpread, pSpeed, pLifetime, pDamage, pHeadshotAddedDamage / pDamage, pForce, deathtype, (cvar("g_balance_campingrifle_secondary_tracer") ? EF_RED : EF_BLUE), 1, pBulletConstant);
+       else
+               fireBallisticBullet(w_shotorg, w_shotdir, pSpread, pSpeed, pLifetime, pDamage, pHeadshotAddedDamage / pDamage, pForce, deathtype, (cvar("g_balance_campingrifle_primary_tracer") ? EF_RED : EF_BLUE), 1, pBulletConstant);
        endFireBallisticBullet();
 
        if (cvar("g_casings") >= 2)
index e885cd0d28d8635b9abe9fd5ce11edb62a9d9eba..4bee058f0fcff973d2d2173332b819559b8f91af 100644 (file)
@@ -216,11 +216,18 @@ float lgbeam_send(entity to, float sf)
 void lgbeam_think()
 {
        self.owner.prevlgfire = time;
-       if (self.owner.weaponentity.state != WS_INUSE || (self.owner.ammo_cells <= 0 && !(self.owner.items & IT_UNLIMITED_WEAPON_AMMO)) || self != self.owner.lgbeam || self.owner.deadflag != DEAD_NO || !self.owner.BUTTON_ATCK)
+       if (self != self.owner.lgbeam)
        {
                remove(self);
                return;
        }
+       if (self.owner.weaponentity.state != WS_INUSE || (self.owner.ammo_cells <= 0 && !(self.owner.items & IT_UNLIMITED_WEAPON_AMMO)) || self.owner.deadflag != DEAD_NO || !self.owner.BUTTON_ATCK)
+       {
+               if(self == self.owner.lgbeam)
+                       self.owner.lgbeam = world;
+               remove(self);
+               return;
+       }
 
        self.nextthink = time;
 
@@ -355,7 +362,7 @@ float w_electro(float req)
                        {
                                if(cvar("g_balance_electro_lightning"))
                                {
-                                       if (self.BUTTON_ATCK_prev == 0)
+                                       if ((!self.lgbeam) || wasfreed(self.lgbeam))
                                        {
                                                W_Electro_Attack3();
                                        }
index 0827d2402fc41df56d8ab42cdf575c2777a195d8..6b98d37cd7404b024f8252e55b49307d58ecf4c1 100644 (file)
@@ -323,13 +323,13 @@ float w_fireball(float req)
        {
                if (self.BUTTON_ATCK)
                if (time >= self.fireball_primarytime)
-               if (weapon_prepareattack(1, cvar("g_balance_fireball_primary_refire")))
+               if (weapon_prepareattack(0, cvar("g_balance_fireball_primary_refire")))
                {
                        W_Fireball_Attack1_Frame0();
                        self.fireball_primarytime = time + cvar("g_balance_fireball_primary_refire2");
                }
                if (self.BUTTON_ATCK2)
-               if (weapon_prepareattack(0, cvar("g_balance_fireball_secondary_refire")))
+               if (weapon_prepareattack(1, cvar("g_balance_fireball_secondary_refire")))
                {
                        W_Fireball_Attack2();
                        weapon_thinkf(WFRAME_FIRE2, cvar("g_balance_fireball_secondary_animtime"), w_ready);
diff --git a/qcsrc/server/w_minelayer.qc b/qcsrc/server/w_minelayer.qc
new file mode 100644 (file)
index 0000000..da847d2
--- /dev/null
@@ -0,0 +1,451 @@
+#ifdef REGISTER_WEAPON
+REGISTER_WEAPON(MINE_LAYER, w_minelayer, IT_ROCKETS, 4, WEP_FLAG_NORMAL | WEP_TYPE_SPLASH, BOT_PICKUP_RATING_HIGH, "minelayer", "minelayer", "Mine Layer");
+#else
+#ifdef SVQC
+void W_Mine_Think (void);
+.float minelayer_detonate, minelayer_mines;
+.float mine_time;
+
+void spawnfunc_weapon_minelayer (void)
+{
+       weapon_defaultspawnfunc(WEP_MINE_LAYER);
+}
+
+void W_Mine_Stick ()
+{
+       spamsound (self, CHAN_PROJECTILE, "weapons/mine_stick.wav", VOL_BASE, ATTN_NORM);
+
+       // in order for mines to face properly when sticking to the ground, they must be a server side entity rather than a csqc projectile
+
+       local entity newmine;
+       newmine = spawn();
+       newmine.classname = self.classname;
+
+       newmine.bot_dodge = self.bot_dodge;
+       newmine.bot_dodgerating = self.bot_dodgerating;
+
+       newmine.owner = self.owner;
+       setsize(newmine, '-4 -4 -4', '4 4 4');
+       setorigin(newmine, self.origin);
+       setmodel(newmine, "models/mine.md3");
+       newmine.angles = vectoangles(-trace_plane_normal); // face against the surface
+
+       newmine.takedamage = self.takedamage;
+       newmine.damageforcescale = self.damageforcescale;
+       newmine.health = self.health;
+       newmine.event_damage = self.event_damage;
+
+       newmine.movetype = MOVETYPE_NONE; // lock the mine in place
+       newmine.projectiledeathtype = self.projectiledeathtype;
+
+       newmine.mine_time = self.mine_time;
+
+       newmine.touch = SUB_Null;
+       newmine.think = W_Mine_Think;
+       newmine.nextthink = time;
+       newmine.cnt = self.cnt;
+       newmine.flags = self.flags;
+
+       remove(self);
+       self = newmine;
+}
+
+void W_Mine_Explode ()
+{
+       if(other.takedamage == DAMAGE_AIM)
+               if(other.classname == "player")
+                       if(IsDifferentTeam(self.owner, other))
+                               if(IsFlying(other))
+                                       AnnounceTo(self.owner, "airshot");
+
+       self.event_damage = SUB_Null;
+       self.takedamage = DAMAGE_NO;
+
+       RadiusDamage (self, self.owner, cvar("g_balance_minelayer_damage"), cvar("g_balance_minelayer_edgedamage"), cvar("g_balance_minelayer_radius"), world, cvar("g_balance_minelayer_force"), self.projectiledeathtype, other);
+
+       if (self.owner.weapon == WEP_MINE_LAYER)
+       {
+               if(self.owner.ammo_rockets < cvar("g_balance_minelayer_ammo"))
+               {
+                       self.owner.cnt = WEP_MINE_LAYER;
+                       ATTACK_FINISHED(self.owner) = time;
+                       self.owner.switchweapon = w_getbestweapon(self.owner);
+               }
+       }
+       remove (self);
+}
+
+void W_Mine_DoRemoteExplode ()
+{
+       self.event_damage = SUB_Null;
+       self.takedamage = DAMAGE_NO;
+
+       RadiusDamage (self, self.owner, cvar("g_balance_minelayer_remote_damage"), cvar("g_balance_minelayer_remote_edgedamage"), cvar("g_balance_minelayer_remote_radius"), world, cvar("g_balance_minelayer_remote_force"), self.projectiledeathtype | HITTYPE_BOUNCE, world);
+
+       if (self.owner.weapon == WEP_MINE_LAYER)
+       {
+               if(self.owner.ammo_rockets < cvar("g_balance_minelayer_ammo"))
+               {
+                       self.owner.cnt = WEP_MINE_LAYER;
+                       ATTACK_FINISHED(self.owner) = time;
+                       self.owner.switchweapon = w_getbestweapon(self.owner);
+               }
+       }
+       remove (self);
+}
+
+void W_Mine_RemoteExplode ()
+{
+       if(self.owner.deadflag == DEAD_NO)
+               if((self.spawnshieldtime >= 0)
+                       ? (time >= self.spawnshieldtime) // timer
+                       : (vlen(NearestPointOnBox(self.owner, self.origin) - self.origin) > cvar("g_balance_minelayer_radius")) // safety device
+               )
+               {
+                       W_Mine_DoRemoteExplode();
+               }
+}
+
+void W_Mine_ProximityExplode ()
+{
+       // make sure no friend is in the mine's radius. If there is any, explosion is delayed until he's at a safe distance
+       if(cvar("g_balance_minelayer_protection"))
+       {
+               entity head;
+               head = findradius(self.origin, cvar("g_balance_minelayer_radius"));
+               while(head)
+               {
+                       if(head == self.owner || !IsDifferentTeam(head, self.owner))
+                               return;
+                       head = head.chain;
+               }
+       }
+
+       self.mine_time = 0;
+       W_Mine_Explode();
+}
+
+void W_Mine_Think (void)
+{
+       entity head;
+
+       self.nextthink = time;
+       if (time > self.cnt)
+       {
+               other = world;
+               self.projectiledeathtype |= HITTYPE_BOUNCE;
+               W_Mine_Explode();
+               return;
+       }
+
+       // a player's mines shall explode if he disconnects or dies
+       // TODO: Do this on team change too
+       if(self.owner.classname != "player" || self.owner.deadflag != DEAD_NO)
+       {
+               other = world;
+               self.projectiledeathtype |= HITTYPE_BOUNCE;
+               W_Mine_Explode();
+               return;
+       }
+
+       // set the mine for detonation when a foe gets close enough
+       head = findradius(self.origin, cvar("g_balance_minelayer_proximityradius"));
+       while(head)
+       {
+               if(head.classname == "player" && head.deadflag == DEAD_NO)
+               if(head != self.owner && IsDifferentTeam(head, self.owner)) // don't trigger for team mates
+               if(!self.mine_time)
+               {
+                       spamsound (self, CHAN_PROJECTILE, "weapons/mine_trigger.wav", VOL_BASE, ATTN_NORM);
+                       self.mine_time = time + cvar("g_balance_minelayer_time");
+               }
+               head = head.chain;
+       }
+
+       // explode if it's time to
+       if(self.mine_time && time >= self.mine_time)
+               W_Mine_ProximityExplode();
+
+       // remote detonation
+       if (self.owner.weapon == WEP_MINE_LAYER)
+       if (self.owner.deadflag == DEAD_NO)
+       if (self.minelayer_detonate)
+               W_Mine_RemoteExplode();
+
+       if(self.csqcprojectile_clientanimate == 0)
+               UpdateCSQCProjectile(self);
+}
+
+void W_Mine_Touch (void)
+{
+       PROJECTILE_TOUCH;
+       if(!other || (other.takedamage != DAMAGE_AIM && other.movetype == MOVETYPE_NONE))
+               W_Mine_Stick();
+       else if(self.movetype != MOVETYPE_NONE) // don't unstick a locked mine when someone touches it
+               self.velocity = '0 0 0';
+}
+
+void W_Mine_Damage (entity inflictor, entity attacker, float damage, float deathtype, vector hitloc, vector force)
+{
+       if (self.health <= 0)
+               return;
+       self.health = self.health - damage;
+       self.angles = vectoangles(self.velocity);
+       if (self.health <= 0)
+               W_PrepareExplosionByDamage(attacker, W_Mine_Explode);
+}
+
+void W_Mine_Attack (void)
+{
+       local entity mine;
+       local entity flash;
+
+       // scan how many mines we placed, and return if we reached our limit
+       if(cvar("g_balance_minelayer_limit"))
+       {
+               self.minelayer_mines = 0;
+               for(mine = world; (mine = find(mine, classname, "mine")); ) if(mine.owner == self)
+                       self.minelayer_mines += 1;
+
+               if(self.minelayer_mines >= cvar("g_balance_minelayer_limit"))
+               {
+                       // the refire delay keeps this message from being spammed
+                       sprint(self, strcat("You cannot place more than ^2", cvar_string("g_balance_minelayer_limit"), " ^7mines at a time\n") );
+                       play2(self, "weapons/unavailable.wav");
+                       return;
+               }
+       }
+
+       if not(self.items & IT_UNLIMITED_WEAPON_AMMO)
+               self.ammo_rockets = self.ammo_rockets - cvar("g_balance_minelayer_ammo");
+
+       W_SetupShot_ProjectileSize (self, '-4 -4 -4', '4 4 4', FALSE, 5, "weapons/mine_fire.wav", cvar("g_balance_minelayer_damage"));
+       pointparticles(particleeffectnum("rocketlauncher_muzzleflash"), w_shotorg, w_shotdir * 1000, 1);
+
+       mine = WarpZone_RefSys_SpawnSameRefSys(self);
+       mine.owner = self;
+       if(cvar("g_balance_minelayer_detonatedelay") >= 0)
+               mine.spawnshieldtime = time + cvar("g_balance_minelayer_detonatedelay");
+       else
+               mine.spawnshieldtime = -1;
+       mine.classname = "mine";
+       mine.bot_dodge = TRUE;
+       mine.bot_dodgerating = cvar("g_balance_minelayer_damage") * 2; // * 2 because it can detonate inflight which makes it even more dangerous
+
+       mine.takedamage = DAMAGE_YES;
+       mine.damageforcescale = cvar("g_balance_minelayer_damageforcescale");
+       mine.health = cvar("g_balance_minelayer_health");
+       mine.event_damage = W_Mine_Damage;
+
+       mine.movetype = MOVETYPE_TOSS;
+       PROJECTILE_MAKETRIGGER(mine);
+       mine.projectiledeathtype = WEP_MINE_LAYER;
+       setsize (mine, '-4 -4 -4', '4 4 4'); // give it some size so it can be shot
+
+       setorigin (mine, w_shotorg - v_forward * 4); // move it back so it hits the wall at the right point
+       W_SetupProjectileVelocity(mine, cvar("g_balance_minelayer_speed"), 0);
+       mine.angles = vectoangles (mine.velocity);
+
+       mine.touch = W_Mine_Touch;
+       mine.think = W_Mine_Think;
+       mine.nextthink = time;
+       mine.cnt = time + cvar("g_balance_minelayer_lifetime");
+       mine.flags = FL_PROJECTILE;
+
+       CSQCProjectile(mine, FALSE, PROJECTILE_MINE, TRUE);
+
+       // muzzle flash for 1st person view
+       flash = spawn ();
+       setmodel (flash, "models/flash.md3"); // precision set below
+       SUB_SetFade (flash, time, 0.1);
+       flash.effects = EF_ADDITIVE | EF_FULLBRIGHT | EF_LOWPRECISION;
+       W_AttachToShotorg(flash, '5 0 0');
+
+       // common properties
+}
+
+void spawnfunc_weapon_minelayer (void); // defined in t_items.qc
+
+float w_minelayer(float req)
+{
+       entity mine;
+       float minfound;
+       if (req == WR_AIM)
+       {
+               // aim and decide to fire if appropriate
+               self.BUTTON_ATCK = bot_aim(cvar("g_balance_minelayer_speed"), 0, cvar("g_balance_minelayer_lifetime"), FALSE);
+               if(skill >= 2) // skill 0 and 1 bots won't detonate mines!
+               {
+                       // decide whether to detonate mines
+                       local entity mine, targetlist, targ;
+                       local float edgedamage, coredamage, edgeradius, recipricoledgeradius, d;
+                       local float selfdamage, teamdamage, enemydamage;
+                       edgedamage = cvar("g_balance_minelayer_edgedamage");
+                       coredamage = cvar("g_balance_minelayer_damage");
+                       edgeradius = cvar("g_balance_minelayer_radius");
+                       recipricoledgeradius = 1 / edgeradius;
+                       selfdamage = 0;
+                       teamdamage = 0;
+                       enemydamage = 0;
+                       targetlist = findchainfloat(bot_attack, TRUE);
+                       mine = find(world, classname, "mine");
+                       while (mine)
+                       {
+                               if (mine.owner != self)
+                               {
+                                       mine = find(mine, classname, "mine");
+                                       continue;
+                               }
+                               targ = targetlist;
+                               while (targ)
+                               {
+                                       d = vlen(targ.origin + (targ.mins + targ.maxs) * 0.5 - mine.origin);
+                                       d = bound(0, edgedamage + (coredamage - edgedamage) * sqrt(1 - d * recipricoledgeradius), 10000);
+                                       // count potential damage according to type of target
+                                       if (targ == self)
+                                               selfdamage = selfdamage + d;
+                                       else if (targ.team == self.team && teams_matter)
+                                               teamdamage = teamdamage + d;
+                                       else if (bot_shouldattack(targ))
+                                               enemydamage = enemydamage + d;
+                                       targ = targ.chain;
+                               }
+                               mine = find(mine, classname, "mine");
+                       }
+                       local float desirabledamage;
+                       desirabledamage = enemydamage;
+                       if (teamplay != 1 && time > self.invincible_finished && time > self.spawnshieldtime)
+                               desirabledamage = desirabledamage - selfdamage * cvar("g_balance_selfdamagepercent");
+                       if (self.team && teamplay != 1)
+                               desirabledamage = desirabledamage - teamdamage;
+
+                       mine = find(world, classname, "mine");
+                       while (mine)
+                       {
+                               if (mine.owner != self)
+                               {
+                                       mine = find(mine, classname, "mine");
+                                       continue;
+                               }
+                               makevectors(mine.v_angle);
+                               targ = targetlist;
+                               if (skill > 9) // normal players only do this for the target they are tracking
+                               {
+                                       targ = targetlist;
+                                       while (targ)
+                                       {
+                                               if (
+                                                       (v_forward * normalize(mine.origin - targ.origin)< 0.1)
+                                                       && desirabledamage > 0.1*coredamage
+                                               )self.BUTTON_ATCK2 = TRUE;
+                                               targ = targ.chain;
+                                       }
+                               }else{
+                                       local float distance; distance= bound(300,vlen(self.origin-self.enemy.origin),30000);
+                                       //As the distance gets larger, a correct detonation gets near imposible
+                                       //Bots are assumed to use the mine spawnfunc_light to see if the mine gets near a player
+                                       if(v_forward * normalize(mine.origin - self.enemy.origin)< 0.1)
+                                               if(self.enemy.classname == "player")
+                                                       if(desirabledamage >= 0.1*coredamage)
+                                                               if(random()/distance*300 > frametime*bound(0,(10-skill)*0.2,1))
+                                                                       self.BUTTON_ATCK2 = TRUE;
+                               //      dprint(ftos(random()/distance*300),">");dprint(ftos(frametime*bound(0,(10-skill)*0.2,1)),"\n");
+                               }
+
+                               mine = find(mine, classname, "mine");
+                       }
+                       // if we would be doing at X percent of the core damage, detonate it
+                       // but don't fire a new shot at the same time!
+                       if (desirabledamage >= 0.75 * coredamage) //this should do group damage in rare fortunate events
+                               self.BUTTON_ATCK2 = TRUE;
+                       if ((skill > 6.5) && (selfdamage > self.health))
+                               self.BUTTON_ATCK2 = FALSE;
+                       //if(self.BUTTON_ATCK2 == TRUE)
+                       //      dprint(ftos(desirabledamage),"\n");
+                       if (self.BUTTON_ATCK2 == TRUE) self.BUTTON_ATCK = FALSE;
+               }
+       }
+       else if (req == WR_THINK)
+       {
+               if (self.BUTTON_ATCK)
+               {
+                       if(weapon_prepareattack(0, cvar("g_balance_minelayer_refire")))
+                       {
+                               W_Mine_Attack();
+                               weapon_thinkf(WFRAME_FIRE1, cvar("g_balance_minelayer_animtime"), w_ready);
+                       }
+               }
+
+               if (self.BUTTON_ATCK2)
+               {
+                       minfound = 0;
+                       for(mine = world; (mine = find(mine, classname, "mine")); ) if(mine.owner == self)
+                       {
+                               if(!mine.minelayer_detonate)
+                               {
+                                       mine.minelayer_detonate = TRUE;
+                                       minfound = 1;
+                               }
+                       }
+                       if(minfound)
+                               sound (self, CHAN_WEAPON2, "weapons/mine_det.wav", VOL_BASE, ATTN_NORM);
+               }
+       }
+       else if (req == WR_PRECACHE)
+       {
+               precache_model ("models/flash.md3");
+               precache_model ("models/mine.md3");
+               precache_model ("models/weapons/g_minelayer.md3");
+               precache_model ("models/weapons/v_minelayer.md3");
+               precache_model ("models/weapons/h_minelayer.iqm");
+               precache_sound ("weapons/mine_det.wav");
+               precache_sound ("weapons/mine_fire.wav");
+               precache_sound ("weapons/mine_stick.wav");
+               precache_sound ("weapons/mine_trigger.wav");
+       }
+       else if (req == WR_SETUP)
+       {
+               weapon_setup(WEP_MINE_LAYER);
+       }
+       else if (req == WR_CHECKAMMO1)
+       {
+               // don't switch while placing a mine
+               if ((ATTACK_FINISHED(self) <= time || self.weapon != WEP_MINE_LAYER)
+                       && self.ammo_rockets < cvar("g_balance_minelayer_ammo"))
+                       return FALSE;
+       }
+       else if (req == WR_CHECKAMMO2)
+               return FALSE;
+       return TRUE;
+};
+#endif
+#ifdef CSQC
+float w_minelayer(float req)
+{
+       if(req == WR_IMPACTEFFECT)
+       {
+               vector org2;
+               org2 = w_org + w_backoff * 12;
+               pointparticles(particleeffectnum("rocket_explode"), org2, '0 0 0', 1);
+               if(!w_issilent)
+                       sound(self, CHAN_PROJECTILE, "weapons/mine_exp.wav", VOL_BASE, ATTN_NORM);
+       }
+       else if(req == WR_PRECACHE)
+       {
+               precache_sound("weapons/mine_exp.wav");
+       }
+       else if (req == WR_SUICIDEMESSAGE)
+               w_deathtypestring = "%s exploded";
+       else if (req == WR_KILLMESSAGE)
+       {
+               if(w_deathtype & HITTYPE_BOUNCE) // (remote detonation)
+                       w_deathtypestring = "%s got too close to %s's mine";
+               else if(w_deathtype & HITTYPE_SPLASH)
+                       w_deathtypestring = "%s almost dodged %s's mine";
+               else
+                       w_deathtypestring = "%s stepped on %s's mine";
+       }
+       return TRUE;
+}
+#endif
+#endif
index 8acf9f4c6b12c90727bf1d357f3e06eb8f873e93..e4c6347fedf430d3f505b5ce7b66e22815f83409 100644 (file)
@@ -43,11 +43,12 @@ void W_Nex_Attack (float issecondary)
        float flying;
        flying = IsFlying(self); // do this BEFORE to make the trace values from FireRailgunBullet last
 
-       f = ExponentialFalloff(cvar("g_balance_nex_velocitydependent_minspeed"), cvar("g_balance_nex_velocitydependent_maxspeed"), cvar("g_balance_nex_velocitydependent_halflife"), vlen('1 0 0' * self.velocity_x + '0 1 0' * self.velocity_y));
+       f = ExponentialFalloff(cvar("g_balance_nex_velocitydependent_minspeed"), cvar("g_balance_nex_velocitydependent_maxspeed"), cvar("g_balance_nex_velocitydependent_halflife"), self.nexspeed);
 
        // TODO: make it more obvious (through effects, indicator on weapon) that damage increases when speed increases
        mydmg *= f;
        myforce *= f;
+       //print("^1Damage: ^7", ftos(mydmg), "\n");
 
        W_SetupShot (self, TRUE, 5, "weapons/nexfire.wav", mydmg);
 
@@ -89,7 +90,15 @@ float w_nex(float req)
                }
                if (self.BUTTON_ATCK2)
                {
-                       if(cvar("g_balance_nex_secondary"))
+                       if(cvar("g_balance_nex_secondary_charge"))
+                       {
+                               if(self.ammo_cells)
+                               {
+                                       self.nexspeed = min(cvar("g_balance_nex_velocitydependent_maxspeed"), self.nexspeed + cvar("g_balance_nex_secondary_charge_rate") * frametime / W_TICSPERFRAME);
+                                       self.ammo_cells = max(0, self.ammo_cells - cvar("g_balance_nex_secondary_charge_ammo") * frametime / W_TICSPERFRAME);
+                               }
+                       }
+                       else if(cvar("g_balance_nex_secondary"))
                        {
                                if (weapon_prepareattack(0, cvar("g_balance_nex_secondary_refire")))
                                {
index cfa6ef965ec768949733736a165038d08555fd28..6e0ecb5b33811de1c266da4a90c617a84d16b2c3 100644 (file)
@@ -48,7 +48,7 @@ float WarpZone_Teleport(entity player)
 
        o1 = WarpZone_TransformOrigin(self, o0);
        v1 = WarpZone_TransformVelocity(self, v0);
-       if(player.classname == "player")
+       if(clienttype(player) != CLIENTTYPE_NOTACLIENT)
                a1 = WarpZone_TransformVAngles(self, player.v_angle);
        else
                a1 = WarpZone_TransformAngles(self, a0);
@@ -335,12 +335,17 @@ void WarpZonePosition_InitStep_FindTarget()
 
 void WarpZoneCamera_InitStep_FindTarget()
 {
+       entity e;
+       float i;
        if(self.target == "")
        {
                error("Camera with no target");
                return;
        }
-       self.enemy = find(world, targetname, self.target);
+       self.enemy = world;
+       for(e = world, i = 0; (e = find(e, targetname, self.target)); )
+               if(random() * ++i < 1)
+                       self.enemy = e;
        if(self.enemy == world)
        {
                error("Camera with nonexisting target");
@@ -348,6 +353,7 @@ void WarpZoneCamera_InitStep_FindTarget()
        }
        ++warpzone_cameras_exist;
        WarpZone_Camera_SetUp(self, self.enemy.origin, self.enemy.angles);
+       self.SendFlags = 0xFFFFFF;
 }
 
 void WarpZone_InitStep_UpdateTransform()
@@ -567,6 +573,8 @@ void WarpZones_Reconnect()
                WarpZone_InitStep_ClearTarget();
        for(self = warpzone_first; self; self = self.warpzone_next)
                WarpZone_InitStep_FindTarget();
+       for(self = warpzone_camera_first; self; self = self.warpzone_next)
+               WarpZoneCamera_InitStep_FindTarget();
        for(self = warpzone_first; self; self = self.warpzone_next)
                WarpZone_InitStep_FinalizeTransform();
        self = e;
@@ -583,8 +591,6 @@ void WarpZone_StartFrame()
                        WarpZone_InitStep_FindOriginTarget();
                for(self = warpzone_position_first; self; self = self.warpzone_next)
                        WarpZonePosition_InitStep_FindTarget();
-               for(self = warpzone_camera_first; self; self = self.warpzone_next)
-                       WarpZoneCamera_InitStep_FindTarget();
                for(self = warpzone_first; self; self = self.warpzone_next)
                        WarpZone_InitStep_UpdateTransform();
                self = e;
@@ -594,6 +600,16 @@ void WarpZone_StartFrame()
                WarpZone_StoreProjectileData(e);
 }
 
+.float warpzone_reconnecting;
+float visible_to_some_client(entity ent)
+{
+       entity e;
+       for(e = nextent(world); clienttype(e) != CLIENTTYPE_NOTACLIENT; e = nextent(e))
+               if(e.classname == "player" && clienttype(e) == CLIENTTYPE_REAL)
+                       if(checkpvs(e.origin + e.view_ofs, ent))
+                               return 1;
+       return 0;
+}
 void trigger_warpzone_reconnect_use()
 {
        entity e;
@@ -601,13 +617,20 @@ void trigger_warpzone_reconnect_use()
        // NOTE: this matches for target, not targetname, but of course
        // targetname must be set too on the other entities
        for(self = warpzone_first; self; self = self.warpzone_next)
-               if(e.target == "" || self.target == e.target)
+               self.warpzone_reconnecting = ((e.target == "" || self.target == e.target) && !((e.spawnflags & 1) && (visible_to_some_client(self) || visible_to_some_client(self.enemy))));
+       for(self = warpzone_camera_first; self; self = self.warpzone_next)
+               self.warpzone_reconnecting = ((e.target == "" || self.target == e.target) && !((e.spawnflags & 1) && visible_to_some_client(self)));
+       for(self = warpzone_first; self; self = self.warpzone_next)
+               if(self.warpzone_reconnecting)
                        WarpZone_InitStep_ClearTarget();
        for(self = warpzone_first; self; self = self.warpzone_next)
-               if(e.target == "" || self.target == e.target)
+               if(self.warpzone_reconnecting)
                        WarpZone_InitStep_FindTarget();
+       for(self = warpzone_camera_first; self; self = self.warpzone_next)
+               if(self.warpzone_reconnecting)
+                       WarpZoneCamera_InitStep_FindTarget();
        for(self = warpzone_first; self; self = self.warpzone_next)
-               if(e.target == "" || self.target == e.target || self.enemy.target == e.target)
+               if(self.warpzone_reconnecting || self.enemy.warpzone_reconnecting)
                        WarpZone_InitStep_FinalizeTransform();
        self = e;
 }
index a791c6f817e866e643fa007a5c378f0e2e0cbe7e..721b37b9142aba750d11267bb1891db1e93ad924 100644 (file)
Binary files a/sound/weapons/campingrifle_fire2.ogg and b/sound/weapons/campingrifle_fire2.ogg differ
diff --git a/sound/weapons/mine_det.ogg b/sound/weapons/mine_det.ogg
new file mode 100644 (file)
index 0000000..3dd5e12
Binary files /dev/null and b/sound/weapons/mine_det.ogg differ
diff --git a/sound/weapons/mine_exp.ogg b/sound/weapons/mine_exp.ogg
new file mode 100644 (file)
index 0000000..664c444
Binary files /dev/null and b/sound/weapons/mine_exp.ogg differ
diff --git a/sound/weapons/mine_fire.ogg b/sound/weapons/mine_fire.ogg
new file mode 100644 (file)
index 0000000..a6408b3
Binary files /dev/null and b/sound/weapons/mine_fire.ogg differ
diff --git a/sound/weapons/mine_stick.wav b/sound/weapons/mine_stick.wav
new file mode 100644 (file)
index 0000000..ae2cb49
Binary files /dev/null and b/sound/weapons/mine_stick.wav differ
diff --git a/sound/weapons/mine_trigger.wav b/sound/weapons/mine_trigger.wav
new file mode 100644 (file)
index 0000000..539a84d
Binary files /dev/null and b/sound/weapons/mine_trigger.wav differ
diff --git a/textures/gakarmor_glow.tga b/textures/gakarmor_glow.tga
new file mode 100644 (file)
index 0000000..946e6b5
Binary files /dev/null and b/textures/gakarmor_glow.tga differ
diff --git a/textures/gakarmor_pants.tga b/textures/gakarmor_pants.tga
deleted file mode 100644 (file)
index 3bfa2f8..0000000
Binary files a/textures/gakarmor_pants.tga and /dev/null differ
diff --git a/textures/items/a_bullets.jpg b/textures/items/a_bullets.jpg
deleted file mode 100644 (file)
index 8a99c05..0000000
Binary files a/textures/items/a_bullets.jpg and /dev/null differ
diff --git a/textures/items/a_bullets.tga b/textures/items/a_bullets.tga
new file mode 100644 (file)
index 0000000..35f8c69
Binary files /dev/null and b/textures/items/a_bullets.tga differ
index ed4e34ad43b053cc249211ddd1605d836b179b9a..ee2a1f5631da5eef4bdd3c1ed986c9021aba925c 100644 (file)
Binary files a/textures/pickups.tga and b/textures/pickups.tga differ
index 0442d39556138a85bdb7f6a780dbe66b6a1fec47..90acf588ce0c1d2e2f0ab48a6a1aa11c9eb3f89d 100644 (file)
Binary files a/textures/pickups_bump.tga and b/textures/pickups_bump.tga differ
index 16d73c23b39a4ae0c849551e13235a4f1184ef3e..4f310bfcfffec46cdf5c677fe5bd3fa15660adc2 100644 (file)
Binary files a/textures/pickups_gloss.tga and b/textures/pickups_gloss.tga differ
index c9e6f711a83b3b37bd3ca51e58a2edb056710f49..d74702995e1d1fc518d355853537889901dea17e 100644 (file)
Binary files a/textures/pickups_glow.tga and b/textures/pickups_glow.tga differ
index 239f2d04d190056247ae4a250aefcddd0552ad7c..71ba57121b2c5f54c5c8701ae1771cab5d7e413d 100644 (file)
Binary files a/textures/portals/portals_blue.tga and b/textures/portals/portals_blue.tga differ
index f321527980a55747c47cc5df3f4aa2d52eaa83fb..813a4e94211a8dfc3e95f7d610946e63d6c1b32a 100644 (file)
Binary files a/textures/portals/portals_blue_gloss.tga and b/textures/portals/portals_blue_gloss.tga differ
index 71ef5c255c74dede7952ff520e0cbc5c14e82130..83d10c4d554291a2ff2271395e0bb3cda7726b9d 100644 (file)
Binary files a/textures/portals/portals_blue_glow.tga and b/textures/portals/portals_blue_glow.tga differ
index 4484921007f4805f5bce449860d0a54b0b067a2b..defb53c60c4cb35e82502734309c6e171f673175 100644 (file)
Binary files a/textures/portals/portals_blue_norm.tga and b/textures/portals/portals_blue_norm.tga differ
index ae9d1a31fd18f7cf2a0f208c4c18f9952bdc4386..59d6dd65d4dbca99094b90e90424abcb76df4d16 100644 (file)
Binary files a/textures/portals/portals_red.tga and b/textures/portals/portals_red.tga differ
index d2baef68112404c0e7c525e1a14a567f4b5f1f25..7e17319f18dd9ca8f9d2d4b4bef01045982bd64a 100644 (file)
Binary files a/textures/portals/portals_red_gloss.tga and b/textures/portals/portals_red_gloss.tga differ
index ee42694415f87726043bb7801ea7e6f264f38988..b3a2f93655086fbe0b405aed0de6ef8ca85e2e69 100644 (file)
Binary files a/textures/portals/portals_red_glow.tga and b/textures/portals/portals_red_glow.tga differ
index 743a26775460bfa6d6128fd78088b7c0606f596a..e392a032392162a51dd6eb867038a899cbc520c2 100644 (file)
Binary files a/textures/portals/portals_red_norm.tga and b/textures/portals/portals_red_norm.tga differ
diff --git a/textures/pyria_glow.jpg b/textures/pyria_glow.jpg
deleted file mode 100644 (file)
index 952dfd9..0000000
Binary files a/textures/pyria_glow.jpg and /dev/null differ
index b1161db172a531798e8ec2969adef2a167400b2d..53a46f3a807f13aa61450a36161a6b68b243ccb9 100644 (file)
Binary files a/textures/pyria_glow.tga and b/textures/pyria_glow.tga differ
diff --git a/textures/pyria_pants.tga b/textures/pyria_pants.tga
deleted file mode 100644 (file)
index 0b6a69c..0000000
Binary files a/textures/pyria_pants.tga and /dev/null differ
index ff448abc5333a5bf83afebd1b20a5d02d4dce78e..62ca44604f4d9736719c222be9223426f44df80c 100644 (file)
Binary files a/textures/pyria_shirt.tga and b/textures/pyria_shirt.tga differ
diff --git a/textures/reptile.tga b/textures/reptile.tga
deleted file mode 100644 (file)
index 2090bb1..0000000
Binary files a/textures/reptile.tga and /dev/null differ
diff --git a/textures/reptile_bump.tga b/textures/reptile_bump.tga
deleted file mode 100644 (file)
index 27c5754..0000000
Binary files a/textures/reptile_bump.tga and /dev/null differ
diff --git a/textures/reptile_gloss.tga b/textures/reptile_gloss.tga
deleted file mode 100644 (file)
index 9647cde..0000000
Binary files a/textures/reptile_gloss.tga and /dev/null differ
diff --git a/textures/reptile_glow.tga b/textures/reptile_glow.tga
deleted file mode 100644 (file)
index 15b3071..0000000
Binary files a/textures/reptile_glow.tga and /dev/null differ
diff --git a/textures/reptile_pants.tga b/textures/reptile_pants.tga
deleted file mode 100644 (file)
index a7d8359..0000000
Binary files a/textures/reptile_pants.tga and /dev/null differ
diff --git a/textures/reptile_shirt.tga b/textures/reptile_shirt.tga
deleted file mode 100644 (file)
index 0e3023f..0000000
Binary files a/textures/reptile_shirt.tga and /dev/null differ
diff --git a/textures/umbra_glow.jpg b/textures/umbra_glow.jpg
deleted file mode 100644 (file)
index f18553a..0000000
Binary files a/textures/umbra_glow.jpg and /dev/null differ
diff --git a/textures/umbra_glow.tga b/textures/umbra_glow.tga
new file mode 100644 (file)
index 0000000..ee222f6
Binary files /dev/null and b/textures/umbra_glow.tga differ
diff --git a/textures/umbra_pants.tga b/textures/umbra_pants.tga
deleted file mode 100644 (file)
index 754f78a..0000000
Binary files a/textures/umbra_pants.tga and /dev/null differ
index d2fdc31f44dd1ec09408fc38397e8b9d6c78e3f3..8d04c364cc12551c79bb65cbf9d313e6150eeae1 100644 (file)
Binary files a/textures/umbra_shirt.tga and b/textures/umbra_shirt.tga differ