]> de.git.xonotic.org Git - xonotic/xonotic-data.pk3dir.git/commitdiff
Merge remote-tracking branch 'origin/Mario/tweaks'
authorMario <mario@smbclan.net>
Sun, 3 Jul 2016 23:14:52 +0000 (09:14 +1000)
committerMario <mario@smbclan.net>
Sun, 3 Jul 2016 23:14:52 +0000 (09:14 +1000)
40 files changed:
.gitlab-ci.yml
balance-nexuiz25.cfg
balance-overkill.cfg
balance-samual.cfg
balance-xdf.cfg
balance-xonotic.cfg
balance-xpm.cfg
defaultXonotic.cfg
models/weapons/g_fireball.md3
models/weapons/h_fireball.iqm
models/weapons/v_fireball.md3
qcsrc/client/hud/panel/vote.qc
qcsrc/client/hud/panel/weapons.qc
qcsrc/common/mutators/mutator/damagetext/damagetext.qc
qcsrc/common/mutators/mutator/overkill/hmg.qc
qcsrc/common/physics/movetypes/toss.qc
qcsrc/common/vehicles/vehicle/racer.qc
qcsrc/common/vehicles/vehicle/raptor.qc
qcsrc/menu/item/dialog.qc
qcsrc/menu/item/inputcontainer.qc
qcsrc/menu/menu.qc
qcsrc/menu/xonotic/_mod.inc
qcsrc/menu/xonotic/_mod.qh
qcsrc/menu/xonotic/dialog_settings_video.qc
qcsrc/menu/xonotic/dialog_uid2name.qc [new file with mode: 0644]
qcsrc/menu/xonotic/dialog_uid2name.qh [new file with mode: 0644]
qcsrc/menu/xonotic/mainwindow.qc
qcsrc/menu/xonotic/util.qc
qcsrc/server/cl_client.qc
qcsrc/server/cl_player.qc
qcsrc/server/mutators/mutator/gamemode_ca.qc
qcsrc/server/mutators/mutator/gamemode_tdm.qc
qcsrc/server/weapons/weaponsystem.qc
scripts/fireball.shader
textures/fireball.tga
textures/fireball_gloss.tga
textures/fireball_glow.tga
textures/fireball_norm.tga [new file with mode: 0644]
textures/fireball_pants.tga [new file with mode: 0644]
textures/fireball_shirt.tga [new file with mode: 0644]

index 3cdd43f30510917818e9a8ab0b4365574d83d84d..7909c3286a6dcbd28402519f993afc9a33a59f16 100644 (file)
@@ -24,7 +24,7 @@ test_sv_game:
     - 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=4bd5b0276cdd100c831c73f0400eca71
