- wget -O data/maps/g-23.waypoints.cache https://gitlab.com/xonotic/xonotic-maps.pk3dir/raw/master/maps/g-23.waypoints.cache
- wget -O data/maps/g-23.waypoints.hardwired https://gitlab.com/xonotic/xonotic-maps.pk3dir/raw/master/maps/g-23.waypoints.hardwired
- make
- - EXPECT=cc5f9dd607764a67822f4db73fd53dc0
+ - EXPECT=f17c2b4e7a8619ff77983de267669802
- HASH=$(${ENGINE} -noconfig -nohome +exec serverbench.cfg
| tee /dev/stderr
| grep '^:'
seta hud_panel_engineinfo_framecounter_exponentialmovingaverage_instantupdate_change_threshold 0.5 "threshold for fps change when to update instantly, to make big fps changes update faster"
seta hud_panel_physics_acceleration_movingaverage 1 "use an averaging method for calculating acceleration instead of the real value"
-seta hud_panel_phisics_update_interval 0.0666 "how often (in seconds) numeric values get updated on screen"
+seta hud_panel_physics_update_interval 0.0666 "how often (in seconds) numeric values get updated on screen"
seta hud_panel_physics_speed_unit "1" "speed unit (1 = qu/s, 2 = m/s, 3 = km/h, 4 = mph, 5 = knots)"
seta hud_panel_itemstime_progressbar_maxtime "30" "when left time is at least this amount, the status bar is full"
set g_balance_machinegun_sustained_spread 0.03
set g_balance_machinegun_switchdelay_drop 0.2
set g_balance_machinegun_switchdelay_raise 0.2
-set g_balance_machinegun_weaponreplace "arc"
+set g_balance_machinegun_weaponreplace ""
set g_balance_machinegun_weaponstart 0
set g_balance_machinegun_weaponstartoverride -1
set g_balance_machinegun_weaponthrowable 1
set g_balance_crylink_secondary_animtime 0.2
set g_balance_crylink_secondary_bouncedamagefactor 0.5
set g_balance_crylink_secondary_bounces 0
-set g_balance_crylink_secondary_damage 35
+set g_balance_crylink_secondary_damage 10
set g_balance_crylink_secondary_edgedamage 5
-set g_balance_crylink_secondary_force -300
+set g_balance_crylink_secondary_force -250
set g_balance_crylink_secondary_joindelay 0
set g_balance_crylink_secondary_joinexplode 0
set g_balance_crylink_secondary_joinexplode_damage 0
set g_balance_crylink_secondary_other_lifetime 5
set g_balance_crylink_secondary_radius 100
set g_balance_crylink_secondary_refire 0.7
-set g_balance_crylink_secondary_shots 1
+set g_balance_crylink_secondary_shots 5
set g_balance_crylink_secondary_speed 3000
set g_balance_crylink_secondary_spread 0.01
set g_balance_crylink_secondary_spreadtype 1
set g_balance_devastator_reload_time 2
set g_balance_devastator_remote_damage 70
set g_balance_devastator_remote_edgedamage 35
-set g_balance_devastator_remote_force 450
+set g_balance_devastator_remote_force 300
set g_balance_devastator_remote_jump_damage 70
-set g_balance_devastator_remote_jump_radius 0
-set g_balance_devastator_remote_jump_velocity_z_add 400
+set g_balance_devastator_remote_jump_force 450
+set g_balance_devastator_remote_jump_radius 100
+set g_balance_devastator_remote_jump_velocity_z_add 0
set g_balance_devastator_remote_jump_velocity_z_max 1500
set g_balance_devastator_remote_jump_velocity_z_min 400
set g_balance_devastator_remote_radius 110
set g_balance_devastator_remote_edgedamage 40
set g_balance_devastator_remote_force 600
set g_balance_devastator_remote_jump_damage 70
+set g_balance_devastator_remote_jump_force 0
set g_balance_devastator_remote_jump_radius 0
set g_balance_devastator_remote_jump_velocity_z_add 400
set g_balance_devastator_remote_jump_velocity_z_max 1500
set g_balance_machinegun_solidpenetration 13.1
set g_balance_machinegun_spread_add 0.012
set g_balance_machinegun_spread_max 0.05
-set g_balance_machinegun_spread_min 0.02
+set g_balance_machinegun_spread_min 0
set g_balance_machinegun_sustained_ammo 1
set g_balance_machinegun_sustained_damage 25
set g_balance_machinegun_sustained_force 5
set g_balance_vortex_charge_start 0.5
set g_balance_vortex_charge_velocity_rate 0
set g_balance_vortex_primary_ammo 10
-set g_balance_vortex_primary_animtime 0.95
+set g_balance_vortex_primary_animtime 0.65
set g_balance_vortex_primary_damage 100
set g_balance_vortex_primary_damagefalloff_forcehalflife 0
set g_balance_vortex_primary_damagefalloff_halflife 0
set g_balance_vortex_secondary_damagefalloff_mindist 0
set g_balance_vortex_secondary_force 0
set g_balance_vortex_secondary_refire 0
-set g_balance_vortex_switchdelay_drop 0.25
-set g_balance_vortex_switchdelay_raise 0.25
+set g_balance_vortex_switchdelay_drop 0.2
+set g_balance_vortex_switchdelay_raise 0.2
set g_balance_vortex_weaponreplace ""
set g_balance_vortex_weaponstart 0
set g_balance_vortex_weaponstartoverride -1
set g_balance_devastator_remote_edgedamage 35
set g_balance_devastator_remote_force 300
set g_balance_devastator_remote_jump_damage 70
+set g_balance_devastator_remote_jump_force 0
set g_balance_devastator_remote_jump_radius 0
set g_balance_devastator_remote_jump_velocity_z_add 400
set g_balance_devastator_remote_jump_velocity_z_max 1500
// }}}
// {{{ #21: Heavy Machine Gun
set g_balance_hmg_ammo 1
-set g_balance_hmg_damage 10
-set g_balance_hmg_force 5
+set g_balance_hmg_damage 30
+set g_balance_hmg_force 10
set g_balance_hmg_refire 0.05
set g_balance_hmg_reload_ammo 120
set g_balance_hmg_reload_time 1
set g_balance_hmg_solidpenetration 32
-set g_balance_hmg_spread_add 0.01
-set g_balance_hmg_spread_max 0.05
-set g_balance_hmg_spread_min 0.02
+set g_balance_hmg_spread_add 0.005
+set g_balance_hmg_spread_max 0.06
+set g_balance_hmg_spread_min 0.01
set g_balance_hmg_switchdelay_drop 0.2
set g_balance_hmg_switchdelay_raise 0.2
set g_balance_hmg_weaponreplace ""
set g_balance_devastator_remote_edgedamage 35
set g_balance_devastator_remote_force 400
set g_balance_devastator_remote_jump_damage 40
+set g_balance_devastator_remote_jump_force 0
set g_balance_devastator_remote_jump_radius 200
set g_balance_devastator_remote_jump_velocity_z_add 500
set g_balance_devastator_remote_jump_velocity_z_max 1500
set g_balance_devastator_remote_edgedamage 35
set g_balance_devastator_remote_force 350
set g_balance_devastator_remote_jump_damage 70
+set g_balance_devastator_remote_jump_force 0
set g_balance_devastator_remote_jump_radius 0
set g_balance_devastator_remote_jump_velocity_z_add 400
set g_balance_devastator_remote_jump_velocity_z_max 1500
set g_balance_electro_primary_lifetime 5
set g_balance_electro_primary_midaircombo_explode 1
set g_balance_electro_primary_midaircombo_interval 0.1
-set g_balance_electro_primary_midaircombo_radius 150
+set g_balance_electro_primary_midaircombo_radius 0
set g_balance_electro_primary_radius 100
set g_balance_electro_primary_refire 0.6
set g_balance_electro_primary_speed 2500
set g_balance_electro_secondary_speed 1000
set g_balance_electro_secondary_speed_up 200
set g_balance_electro_secondary_speed_z 0
-set g_balance_electro_secondary_spread 0.04
+set g_balance_electro_secondary_spread 0
set g_balance_electro_secondary_stick 0
set g_balance_electro_secondary_touchexplode 1
set g_balance_electro_switchdelay_drop 0.2
set g_balance_vortex_secondary_damagefalloff_mindist 0
set g_balance_vortex_secondary_force 0
set g_balance_vortex_secondary_refire 0
-set g_balance_vortex_switchdelay_drop 0.25
-set g_balance_vortex_switchdelay_raise 0.25
+set g_balance_vortex_switchdelay_drop 0.2
+set g_balance_vortex_switchdelay_raise 0.2
set g_balance_vortex_weaponreplace ""
set g_balance_vortex_weaponstart 0
set g_balance_vortex_weaponstartoverride -1
set g_balance_hagar_primary_radius 65
set g_balance_hagar_primary_refire 0.16667
set g_balance_hagar_primary_speed 2200
-set g_balance_hagar_primary_spread 0.03
+set g_balance_hagar_primary_spread 0
set g_balance_hagar_reload_ammo 0
set g_balance_hagar_reload_time 2
set g_balance_hagar_secondary 1
set g_balance_hagar_secondary_radius 80
set g_balance_hagar_secondary_refire 0.5
set g_balance_hagar_secondary_speed 2000
-set g_balance_hagar_secondary_spread 0.05
+set g_balance_hagar_secondary_spread 0
set g_balance_hagar_switchdelay_drop 0.2
set g_balance_hagar_switchdelay_raise 0.2
set g_balance_hagar_weaponreplace ""
set g_balance_devastator_remote_edgedamage 35
set g_balance_devastator_remote_force 300
set g_balance_devastator_remote_jump_damage 70
+set g_balance_devastator_remote_jump_force 450
set g_balance_devastator_remote_jump_radius 0
-set g_balance_devastator_remote_jump_velocity_z_add 400
+set g_balance_devastator_remote_jump_velocity_z_add 0
set g_balance_devastator_remote_jump_velocity_z_max 1500
set g_balance_devastator_remote_jump_velocity_z_min 400
set g_balance_devastator_remote_radius 110
// }}}
// {{{ #19: Shockwave (MUTATOR WEAPON)
set g_balance_shockwave_blast_animtime 0.3
-set g_balance_shockwave_blast_damage 20
+set g_balance_shockwave_blast_damage 40
set g_balance_shockwave_blast_distance 1000
set g_balance_shockwave_blast_edgedamage 0
-set g_balance_shockwave_blast_force 200
+set g_balance_shockwave_blast_force 15
set g_balance_shockwave_blast_force_forwardbias 50
-set g_balance_shockwave_blast_force_zscale 2
+set g_balance_shockwave_blast_force_zscale 1
set g_balance_shockwave_blast_jump_damage 20
set g_balance_shockwave_blast_jump_edgedamage 0
-set g_balance_shockwave_blast_jump_force 300
-set g_balance_shockwave_blast_jump_force_velocitybias 0
-set g_balance_shockwave_blast_jump_force_zscale 1.25
+set g_balance_shockwave_blast_jump_force 100
+set g_balance_shockwave_blast_jump_force_velocitybias 1
+set g_balance_shockwave_blast_jump_force_zscale 1
set g_balance_shockwave_blast_jump_multiplier_accuracy 0.5
set g_balance_shockwave_blast_jump_multiplier_distance 0.5
set g_balance_shockwave_blast_jump_multiplier_min 0
set g_balance_shockwave_blast_jump_radius 150
-set g_balance_shockwave_blast_multiplier_accuracy 0.5
-set g_balance_shockwave_blast_multiplier_distance 0.5
+set g_balance_shockwave_blast_multiplier_accuracy 0.45
+set g_balance_shockwave_blast_multiplier_distance 0.2
set g_balance_shockwave_blast_multiplier_min 0
set g_balance_shockwave_blast_refire 0.75
set g_balance_shockwave_blast_splash_damage 15
// }}}
// {{{ #20: Arc
set g_balance_arc_beam_ammo 6
-set g_balance_arc_beam_animtime 0.2
+set g_balance_arc_beam_animtime 0.1
set g_balance_arc_beam_botaimlifetime 0
set g_balance_arc_beam_botaimspeed 0
-set g_balance_arc_beam_damage 115
+set g_balance_arc_beam_damage 100
set g_balance_arc_beam_degreespersegment 1
set g_balance_arc_beam_distancepersegment 0
set g_balance_arc_beam_falloff_halflifedist 0
set g_balance_arc_beam_falloff_maxdist 0
set g_balance_arc_beam_falloff_mindist 0
-set g_balance_arc_beam_force 900
+set g_balance_arc_beam_force 600
set g_balance_arc_beam_healing_amax 0
set g_balance_arc_beam_healing_aps 50
set g_balance_arc_beam_healing_hmax 150
set g_balance_arc_cooldown_release 0
set g_balance_arc_overheat_max 5
set g_balance_arc_overheat_min 3
-set g_balance_arc_beam_heat 0.75
-set g_balance_arc_burst_heat 4
+set g_balance_arc_beam_heat 0
+set g_balance_arc_burst_heat 5
set g_balance_arc_beam_maxangle 10
set g_balance_arc_beam_nonplayerdamage 80
set g_balance_arc_beam_range 1000
set g_balance_arc_bolt_lifetime 5
set g_balance_arc_bolt_radius 65
set g_balance_arc_bolt_refire 0.16667
-set g_balance_arc_bolt_speed 2200
+set g_balance_arc_bolt_speed 2300
set g_balance_arc_bolt_spread 0
set g_balance_arc_burst_ammo 15
set g_balance_arc_burst_damage 250
set g_balance_electro_primary_lifetime 5
set g_balance_electro_primary_midaircombo_explode 1
set g_balance_electro_primary_midaircombo_interval 0.1
-set g_balance_electro_primary_midaircombo_radius 150
+set g_balance_electro_primary_midaircombo_radius 0
set g_balance_electro_primary_radius 100
set g_balance_electro_primary_refire 0.6
set g_balance_electro_primary_speed 2500
set g_balance_electro_secondary_speed 1000
set g_balance_electro_secondary_speed_up 200
set g_balance_electro_secondary_speed_z 0
-set g_balance_electro_secondary_spread 0.04
+set g_balance_electro_secondary_spread 0
set g_balance_electro_secondary_stick 0
set g_balance_electro_secondary_touchexplode 1
set g_balance_electro_switchdelay_drop 0.2
set g_balance_vortex_secondary_damagefalloff_mindist 0
set g_balance_vortex_secondary_force 0
set g_balance_vortex_secondary_refire 0
-set g_balance_vortex_switchdelay_drop 0.25
-set g_balance_vortex_switchdelay_raise 0.25
+set g_balance_vortex_switchdelay_drop 0.2
+set g_balance_vortex_switchdelay_raise 0.2
set g_balance_vortex_weaponreplace ""
set g_balance_vortex_weaponstart 0
set g_balance_vortex_weaponstartoverride -1
set g_balance_hagar_primary_radius 65
set g_balance_hagar_primary_refire 0.16667
set g_balance_hagar_primary_speed 2200
-set g_balance_hagar_primary_spread 0.03
+set g_balance_hagar_primary_spread 0
set g_balance_hagar_reload_ammo 0
set g_balance_hagar_reload_time 2
set g_balance_hagar_secondary 1
set g_balance_hagar_secondary_radius 80
set g_balance_hagar_secondary_refire 0.5
set g_balance_hagar_secondary_speed 2000
-set g_balance_hagar_secondary_spread 0.05
+set g_balance_hagar_secondary_spread 0
set g_balance_hagar_switchdelay_drop 0.2
set g_balance_hagar_switchdelay_raise 0.2
set g_balance_hagar_weaponreplace ""
set g_balance_devastator_remote_edgedamage 35
set g_balance_devastator_remote_force 300
set g_balance_devastator_remote_jump_damage 70
+set g_balance_devastator_remote_jump_force 450
set g_balance_devastator_remote_jump_radius 0
-set g_balance_devastator_remote_jump_velocity_z_add 400
+set g_balance_devastator_remote_jump_velocity_z_add 0
set g_balance_devastator_remote_jump_velocity_z_max 1500
set g_balance_devastator_remote_jump_velocity_z_min 400
set g_balance_devastator_remote_radius 110
// }}}
// {{{ #19: Shockwave (MUTATOR WEAPON)
set g_balance_shockwave_blast_animtime 0.3
-set g_balance_shockwave_blast_damage 20
+set g_balance_shockwave_blast_damage 40
set g_balance_shockwave_blast_distance 1000
set g_balance_shockwave_blast_edgedamage 0
-set g_balance_shockwave_blast_force 200
+set g_balance_shockwave_blast_force 15
set g_balance_shockwave_blast_force_forwardbias 50
-set g_balance_shockwave_blast_force_zscale 2
+set g_balance_shockwave_blast_force_zscale 1
set g_balance_shockwave_blast_jump_damage 20
set g_balance_shockwave_blast_jump_edgedamage 0
-set g_balance_shockwave_blast_jump_force 300
-set g_balance_shockwave_blast_jump_force_velocitybias 0
-set g_balance_shockwave_blast_jump_force_zscale 1.25
+set g_balance_shockwave_blast_jump_force 100
+set g_balance_shockwave_blast_jump_force_velocitybias 1
+set g_balance_shockwave_blast_jump_force_zscale 1
set g_balance_shockwave_blast_jump_multiplier_accuracy 0.5
set g_balance_shockwave_blast_jump_multiplier_distance 0.5
set g_balance_shockwave_blast_jump_multiplier_min 0
set g_balance_shockwave_blast_jump_radius 150
-set g_balance_shockwave_blast_multiplier_accuracy 0.5
-set g_balance_shockwave_blast_multiplier_distance 0.5
+set g_balance_shockwave_blast_multiplier_accuracy 0.45
+set g_balance_shockwave_blast_multiplier_distance 0.2
set g_balance_shockwave_blast_multiplier_min 0
set g_balance_shockwave_blast_refire 0.75
set g_balance_shockwave_blast_splash_damage 15
// }}}
// {{{ #20: Arc
set g_balance_arc_beam_ammo 6
-set g_balance_arc_beam_animtime 0.2
+set g_balance_arc_beam_animtime 0.1
set g_balance_arc_beam_botaimlifetime 0
set g_balance_arc_beam_botaimspeed 0
-set g_balance_arc_beam_damage 115
+set g_balance_arc_beam_damage 100
set g_balance_arc_beam_degreespersegment 1
set g_balance_arc_beam_distancepersegment 0
set g_balance_arc_beam_falloff_halflifedist 0
set g_balance_arc_beam_falloff_maxdist 0
set g_balance_arc_beam_falloff_mindist 0
-set g_balance_arc_beam_force 900
+set g_balance_arc_beam_force 600
set g_balance_arc_beam_healing_amax 0
set g_balance_arc_beam_healing_aps 50
set g_balance_arc_beam_healing_hmax 150
set g_balance_arc_cooldown_release 0
set g_balance_arc_overheat_max 5
set g_balance_arc_overheat_min 3
-set g_balance_arc_beam_heat 0.75
-set g_balance_arc_burst_heat 4
+set g_balance_arc_beam_heat 0
+set g_balance_arc_burst_heat 5
set g_balance_arc_beam_maxangle 10
set g_balance_arc_beam_nonplayerdamage 80
set g_balance_arc_beam_range 1000
set g_balance_arc_bolt_lifetime 5
set g_balance_arc_bolt_radius 65
set g_balance_arc_bolt_refire 0.16667
-set g_balance_arc_bolt_speed 2200
+set g_balance_arc_bolt_speed 2300
set g_balance_arc_bolt_spread 0
set g_balance_arc_burst_ammo 15
set g_balance_arc_burst_damage 250
set g_pickup_fuel_max 100
set g_pickup_armorsmall 5
set g_pickup_armorsmall_max 20
-set g_pickup_armorsmall_anyway 0
+set g_pickup_armorsmall_anyway 1
set g_pickup_armormedium 25
-set g_pickup_armormedium_max 200
+set g_pickup_armormedium_max 100
set g_pickup_armormedium_anyway 1
set g_pickup_armorbig 50
-set g_pickup_armorbig_max 200
+set g_pickup_armorbig_max 100
set g_pickup_armorbig_anyway 1
set g_pickup_armorlarge 100
-set g_pickup_armorlarge_max 200
+set g_pickup_armorlarge_max 100
set g_pickup_armorlarge_anyway 1
set g_pickup_healthsmall 5
set g_pickup_healthsmall_max 200
set g_balance_armor_regenlinear 0
set g_balance_armor_rot 0
set g_balance_armor_rotlinear 1
-set g_balance_pause_armor_rot 1
+set g_balance_pause_armor_rot 5
set g_balance_pause_armor_rot_spawn 5
set g_balance_armor_regenstable 100
set g_balance_armor_rotstable 0
set g_balance_armor_limit 999
-set g_balance_armor_blockpercent 0.7
+set g_balance_armor_blockpercent 0.6
set g_balance_fuel_regen 0.1 "fuel regeneration (only applies if the player owns IT_FUEL_REGEN)"
set g_balance_fuel_regenlinear 0
set g_balance_pause_fuel_regen 2 // other than this, fuel uses the health regen counter
seta cl_unpress_zoom_on_spawn 1 "automatically unpress zoom when you spawn"
seta cl_unpress_zoom_on_death 1 "automatically unpress zoom when you die (and don't allow zoom again while dead)"
seta cl_unpress_zoom_on_weapon_switch 1 "automatically unpress zoom when you switch a weapon"
-seta cl_unpress_attack_on_weapon_switch 1 "automatically unpress fire and fire1 attack buttons when you switch a weapon"
+seta cl_unpress_attack_on_weapon_switch 0 "automatically unpress fire and fire1 attack buttons when you switch a weapon"
seta cl_spawn_event_particles 1 "pointparticles effect whenever a player spawns"
seta cl_spawn_event_sound 1 "sound effect whenever a player spawns"
//seta cl_spawn_point_model 0 "place a model at all spawn points" // still needs a model
seta cl_spawn_point_particles 1 "pointparticles effect at all spawn points" // managed by effects-.cfg files
+seta cl_spawn_point_dist_min 1200
+seta cl_spawn_point_dist_max 1600
freelook 1
sensitivity 6
set sv_friction_on_land 0
set sv_friction_slick 0.5
+set sv_slick_applygravity 0
+
+set sv_aircontrol_backwards 0 "apply forward aircontrol options to backward movement"
+
set sv_player_viewoffset "0 0 35" "view offset of the player model"
set sv_player_mins "-16 -16 -24" "playermodel mins"
set sv_player_maxs "16 16 45" "playermodel maxs"
seta sv_servermodelsonly 1
cl_curl_enabled 1
-cl_curl_maxspeed 500
+cl_curl_maxdownloads 3
+cl_curl_maxspeed 0
cl_curl_useragent 1
cl_curl_useragent_append "$g_xonoticversion"
set g_waypoints_for_items 0 "make waypoints out of items, values: 0 = never, 1 = unless the mapper prevents it by worldspawn.spawnflags & 1, 2 = always"
seta g_maplist_votable 6 "number of maps that are shown in the map voting at the end of a match"
-seta g_maplist_votable_keeptwotime 15
+seta g_maplist_votable_keeptwotime 15 "show only 2 options after this amount of time during map vote screen"
seta g_maplist_votable_timeout 30 "timeout for the map voting; must be below 50 seconds!"
seta g_maplist_votable_suggestions 2
seta g_maplist_votable_suggestions_override_mostrecent 0
seta g_maplist_votable_screenshot_dir "maps levelshots" "where to look for map screenshots"
set sv_vote_gametype 0 "show a vote screen for gametypes before map vote screen"
-set sv_vote_gametype_keeptwotime 10 "show only 2 options for this amount of time during gametype vote screen"
+set sv_vote_gametype_keeptwotime 10 "show only 2 options after this amount of time during gametype vote screen"
set sv_vote_gametype_options "dm ctf ca lms tdm ft"
set sv_vote_gametype_timeout 20
set sv_vote_gametype_default_current 1 "Keep the current gametype if no one votes"
seta menu_slist_categories_CAT_RECOMMENDED_override ""
seta menu_slist_categories_CAT_NORMAL_override ""
seta menu_slist_categories_CAT_SERVERS_override "CAT_NORMAL"
-seta menu_slist_categories_CAT_XPM_override "CAT_NORMAL"
+seta menu_slist_categories_CAT_XPM_override ""
seta menu_slist_categories_CAT_MODIFIED_override ""
seta menu_slist_categories_CAT_OVERKILL_override ""
seta menu_slist_categories_CAT_INSTAGIB_override ""
set sv_join_notices ""
set sv_join_notices_time 15
+seta cl_items_nofade 0
+seta cl_animate_items 1
seta cl_ghost_items 0.45 "enable ghosted items (when between 0 and 1, overrides the alpha value)"
seta cl_ghost_items_color "-1 -1 -1" "color of ghosted items, 0 0 0 leaves the color unchanged"
set sv_simple_items 1 "allow or forbid client use of simple items"
set g_ctf_flag_return 1 "auto return the flag to base when touched by a teammate"
set g_ctf_flag_return_carrying 0 "(manual return mode) auto return the flag to base if touched by a flag carrier"
set g_ctf_flag_return_carried_radius 100 "allow flags to be returned by carrier if base is within this radius"
-set g_ctf_flag_return_time 15
-set g_ctf_flag_return_dropped 100
-set g_ctf_flag_return_damage 0
+set g_ctf_flag_return_time 15 "automatically return the flag to base after this amount of time"
+set g_ctf_flag_return_dropped 100 "automatically return the flag to base if dropped within this distance from base (in qu)"
+set g_ctf_flag_return_damage 0 "allow the flag to be damaged, reducing time needed to automatically return to base"
+set g_ctf_flag_return_damage_delay 0 "how much time the flag takes to automatically return to base if it falls into lava/slime/trigger hurt"
set g_ctf_flag_return_when_unreachable 1 "automatically return the flag if it falls into lava/slime/trigger hurt"
set g_ctf_flagcarrier_auto_helpme_damage 100 "automatically place a helpme notification on flag carrier waypointsprite if they get hit and their health dips below this value"
set g_ctf_flagcarrier_auto_helpme_time 2 "antispam time for the helpme notification"
set g_nexball_basketball_trail 1 "1 to leave a trail"
set g_nexball_football_trail 0 "1 to leave a trail"
set g_nexball_trail_color 254 "1-256 for different colors (Quake palette, 254 is white)"
+set g_nexball_playerclip_collisions 1 "make the ball bounce off clips"
set g_nexball_radar_showallplayers 1 "1: show every player and the ball on the radar 0: only show teammates and the ball on the radar"
seta g_nexball_safepass_maxdist 5000 "Max distance to allow save fassping (0 to turn off safe passing)"
seta g_nexball_safepass_turnrate 0.1 "How fast the safe-pass ball can habge direction"
set sv_minigames_snake_delay_initial 0.7 "Initial delay between snake movement"
set sv_minigames_snake_delay_multiplier 50 "Multiplier of incremental of movement speed (player_score / cvar)"
set sv_minigames_snake_delay_min 0.1 "Minimum delay between snake movement (at fastest rate)"
+set sv_minigames_snake_lives 3
seta cl_dodging_timeout 0.2 "determines how long apart (in seconds) two taps on the same direction key are considered a dodge. use 0 to disable"
-set sv_dodging_wall_dodging 0 "set to 1 to allow dodging off walls. 0 to disable"
+set sv_dodging_air_dodging 0
+set sv_dodging_wall_dodging 0 "allow dodging off walls"
set sv_dodging_delay 0.7 "determines how long a player has to wait to be able to dodge again after dodging"
set sv_dodging_up_speed 200 "the jump velocity of the dodge"
set sv_dodging_horiz_speed 400 "the horizontal velocity of the dodge"
set sv_dodging_wall_distance_threshold 10 "the maximum distance from a wall that still allows dodging"
set sv_dodging_sound 1 "if 1 dodging makes a sound. if 0 dodging is silent"
set sv_dodging_frozen 0 "allow dodging while frozen"
+set sv_dodging_frozen_doubletap 0
// ===========
set g_instagib_extralives 1 "how many extra lives you will get per powerup"
set g_instagib_ammo_start 10 "starting ammo"
set g_instagib_ammo_drop 5 "how much ammo you'll get for weapons or cells"
+set g_instagib_ammo_convert_bullets 0 "convert bullet ammo packs to insta cell ammo packs"
+set g_instagib_ammo_convert_cells 0 "convert normal cell ammo packs to insta cell ammo packs"
+set g_instagib_ammo_convert_rockets 0 "convert rocket ammo packs to insta cell ammo packs"
+set g_instagib_ammo_convert_shells 0 "convert shell ammo packs to insta cell ammo packs"
set g_instagib_invis_alpha 0.15
set g_instagib_speed_highspeed 1.5 "speed-multiplier that applies while you carry the invincibility powerup"
set g_instagib_damagedbycontents 1 "allow damage from lava pits in instagib"
// ==========
set g_overkill 0 "enable overkill"
-set g_overkill_100a_anyway 1
-set g_overkill_100h_anyway 1
set g_overkill_powerups_replace 1
-set g_overkill_superguns_respawn_time 120
+set g_overkill_filter_healthmega 0
+set g_overkill_filter_armormedium 0
+set g_overkill_filter_armorbig 0
+set g_overkill_filter_armorlarge 0
set g_overkill_ammo_charge 0
set g_overkill_ammo_charge_notice 1
set g_nades_client_select 0 "allow client side selection of nade type"
set g_nades_pickup 0 "allow picking up thrown nades (not your own)"
set g_nades_pickup_time 2 "time until picked up nade explodes"
+set g_nades_override_dropweapon 1
set g_nades_nade_lifetime 3.5
set g_nades_nade_minforce 400
set g_nades_nade_maxforce 2000
set g_buffs_random_lifetime 30 "re-spawn the buff again if it hasn't been touched after this time in seconds"
set g_buffs_random_location 0 "randomize buff location on start and when reset"
set g_buffs_random_location_attempts 10 "number of random locations a single buff will attempt to respawn at before giving up"
-set g_buffs_spawn_count 5 "how many buffs to spawn on the map if none exist already"
+set g_buffs_spawn_count 0 "how many buffs to spawn on the map if none exist already"
set g_buffs_replace_powerups 1 "replace powerups on the map with random buffs"
set g_buffs_cooldown_activate 5 "cooldown period when buff is first activated"
set g_buffs_cooldown_respawn 3 "cooldown period when buff is reloading"
seta notification_ANNCE_VOTE_CALL "2" "0 = disabled, 1 = enabled if gentle mode is off, 2 = always enabled"
seta notification_ANNCE_VOTE_FAIL "2" "0 = disabled, 1 = enabled if gentle mode is off, 2 = always enabled"
-// MSG_INFO notifications (count = 316):
+// MSG_INFO notifications (count = 320):
seta notification_INFO_CA_JOIN_LATE "1" "0 = off, 1 = print to console, 2 = print to console and chatbox (if notification_allow_chatboxprint is enabled)"
seta notification_INFO_CA_LEAVE "1" "0 = off, 1 = print to console, 2 = print to console and chatbox (if notification_allow_chatboxprint is enabled)"
seta notification_INFO_CHAT_NOSPECTATORS "2" "0 = off, 1 = print to console, 2 = print to console and chatbox (if notification_allow_chatboxprint is enabled)"
seta notification_INFO_LMS_NOLIVES "1" "0 = off, 1 = print to console, 2 = print to console and chatbox (if notification_allow_chatboxprint is enabled)"
seta notification_INFO_MINIGAME_INVITE "1" "0 = off, 1 = print to console, 2 = print to console and chatbox (if notification_allow_chatboxprint is enabled)"
seta notification_INFO_MONSTERS_DISABLED "1" "0 = off, 1 = print to console, 2 = print to console and chatbox (if notification_allow_chatboxprint is enabled)"
+seta notification_INFO_NEXBALL_RETURN_HELD_BLUE "1" "0 = off, 1 = print to console, 2 = print to console and chatbox (if notification_allow_chatboxprint is enabled)"
+seta notification_INFO_NEXBALL_RETURN_HELD_PINK "1" "0 = off, 1 = print to console, 2 = print to console and chatbox (if notification_allow_chatboxprint is enabled)"
+seta notification_INFO_NEXBALL_RETURN_HELD_RED "1" "0 = off, 1 = print to console, 2 = print to console and chatbox (if notification_allow_chatboxprint is enabled)"
+seta notification_INFO_NEXBALL_RETURN_HELD_YELLOW "1" "0 = off, 1 = print to console, 2 = print to console and chatbox (if notification_allow_chatboxprint is enabled)"
seta notification_INFO_ONSLAUGHT_CAPTURE "1" "0 = off, 1 = print to console, 2 = print to console and chatbox (if notification_allow_chatboxprint is enabled)"
seta notification_INFO_ONSLAUGHT_CPDESTROYED_BLUE "1" "0 = off, 1 = print to console, 2 = print to console and chatbox (if notification_allow_chatboxprint is enabled)"
seta notification_INFO_ONSLAUGHT_CPDESTROYED_PINK "1" "0 = off, 1 = print to console, 2 = print to console and chatbox (if notification_allow_chatboxprint is enabled)"
seta notification_show_sprees_info_newline "1" "Show attacker spree information for MSG_INFO messages on a separate line than the death notification itself"
seta notification_show_sprees_info_specialonly "1" "Don't show attacker spree information in MSG_INFO messages if it isn't an achievement"
-// Notification counts (total = 817): MSG_ANNCE = 89, MSG_INFO = 316, MSG_CENTER = 231, MSG_MULTI = 153, MSG_CHOICE = 28
+// Notification counts (total = 820): MSG_ANNCE = 89, MSG_INFO = 320, MSG_CENTER = 230, MSG_MULTI = 153, MSG_CHOICE = 28
set g_physics_xonotic_airaccel_sideways_friction 0
set g_physics_xonotic_aircontrol 100
set g_physics_xonotic_aircontrol_power 2
+set g_physics_xonotic_aircontrol_backwards 0
set g_physics_xonotic_aircontrol_penalty 0
set g_physics_xonotic_warsowbunny_airforwardaccel 1.00001
set g_physics_xonotic_warsowbunny_topspeed 925
set g_physics_nexuiz_airaccel_sideways_friction 0.35
set g_physics_nexuiz_aircontrol 0
set g_physics_nexuiz_aircontrol_power 2
+set g_physics_nexuiz_aircontrol_backwards 0
set g_physics_nexuiz_aircontrol_penalty 0
set g_physics_nexuiz_warsowbunny_airforwardaccel 1.00001
set g_physics_nexuiz_warsowbunny_topspeed 925
set g_physics_quake_airaccel_sideways_friction 0
set g_physics_quake_aircontrol 0
set g_physics_quake_aircontrol_power 2
+set g_physics_quake_aircontrol_backwards 0
set g_physics_quake_aircontrol_penalty 0
set g_physics_quake_warsowbunny_airforwardaccel 1.00001
set g_physics_quake_warsowbunny_topspeed 925
set g_physics_warsow_airaccel_sideways_friction 0
set g_physics_warsow_aircontrol 0
set g_physics_warsow_aircontrol_power 2
+set g_physics_warsow_aircontrol_backwards 0
set g_physics_warsow_aircontrol_penalty 0
set g_physics_warsow_warsowbunny_airforwardaccel 1.00001
set g_physics_warsow_warsowbunny_topspeed 925
set g_physics_defrag_airaccel_sideways_friction 0
set g_physics_defrag_aircontrol 150
set g_physics_defrag_aircontrol_power 2
+set g_physics_defrag_aircontrol_backwards 0
set g_physics_defrag_aircontrol_penalty 0
set g_physics_defrag_warsowbunny_airforwardaccel 1.00001
set g_physics_defrag_warsowbunny_topspeed 925
set g_physics_quake3_airaccel_sideways_friction 0
set g_physics_quake3_aircontrol 0
set g_physics_quake3_aircontrol_power 2
+set g_physics_quake3_aircontrol_backwards 0
set g_physics_quake3_aircontrol_penalty 0
set g_physics_quake3_warsowbunny_airforwardaccel 1.00001
set g_physics_quake3_warsowbunny_topspeed 925
set g_physics_vecxis_airaccel_sideways_friction 0.3
set g_physics_vecxis_aircontrol 0
set g_physics_vecxis_aircontrol_power 2
+set g_physics_vecxis_aircontrol_backwards 0
set g_physics_vecxis_aircontrol_penalty 0
set g_physics_vecxis_warsowbunny_airforwardaccel 1.00001
set g_physics_vecxis_warsowbunny_topspeed 925
set g_physics_quake2_airaccel_sideways_friction 0
set g_physics_quake2_aircontrol 0
set g_physics_quake2_aircontrol_power 2
+set g_physics_quake2_aircontrol_backwards 0
set g_physics_quake2_aircontrol_penalty 0
set g_physics_quake2_warsowbunny_airforwardaccel 1.00001
set g_physics_quake2_warsowbunny_topspeed 925
set g_physics_bones_airaccel_sideways_friction 0
set g_physics_bones_aircontrol 150
set g_physics_bones_aircontrol_power 2
+set g_physics_bones_aircontrol_backwards 0
set g_physics_bones_aircontrol_penalty 0
set g_physics_bones_warsowbunny_airforwardaccel 1.00001
set g_physics_bones_warsowbunny_topspeed 925
sv_aircontrol 150
sv_aircontrol_penalty 0
sv_aircontrol_power 2
+sv_aircontrol_backwards 0
sv_airspeedlimit_nonqw 0
sv_warsowbunny_turnaccel 0
sv_warsowbunny_accel 0.1593
sv_airstrafeaccel_qw -0.97
sv_aircontrol 125
sv_aircontrol_power 2.5
+sv_aircontrol_backwards 0
sv_airspeedlimit_nonqw 0
sv_warsowbunny_turnaccel 0
sv_warsowbunny_accel 0.1593
sv_aircontrol 0
sv_aircontrol_penalty 0
sv_aircontrol_power 2
+sv_aircontrol_backwards 0
sv_airspeedlimit_nonqw 0
sv_warsowbunny_turnaccel 0
sv_warsowbunny_accel 0.1593
sv_aircontrol 125
sv_aircontrol_penalty 150
sv_aircontrol_power 2.5
+sv_aircontrol_backwards 0
sv_airspeedlimit_nonqw 800
sv_warsowbunny_turnaccel 0
sv_warsowbunny_accel 0.1593
sv_aircontrol 125
sv_aircontrol_penalty 150
sv_aircontrol_power 2
+sv_aircontrol_backwards 0
sv_airspeedlimit_nonqw 800
sv_warsowbunny_turnaccel 0
sv_warsowbunny_accel 0.1593
sv_aircontrol 0
sv_aircontrol_penalty 0
sv_aircontrol_power 2
+sv_aircontrol_backwards 0
sv_airspeedlimit_nonqw 0
sv_warsowbunny_turnaccel 0
sv_warsowbunny_accel 0.1593
sv_aircontrol 0
sv_aircontrol_penalty 0
sv_aircontrol_power 2
+sv_aircontrol_backwards 0
sv_airspeedlimit_nonqw 0
sv_warsowbunny_turnaccel 0
sv_warsowbunny_accel 0.1593
sv_aircontrol 0
sv_aircontrol_penalty 0
sv_aircontrol_power 2
+sv_aircontrol_backwards 0
sv_airspeedlimit_nonqw 0
sv_warsowbunny_turnaccel 0
sv_warsowbunny_accel 0.1593
sv_aircontrol 0
sv_aircontrol_penalty 0
sv_aircontrol_power 2
+sv_aircontrol_backwards 0
sv_airspeedlimit_nonqw 0
sv_warsowbunny_turnaccel 0
sv_warsowbunny_accel 0.1593
sv_aircontrol 0
sv_aircontrol_penalty 0
sv_aircontrol_power 2
+sv_aircontrol_backwards 0
sv_airspeedlimit_nonqw 0
sv_warsowbunny_turnaccel 0
sv_warsowbunny_accel 0.1593
sv_aircontrol 0
sv_aircontrol_penalty 0
sv_aircontrol_power 2
+sv_aircontrol_backwards 0
sv_airspeedlimit_nonqw 0
sv_warsowbunny_turnaccel 0
sv_warsowbunny_accel 0.1593
sv_aircontrol 0
sv_aircontrol_penalty 0
sv_aircontrol_power 2
+sv_aircontrol_backwards 0
sv_airspeedlimit_nonqw 0
sv_warsowbunny_turnaccel 0
sv_warsowbunny_accel 0.1593
sv_aircontrol 0
sv_aircontrol_penalty 0
sv_aircontrol_power 2
+sv_aircontrol_backwards 0
sv_airspeedlimit_nonqw 0
sv_warsowbunny_turnaccel 0
sv_warsowbunny_accel 0.1593
sv_aircontrol 0
sv_aircontrol_penalty 0
sv_aircontrol_power 2
+sv_aircontrol_backwards 0
sv_airspeedlimit_nonqw 0
sv_warsowbunny_turnaccel 0
sv_warsowbunny_accel 0.1593
sv_aircontrol 0
sv_aircontrol_penalty 0
sv_aircontrol_power 2
+sv_aircontrol_backwards 0
sv_airspeedlimit_nonqw 0
sv_warsowbunny_turnaccel 0
sv_warsowbunny_accel 0.1593
sv_aircontrol 125
sv_aircontrol_penalty 100
sv_aircontrol_power 2
+sv_aircontrol_backwards 0
sv_airspeedlimit_nonqw 0
sv_warsowbunny_turnaccel 0
sv_warsowbunny_accel 0.1593
sv_aircontrol 0
sv_aircontrol_penalty 0
sv_aircontrol_power 2
+sv_aircontrol_backwards 0
sv_airspeedlimit_nonqw 0
sv_warsowbunny_turnaccel 0
sv_warsowbunny_accel 0.1593
sv_aircontrol 0
sv_aircontrol_penalty 0
sv_aircontrol_power 2
+sv_aircontrol_backwards 0
sv_airspeedlimit_nonqw 0
sv_warsowbunny_turnaccel 0
sv_warsowbunny_accel 0.1593
sv_aircontrol 0
sv_aircontrol_penalty 0
sv_aircontrol_power 2
+sv_aircontrol_backwards 0
sv_airspeedlimit_nonqw 0
sv_warsowbunny_turnaccel 0
sv_warsowbunny_accel 0.1593
sv_aircontrol 0
sv_aircontrol_penalty 0
sv_aircontrol_power 2
+sv_aircontrol_backwards 0
sv_airspeedlimit_nonqw 0
sv_warsowbunny_turnaccel 0
sv_warsowbunny_accel 0.1593
sv_aircontrol 0
sv_aircontrol_penalty 0
sv_aircontrol_power 2
+sv_aircontrol_backwards 0
sv_airspeedlimit_nonqw 0
sv_warsowbunny_turnaccel 0
sv_warsowbunny_accel 0.1593
sv_aircontrol 0
sv_aircontrol_penalty 0
sv_aircontrol_power 2
+sv_aircontrol_backwards 0
sv_airspeedlimit_nonqw 0
sv_warsowbunny_turnaccel 0
sv_warsowbunny_accel 0.1593
sv_aircontrol 0
sv_aircontrol_penalty 0
sv_aircontrol_power 2
+sv_aircontrol_backwards 0
sv_airspeedlimit_nonqw 0
sv_warsowbunny_turnaccel 0
sv_warsowbunny_accel 0.1593
sv_aircontrol 0
sv_aircontrol_penalty 0
sv_aircontrol_power 2
+sv_aircontrol_backwards 0
sv_airspeedlimit_nonqw 0
sv_warsowbunny_turnaccel 9 // activates warsow movement mode
sv_warsowbunny_accel 0.1593
sv_aircontrol 150
sv_aircontrol_penalty 0
sv_aircontrol_power 2
+sv_aircontrol_backwards 0
sv_airspeedlimit_nonqw 0
sv_warsowbunny_turnaccel 0
sv_warsowbunny_accel 0.1593
sv_aircontrol 0
sv_aircontrol_penalty 0
sv_aircontrol_power 2
+sv_aircontrol_backwards 0
sv_airspeedlimit_nonqw 0
sv_warsowbunny_turnaccel 6 // activates warsow movement mode
sv_warsowbunny_accel 0.1585
sv_aircontrol 100
sv_aircontrol_penalty 0
sv_aircontrol_power 2
+sv_aircontrol_backwards 0
sv_airspeedlimit_nonqw 900
sv_warsowbunny_turnaccel 0
sv_warsowbunny_accel 0.1593
sv_aircontrol 125
sv_aircontrol_penalty 150
sv_aircontrol_power 2
+sv_aircontrol_backwards 0
sv_airspeedlimit_nonqw 800
sv_warsowbunny_turnaccel 0
sv_warsowbunny_accel 0.1593
sv_aircontrol 125
sv_aircontrol_penalty 180
sv_aircontrol_power 2
+sv_aircontrol_backwards 0
sv_airspeedlimit_nonqw 800
sv_warsowbunny_turnaccel 0
sv_warsowbunny_accel 0.1593
sv_aircontrol 150
sv_aircontrol_penalty 0
sv_aircontrol_power 2
+sv_aircontrol_backwards 0
sv_airspeedlimit_nonqw 0
sv_warsowbunny_turnaccel 0
sv_warsowbunny_accel 0.1593
sv_aircontrol 100
sv_aircontrol_penalty 100
sv_aircontrol_power 2.5
+sv_aircontrol_backwards 0
sv_airspeedlimit_nonqw 0
sv_warsowbunny_turnaccel 0
sv_warsowbunny_accel 0.1593
float autocvar_cl_zoomfactor;
float autocvar_cl_zoomsensitivity;
float autocvar_cl_zoomspeed;
-bool autocvar_cl_unpress_zoom_on_spawn = 1;
-bool autocvar_cl_unpress_zoom_on_death = 1;
-bool autocvar_cl_unpress_zoom_on_weapon_switch = 1;
-bool autocvar_cl_unpress_attack_on_weapon_switch = 1;
+bool autocvar_cl_unpress_zoom_on_spawn = true;
+bool autocvar_cl_unpress_zoom_on_death = true;
+bool autocvar_cl_unpress_zoom_on_weapon_switch = true;
+bool autocvar_cl_unpress_attack_on_weapon_switch = false;
bool autocvar_con_chat;
bool autocvar_con_chatrect;
float autocvar_con_chatsize;
float autocvar_crosshair_rpc_size = 1;
int autocvar_cl_nade_timer;
bool autocvar_r_drawviewmodel;
-bool autocvar_cl_items_nofade;
if(this.tag_entity && wasfreed(this.tag_entity))
this.tag_entity = NULL;
- viewloc_SetTags(this);
-
MUTATOR_CALLHOOK(TagIndex_Update, this);
if(this.tag_networkentity)
#include "centerprint.qh"
#include "scoreboard.qh"
+#include <common/notifications/all.qh>
// CenterPrint (#16)
else // Expiring soon, so fade it out.
a = (centerprint_expire_time[j] - time) / max(0.0001, autocvar_hud_panel_centerprint_fade_out);
+ if(centerprint_msgID[j] == CPID_TIMEIN)
+ a = 1;
+
// while counting down show it anyway in order to hold the current message position
if (a <= 0.5/255.0 && centerprint_countdown_num[j] == 0) // Guaranteed invisible - don't show.
continue;
bool Scoreboard_WouldDraw()
{
- if (QuickMenu_IsOpened())
+ if (MUTATOR_CALLHOOK(DrawScoreboard))
+ return false;
+ else if (QuickMenu_IsOpened())
return false;
else if (HUD_Radar_Clickable())
return false;
/** Return true to not draw crosshair */
MUTATOR_HOOKABLE(DrawCrosshair, EV_NO_ARGS);
+
+/** Return true to not draw scoreboard */
+MUTATOR_HOOKABLE(DrawScoreboard, EV_NO_ARGS);
this.movedir_z = ReadCoord();
this.lip = ReadByte() / 255.0;
}
- this.fade_start = ReadShort();
- this.fade_end = ReadShort();
- this.alpha_max = ReadShort();
- this.alpha_min = ReadShort();
- this.inactive = ReadShort();
+ this.fade_start = ReadByte();
+ this.fade_end = ReadByte();
+ this.alpha_max = ReadByte();
+ this.alpha_min = ReadByte();
+ this.inactive = ReadByte();
this.fade_vertical_offset = ReadShort();
BGMScript_InitEntity(this);
}
REGISTER_SP(RACE_LAPS);
REGISTER_SP(RACE_FASTEST);
-REGISTER_SP(CTS_TIME);
-REGISTER_SP(CTS_LAPS);
-REGISTER_SP(CTS_FASTEST);
+//REGISTER_SP(CTS_TIME);
+//REGISTER_SP(CTS_LAPS);
+//REGISTER_SP(CTS_FASTEST);
REGISTER_SP(ASSAULT_OBJECTIVES);
MACRO_END
// #define PROP(public, fld, set, sv, cl)
-#define ENTCS_NETPROPS(PROP) PROP(false, sv_entnum, ENTCS_SET_NORMAL, {}, {}) /* sentinel */ \
+#define ENTCS_NETPROPS(ent, PROP) PROP(false, sv_entnum, ENTCS_SET_NORMAL, {}, {}) /* sentinel */ \
PROP(false, origin, ENTCS_SET_NORMAL, \
- { WriteShort(chan, this.origin.x); WriteShort(chan, this.origin.y); \
- WriteShort(chan, this.origin.z); }, \
- { this.has_sv_origin = true; vector v; v.x = ReadShort(); v.y = ReadShort(); v.z = ReadShort(); setorigin(this, v); }) \
+ { WriteShort(chan, ent.origin.x); WriteShort(chan, ent.origin.y); \
+ WriteShort(chan, ent.origin.z); }, \
+ { ent.has_sv_origin = true; vector v; v.x = ReadShort(); v.y = ReadShort(); v.z = ReadShort(); setorigin(ent, v); }) \
\
PROP(false, angles_y, ENTCS_SET_NORMAL, \
- { WriteByte(chan, this.angles.y / 360 * 256); }, \
- { vector v = '0 0 0'; v.y = ReadByte() / 256 * 360; this.angles = v; }) \
+ { WriteByte(chan, ent.angles.y / 360 * 256); }, \
+ { vector v = '0 0 0'; v.y = ReadByte() / 256 * 360; ent.angles = v; }) \
\
PROP(false, health, ENTCS_SET_NORMAL, \
- { WriteByte(chan, bound(0, this.health / 10, 255)); /* FIXME: use a better scale? */ }, \
- { this.healthvalue = ReadByte() * 10; }) \
+ { WriteByte(chan, bound(0, ent.health / 10, 255)); /* FIXME: use a better scale? */ }, \
+ { ent.healthvalue = ReadByte() * 10; }) \
\
PROP(false, armorvalue, ENTCS_SET_NORMAL, \
- { WriteByte(chan, bound(0, this.armorvalue / 10, 255)); /* FIXME: use a better scale? */ }, \
- { this.armorvalue = ReadByte() * 10; }) \
+ { WriteByte(chan, bound(0, ent.armorvalue / 10, 255)); /* FIXME: use a better scale? */ }, \
+ { ent.armorvalue = ReadByte() * 10; }) \
\
PROP(true, netname, ENTCS_SET_MUTABLE_STRING, \
- { WriteString(chan, this.netname); }, \
- { if (this.netname) strunzone(this.netname); this.netname = strzone(ReadString()); }) \
+ { WriteString(chan, ent.netname); }, \
+ { if (ent.netname) strunzone(ent.netname); ent.netname = strzone(ReadString()); }) \
\
PROP(true, model, ENTCS_SET_NORMAL, \
- { WriteString(chan, this.model); }, \
- { if (this.model) strunzone(this.model); this.model = strzone(ReadString()); }) \
+ { WriteString(chan, ent.model); }, \
+ { if (ent.model) strunzone(ent.model); ent.model = strzone(ReadString()); }) \
\
PROP(true, skin, ENTCS_SET_NORMAL, \
- { WriteByte(chan, this.skin); }, \
- { this.skin = ReadByte(); }) \
+ { WriteByte(chan, ent.skin); }, \
+ { ent.skin = ReadByte(); }) \
\
PROP(true, clientcolors, ENTCS_SET_NORMAL, \
- { WriteByte(chan, this.clientcolors); }, \
- { this.colormap = ReadByte(); }) \
+ { WriteByte(chan, ent.clientcolors); }, \
+ { ent.colormap = ReadByte(); }) \
\
PROP(true, frags, ENTCS_SET_NORMAL, \
- { WriteShort(chan, this.frags); }, \
- { this.frags = ReadShort(); }) \
+ { WriteShort(chan, ent.frags); }, \
+ { ent.frags = ReadShort(); }) \
\
/**/
} \
i += 1; \
}
- ENTCS_NETPROPS(X);
+ ENTCS_NETPROPS(this, X);
#undef X
if (i >= BITS(16 - 1)) LOG_FATAL("Exceeded ENTCS_NETPROPS limit");
}
} \
i += 1; \
}
- ENTCS_NETPROPS(X);
+ ENTCS_NETPROPS(this, X);
#undef X
return true;
}
} \
i += 1; \
}
- ENTCS_NETPROPS(X);
+ ENTCS_NETPROPS(this, X);
#undef X
setorigin(this, this.origin); // relink
}
} \
i += 1; \
}
- ENTCS_NETPROPS(X);
+ ENTCS_NETPROPS(e, X);
#undef X
e.iflags |= IFLAG_ORIGIN;
InterpolateOrigin_Note(e);
bool autocvar_g_nexball_radar_showallplayers;
bool autocvar_g_nexball_sound_bounce;
int autocvar_g_nexball_trail_color;
+bool autocvar_g_nexball_playerclip_collisions = true;
float autocvar_g_nexball_safepass_turnrate;
float autocvar_g_nexball_safepass_maxdist;
{
if(this.ballcarried.teamtime && (this.ballcarried.teamtime < time))
{
- bprint("The ", Team_ColoredFullName(this.team), " held the ball for too long.\n");
- DropBall(this.ballcarried, this.ballcarried.owner.origin, '0 0 0');
+ Send_Notification(NOTIF_ALL, NULL, MSG_INFO, APP_TEAM_NUM(this.team, INFO_NEXBALL_RETURN_HELD));
entity e = this.ballcarried;
+ DropBall(this.ballcarried, this.ballcarried.owner.origin, '0 0 0');
ResetBall(e);
}
else
if(this.cnt < 2) // step 1
{
if(time == this.teamtime)
- bprint("The ", Team_ColoredFullName(this.team), " held the ball for too long.\n");
+ Send_Notification(NOTIF_ALL, NULL, MSG_INFO, APP_TEAM_NUM(this.team, INFO_NEXBALL_RETURN_HELD));
settouch(this, func_null);
set_movetype(this, MOVETYPE_NOCLIP);
set_movetype(this, MOVETYPE_FLY);
+ if(autocvar_g_nexball_playerclip_collisions)
+ {
+ this.dphitcontentsmask = DPCONTENTS_BODY | DPCONTENTS_SOLID | DPCONTENTS_PLAYERCLIP;
+ this.dphitcontentsmask |= DPCONTENTS_PLAYERCLIP;
+ }
+
if(!autocvar_g_nexball_sound_bounce)
this.noise = "";
else if(this.noise == "")
{
if(SAME_TEAM(tmp_entity, player))
if(random_target)
- RandomSelection_Add(tmp_entity, 0, string_null, 1, 1);
+ RandomSelection_AddEnt(tmp_entity, 1, 1);
else if(vlen2(tmp_entity.origin - spawn_loc) <= vlen2(closest_target.origin - spawn_loc) || closest_target == NULL)
closest_target = tmp_entity;
}
for(tmp_entity = ons_worldgeneratorlist; tmp_entity; tmp_entity = tmp_entity.ons_worldgeneratornext)
{
if(random_target)
- RandomSelection_Add(tmp_entity, 0, string_null, 1, 1);
+ RandomSelection_AddEnt(tmp_entity, 1, 1);
else
{
if(SAME_TEAM(tmp_entity, player))
{
string pos = minigame_tile_buildname(i, j);
if(!snake_find_piece(minigame, pos))
- RandomSelection_Add(NULL, 0, pos, 1, 1);
+ RandomSelection_AddString(pos, 1, 1);
}
entity piece = msle_spawn(minigame,"minigame_board_piece");
{
string pos = minigame_tile_buildname(i, j);
if(!snake_find_piece(minigame, pos))
- RandomSelection_Add(NULL, 0, pos, 1, 1);
+ RandomSelection_AddString(pos, 1, 1);
}
entity piece = msle_spawn(minigame,"minigame_board_piece");
for ( int i = 0; i < 9; i++ )
{
if ( piecemask & f )
- RandomSelection_Add(NULL, f, string_null, 1, 1);
+ RandomSelection_AddFloat(f, 1, 1);
f <<= 1;
}
void Monster_Move(entity this, float runspeed, float walkspeed, float stpspeed)
{
- if(this.target2) { this.goalentity = find(NULL, targetname, this.target2); }
+ // update goal entity if lost
+ if(this.target2 && this.goalentity.targetname != this.target2) { this.goalentity = find(NULL, targetname, this.target2); }
entity targ;
}
else
{
- entity e = find(NULL, targetname, this.target2);
+ entity e = this.goalentity; //find(NULL, targetname, this.target2);
if(e.target2)
this.target2 = e.target2;
- else if(e.target)
+ else if(e.target) // compatibility
this.target2 = e.target;
movelib_brake_simple(this, stpspeed);
#include <server/autocvars.qh>
#include <server/defs.qh>
#endif
-entity spawnmonster (string monster, float monster_id, entity spawnedby, entity own, vector orig, float respwn, float invincible, float moveflag)
+entity spawnmonster (string monster, int monster_id, entity spawnedby, entity own, vector orig, bool respwn, bool invincible, int moveflag)
{
- float i;
entity e = spawn();
e.spawnflags = MONSTERFLAG_SPAWNED;
if(monster == "random")
{
- RandomSelection_Init();
- for(i = MON_FIRST; i <= MON_LAST; ++i)
- RandomSelection_Add(NULL, i, string_null, 1, 1);
+ RandomSelection_Init();
+ FOREACH(Monsters, it != MON_Null,
+ {
+ RandomSelection_AddEnt(it, 1, 1);
+ });
- monster_id = RandomSelection_chosen_float;
+ monster_id = RandomSelection_chosen_ent.monsterid;
}
else if(monster != "")
{
- float found = 0;
- entity mon;
- for(i = MON_FIRST; i <= MON_LAST; ++i)
+ bool found = false;
+ FOREACH(Monsters, it != MON_Null,
{
- mon = get_monsterinfo(i);
- if(mon.netname == monster)
+ if(it.netname == monster)
{
found = true;
- monster_id = mon.monsterid; // we have the monster, old monster id is no longer required
+ monster_id = it.monsterid; // we have the monster, old monster id is no longer required
break;
}
- }
+ });
if(!found)
monster_id = ((monster_id > 0) ? monster_id : MON_FIRST);
}
#pragma once
-entity spawnmonster (string monster, float monster_id, entity spawnedby, entity own, vector orig, float respwn, float invincible, float moveflag);
+entity spawnmonster (string monster, int monster_id, entity spawnedby, entity own, vector orig, bool respwn, bool invincible, int moveflag);
FOREACH(Buffs, buff_Available(it), LAMBDA(
it.buff_seencount += 1;
// if it's already been chosen, give it a lower priority
- RandomSelection_Add(NULL, it.m_itemid, string_null, 1, max(0.2, 1 / it.buff_seencount));
+ RandomSelection_AddFloat(it.m_itemid, 1, max(0.2, 1 / it.buff_seencount));
));
ent.buffs = RandomSelection_chosen_float;
}
#include "sv_instagib.qh"
int autocvar_g_instagib_ammo_drop;
+bool autocvar_g_instagib_ammo_convert_cells;
+bool autocvar_g_instagib_ammo_convert_rockets;
+bool autocvar_g_instagib_ammo_convert_shells;
+bool autocvar_g_instagib_ammo_convert_bullets;
int autocvar_g_instagib_extralives;
float autocvar_g_instagib_speed_highspeed;
start_items |= IT_UNLIMITED_SUPERWEAPONS;
}
+void replace_with_insta_cells(entity item)
+{
+ entity e = spawn();
+ setorigin(e, item.origin);
+ e.noalign = item.noalign;
+ e.cnt = item.cnt;
+ e.team = item.team;
+ e.spawnfunc_checked = true;
+ spawnfunc_item_minst_cells(e);
+}
+
MUTATOR_HOOKFUNCTION(mutator_instagib, FilterItem)
{
entity item = M_ARGV(0, entity);
if(item.classname == "item_cells")
- return true; // no normal cells?
+ {
+ if(autocvar_g_instagib_ammo_convert_cells)
+ {
+ replace_with_insta_cells(item);
+ }
+ return true;
+ }
+ else if(item.classname == "item_rockets")
+ {
+ if(autocvar_g_instagib_ammo_convert_rockets)
+ {
+ replace_with_insta_cells(item);
+ }
+ return true;
+ }
+ else if(item.classname == "item_shells")
+ {
+ if(autocvar_g_instagib_ammo_convert_shells)
+ {
+ replace_with_insta_cells(item);
+ }
+ return true;
+ }
+ else if(item.classname == "item_bullets")
+ {
+ if(autocvar_g_instagib_ammo_convert_bullets)
+ {
+ replace_with_insta_cells(item);
+ }
+ return true;
+ }
if(item.weapon == WEP_VAPORIZER.m_id && item.classname == "droppedweapon")
{
if(item.weapon == WEP_DEVASTATOR.m_id || item.weapon == WEP_VORTEX.m_id)
{
- entity e = spawn();
- setorigin(e, item.origin);
- e.noalign = item.noalign;
- e.cnt = item.cnt;
- e.team = item.team;
- e.spawnfunc_checked = true;
- spawnfunc_item_minst_cells(e);
+ replace_with_insta_cells(item);
return true;
}
#include "sv_melee_only.qh"
-REGISTER_MUTATOR(melee_only, cvar("g_melee_only") && !cvar("g_instagib") && !g_nexball);
+REGISTER_MUTATOR(melee_only, cvar("g_melee_only") && !cvar("g_instagib") && !cvar("g_overkill") && !g_nexball);
-MUTATOR_HOOKFUNCTION(melee_only, SetStartItems)
+MUTATOR_HOOKFUNCTION(melee_only, SetStartItems, CBC_ORDER_LAST)
{
start_ammo_shells = warmup_start_ammo_shells = 0;
start_weapons = warmup_start_weapons = WEPSET(SHOTGUN);
if(d < dist)
{
e.fireball_impactvec = p;
- RandomSelection_Add(e, 0, string_null, 1 / (1 + d), !Fire_IsBurning(e));
+ RandomSelection_AddEnt(e, 1 / (1 + d), !Fire_IsBurning(e));
}
}
if(RandomSelection_chosen_ent)
setsize(_nade, '-16 -16 -16', '16 16 16');
set_movetype(_nade, MOVETYPE_BOUNCE);
- tracebox(_nade.origin, _nade.mins, _nade.maxs, _nade.origin, false, _nade);
+ tracebox(_nade.origin, _nade.mins, _nade.maxs, _nade.origin, MOVE_NOMONSTERS, _nade);
if (trace_startsolid)
setorigin(_nade, e.origin);
RandomSelection_Init();
FOREACH(Weapons, it != WEP_Null, LAMBDA(
if(NIX_CanChooseWeapon(it.m_id))
- RandomSelection_Add(NULL, it.m_id, string_null, 1, (it.m_id != nix_weapon));
+ RandomSelection_AddFloat(it.m_id, 1, (it.m_id != nix_weapon));
));
nix_nextweapon = RandomSelection_chosen_float;
}
#include "rpc.qh"
bool autocvar_g_overkill_powerups_replace;
-float autocvar_g_overkill_superguns_respawn_time;
-bool autocvar_g_overkill_100h_anyway;
-bool autocvar_g_overkill_100a_anyway;
bool autocvar_g_overkill_ammo_charge;
float autocvar_g_overkill_ammo_charge_notice;
float autocvar_g_overkill_ammo_charge_limit;
-.vector ok_deathloc;
-.float ok_spawnsys_timer;
+bool autocvar_g_overkill_filter_healthmega;
+bool autocvar_g_overkill_filter_armormedium;
+bool autocvar_g_overkill_filter_armorbig;
+bool autocvar_g_overkill_filter_armorlarge;
+
.float ok_lastwep;
.float ok_item;
.float ok_use_ammocharge = _STAT(OK_AMMO_CHARGE);
.float ok_ammo_charge = _STAT(OK_AMMO_CHARGEPOOL);
-.float ok_pauseregen_finished;
-
void(entity ent, float wep) ok_DecreaseCharge;
void ok_Initialize();
if(!IS_DEAD(frag_target))
{
Send_Notification(NOTIF_ONE, frag_attacker, MSG_CENTER, CENTER_SECONDARY_NODAMAGE);
- M_ARGV(6, vector) = '0 0 0';
+ M_ARGV(6, vector) = '0 0 0'; // force
}
- M_ARGV(4, float) = 0;
+ M_ARGV(4, float) = 0; // damage
}
}
-MUTATOR_HOOKFUNCTION(ok, PlayerDamage_SplitHealthArmor)
-{
- entity frag_target = M_ARGV(2, entity);
- float damage_take = M_ARGV(4, float);
-
- if(damage_take)
- frag_target.ok_pauseregen_finished = max(frag_target.ok_pauseregen_finished, time + 2);
-}
-
void ok_DropItem(entity this, entity targ)
{
entity e = new(droppedweapon); // hax
ok_DropItem(mon, frag_attacker);
}
-MUTATOR_HOOKFUNCTION(ok, PlayerRegen)
-{
- entity player = M_ARGV(0, entity);
-
- // overkill's values are different, so use custom regen
- if(!STAT(FROZEN, player))
- {
- player.armorvalue = CalcRotRegen(player.armorvalue, autocvar_g_balance_armor_regenstable, autocvar_g_balance_armor_regen, autocvar_g_balance_armor_regenlinear,
- 1 * frametime * (time > player.ok_pauseregen_finished), 0, 0, 1, 1 * frametime * (time > player.pauserotarmor_finished), autocvar_g_balance_armor_limit);
- player.health = CalcRotRegen(player.health, autocvar_g_balance_health_regenstable, 0, 100, 1 * frametime * (time > player.ok_pauseregen_finished), 200, 0,
- autocvar_g_balance_health_rotlinear, 1 * frametime * (time > player.pauserothealth_finished), autocvar_g_balance_health_limit);
-
- float minf, maxf, limitf;
-
- maxf = autocvar_g_balance_fuel_rotstable;
- minf = autocvar_g_balance_fuel_regenstable;
- limitf = autocvar_g_balance_fuel_limit;
-
- player.ammo_fuel = CalcRotRegen(player.ammo_fuel, minf, autocvar_g_balance_fuel_regen, autocvar_g_balance_fuel_regenlinear,
- frametime * (time > player.pauseregen_finished) * ((player.items & ITEM_JetpackRegen.m_itemid) != 0), maxf, autocvar_g_balance_fuel_rot, autocvar_g_balance_fuel_rotlinear, frametime * (time > player.pauserotfuel_finished), limitf);
- }
- return true; // return true anyway, as frozen uses no regen
-}
-
MUTATOR_HOOKFUNCTION(ok, ForbidThrowCurrentWeapon)
{
return true;
ok_IncreaseCharge(player, PS(player).m_weapon.m_id);
if(PHYS_INPUT_BUTTON_ATCK2(player))
- if(!forbidWeaponUse(player) || player.weapon_blocked) // allow if weapon is blocked
+ if( !forbidWeaponUse(player) || player.weapon_blocked // allow if weapon is blocked
+ || (round_handler_IsActive() && !round_handler_IsRoundStarted()) )
if(time >= player.jump_interval)
{
player.jump_interval = time + WEP_CVAR_PRI(blaster, refire) * W_WeaponRateFactor(player);
// if player changed their weapon while dead, don't switch to their death weapon
if(player.impulse)
player.ok_lastwep = 0;
-
- player.ok_pauseregen_finished = time + 2;
}
void self_spawnfunc_weapon_hmg(entity this) { spawnfunc_weapon_hmg(this); }
wep.noalign = ent.noalign;
wep.cnt = ent.cnt;
wep.team = ent.team;
- wep.respawntime = autocvar_g_overkill_superguns_respawn_time;
+ wep.respawntime = g_pickup_respawntime_superweapon;
wep.pickup_anyway = true;
wep.spawnfunc_checked = true;
setthink(wep, self_spawnfunc_weapon_hmg);
wep.noalign = ent.noalign;
wep.cnt = ent.cnt;
wep.team = ent.team;
- wep.respawntime = autocvar_g_overkill_superguns_respawn_time;
+ wep.respawntime = g_pickup_respawntime_superweapon;
wep.pickup_anyway = true;
wep.spawnfunc_checked = true;
setthink(wep, self_spawnfunc_weapon_rpc);
entity item = M_ARGV(0, entity);
if(item.ok_item)
- return;
+ return false;
- switch(item.items)
+ switch(item.itemdef)
{
- case ITEM_HealthMega.m_itemid: return !(autocvar_g_overkill_100h_anyway);
- case ITEM_ArmorMega.m_itemid: return !(autocvar_g_overkill_100a_anyway);
+ case ITEM_HealthMega: return autocvar_g_overkill_filter_healthmega;
+ case ITEM_ArmorMedium: return autocvar_g_overkill_filter_armormedium;
+ // WARNING: next two statements look wrong because of inconsistency between cvar names and code
+ // armor cvars need renaming to be consistent with their health counterparts
+ case ITEM_ArmorLarge: return autocvar_g_overkill_filter_armorbig;
+ case ITEM_ArmorMega: return autocvar_g_overkill_filter_armorlarge;
}
return true;
client.ok_use_ammocharge = spectatee.ok_use_ammocharge;
}
-MUTATOR_HOOKFUNCTION(ok, SetStartItems)
+MUTATOR_HOOKFUNCTION(ok, SetStartItems, CBC_ORDER_LAST)
{
WepSet ok_start_items = (WEPSET(MACHINEGUN) | WEPSET(VORTEX) | WEPSET(SHOTGUN));
continue;
if(!checkpvs(spawn_spot.origin, it))
continue;
- RandomSelection_Add(it, 0, string_null, 1, 1);
+ RandomSelection_AddEnt(it, 1, 1);
));
if(RandomSelection_chosen_ent)
(vid_conwidth - (vid_conwidth * waypointsprite_edgeoffset_right)) - o.x,
(vid_conheight - (vid_conheight * waypointsprite_edgeoffset_bottom)) - o.y);
- float vidscale = max(vid_conwidth / vid_width, vid_conheight / vid_height);
-
float crosshairdistance = sqrt( pow(o.x - vid_conwidth/2, 2) + pow(o.y - vid_conheight/2, 2) );
- t = waypointsprite_scale * vidscale;
+ t = waypointsprite_scale;
a *= waypointsprite_alpha;
{
float waypointsprite_distancefadedistance;
float waypointsprite_alpha;
-const float SPRITE_HEALTHBAR_WIDTH = 144;
-const float SPRITE_HEALTHBAR_HEIGHT = 9;
+const float SPRITE_HEALTHBAR_WIDTH = 104;
+const float SPRITE_HEALTHBAR_HEIGHT = 7;
const float SPRITE_HEALTHBAR_MARGIN = 6;
const float SPRITE_HEALTHBAR_BORDER = 2;
const float SPRITE_HEALTHBAR_BORDERALPHA = 1;
MSG_INFO_NOTIF(MONSTERS_DISABLED, 1, 0, 0, "", "", "", _("^BGMonsters are currently disabled"), "")
+ MULTITEAM_INFO(NEXBALL_RETURN_HELD, 4, 1, 0, 0, "", "", "", _("^BGThe ^TC^TT^BG team held the ball for too long"), "", NAME)
+
MSG_INFO_NOTIF(ONSLAUGHT_CAPTURE, 1, 2, 0, "s1 s2", "", "", _("^BG%s^BG captured %s^BG control point"), "")
MULTITEAM_INFO(ONSLAUGHT_CPDESTROYED, 4, 1, 2, 0, "s1 s2", "", "", _("^TC^TT^BG team %s^BG control point has been destroyed by %s"), "", NAME)
MULTITEAM_INFO(ONSLAUGHT_GENDESTROYED, 4, 1, 0, 0, "", "", "", _("^TC^TT^BG generator has been destroyed"), "", GENERATOR)
MSG_CENTER_NOTIF(TEAMCHANGE_SUICIDE, 1, 0, 1, "", CPID_TEAMCHANGE, "1 f1", _("^K1Suicide in ^COUNT"), "")
MSG_CENTER_NOTIF(TIMEOUT_BEGINNING, 1, 0, 1, "", CPID_TIMEOUT, "1 f1", _("^F4Timeout begins in ^COUNT"), "")
- MSG_CENTER_NOTIF(TIMEOUT_ENDING, 1, 0, 1, "", CPID_TIMEOUT, "1 f1", _("^F4Timeout ends in ^COUNT"), "")
+ MSG_CENTER_NOTIF(TIMEOUT_ENDING, 1, 0, 1, "", CPID_TIMEIN, "1 f1", _("^F4Timeout ends in ^COUNT"), "")
MSG_CENTER_NOTIF(JOIN_PREVENT_MINIGAME, 1, 0, 0, "", CPID_Null, "0 0", _("^K1Cannot join given minigame session!"), "" )
CASE(CPID, RACE_FINISHLAP)
CASE(CPID, TEAMCHANGE)
CASE(CPID, TIMEOUT)
+ CASE(CPID, TIMEIN)
CASE(CPID, VEHICLES)
CASE(CPID, VEHICLES_OTHER)
/** always last */
#define IS_ONGROUND(s) boolean((s).flags & FL_ONGROUND)
#define SET_ONGROUND(s) ((s).flags |= FL_ONGROUND)
#define UNSET_ONGROUND(s) ((s).flags &= ~FL_ONGROUND)
+#define IS_ONSLICK(s) boolean((s).flags & FL_ONSLICK)
+#define SET_ONSLICK(s) ((s).flags |= FL_ONSLICK)
+#define UNSET_ONSLICK(s) ((s).flags &= ~FL_ONSLICK)
#ifdef CSQC
.float bouncestop;
const int MOVETYPE_ANGLECLIP = 2;
#endif
+const int FL_ONSLICK = BIT(20);
+
const int MOVETYPE_FAKEPUSH = 13;
const int MOVEFLAG_VALID = BIT(23);
STAT(MOVEVARS_AIRSPEEDLIMIT_NONQW, this) = Physics_ClientOption(this, "airspeedlimit_nonqw", autocvar_sv_airspeedlimit_nonqw) * maxspd_mod;
STAT(MOVEVARS_MAXSPEED, this) = Physics_ClientOption(this, "maxspeed", autocvar_sv_maxspeed) * maxspd_mod; // also slow walking
+ STAT(PL_MIN, this) = autocvar_sv_player_mins;
+ STAT(PL_MAX, this) = autocvar_sv_player_maxs;
+ STAT(PL_VIEW_OFS, this) = autocvar_sv_player_viewoffset;
+ STAT(PL_CROUCH_MIN, this) = autocvar_sv_player_crouch_mins;
+ STAT(PL_CROUCH_MAX, this) = autocvar_sv_player_crouch_maxs;
+ STAT(PL_CROUCH_VIEW_OFS, this) = autocvar_sv_player_crouch_viewoffset;
+
// old stats
// fix some new settings
STAT(MOVEVARS_AIRACCEL_QW_STRETCHFACTOR, this) = Physics_ClientOption(this, "airaccel_qw_stretchfactor", autocvar_sv_airaccel_qw_stretchfactor);
STAT(MOVEVARS_AIRACCEL_SIDEWAYS_FRICTION, this) = Physics_ClientOption(this, "airaccel_sideways_friction", autocvar_sv_airaccel_sideways_friction);
STAT(MOVEVARS_AIRCONTROL, this) = Physics_ClientOption(this, "aircontrol", autocvar_sv_aircontrol);
STAT(MOVEVARS_AIRCONTROL_POWER, this) = Physics_ClientOption(this, "aircontrol_power", autocvar_sv_aircontrol_power);
+ STAT(MOVEVARS_AIRCONTROL_BACKWARDS, this) = Physics_ClientOption(this, "aircontrol_backwards", autocvar_sv_aircontrol_backwards);
STAT(MOVEVARS_AIRCONTROL_PENALTY, this) = Physics_ClientOption(this, "aircontrol_penalty", autocvar_sv_aircontrol_penalty);
STAT(MOVEVARS_WARSOWBUNNY_AIRFORWARDACCEL, this) = Physics_ClientOption(this, "warsowbunny_airforwardaccel", autocvar_sv_warsowbunny_airforwardaccel);
STAT(MOVEVARS_WARSOWBUNNY_TOPSPEED, this) = Physics_ClientOption(this, "warsowbunny_topspeed", autocvar_sv_warsowbunny_topspeed);
void CPM_PM_Aircontrol(entity this, float dt, vector wishdir, float wishspeed)
{
- float k = 32 * (2 * IsMoveInDirection(this.movement, 0) - 1);
+ float movity = IsMoveInDirection(this.movement, 0);
+ if(PHYS_AIRCONTROL_BACKWARDS(this))
+ movity += IsMoveInDirection(this.movement, 180);
+
+ float k = 32 * (2 * movity - 1);
if (k <= 0)
return;
}
if (!doublejump)
- if (!IS_ONGROUND(this))
+ if (!IS_ONGROUND(this) && !IS_ONSLICK(this))
return IS_JUMP_HELD(this);
bool track_jump = PHYS_CL_TRACK_CANJUMP(this);
}
}
- if (!WAS_ONGROUND(this))
+ if (!WAS_ONGROUND(this) && !WAS_ONSLICK(this))
{
#ifdef SVQC
if(autocvar_speedmeter)
this.velocity_z += mjumpheight;
UNSET_ONGROUND(this);
+ UNSET_ONSLICK(this);
SET_JUMP_HELD(this);
#ifdef SVQC
#endif
}
+void PM_check_slick(entity this)
+{
+ if(!IS_ONGROUND(this))
+ return;
+
+ if(!PHYS_SLICK_APPLYGRAVITY(this))
+ return;
+
+ tracebox(this.origin, this.mins, this.maxs, this.origin - '0 0 1', MOVE_NOMONSTERS, this);
+ if (trace_dphitq3surfaceflags & Q3SURFACEFLAG_SLICK)
+ {
+ UNSET_ONGROUND(this);
+ SET_ONSLICK(this);
+ }
+ else
+ UNSET_ONSLICK(this);
+}
+
void PM_check_blocked(entity this)
{
#ifdef SVQC
#endif
}
-.vector oldmovement;
-
void PM_jetpack(entity this, float maxspd_mod, float dt)
{
//makevectors(this.v_angle.y * '0 1 0');
#define PHYS_AIRCONTROL(s) STAT(MOVEVARS_AIRCONTROL, s)
#define PHYS_AIRCONTROL_PENALTY(s) STAT(MOVEVARS_AIRCONTROL_PENALTY, s)
#define PHYS_AIRCONTROL_POWER(s) STAT(MOVEVARS_AIRCONTROL_POWER, s)
+#define PHYS_AIRCONTROL_BACKWARDS(s) STAT(MOVEVARS_AIRCONTROL_BACKWARDS, s)
#define PHYS_AIRSPEEDLIMIT_NONQW(s) STAT(MOVEVARS_AIRSPEEDLIMIT_NONQW, s)
#define PHYS_AIRSTOPACCELERATE(s) STAT(MOVEVARS_AIRSTOPACCELERATE, s)
#define PHYS_AIRSTRAFEACCELERATE(s) STAT(MOVEVARS_AIRSTRAFEACCELERATE, s)
#define UPWARD_VELOCITY_CLEARS_ONGROUND(s) STAT(GAMEPLAYFIX_UPVELOCITYCLEARSONGROUND, s)
+#define PHYS_SLICK_APPLYGRAVITY(s) STAT(SLICK_APPLYGRAVITY, s)
+
#define PHYS_INPUT_BUTTON_ATCK(s) PHYS_INPUT_BUTTON_BUTTON1(s)
#define PHYS_INPUT_BUTTON_JUMP(s) PHYS_INPUT_BUTTON_BUTTON2(s)
#define PHYS_INPUT_BUTTON_ATCK2(s) PHYS_INPUT_BUTTON_BUTTON3(s)
#define UNSET_JUMP_HELD(s) ((s).flags |= FL_JUMPRELEASED)
#define WAS_ONGROUND(s) boolean((s).lastflags & FL_ONGROUND)
+#define WAS_ONSLICK(s) boolean((s).lastflags & FL_ONSLICK)
#define ITEMS_STAT(s) ((s).items)
bool Physics_Valid(string thecvar);
+ void Physics_UpdateStats(entity this, float maxspd_mod);
+
.float stat_sv_airspeedlimit_nonqw = _STAT(MOVEVARS_AIRSPEEDLIMIT_NONQW);
.float stat_sv_maxspeed = _STAT(MOVEVARS_MAXSPEED);
REGISTER_STAT(SPECTATORSPEED, float)
+#ifdef SVQC
+bool autocvar_sv_slick_applygravity;
+#endif
+REGISTER_STAT(SLICK_APPLYGRAVITY, bool, autocvar_sv_slick_applygravity)
+
#ifdef SVQC
#include "physics/movetypes/movetypes.qh"
#endif
REGISTER_STAT(MOVEVARS_AIRSPEEDLIMIT_NONQW, float)
REGISTER_STAT(MOVEVARS_AIRSTRAFEACCEL_QW, float)
REGISTER_STAT(MOVEVARS_AIRCONTROL_POWER, float)
+REGISTER_STAT(MOVEVARS_AIRCONTROL_BACKWARDS, bool)
noref bool autocvar_sv_gameplayfix_nogravityonground;
REGISTER_STAT(MOVEFLAGS, int, MOVEFLAG_VALID
| (autocvar_sv_gameplayfix_q2airaccelerate ? MOVEFLAG_Q2AIRACCELERATE : 0)
if(it.classname != "item_flag_team" && it.classname != "item_kh_key")
{
Item_Show(it, -1);
- RandomSelection_Add(it, 0, string_null, it.cnt, 0);
+ RandomSelection_AddEnt(it, it.cnt, 0);
}
});
e = RandomSelection_chosen_ent;
IL_EACH(g_items, it.team == this.team,
{
if(it.classname != "item_flag_team" && it.classname != "item_kh_key")
- RandomSelection_Add(it, 0, string_null, it.cnt, 0);
+ RandomSelection_AddEnt(it, it.cnt, 0);
});
e = RandomSelection_chosen_ent;
#ifdef CSQC
+bool autocvar_cl_items_nofade;
float autocvar_cl_animate_items = 1;
float autocvar_cl_ghost_items = 0.45;
vector autocvar_cl_ghost_items_color = '-1 -1 -1';
stopsound (this, CH_TRIGGER_SINGLE);
}
+void func_breakable_destroy(entity this, entity actor, entity trigger);
void func_breakable_behave_restore(entity this)
{
this.health = this.max_health;
this.bot_attack = true;
this.event_damage = func_breakable_damage;
}
+ if(this.spawnflags & 4)
+ this.use = func_breakable_destroy; // don't need to set it usually, as .use isn't reset
this.state = 0;
this.nextthink = 0; // cancel auto respawn
func_breakable_colormod(this);
RandomSelection_Init();
FOREACH_WORD(teleporter.noise, true,
{
- RandomSelection_Add(NULL, 0, it, 1, 1);
+ RandomSelection_AddString(it, 1, 1);
});
thesound = RandomSelection_chosen_string;
}
if(check_tdeath(player, locout, '0 0 0', '0 0 0'))
p = 0;
}
- RandomSelection_Add(it, 0, string_null, (it.cnt ? it.cnt : 1), p);
+ RandomSelection_AddEnt(it, (it.cnt ? it.cnt : 1), p);
});
e = RandomSelection_chosen_ent;
}
void delay_use(entity this, entity actor, entity trigger)
{
setthink(this, SUB_UseTargets_self);
- this.nextthink = this.wait;
+ this.nextthink = time + this.wait;
}
void delay_reset(entity this)
for(e = NULL; (e = find(e, targetname, this.target)); )
{
if(e.cnt)
- RandomSelection_Add(e, 0, string_null, e.cnt, 1);
+ RandomSelection_AddEnt(e, e.cnt, 1);
else
- RandomSelection_Add(e, 0, string_null, 1, 1);
+ RandomSelection_AddEnt(e, 1, 1);
}
toucher.velocity = trigger_push_calculatevelocity(toucher.origin, RandomSelection_chosen_ent, this.height);
}
t.target2 = this.target2;
t.target3 = this.target3;
t.target4 = this.target4;
+ t.antiwall_flag = this.antiwall_flag;
return;
}
{
if(this.target_random)
{
- RandomSelection_Add(t, 0, string_null, 1, 0);
+ RandomSelection_AddEnt(t, 1, 0);
}
else
{
o_z = 0;
- float edgedistance_min, crosshairdistance;
- edgedistance_min = min((o_y - (vid_conheight * waypointsprite_edgeoffset_top)),
+ float edgedistance_min = min((o.y - (vid_conheight * waypointsprite_edgeoffset_top)),
(o_x - (vid_conwidth * waypointsprite_edgeoffset_left)),
(vid_conwidth - (vid_conwidth * waypointsprite_edgeoffset_right)) - o_x,
(vid_conheight - (vid_conheight * waypointsprite_edgeoffset_bottom)) - o_y);
- float vidscale = max(vid_conwidth / vid_width, vid_conheight / vid_height);
+ float crosshairdistance = sqrt( pow(o.x - vid_conwidth/2, 2) + pow(o.y - vid_conheight/2, 2) );
- crosshairdistance = sqrt( pow(o_x - vid_conwidth/2, 2) + pow(o_y - vid_conheight/2, 2) );
-
- t = waypointsprite_scale * vidscale;
+ t = waypointsprite_scale;
a *= waypointsprite_alpha;
{
RandomSelection_Init();
FOREACH(Weapons, it != WEP_Null, {
if (remaining & (it.m_wepset))
- RandomSelection_Add(it, 0, string_null, 1, 1);
+ RandomSelection_AddEnt(it, 1, 1);
});
Weapon w = RandomSelection_chosen_ent;
result |= WepSet_FromWeapon(w);
P(class, prefix, remote_edgedamage, float, NONE) \
P(class, prefix, remote_force, float, NONE) \
P(class, prefix, remote_jump_damage, float, NONE) \
+ P(class, prefix, remote_jump_force, float, NONE) \
P(class, prefix, remote_jump_radius, float, NONE) \
P(class, prefix, remote_jump_velocity_z_add, float, NONE) \
P(class, prefix, remote_jump_velocity_z_max, float, NONE) \
this.event_damage = func_null;
this.takedamage = DAMAGE_NO;
- float handled_as_rocketjump = false;
+ bool handled_as_rocketjump = false;
+ entity head = NULL;
- entity head = WarpZone_FindRadius(
- this.origin,
- WEP_CVAR(devastator, remote_jump_radius),
- false
- );
-
- while(head)
+ if(WEP_CVAR(devastator, remote_jump_radius))
{
- if(head.takedamage && (head == this.realowner))
+ head = WarpZone_FindRadius(
+ this.origin,
+ WEP_CVAR(devastator, remote_jump_radius),
+ false
+ );
+
+ while(head)
{
- float distance_to_head = vlen(this.origin - head.WarpZone_findradius_nearest);
- if(distance_to_head <= WEP_CVAR(devastator, remote_jump_radius))
+ if(head.takedamage && (head == this.realowner))
{
- // we handled this as a rocketjump :)
- handled_as_rocketjump = true;
-
- // modify velocity
- head.velocity_x *= 0.9;
- head.velocity_y *= 0.9;
- head.velocity_z = bound(
- WEP_CVAR(devastator, remote_jump_velocity_z_min),
- head.velocity.z + WEP_CVAR(devastator, remote_jump_velocity_z_add),
- WEP_CVAR(devastator, remote_jump_velocity_z_max)
- );
-
- // now do the damage
- RadiusDamage(
- this,
- head,
- WEP_CVAR(devastator, remote_jump_damage),
- WEP_CVAR(devastator, remote_jump_damage),
- WEP_CVAR(devastator, remote_jump_radius),
- NULL,
- head,
- 0,
- this.projectiledeathtype | HITTYPE_BOUNCE,
- NULL
- );
- break;
+ if(vdist(this.origin - head.WarpZone_findradius_nearest, <=, WEP_CVAR(devastator, remote_jump_radius)))
+ {
+ // we handled this as a rocketjump :)
+ handled_as_rocketjump = true;
+
+ // modify velocity
+ if(WEP_CVAR(devastator, remote_jump_velocity_z_add))
+ {
+ head.velocity_x *= 0.9;
+ head.velocity_y *= 0.9;
+ head.velocity_z = bound(
+ WEP_CVAR(devastator, remote_jump_velocity_z_min),
+ head.velocity.z + WEP_CVAR(devastator, remote_jump_velocity_z_add),
+ WEP_CVAR(devastator, remote_jump_velocity_z_max)
+ );
+ }
+
+ // now do the damage
+ RadiusDamage(
+ this,
+ head,
+ WEP_CVAR(devastator, remote_jump_damage),
+ WEP_CVAR(devastator, remote_jump_damage),
+ WEP_CVAR(devastator, remote_jump_radius),
+ NULL,
+ head,
+ (WEP_CVAR(devastator, remote_jump_force) ? WEP_CVAR(devastator, remote_jump_force) : 0),
+ this.projectiledeathtype | HITTYPE_BOUNCE,
+ NULL
+ );
+ break;
+ }
}
+ head = head.chain;
}
- head = head.chain;
}
RadiusDamage(
if(d < dist)
{
e.fireball_impactvec = p;
- RandomSelection_Add(e, 0, string_null, 1 / (1 + d), !Fire_IsBurning(e));
+ RandomSelection_AddEnt(e, 1 / (1 + d), !Fire_IsBurning(e));
}
}
if(RandomSelection_chosen_ent)
break;
}
- if((this.owner.sv_entnum == player_localentnum - 1) && autocvar_chase_active <= 0)
+ if((this.owner.sv_entnum == player_localentnum - 1))
{
switch(this.HookType)
{
default:
case NET_ENT_CLIENT_HOOK:
- a = view_origin + view_forward * vs.x + view_right * -vs.y + view_up * vs.z;
+ if(autocvar_chase_active > 0)
+ a = csqcplayer.origin;
+ else
+ a = view_origin + view_forward * vs.x + view_right * -vs.y + view_up * vs.z;
b = this.origin;
break;
case NET_ENT_CLIENT_ARC_BEAM:
{
this.team = myteam + 1; // is this correct?
PHYS_WATERJUMP_TIME(this) -= dt;
- this.oldmovement = this.movement;
this.movement = PHYS_INPUT_MOVEVALUES(this);
this.items = STAT(ITEMS, this);
this.spectatorspeed = STAT(SPECTATORSPEED, this);
goto end;
}
+ PM_check_slick(this);
+
if (IS_SVQC && !PHYS_FIXANGLE(this)) { this.angles = '0 1 0' * this.v_angle.y; }
if (IS_PLAYER(this)) {
if (IS_ONGROUND(this)) {
}
if (this.com_phys_ladder) {
if (this.viewloc) {
- wishvel.z = this.oldmovement.x;
+ wishvel.z = this.movement_old.x;
}
if (this.ladder_entity.classname == "func_water") {
float f = vlen(wishvel);
this.csqcmodel_teleported = 1;
}
+ if(sf & BIT(14))
+ viewloc_SetTags(this);
+
CSQCModel_InterpolateAnimation_Note(this, sf);
InterpolateOrigin_Note(this);
CSQCPlayer_PostUpdate(this);
RandomSelection_best_priority = -1;
}
-void RandomSelection_Add(entity e, float f, string s, float weight, float priority)
+void RandomSelection_Add(entity e, float f, string s, vector v, float weight, float priority)
{
if (priority > RandomSelection_best_priority)
{
RandomSelection_chosen_ent = e;
RandomSelection_chosen_float = f;
RandomSelection_chosen_string = s;
+ RandomSelection_chosen_vec = v;
RandomSelection_totalweight = weight;
}
else if (priority == RandomSelection_best_priority)
RandomSelection_chosen_ent = e;
RandomSelection_chosen_float = f;
RandomSelection_chosen_string = s;
+ RandomSelection_chosen_vec = v;
}
}
}
entity RandomSelection_chosen_ent;
float RandomSelection_chosen_float;
string RandomSelection_chosen_string;
+vector RandomSelection_chosen_vec;
void RandomSelection_Init();
-void RandomSelection_Add(entity e, float f, string s, float weight, float priority);
+void RandomSelection_Add(entity e, float f, string s, vector v, float weight, float priority);
+#define RandomSelection_AddEnt(e, weight, priority) RandomSelection_Add(e, 0, string_null, '0 0 0', weight, priority)
+#define RandomSelection_AddFloat(f, weight, priority) RandomSelection_Add(NULL, f, string_null, '0 0 0', weight, priority)
+#define RandomSelection_AddString(s, weight, priority) RandomSelection_Add(NULL, 0, s, '0 0 0', weight, priority)
+#define RandomSelection_AddVec(v, weight, priority) RandomSelection_Add(NULL, 0, string_null, v, weight, priority)
// prandom - PREDICTABLE random number generator
#include "mainwindow.qh"
#define ADDVALUE_FPS(i) e.addValue(e, strzone(sprintf(_("%d fps"), i)), #i)
+#define ADDVALUE_SPEED_KB(i) e.addValue(e, strzone(sprintf(_("%d kb/s"), i)), #i)
+#define ADDVALUE_SPEED_MB(i, j) e.addValue(e, strzone(sprintf(_("%d MB/s"), i)), #j)
entity makeXonoticMiscSettingsTab()
{
entity me;
me.TD(me, 1, 2, e = makeXonoticSlider_T(1, 5, 1, "cl_curl_maxdownloads",
_("Maximum number of concurrent HTTP/FTP downloads")));
me.TR(me);
- me.TD(me, 1, 1, e = makeXonoticTextLabel(0, _("Speed (kB/s):")));
- me.TD(me, 1, 2, e = makeXonoticSlider_T(10, 2000, 50, "cl_curl_maxspeed",
- _("Maximum download speed")));
+ me.TD(me, 1, 1, e = makeXonoticTextLabel(0, _("Download speed:")));
+ me.TD(me, 1, 2, e = makeXonoticTextSlider("cl_curl_maxspeed"));
+ ADDVALUE_SPEED_KB(50);
+ ADDVALUE_SPEED_KB(100);
+ ADDVALUE_SPEED_KB(300);
+ ADDVALUE_SPEED_KB(500);
+ ADDVALUE_SPEED_MB(1, 1000);
+ ADDVALUE_SPEED_MB(2, 2000);
+ e.addValue(e, strzone(_("Unlimited")), "0");
+ e.configureXonoticTextSliderValues(e);
me.TR(me);
if(cvar("developer"))
{
float autocvar_sv_airaccel_sideways_friction;
float autocvar_sv_aircontrol;
float autocvar_sv_aircontrol_power;
+float autocvar_sv_aircontrol_backwards;
float autocvar_sv_aircontrol_penalty;
float autocvar_sv_warsowbunny_airforwardaccel;
float autocvar_sv_warsowbunny_topspeed;
break;
}
));
- RandomSelection_Add(NULL, 0, readfile, 1, prio);
+ RandomSelection_AddString(readfile, 1, prio);
}
readfile = RandomSelection_chosen_string;
fclose(file);
case CHIMPULSE_R00T.impulse:
IS_CHEAT(this, imp, 0, 0);
RandomSelection_Init();
- FOREACH_CLIENT(IS_PLAYER(it) && !IS_DEAD(it) && DIFF_TEAM(it, this), LAMBDA(RandomSelection_Add(it, 0, string_null, 1, 1)));
+ FOREACH_CLIENT(IS_PLAYER(it) && !IS_DEAD(it) && DIFF_TEAM(it, this), LAMBDA(RandomSelection_AddEnt(it, 1, 1)));
if(RandomSelection_chosen_ent)
e = RandomSelection_chosen_ent;
else
RandomSelection_Init();
crosshair_trace(this);
for(entity e = NULL; (e = find(e, classname, "dragbox_box")); )
- RandomSelection_Add(e, 0, string_null, 1, 1 / vlen(e.origin + (e.mins + e.maxs) * 0.5 - trace_endpos));
+ RandomSelection_AddEnt(e, 1, 1 / vlen(e.origin + (e.mins + e.maxs) * 0.5 - trace_endpos));
for(entity e = NULL; (e = find(e, classname, "dragpoint")); )
- RandomSelection_Add(e, 0, string_null, 1, 1 / vlen(e.origin + (e.mins + e.maxs) * 0.5 - trace_endpos));
+ RandomSelection_AddEnt(e, 1, 1 / vlen(e.origin + (e.mins + e.maxs) * 0.5 - trace_endpos));
if(RandomSelection_chosen_ent)
{
delete(RandomSelection_chosen_ent.killindicator.killindicator);
RandomSelection_Init();
crosshair_trace(this);
for(entity e = NULL; (e = find(e, classname, "dragbox_box")); )
- RandomSelection_Add(e, 0, string_null, 1, 1 / vlen(e.origin + (e.mins + e.maxs) * 0.5 - trace_endpos));
+ RandomSelection_AddEnt(e, 1, 1 / vlen(e.origin + (e.mins + e.maxs) * 0.5 - trace_endpos));
for(entity e = NULL; (e = find(e, classname, "dragpoint")); )
- RandomSelection_Add(e, 0, string_null, 1, 1 / vlen(e.origin + (e.mins + e.maxs) * 0.5 - trace_endpos));
+ RandomSelection_AddEnt(e, 1, 1 / vlen(e.origin + (e.mins + e.maxs) * 0.5 - trace_endpos));
if(RandomSelection_chosen_ent)
{
if(substring(argv(1), 0, 1) == "*")
FixPlayermodel(this);
this.drawonlytoclient = NULL;
+ this.viewloc = NULL;
+
this.crouch = false;
- this.view_ofs = STAT(PL_VIEW_OFS, NULL);
- setsize(this, STAT(PL_MIN, NULL), STAT(PL_MAX, NULL));
+ this.view_ofs = STAT(PL_VIEW_OFS, this);
+ setsize(this, STAT(PL_MIN, this), STAT(PL_MAX, this));
this.spawnorigin = spot.origin;
setorigin(this, spot.origin + '0 0 1' * (1 - this.mins.z - 24));
// don't reset back to last position, even if new position is stuck in solid
if (IS_REAL_CLIENT(this))
sv_notice_join(this);
+ // update physics stats (players can spawn before physics runs)
+ Physics_UpdateStats(this, PHYS_HIGHSPEED(this));
+
IL_EACH(g_initforplayer, it.init_for_player, {
it.init_for_player(it, this);
});
void GetPressedKeys(entity this)
{
MUTATOR_CALLHOOK(GetPressedKeys, this);
- int keys = this.pressedkeys;
+ int keys = STAT(PRESSED_KEYS, this);
keys = BITSET(keys, KEY_FORWARD, this.movement.x > 0);
keys = BITSET(keys, KEY_BACKWARD, this.movement.x < 0);
keys = BITSET(keys, KEY_RIGHT, this.movement.y > 0);
keys = BITSET(keys, KEY_CROUCH, PHYS_INPUT_BUTTON_CROUCH(this));
keys = BITSET(keys, KEY_ATCK, PHYS_INPUT_BUTTON_ATCK(this));
keys = BITSET(keys, KEY_ATCK2, PHYS_INPUT_BUTTON_ATCK2(this));
- this.pressedkeys = keys;
+ this.pressedkeys = keys; // store for other users
+
+ STAT(PRESSED_KEYS, this) = keys;
}
/*
this.hit_time = spectatee.hit_time;
this.strength_finished = spectatee.strength_finished;
this.invincible_finished = spectatee.invincible_finished;
- this.pressedkeys = spectatee.pressedkeys;
+ STAT(PRESSED_KEYS, this) = STAT(PRESSED_KEYS, spectatee);
this.weapons = spectatee.weapons;
this.vortex_charge = spectatee.vortex_charge;
this.vortex_chargepool_ammo = spectatee.vortex_chargepool_ammo;
this.angles = spectatee.v_angle;
STAT(FROZEN, this) = STAT(FROZEN, spectatee);
this.revive_progress = spectatee.revive_progress;
+ this.viewloc = spectatee.viewloc;
if(!PHYS_INPUT_BUTTON_USE(this) && STAT(CAMERA_SPECTATOR, this) != 2)
this.fixangle = true;
setorigin(this, spectatee.origin);
{
if ((this.respawn_flags & RESPAWN_FORCE) && !(this.respawn_time < this.respawn_time_max))
this.deadflag = DEAD_RESPAWNING;
- else if (!button_pressed || (this.respawn_flags & RESPAWN_FORCE))
+ else if (!button_pressed || (time >= this.respawn_time_max && (this.respawn_flags & RESPAWN_FORCE)))
this.deadflag = DEAD_DEAD;
break;
}
}
else // time to end the timeout
{
+ Kill_Notification(NOTIF_ALL, NULL, MSG_CENTER, CPID_TIMEIN);
timeout_status = TIMEOUT_INACTIVE;
// reset the slowmo value back to normal
string clientstuff;
.float phase;
-.int pressedkeys = _STAT(PRESSED_KEYS);
+.int pressedkeys;
.string fog;
return;
if(STAT(FROZEN, targ) && STAT(FROZEN, targ) != 3) // only reset health if target was frozen
+ {
targ.health = ((IS_PLAYER(targ)) ? start_health : targ.max_health);
+ targ.pauseregen_finished = time + autocvar_g_balance_pause_health_regen;
+ }
STAT(FROZEN, targ) = 0;
targ.revive_progress = 0;
WriteCoord(MSG_ENTITY, this.movedir.z);
WriteByte(MSG_ENTITY, floor(this.lip * 255));
}
- WriteShort(MSG_ENTITY, this.fade_start);
- WriteShort(MSG_ENTITY, this.fade_end);
- WriteShort(MSG_ENTITY, this.alpha_max);
- WriteShort(MSG_ENTITY, this.alpha_min);
- WriteShort(MSG_ENTITY, this.inactive);
+ WriteByte(MSG_ENTITY, this.fade_start);
+ WriteByte(MSG_ENTITY, this.fade_end);
+ WriteByte(MSG_ENTITY, this.alpha_max);
+ WriteByte(MSG_ENTITY, this.alpha_min);
+ WriteByte(MSG_ENTITY, this.inactive);
WriteShort(MSG_ENTITY, this.fade_vertical_offset);
}
BADCVAR("g_invasion_point_limit");
BADCVAR("g_keyhunt_point_leadlimit");
BADCVAR("g_nexball_goalleadlimit");
+ BADCVAR("g_new_toys_use_pickupsound");
+ BADCVAR("g_physics_predictall");
+ BADCVAR("g_piggyback");
BADCVAR("g_tdm_point_leadlimit");
BADCVAR("g_tdm_point_limit");
BADCVAR("leadlimit_and_fraglimit");
BADCVAR("leadlimit_override");
BADCVAR("pausable");
- BADCVAR("sv_allow_fullbright");
BADCVAR("sv_checkforpacketsduringsleep");
BADCVAR("sv_intermission_cdtrack");
BADCVAR("sv_minigames");
BADCVAR("sv_namechangetimer");
BADCVAR("sv_precacheplayermodels");
+ BADCVAR("sv_stepheight");
BADCVAR("sv_timeout");
BADPREFIX("crypto_");
BADPREFIX("gameversion_");
BADPREFIX("net_");
BADPREFIX("prvm_");
BADPREFIX("skill_");
+ BADPREFIX("sv_allow_");
BADPREFIX("sv_cullentities_");
BADPREFIX("sv_maxidle_");
BADPREFIX("sv_minigames_");
+ BADPREFIX("sv_radio_");
BADPREFIX("sv_timeout_");
BADPREFIX("sv_vote_");
BADPREFIX("timelimit_");
BADCVAR("g_balance_teams_scorefactor");
BADCVAR("g_ban_sync_trusted_servers");
BADCVAR("g_ban_sync_uri");
+ BADCVAR("g_buffs");
BADCVAR("g_ca_teams_override");
BADCVAR("g_ctf_ignore_frags");
BADCVAR("g_domination_point_limit");
BADCVAR("g_maxplayers");
BADCVAR("g_mirrordamage");
BADCVAR("g_nexball_goallimit");
+ BADCVAR("g_norecoil");
+ BADCVAR("g_physics_clientselect");
BADCVAR("g_powerups");
BADCVAR("g_spawnshieldtime");
BADCVAR("g_start_delay");
BADCVAR("g_grappling_hook");
BADCVAR("g_jetpack");
+#undef BADPRESUFFIX
#undef BADPREFIX
#undef BADCVAR
if(cvar_string("g_mod_config") != cvar_defstring("g_mod_config"))
modname = cvar_string("g_mod_config");
// extra mutators that deserve to count as mod
- MUTATOR_CALLHOOK(SetModname);
+ MUTATOR_CALLHOOK(SetModname, modname);
+ modname = M_ARGV(0, string);
// save it for later
modname = strzone(modname);
stuffcmd(e, "\nscr_printspeed 1000000\n");
RandomSelection_Init();
FOREACH_WORD(autocvar_sv_intermission_cdtrack, true, LAMBDA(
- RandomSelection_Add(NULL, 0, it, 1, 1);
+ RandomSelection_AddString(it, 1, 1);
));
if (RandomSelection_chosen_string != "")
{
float mapvote_nextthink;
float mapvote_keeptwotime;
float mapvote_timeout;
-string mapvote_message;
const float MAPVOTE_SCREENSHOT_DIRS_COUNT = 4;
string mapvote_screenshot_dirs[MAPVOTE_SCREENSHOT_DIRS_COUNT];
float mapvote_screenshot_dirs_count;
mapvote_timeout = time + autocvar_g_maplist_votable_timeout;
if(mapvote_count_real < 3 || mapvote_keeptwotime <= time)
mapvote_keeptwotime = 0;
- mapvote_message = "Choose a map and press its key!";
MapVote_Spawn();
}
for(i = 0; i < mapvote_count_real; ++i)
if ( mapvote_maps_flags[i] & GTV_AVAILABLE )
{
- RandomSelection_Add(NULL, i, string_null, 1, mapvote_selections[i]);
+ RandomSelection_AddFloat(i, 1, mapvote_selections[i]);
if ( gametypevote && mapvote_maps[i] == MapInfo_Type_ToString(MapInfo_CurrentGametype()) )
{
currentVotes = mapvote_selections[i];
for(i = 0; i < mapvote_count_real; ++i)
if(i != firstPlace)
if ( mapvote_maps_flags[i] & GTV_AVAILABLE )
- RandomSelection_Add(NULL, i, string_null, 1, mapvote_selections[i]);
+ RandomSelection_AddFloat(i, 1, mapvote_selections[i]);
secondPlace = RandomSelection_chosen_float;
secondPlaceVotes = RandomSelection_best_priority;
//dprint("Second place: ", ftos(secondPlace), "\n");
{
float didntvote;
MapVote_TouchMask();
- mapvote_message = "Now decide between the TOP TWO!";
mapvote_keeptwotime = 0;
result = strcat(":vote:keeptwo:", mapvote_maps[firstPlace]);
result = strcat(result, ":", ftos(firstPlaceVotes));
void MapVote_Tick()
{
- float keeptwo;
float totalvotes;
- keeptwo = mapvote_keeptwotime;
MapVote_CheckRules_1(); // count
if(MapVote_CheckRules_2()) // decide
return;
#define EV_SetModname(i, o) \
/** name of the mutator/mod if it warrants showing as such in the server browser */ \
+ /**/ i(string, MUTATOR_ARGV_0_string) \
/**/ o(string, MUTATOR_ARGV_0_string) \
/**/
MUTATOR_HOOKABLE(SetModname, EV_SetModname);
ScoreRules_basics(0, 0, 0, false);
if(g_race_qualifying)
{
- ScoreInfo_SetLabel_PlayerScore(SP_CTS_FASTEST, "fastest", SFL_SORT_PRIO_PRIMARY | SFL_LOWER_IS_BETTER | SFL_TIME);
+ ScoreInfo_SetLabel_PlayerScore(SP_RACE_FASTEST, "fastest", SFL_SORT_PRIO_PRIMARY | SFL_LOWER_IS_BETTER | SFL_TIME);
}
else
{
- ScoreInfo_SetLabel_PlayerScore(SP_CTS_LAPS, "laps", SFL_SORT_PRIO_PRIMARY);
- ScoreInfo_SetLabel_PlayerScore(SP_CTS_TIME, "time", SFL_SORT_PRIO_SECONDARY | SFL_LOWER_IS_BETTER | SFL_TIME);
- ScoreInfo_SetLabel_PlayerScore(SP_CTS_FASTEST, "fastest", SFL_LOWER_IS_BETTER | SFL_TIME);
+ ScoreInfo_SetLabel_PlayerScore(SP_RACE_LAPS, "laps", SFL_SORT_PRIO_PRIMARY);
+ ScoreInfo_SetLabel_PlayerScore(SP_RACE_TIME, "time", SFL_SORT_PRIO_SECONDARY | SFL_LOWER_IS_BETTER | SFL_TIME);
+ ScoreInfo_SetLabel_PlayerScore(SP_RACE_FASTEST, "fastest", SFL_LOWER_IS_BETTER | SFL_TIME);
}
ScoreRules_basics_end();
}
if(gameover)
return true;
- entity player = M_ARGV(0, entity);
-
- if(STAT(FROZEN, player) == 1)
- {
- // keep health = 1
- player.pauseregen_finished = time + autocvar_g_balance_pause_health_regen;
- }
-
if(round_handler_IsActive())
if(!round_handler_IsRoundStarted())
return true;
int n;
-
- entity o;
- o = NULL;
+ entity o = NULL;
+ entity player = M_ARGV(0, entity);
//if(STAT(FROZEN, player))
//if(player.freezetag_frozen_timeout > 0 && time < player.freezetag_frozen_timeout)
//player.iceblock.alpha = ICE_MIN_ALPHA + (ICE_MAX_ALPHA - ICE_MIN_ALPHA) * (player.freezetag_frozen_timeout - time) / (player.freezetag_frozen_timeout - player.freezetag_frozen_time);
bool autocvar_g_invasion_zombies_only;
float autocvar_g_invasion_spawn_delay;
+.string spawnmob;
+
spawnfunc(invasion_spawnpoint)
{
if(!g_invasion) { delete(this); return; }
IL_PUSH(g_invasion_spawns, this);
if(autocvar_g_invasion_zombies_only) // precache only if it hasn't been already
- if(this.monsterid) {
- Monster mon = get_monsterinfo(this.monsterid);
- mon.mr_precache(mon);
+ if(this.spawnmob)
+ {
+ FOREACH(Monsters, it.netname == this.spawnmob,
+ {
+ it.mr_precache(it);
+ });
}
}
{
if((it.spawnflags & MONSTER_TYPE_FLY) || (it.spawnflags & MONSTER_TYPE_SWIM) || (it.spawnflags & MONSTER_SIZE_QUAKE) || ((it.spawnflags & MON_FLAG_SUPERMONSTER) && supermonster_count >= 1))
continue;
- RandomSelection_Add(NULL, it.monsterid, string_null, 1, 1);
+ RandomSelection_AddFloat(it.monsterid, 1, 1);
});
return RandomSelection_chosen_float;
IL_EACH(g_invasion_spawns, true,
{
- RandomSelection_Add(it, 0, string_null, 1, ((time >= it.spawnshieldtime) ? 0.2 : 1)); // give recently used spawnpoints a very low rating
+ RandomSelection_AddEnt(it, 1, ((time >= it.spawnshieldtime) ? 0.2 : 1)); // give recently used spawnpoints a very low rating
it.spawnshieldtime = time + autocvar_g_invasion_spawnpoint_spawn_delay;
});
return RandomSelection_chosen_ent;
}
-void invasion_SpawnChosenMonster(float mon)
+void invasion_SpawnChosenMonster(int mon)
{
entity spawn_point, monster;
setthink(e, SUB_Remove);
e.nextthink = time + 0.1;
}
- else
- monster = spawnmonster("", ((spawn_point.monsterid) ? spawn_point.monsterid : mon), spawn_point, spawn_point, spawn_point.origin, false, false, 2);
+ else // if spawnmob field falls through (unset), fallback to mon (relying on spawnmonster for that behaviour)
+ monster = spawnmonster(spawn_point.spawnmob, mon, spawn_point, spawn_point, spawn_point.origin, false, false, 2);
if(spawn_point) monster.target2 = spawn_point.target2;
monster.spawnshieldtime = time;
else
{
RandomSelection_Init();
- if(inv_monsters_perteam[NUM_TEAM_1] > 0) RandomSelection_Add(NULL, NUM_TEAM_1, string_null, 1, 1);
- if(inv_monsters_perteam[NUM_TEAM_2] > 0) RandomSelection_Add(NULL, NUM_TEAM_2, string_null, 1, 1);
- if(invasion_teams >= 3) if(inv_monsters_perteam[NUM_TEAM_3] > 0) { RandomSelection_Add(NULL, NUM_TEAM_3, string_null, 1, 1); }
- if(invasion_teams >= 4) if(inv_monsters_perteam[NUM_TEAM_4] > 0) { RandomSelection_Add(NULL, NUM_TEAM_4, string_null, 1, 1); }
+ if(inv_monsters_perteam[NUM_TEAM_1] > 0) RandomSelection_AddFloat(NUM_TEAM_1, 1, 1);
+ if(inv_monsters_perteam[NUM_TEAM_2] > 0) RandomSelection_AddFloat(NUM_TEAM_2, 1, 1);
+ if(invasion_teams >= 3) if(inv_monsters_perteam[NUM_TEAM_3] > 0) { RandomSelection_AddFloat(NUM_TEAM_3, 1, 1); }
+ if(invasion_teams >= 4) if(inv_monsters_perteam[NUM_TEAM_4] > 0) { RandomSelection_AddFloat(NUM_TEAM_4, 1, 1); }
monster.team = RandomSelection_chosen_float;
}
RandomSelection_Init();
for(spot = firstspot; spot; spot = spot.chain)
- RandomSelection_Add(spot, 0, string_null, pow(bound(lower, spot.spawnpoint_score.y, upper), exponent) * spot.cnt, (spot.spawnpoint_score.y >= lower) * 0.5 + spot.spawnpoint_score.x);
+ RandomSelection_AddEnt(spot, pow(bound(lower, spot.spawnpoint_score.y, upper), exponent) * spot.cnt, (spot.spawnpoint_score.y >= lower) * 0.5 + spot.spawnpoint_score.x);
return RandomSelection_chosen_ent;
}
// now t is the minimum, or A minimum!
if(t == 1 || TeamSmallerEqThanTeam(1, t, pl))
- RandomSelection_Add(NULL, 1, string_null, 1, 1);
+ RandomSelection_AddFloat(1, 1, 1);
if(t == 2 || TeamSmallerEqThanTeam(2, t, pl))
- RandomSelection_Add(NULL, 2, string_null, 1, 1);
+ RandomSelection_AddFloat(2, 1, 1);
if(t == 3 || TeamSmallerEqThanTeam(3, t, pl))
- RandomSelection_Add(NULL, 3, string_null, 1, 1);
+ RandomSelection_AddFloat(3, 1, 1);
if(t == 4 || TeamSmallerEqThanTeam(4, t, pl))
- RandomSelection_Add(NULL, 4, string_null, 1, 1);
+ RandomSelection_AddFloat(4, 1, 1);
return RandomSelection_chosen_float;
}