mirror of
https://github.com/nzp-team/quakec.git
synced 2025-02-21 19:21:54 +00:00
SERVER: Fix for PaP giving duplicate primary weapon if there's no secondary
This commit is contained in:
parent
c3c2bfe65c
commit
8fc831684b
1 changed files with 6 additions and 2 deletions
|
@ -1943,8 +1943,12 @@ void touch_pap() {
|
||||||
useprint (other, 7, 0, 0);
|
useprint (other, 7, 0, 0);
|
||||||
|
|
||||||
if (other.button7) {
|
if (other.button7) {
|
||||||
if (!other.secondaryweapon) {
|
// Back-up current weapon into second slot, it's getting replaced.
|
||||||
WeaponSwitch(other);
|
if (!other.secondaryweapon && other.weapon != EqualPapWeapon(self.weapon)) {
|
||||||
|
other.secondaryweapon = other.weapon;
|
||||||
|
other.secondarymag = other.currentmag;
|
||||||
|
other.secondarymag2 = other.currentmag2;
|
||||||
|
other.secondaryammo = other.currentammo;
|
||||||
}
|
}
|
||||||
|
|
||||||
other.weapon = EqualPapWeapon(self.weapon);
|
other.weapon = EqualPapWeapon(self.weapon);
|
||||||
|
|
Loading…
Reference in a new issue