+    - EXPECT=9b2513f29762de886296f998ac8725c9
     - HASH=$(${ENGINE} -noconfig -nohome +exec serverbench.cfg
       | tee /dev/stderr
       | grep '^:'
index 3ac47371ee350ab68ce3fe4c5c2c3d2dfe769696..f49e50cce2a26856ab6d52203e40b027eb1305df 100644 (file)
@@ -32,7 +32,7 @@ set g_balance_nix_ammo_nails 45
 set g_balance_nix_ammo_rockets 15
 set g_balance_nix_ammo_cells 15
 set g_balance_nix_ammo_plasma 15
-set g_balance_nix_ammo_fuel 0
+set g_balance_nix_ammo_fuel 25
 set g_balance_nix_ammoincr_shells 2 // eh this will need figured out later I assume
 set g_balance_nix_ammoincr_nails 6
 set g_balance_nix_ammoincr_rockets 2
index a691a191838bdae351692863f639a759fb1e5059..1a4b9bb940e11594f94c6785a043c22d85c87e40 100644 (file)
@@ -32,7 +32,7 @@ set g_balance_nix_ammo_nails 320
 set g_balance_nix_ammo_rockets 160
 set g_balance_nix_ammo_cells 180
 set g_balance_nix_ammo_plasma 180
-set g_balance_nix_ammo_fuel 0
+set g_balance_nix_ammo_fuel 100
 set g_balance_nix_ammoincr_shells 2 // eh this will need figured out later I assume
 set g_balance_nix_ammoincr_nails 6
 set g_balance_nix_ammoincr_rockets 2
index 6d7831adac2624bbe88528ddc4388f7059cd18d5..08e38f16713fb82f5c70517b960dffb15cd12971 100644 (file)
@@ -32,7 +32,7 @@ set g_balance_nix_ammo_nails 320
 set g_balance_nix_ammo_rockets 160
 set g_balance_nix_ammo_cells 180
 set g_balance_nix_ammo_plasma 180
-set g_balance_nix_ammo_fuel 0
+set g_balance_nix_ammo_fuel 100
 set g_balance_nix_ammoincr_shells 2 // eh this will need figured out later I assume
 set g_balance_nix_ammoincr_nails 6
 set g_balance_nix_ammoincr_rockets 2
index 07b38e830a8f988235a1ba0306db0c488f8c21f3..e816f89abd74997bfda5f5687e9d3f9911f4f1bd 100644 (file)
@@ -32,7 +32,7 @@ set g_balance_nix_ammo_nails 320
 set g_balance_nix_ammo_rockets 160
 set g_balance_nix_ammo_cells 180
 set g_balance_nix_ammo_plasma 180
-set g_balance_nix_ammo_fuel 0
+set g_balance_nix_ammo_fuel 100
 set g_balance_nix_ammoincr_shells 2 // eh this will need figured out later I assume
 set g_balance_nix_ammoincr_nails 6
 set g_balance_nix_ammoincr_rockets 2
index ddc40e288eda5c3a8aaa18e47b96ac2f9772236b..aafb810449058632c56acafb7b224668395ef6fc 100644 (file)
@@ -32,7 +32,7 @@ set g_balance_nix_ammo_nails 320
 set g_balance_nix_ammo_rockets 160
 set g_balance_nix_ammo_cells 180
 set g_balance_nix_ammo_plasma 180
-set g_balance_nix_ammo_fuel 0
+set g_balance_nix_ammo_fuel 100
 set g_balance_nix_ammoincr_shells 2 // eh this will need figured out later I assume
 set g_balance_nix_ammoincr_nails 6
 set g_balance_nix_ammoincr_rockets 2
index e0aa8b08270ddd73312518916661e2db0fb101cb..342d3e068e2b679ad1f5cec0c00257867a461ab6 100644 (file)
@@ -32,7 +32,7 @@ set g_balance_nix_ammo_nails 320
 set g_balance_nix_ammo_rockets 160
 set g_balance_nix_ammo_cells 180
 set g_balance_nix_ammo_plasma 180
-set g_balance_nix_ammo_fuel 0
+set g_balance_nix_ammo_fuel 100
 set g_balance_nix_ammoincr_shells 2 // eh this will need figured out later I assume
 set g_balance_nix_ammoincr_nails 6
 set g_balance_nix_ammoincr_rockets 2
index 0c280744afa9f18d8dc9c24bd3f594c6dea0211e..3b3e48b620dfb44c67d77f686452699ac5693dc0 100644 (file)
@@ -784,6 +784,8 @@ seta cl_damagetext_alpha_lifetime "3" "Damage text lifetime in seconds"
 seta cl_damagetext_velocity "0 0 20" "Damage text move direction"
 seta cl_damagetext_offset "0 -40 0" "Damage text offset"
 seta cl_damagetext_accumulate_range "30" "Damage text spawned within this range is accumulated"
+seta cl_damagetext_friendlyfire "1" "Show damage text for friendlyfire too"
+seta cl_damagetext_friendlyfire_color "1 0 0" "Damage text color for friendlyfire"
 
 set sv_itemstime 1 "enable networking of left time until respawn for items such as mega health and large armor"
 
index c953426724ec3ba219dd00b6a5659e5fa837254d..b1463090f7d2d5783b86cf2c9c032b089c5e2f56 100644 (file)
Binary files a/models/weapons/g_fireball.md3 and b/models/weapons/g_fireball.md3 differ
index 40a6b06a8341072f8d3a99f40e044535459ff544..3a9db00cedc20461beaf21a73e8527ec8e0b0d43 100644 (file)
Binary files a/models/weapons/h_fireball.iqm and b/models/weapons/h_fireball.iqm differ
index a5e847c37b375d7222611e30f63d6ce38fbfccd3..18fbf7489035b48c291686663142d718c2376058 100644 (file)
Binary files a/models/weapons/v_fireball.md3 and b/models/weapons/v_fireball.md3 differ
index 89c784a1083be4e0ece863ca00419549520c05de..d7d4d252bec67441f178311e5f593bde24220536 100644 (file)
@@ -7,6 +7,15 @@ void HUD_Vote()
 {
        if(autocvar_cl_allow_uid2name == -1 && (gametype == MAPINFO_TYPE_CTS || gametype == MAPINFO_TYPE_RACE || (serverflags & SERVERFLAG_PLAYERSTATS)))
        {
+               // this dialog gets overriden by the uid2name menu dialog, if it exists
+               // TODO remove this client side uid2name dialog in the next release
+               if(autocvar__menu_alpha)
+                       hud_fade_alpha = 0;
+               else
+                       uid2name_dialog = 0;
+               if (!uid2name_dialog)
+                       localcmd("menu_cmd directmenu Uid2Name\n");
+
                vote_active = 1;
                if (autocvar__hud_configure)
                {
index 984cb4f50519097481f08ee8d701babcf058e160..a30006c26377f7b93f3fdd9d37f35d934cd73221 100644 (file)
@@ -56,6 +56,8 @@ void HUD_Weapons()
        float when = max(1, autocvar_hud_panel_weapons_complainbubble_time);
        float fadetime = max(0, autocvar_hud_panel_weapons_complainbubble_fadetime);
 
+       bool infinite_ammo = (STAT(ITEMS) & IT_UNLIMITED_WEAPON_AMMO);
+
        vector weapon_pos, weapon_size = '0 0 0';
        vector color;
 
@@ -330,7 +332,7 @@ void HUD_Weapons()
        }
 
        // calculate position/size for visual bar displaying ammount of ammo status
-       if (autocvar_hud_panel_weapons_ammo)
+       if (!infinite_ammo && autocvar_hud_panel_weapons_ammo)
        {
                ammo_color = stov(autocvar_hud_panel_weapons_ammo_color);
                ammo_alpha = panel_fg_alpha * autocvar_hud_panel_weapons_ammo_alpha;
@@ -466,7 +468,7 @@ void HUD_Weapons()
                        }
 
                        // draw ammo status bar
-                       if(autocvar_hud_panel_weapons_ammo && (it.ammo_field != ammo_none))
+                       if(!infinite_ammo && autocvar_hud_panel_weapons_ammo && (it.ammo_field != ammo_none))
                        {
                                float ammo_full;
                                a = getstati(GetAmmoStat(it.ammo_field)); // how much ammo do we have?
index 2a1795d63c94afad39c367c52eb0decd51172575..371bf2bbe08a581396a4e4a65d2f6286e51f0ac4 100644 (file)
@@ -25,16 +25,20 @@ AUTOCVAR_SAVE(cl_damagetext_alpha_lifetime,     float,  3,          "Damage text
 AUTOCVAR_SAVE(cl_damagetext_velocity,           vector, '0 0 20',   "Damage text move direction");
 AUTOCVAR_SAVE(cl_damagetext_offset,             vector, '0 -40 0',  "Damage text offset");
 AUTOCVAR_SAVE(cl_damagetext_accumulate_range,   float,  30,         "Damage text spawned within this range is accumulated");
+AUTOCVAR_SAVE(cl_damagetext_friendlyfire,       bool,   true,       "Show damage text for friendlyfire too");
+AUTOCVAR_SAVE(cl_damagetext_friendlyfire_color, vector, '1 0 0',    "Damage text color for friendlyfire");
 #endif
 
 #ifdef CSQC
 CLASS(DamageText, Object)
     ATTRIB(DamageText, m_color, vector, autocvar_cl_damagetext_color)
+    ATTRIB(DamageText, m_color_friendlyfire, vector, autocvar_cl_damagetext_friendlyfire_color)
     ATTRIB(DamageText, m_size, float, autocvar_cl_damagetext_size)
     ATTRIB(DamageText, alpha, float, autocvar_cl_damagetext_alpha_start)
     ATTRIB(DamageText, fade_rate, float, 1 / autocvar_cl_damagetext_alpha_lifetime)
     ATTRIB(DamageText, velocity, vector, autocvar_cl_damagetext_velocity)
     ATTRIB(DamageText, m_group, int, 0)
+    ATTRIB(DamageText, m_friendlyfire, bool, false)
     ATTRIB(DamageText, m_damage, int, 0)
     ATTRIB(DamageText, m_armordamage, int, 0)
     ATTRIB(DamageText, m_deathtype, int, 0)
@@ -49,7 +53,13 @@ CLASS(DamageText, Object)
         vector pos = project_3d_to_2d(this.origin) + autocvar_cl_damagetext_offset;
         if (pos.z >= 0 && this.m_size > 0) {
             pos.z = 0;
-            vector rgb = this.m_color;
+            vector rgb;
+            if (this.m_friendlyfire) {
+                rgb = this.m_color_friendlyfire;
+            }
+            else {
+                rgb = this.m_color;
+            }
             if (autocvar_cl_damagetext_color_per_weapon) {
                 Weapon w = DEATH_WEAPONOF(this.m_deathtype);
                 if (w != WEP_Null) rgb = w.wpcolor;
@@ -71,9 +81,10 @@ CLASS(DamageText, Object)
         this.alpha = 1;
     }
 
-    CONSTRUCTOR(DamageText, int _group, vector _origin, int _health, int _armor, int _deathtype) {
+    CONSTRUCTOR(DamageText, int _group, vector _origin, int _health, int _armor, int _deathtype, bool _friendlyfire) {
         CONSTRUCT(DamageText);
         this.m_group = _group;
+        this.m_friendlyfire = _friendlyfire;
         DamageText_update(this, _origin, _health, _armor, _deathtype);
     }
 ENDCLASS(DamageText)
@@ -111,6 +122,7 @@ MUTATOR_HOOKFUNCTION(damagetext, PlayerDamaged) {
             WriteCoord(MSG_ONE, location.y);
             WriteCoord(MSG_ONE, location.z);
             WriteInt24_t(MSG_ONE, deathtype);
+            WriteByte(MSG_ONE, SAME_TEAM(hit, attacker));
         }
     ));
 }
@@ -124,8 +136,12 @@ NET_HANDLE(damagetext, bool isNew)
     int group = ReadShort();
     vector location = vec3(ReadCoord(), ReadCoord(), ReadCoord());
     int deathtype = ReadInt24_t();
+    bool friendlyfire = ReadByte();
     return = true;
     if (autocvar_cl_damagetext) {
+        if (friendlyfire && !autocvar_cl_damagetext_friendlyfire) {
+            return;
+        }
         if (autocvar_cl_damagetext_accumulate_range) {
             for (entity e = findradius(location, autocvar_cl_damagetext_accumulate_range); e; e = e.chain) {
                 if (e.instanceOfDamageText && e.m_group == group) {
@@ -134,7 +150,7 @@ NET_HANDLE(damagetext, bool isNew)
                 }
             }
         }
-        NEW(DamageText, group, location, health, armor, deathtype);
+        NEW(DamageText, group, location, health, armor, deathtype, friendlyfire);
     }
 }
 #endif
@@ -174,6 +190,17 @@ CLASS(XonoticDamageTextSettings, XonoticTab)
                 setDependent(e, "cl_damagetext", 1, 1);
             this.TD(this, 2, 2, e = makeXonoticColorpickerString("cl_damagetext_color", "cl_damagetext_color"));
                 setDependent(e, "cl_damagetext", 1, 1);
+        this.TR(this);
+        this.TR(this);
+        // friendly fire
+            this.TD(this, 1, 3, e = makeXonoticCheckBox(0, "cl_damagetext_friendlyfire", _("Draw damage numbers for friendly fire")));
+                setDependent(e, "cl_damagetext", 1, 1);
+        this.TR(this);
+            this.TD(this, 1, 1, e = makeXonoticTextLabel(0, _("Color (Friendly Fire):")));
+                setDependentAND(e, "cl_damagetext", 1, 1, "cl_damagetext_friendlyfire", 1, 1);
+            this.TD(this, 2, 2, e = makeXonoticColorpickerString("cl_damagetext_friendlyfire_color", "cl_damagetext_friendlyfire_color"));
+                setDependentAND(e, "cl_damagetext", 1, 1, "cl_damagetext_friendlyfire", 1, 1);
+        this.TR(this);
     }
 ENDCLASS(XonoticDamageTextSettings)
 #endif
index e0ae539318c3db8dd949079bf789dda1521a9e43..b8fd7430988464796cd9e9f7aa8af43dfd11b2c9 100644 (file)
@@ -62,8 +62,7 @@ void W_HeavyMachineGun_Attack_Auto(Weapon thiswep, entity actor, .entity weapone
                return;
        }
 
-       if(!thiswep.wr_checkammo1(thiswep, actor))
-       if(!(actor.items & IT_UNLIMITED_WEAPON_AMMO))
+       if((!thiswep.wr_checkammo1(thiswep, actor) && !(actor.items & IT_UNLIMITED_WEAPON_AMMO)) || (!(actor.items & IT_SUPERWEAPON) && !(actor.items & IT_UNLIMITED_SUPERWEAPONS)))
        {
                W_SwitchWeapon_Force(actor, w_getbestweapon(actor));
                w_ready(thiswep, actor, weaponentity, fire);
index f515a75f9fbbb09c17bd5abc78ef07312650372d..5bea38c5b806d97f49594f911be68d64636ceeda 100644 (file)
@@ -23,13 +23,19 @@ void _Movetype_Physics_Toss(entity this, float dt)  // SV_Physics_Toss
 
        _Movetype_CheckVelocity(this);
 
-       if (this.move_movetype == MOVETYPE_BOUNCE || this.move_movetype == MOVETYPE_TOSS)
+       /*if (this.move_movetype == MOVETYPE_BOUNCE || this.move_movetype == MOVETYPE_TOSS)
        {
                this.move_didgravity = 1;
                this.move_velocity_z -= (GAMEPLAYFIX_GRAVITYUNAFFECTEDBYTICRATE ? 0.5 : 1)
                    * dt
                    * (this.gravity ? this.gravity : 1)
                    * PHYS_GRAVITY(this);
+       }*/
+
+       if (this.move_movetype == MOVETYPE_BOUNCE || this.move_movetype == MOVETYPE_TOSS)
+       {
+               this.move_didgravity = true;
+               this.move_velocity_z -= (((this.gravity) ? this.gravity : 1) * PHYS_GRAVITY(this) * dt);
        }
 
        this.move_angles = this.move_angles + this.move_avelocity * dt;
@@ -108,8 +114,8 @@ void _Movetype_Physics_Toss(entity this, float dt)  // SV_Physics_Toss
                        break;
        }
 
-       if (GAMEPLAYFIX_GRAVITYUNAFFECTEDBYTICRATE && this.move_didgravity > 0 && !(this.move_flags & FL_ONGROUND))
-               this.move_velocity_z -= 0.5 * dt * (this.gravity ? this.gravity : 1) * PHYS_GRAVITY(this);
+       //if (GAMEPLAYFIX_GRAVITYUNAFFECTEDBYTICRATE && this.move_didgravity > 0 && !(this.move_flags & FL_ONGROUND))
+       //      this.move_velocity_z -= 0.5 * dt * (this.gravity ? this.gravity : 1) * PHYS_GRAVITY(this);
 
        _Movetype_CheckWaterTransition(this);
 }
index 9e1a84771d1ddb57cc40a44e0e4978de7312c7a1..9c0f40210cc9b8d063c296d811730277fd4dd8fe 100644 (file)
@@ -186,7 +186,7 @@ bool racer_frame(entity this)
 
        traceline(vehic.origin, vehic.origin + '0 0 1', MOVE_NOMONSTERS, this);
        int cont = trace_dpstartcontents;
-       if(cont & DPCONTENTS_WATER)
+       if(!(cont & DPCONTENTS_WATER))
                vehic.air_finished = time + autocvar_g_vehicle_racer_water_time;
 
        if(IS_DEAD(vehic))
index ab69c3c0d54952bca6ad226a9739c299381bd676..eedadfcebb51a7b7f70849d733be80d38f75f216 100644 (file)
@@ -47,6 +47,8 @@ float autocvar_g_vehicle_raptor_speed_up = 1700;
 float autocvar_g_vehicle_raptor_speed_down = 1700;
 float autocvar_g_vehicle_raptor_friction = 2;
 
+bool autocvar_g_vehicle_raptor_swim = false;
+
 float autocvar_g_vehicle_raptor_cannon_turnspeed = 120;
 float autocvar_g_vehicle_raptor_cannon_turnlimit = 20;
 float autocvar_g_vehicle_raptor_cannon_pitchlimit_up = 12;
@@ -726,6 +728,9 @@ METHOD(Raptor, vr_spawn, void(Raptor thisveh, entity instance))
     instance.solid               = SOLID_SLIDEBOX;
     instance.vehicle_energy = 1;
 
+    if(!autocvar_g_vehicle_raptor_swim)
+       instance.dphitcontentsmask |= DPCONTENTS_LIQUIDSMASK;
+
     instance.PlayerPhysplug = raptor_frame;
 
     instance.bomb1.gun1.avelocity_y = 90;
index c4a78fa568802c305e763aedca9e96eb59bfb595..f0aebabc2ee42196281e5ed7db578f0a390d33c8 100644 (file)
                                return 1;
                        }
                }
