X-Git-Url: http://de.git.xonotic.org/?p=xonotic%2Fxonotic-data.pk3dir.git;a=blobdiff_plain;f=qcsrc%2Fserver%2Fclient.qc;h=b27ce6af9bc14dc2010720dc5571eafb7b59cbaa;hp=9d5be4c80f3cb432d32fd3939aedd59327bbb6e8;hb=85ee0c0e1aaa7dfd84ca4e40edf6fb6ee1049dca;hpb=53911d2ce2724f2da23fb6806e491ce795ae4326 diff --git a/qcsrc/server/client.qc b/qcsrc/server/client.qc index 9d5be4c80f..b27ce6af9b 100644 --- a/qcsrc/server/client.qc +++ b/qcsrc/server/client.qc @@ -338,6 +338,7 @@ void PutObserverInServer(entity this) this.items = 0; this.weapons = '0 0 0'; + this.dual_weapons = '0 0 0'; this.drawonlytoclient = this; this.weaponmodel = ""; @@ -572,6 +573,8 @@ void PutClientInServer(entity this) } SetSpectatee_status(this, 0); + this.dual_weapons = '0 0 0'; + this.superweapons_finished = (this.weapons & WEPSET_SUPERWEAPONS) ? time + autocvar_g_balance_superweapons_time : 0; this.items = start_items; @@ -714,7 +717,7 @@ void PutClientInServer(entity this) for(int slot = 0; slot < MAX_WEAPONSLOTS; ++slot) { .entity weaponentity = weaponentities[slot]; - if(slot == 0) + if(slot == 0 || autocvar_g_weaponswitch_debug == 1) this.(weaponentity).m_switchweapon = w_getbestweapon(this, weaponentity); else this.(weaponentity).m_switchweapon = WEP_Null; @@ -1694,6 +1697,7 @@ void SpectateCopy(entity this, entity spectatee) this.superweapons_finished = spectatee.superweapons_finished; STAT(PRESSED_KEYS, this) = STAT(PRESSED_KEYS, spectatee); this.weapons = spectatee.weapons; + this.dual_weapons = spectatee.dual_weapons; this.vortex_charge = spectatee.vortex_charge; this.vortex_chargepool_ammo = spectatee.vortex_chargepool_ammo; this.hagar_load = spectatee.hagar_load; @@ -2381,6 +2385,13 @@ void PlayerPreThink (entity this) } } else { if (frametime) player_anim(this); + + if (this.respawn_flags & RESPAWN_DENY) + { + STAT(RESPAWN_TIME, this) = 0; + return; + } + bool button_pressed = (PHYS_INPUT_BUTTON_ATCK(this) || PHYS_INPUT_BUTTON_JUMP(this) || PHYS_INPUT_BUTTON_ATCK2(this) || PHYS_INPUT_BUTTON_HOOK(this) || PHYS_INPUT_BUTTON_USE(this)); switch(this.deadflag)