-               return SUPER(Dialog).keyDown(me, key, ascii, shift);
+               float r = SUPER(Dialog).keyDown(me, key, ascii, shift);
+               if (!me.closable && key == K_ESCAPE)
+                       return 1;
+               return r;
        }
index 3840721e35f9a032ab3f008471bb53e22a806802..37c46240f77fdcd8bf704b1b6d999aaa3de5e254 100644 (file)
@@ -20,7 +20,8 @@
        float InputContainer_keyDown(entity me, float scan, float ascii, float shift)
        {
                entity f, ff;
-               if (SUPER(InputContainer).keyDown(me, scan, ascii, shift)) return 1;
+               if (SUPER(InputContainer).keyDown(me, scan, ascii, shift))
+                       return 1;
                if (scan == K_ESCAPE)
                {
                        f = me.focusedChild;
index 96d98b9c502149cfe54d18461cbc08ec9ff0c1e6..9b617ab8a16eaa421a050b3732bb7890801af3b6 100644 (file)
@@ -270,7 +270,8 @@ void m_keydown(float key, float ascii)
        else
        {
                draw_reset_cropped();
-               if (!mouseButtonsPressed && key >= K_MOUSE1 && key <= K_MOUSE3) main.mousePress(main, menuMousePos);
+               if (!mouseButtonsPressed && key >= K_MOUSE1 && key <= K_MOUSE3)
+                       main.mousePress(main, menuMousePos);
                if (!main.keyDown(main, key, ascii, menuShiftState))
                {
                        // disable menu on unhandled ESC
index 867f77b8402b797db0297b0e34c7343aff1a8b20..577c8225803461225c818ce07f6cf396d1806f10 100644 (file)
@@ -79,6 +79,7 @@
 #include <menu/xonotic/dialog_singleplayer.qc>
 #include <menu/xonotic/dialog_singleplayer_winner.qc>
 #include <menu/xonotic/dialog_teamselect.qc>
+#include <menu/xonotic/dialog_uid2name.qc>
 #include <menu/xonotic/gametypelist.qc>
 #include <menu/xonotic/hudskinlist.qc>
 #include <menu/xonotic/image.qc>
index adfefc05d7d5210ff1edd713b751a79afca1bf05..b6e34eff247606d774eb1d321fe9f7539071d3ff 100644 (file)
@@ -79,6 +79,7 @@
 #include <menu/xonotic/dialog_singleplayer.qh>
 #include <menu/xonotic/dialog_singleplayer_winner.qh>
 #include <menu/xonotic/dialog_teamselect.qh>
+#include <menu/xonotic/dialog_uid2name.qh>
 #include <menu/xonotic/gametypelist.qh>
 #include <menu/xonotic/hudskinlist.qh>
 #include <menu/xonotic/image.qh>
index 9320a6ebf2101603fe79e478d3b1abf347f8fe7e..8ee51fde97405b4a424ff79f699c3fd6ded25684 100644 (file)
@@ -46,6 +46,7 @@ void XonoticVideoSettingsTab_fill(entity me)
                        e.addValue(e, ZCTX(_("SZ^Gigantic")), "0.75");
                        e.addValue(e, ZCTX(_("SZ^Colossal")), "1");
                        e.configureXonoticTextSliderValues(e);
+                       e.applyButton = videoApplyButton;
        me.TR(me);
                me.TD(me, 1, 1, e = makeXonoticTextLabel(0, _("Color depth:")));
                me.TD(me, 1, 2, e = makeXonoticTextSlider_T("vid_bitsperpixel",
diff --git a/qcsrc/menu/xonotic/dialog_uid2name.qc b/qcsrc/menu/xonotic/dialog_uid2name.qc
new file mode 100644 (file)
index 0000000..1cd77b0
--- /dev/null
@@ -0,0 +1,18 @@
+#include "dialog_uid2name.qh"
+
+#include "textlabel.qh"
+#include "commandbutton.qh"
+
+void XonoticUid2NameDialog_fill(entity me)
+{
+       entity e;
+       me.TR(me);
+               me.TD(me, 1, 2, makeXonoticTextLabel(0.5, _("Allow player statistics to use your nickname?")));
+       me.TR(me);
+               me.TD(me, 1, 2, makeXonoticTextLabel(0.5, _("Answering \"No\" you will appear as \"Anonymous player\"")));
+       me.TR(me);
+       me.TR(me);
+               me.TD(me, 1, 1, e = makeXonoticCommandButton(_("Yes"), '0 0 0', "vyes; setreport cl_allow_uid2name 1", COMMANDBUTTON_CLOSE));
+                       e.preferredFocusPriority = 1;
+               me.TD(me, 1, 1, e = makeXonoticCommandButton(_("No"), '0 0 0', "vno; setreport cl_allow_uid2name 0", COMMANDBUTTON_CLOSE));
+}
diff --git a/qcsrc/menu/xonotic/dialog_uid2name.qh b/qcsrc/menu/xonotic/dialog_uid2name.qh
new file mode 100644 (file)
index 0000000..4bec3d1
--- /dev/null
@@ -0,0 +1,13 @@
+#pragma once
+
+#include "rootdialog.qh"
+CLASS(XonoticUid2NameDialog, XonoticRootDialog)
+       METHOD(XonoticUid2NameDialog, fill, void(entity));
+       ATTRIB(XonoticUid2NameDialog, title, string, string_null)
+       ATTRIB(XonoticUid2NameDialog, color, vector, SKINCOLOR_DIALOG_TEAMSELECT)
+       ATTRIB(XonoticUid2NameDialog, intendedWidth, float, 0.5)
+       ATTRIB(XonoticUid2NameDialog, rows, float, 4)
+       ATTRIB(XonoticUid2NameDialog, columns, float, 2)
+       ATTRIB(XonoticUid2NameDialog, name, string, "Uid2Name")
+       ATTRIB(XonoticUid2NameDialog, closable, float, 0)
+ENDCLASS(XonoticUid2NameDialog)
index fb25eebdef39bc2d4bc92cb5b1fd78d0f33c767e..0e071c2e71efc20321722e13b4246f46ec81cfda 100644 (file)
@@ -39,6 +39,7 @@
 #include "dialog_sandboxtools.qh"
 #include "dialog_monstertools.qh"
 #include "dialog_teamselect.qh"
+#include "dialog_uid2name.qh"
 #include "dialog_singleplayer.qh"
 #include "dialog_multiplayer.qh"
 #include "dialog_settings.qh"
@@ -224,6 +225,10 @@ void MainWindow_configureMainWindow(entity me)
        i.configureDialog(i);
        me.addItemCentered(me, i, i.intendedWidth * eX + i.intendedHeight * eY, SKINALPHAS_MAINMENU_z);
 
+       i = NEW(XonoticUid2NameDialog);
+       i.configureDialog(i);
+       me.addItemCentered(me, i, i.intendedWidth * eX + i.intendedHeight * eY, SKINALPHAS_MAINMENU_z);
+
        i = NEW(XonoticMonsterToolsDialog);
        i.configureDialog(i);
        me.addItemCentered(me, i, i.intendedWidth * eX + i.intendedHeight * eY, SKINALPHAS_MAINMENU_z * SKINALPHA_DIALOG_SANDBOXTOOLS);
index 4d704606d31275d4281b03e2fdb1f66c864bd6d4..e1ac53a29859b0246ec2037ed8bc156640e410b3 100644 (file)
@@ -429,6 +429,12 @@ void UpdateNotification_URI_Get_Callback(float id, float status, string data)
                }
        }
 
+       if(un_bannedservers != "")
+       {
+               _Nex_ExtResponseSystem_BannedServers = strzone(un_bannedservers);
+               _Nex_ExtResponseSystem_BannedServersNeedsRefresh = 1;
+       }
+
        if(un_emergency_pk3s != "")
        {
                _Nex_ExtResponseSystem_Packs = strzone(un_emergency_pk3s);
index b10ea960c5b16d6ed9370d3e84413cc14b586903..d813391bd6e32be463258c7f607ec59d735aca09 100644 (file)
@@ -1735,7 +1735,6 @@ bool SpectatePrev(entity this)
                    ent = M_ARGV(1, entity);
                    break;
                case MUT_SPECPREV_RETURN:
-                   ent = M_ARGV(1, entity);
                    return true;
                case MUT_SPECPREV_CONTINUE:
                default:
@@ -2388,7 +2387,7 @@ void DrownPlayer(entity this)
        if(IS_DEAD(this))
                return;
 
-       if (this.waterlevel != WATERLEVEL_SUBMERGED)
+       if (this.waterlevel != WATERLEVEL_SUBMERGED || this.vehicle)
        {
                if(this.air_finished < time)
                        PlayerSound(this, playersound_gasp, CH_PLAYER, VOICETYPE_PLAYERSOUND);
index 4c54dddaa6901f137e28772c913bac6d1b6d0d2b..ae823f7bdb99705ccccf33c273e37162df43dffe 100644 (file)
@@ -494,11 +494,14 @@ void PlayerDamage(entity this, entity inflictor, entity attacker, float damage,
                valid_damage_for_weaponstats = 1;
        }
 
+       dh = dh - max(this.health, 0);
+       da = da - max(this.armorvalue, 0);
        if(valid_damage_for_weaponstats)
        {
-               dh = dh - max(this.health, 0);
-               da = da - max(this.armorvalue, 0);
                WeaponStats_LogDamage(awep.m_id, abot, PS(this).m_weapon.m_id, vbot, dh + da);
+       }
+       if (dh + da)
+       {
                MUTATOR_CALLHOOK(PlayerDamaged, attacker, this, dh, da, hitloc, deathtype);
        }
 
index 2a8da29c275210b8646a31ba08bae7a0a6bc3d1f..6e302a177909ba45f86578aeaea202bc1267bef4 100644 (file)
@@ -307,7 +307,7 @@ void ca_LastPlayerForTeam_Notify(entity this)
 MUTATOR_HOOKFUNCTION(ca, PlayerDies)
 {
        entity frag_target = M_ARGV(2, entity);
-       
+
        ca_LastPlayerForTeam_Notify(frag_target);
        if (!allowed_to_spawn)
                frag_target.respawn_flags =  RESPAWN_SILENT;
@@ -340,6 +340,8 @@ MUTATOR_HOOKFUNCTION(ca, MakePlayerObserver)
                player.caplayer = 0;
        if (player.caplayer)
                player.frags = FRAGS_LMS_LOSER;
+    else
+        player.frags = FRAGS_SPECTATOR;
        if (!warmup_stage)
                eliminatedPlayers.SendFlags |= 1;
        return true;  // prevent team reset
@@ -439,11 +441,11 @@ MUTATOR_HOOKFUNCTION(ca, SpectateSet)
 MUTATOR_HOOKFUNCTION(ca, SpectateNext)
 {
     entity client = M_ARGV(0, entity);
-    entity targ = M_ARGV(1, entity);
 
        if (!autocvar_g_ca_spectate_enemies && client.caplayer)
        {
-               targ = CA_SpectateNext(client, targ);
+               entity targ = M_ARGV(1, entity);
+               M_ARGV(1, entity) = CA_SpectateNext(client, targ);
                return true;
        }
 }
@@ -468,6 +470,8 @@ MUTATOR_HOOKFUNCTION(ca, SpectatePrev)
                }
        }
 
+       M_ARGV(1, entity) = targ;
+
        return MUT_SPECPREV_FOUND;
 }
 
index 787412908513449a6f5c28a81d4a47557ca95023..0d516b262623c6f5489d665977ed68c34b7f312a 100644 (file)
@@ -60,11 +60,12 @@ spawnfunc(tdm_team)
 // code from here on is just to support maps that don't have team entities
 void tdm_SpawnTeam (string teamname, float teamcolor)
 {
-       entity this = new(tdm_team);
+       entity this = new_pure(tdm_team);
        this.netname = teamname;
        this.cnt = teamcolor;
+       this.team = this.cnt + 1;
        this.spawnfunc_checked = true;
-       spawnfunc_tdm_team(this);
+       //spawnfunc_tdm_team(this);
 }
 
 void tdm_DelayedInit(entity this)
index fded1d7b478345df64353e196968e8a208646462..32e9a5670299b9dc00de52256f5081c3b77d49ca 100644 (file)
@@ -408,6 +408,7 @@ bool forbidWeaponUse(entity player)
        if (time < game_starttime && !autocvar_sv_ready_restart_after_countdown) return true;
        if (round_handler_IsActive() && !round_handler_IsRoundStarted()) return true;
        if (player.player_blocked) return true;
+       if (gameover) return true;
        if (STAT(FROZEN, player)) return true;
        if (player.weapon_blocked) return true;
        return false;
index 822be77f722a64a13f84fb61c961322debbc854a..8df3e2a55883c619162445816cf69237b0210b91 100644 (file)
@@ -1,10 +1,7 @@
-fireball
+fireball_plasma
 {
-       {
-               map textures/fireball
-               tcgen environment
-       }
-       {
-               map $lightmap
-       }
+ {
+       map textures/fireball_plasma.tga
+       tcMod scroll 0.03 0.001
+ }
 }
index 53b47a192cc15ed112834ccc703459006e1c0260..c631e8c880dc98a903d13d2683e7ef0dacd54cf6 100644 (file)
Binary files a/textures/fireball.tga and b/textures/fireball.tga differ
index 8cd8b25bdc50041f5a84b7519551802a32a5c3db..eaf50d0a2e63d8f4a51c8ff2f26fe4d33d158d1d 100644 (file)
Binary files a/textures/fireball_gloss.tga and b/textures/fireball_gloss.tga differ
index c949f92a47d69059cfdadd94a810b87785abadb0..358784d8fd784613e6766861f34404b496b92150 100644 (file)
Binary files a/textures/fireball_glow.tga and b/textures/fireball_glow.tga differ
diff --git a/textures/fireball_norm.tga b/textures/fireball_norm.tga
new file mode 100644 (file)
index 0000000..b0bd3f9
Binary files /dev/null and b/textures/fireball_norm.tga differ
diff --git a/textures/fireball_pants.tga b/textures/fireball_pants.tga
new file mode 100644 (file)
index 0000000..2fbc09a
Binary files /dev/null and b/textures/fireball_pants.tga differ
diff --git a/textures/fireball_shirt.tga b/textures/fireball_shirt.tga
new file mode 100644 (file)
index 0000000..3d93916
Binary files /dev/null and b/textures/fireball_shirt.tga differ