diff --git a/quakec/fallout2/cmds.qc b/quakec/fallout2/cmds.qc index aa29552c1..8f7613580 100644 --- a/quakec/fallout2/cmds.qc +++ b/quakec/fallout2/cmds.qc @@ -1022,7 +1022,35 @@ void(string arg1) Cmd_InvMix = sprint(self, PRINT_MEDIUM, "1 super stim created\n"); sound (self, CHAN_BODY, "misc/item1.wav", 1, ATTN_NORM); } + else if ((iid1 == IID_WP_NEEDLER && iid2 == IID_WP_NEEDLER) || + (iid2 == IID_WP_NEEDLER && iid1 == IID_WP_NEEDLER)) + { + + + if (random()*100 > (self.skill_science*10)) + { + sprint(self, PRINT_MEDIUM, "your concoction exploded!\n"); + Explosion(); + return; + } + + x = FindEmptySlot(self); + + if (x == 0) + { + sprint(self, 2, "no more room in inventory!\n"); + sound (self, CHAN_BODY, "misc/beep1.wav", 1, ATTN_NORM); + return; + } + + DecreaseDestroySlot(23); + DecreaseDestroySlot(24); + + SetItemSlot(self, x, SlotVal(IID_WP_ACR, 1)); + sprint(self, PRINT_MEDIUM, "Steyr ACR created\n"); + sound (self, CHAN_BODY, "misc/item1.wav", 1, ATTN_NORM); + } else { sprint(self, PRINT_MEDIUM, "cannot merge items!\n"); diff --git a/quakec/fallout2/inventory.qc b/quakec/fallout2/inventory.qc index 2a08b99dc..ce01a0e7d 100644 --- a/quakec/fallout2/inventory.qc +++ b/quakec/fallout2/inventory.qc @@ -561,6 +561,12 @@ float(entity e, float iid) FindSuitableEmptySlot = if (ToIID(e.islot16) == IID_NONE) if (FitsInSlot(16, iid)) return 16; + if (ToIID(e.islot15) == IID_NONE) + if (FitsInSlot(23, iid)) + return 23; + if (ToIID(e.islot16) == IID_NONE) + if (FitsInSlot(24, iid)) + return 24; } else if (IsJunk(iid)) { @@ -576,10 +582,6 @@ float(entity e, float iid) FindSuitableEmptySlot = return 21; if (ToIID(e.islot22) == IID_NONE) return 22; - if (ToIID(e.islot23) == IID_NONE) - return 23; - if (ToIID(e.islot24) == IID_NONE) - return 24; } return 0; }; @@ -635,10 +637,6 @@ slot_t(float slot) SlotField = return islot23; if (slot == 24) return islot24; - if (slot == 25) - return mixslot1; - if (slot == 26) - return mixslot2; //bprint(PRINT_MEDIUM, "ERROR: Invalid slot number (", ftos(slot), ")\n"); return islot1; @@ -1510,31 +1508,31 @@ float(float iid) GetBaseValue = if (iid == IID_AM_NEEDLER) - return 1; + return 7; if (iid == IID_AM_2MMEC) - return 1; + return 15; if (iid == IID_AM_10MM) - return 1; + return 3; if (iid == IID_AM_556MM) - return 1; + return 5; if (iid == IID_AM_5MMHIGHVEL) - return 1; + return 4; if (iid == IID_AM_12GAUGESHELLS) - return 1; + return 4; if (iid == IID_AM_ENERGYCELL) - return 1; + return 12; if (iid == IID_AM_762MM) - return 1; + return 8; if (iid == IID_AM_44MAGNUM) - return 1; + return 6; if (iid == IID_AM_WARSAW) - return 1; + return 5; if (iid == IID_AM_45ACP) - return 1; + return 4; if (iid == IID_AM_ROCKET) - return 1; + return 30; if (iid == IID_AM_CASELESS) - return 1; + return 10; if (iid == IID_GREN_STUN) @@ -2332,10 +2330,7 @@ float(float slotno, float iid) FitsInSlot = return IsJunk(iid); if (slotno == 22) return IsJunk(iid); - if (slotno == 23) - return IsJunk(iid); - if (slotno == 24) - return IsJunk(iid); + return true; }; diff --git a/quakec/fallout2/weapons.qc b/quakec/fallout2/weapons.qc index e7eed3f62..2c716199f 100644 --- a/quakec/fallout2/weapons.qc +++ b/quakec/fallout2/weapons.qc @@ -1641,7 +1641,7 @@ void() W_Attack = else if (weap == IID_WP_AK112_M) FireAssaultRifle(16, 10, "weapons/ak112.wav", 4000, 0.095); else if (weap == IID_WP_ACR) - FireAssaultRifle(16, 7, "weapons/auto2.wav", 9000, 0.090); + FireAssaultRifle(16, 7, "weapons/ak112.wav", 9000, 0.090); else if (weap == IID_WP_AK74) FireAssaultRifle(20, 12, "ogre/ak47.wav", 3500, 0.090); else if (weap == IID_WP_DKS1) @@ -1766,6 +1766,7 @@ void() CheatCommand = self.islot18 = SlotVal(IID_MISC_NUKACOLA, 50); self.islot19 = SlotVal(IID_MISC_AEROSOL, 50); self.islot20 = SlotVal(IID_MISC_GUM, 50); + self.islot10 = SlotVal(IID_WP_ACR, 1); }; /* @@ -2548,9 +2549,9 @@ void () FlashExplode = { if (CanDamage (self, te)) { - te.flash = 4; - te.attack_finished = time + 4; - spawn_excla(te, 4); + te.flash = 12; + te.attack_finished = time + 12; + spawn_excla(te, 12); } } @@ -2561,9 +2562,9 @@ void () FlashExplode = te.missionbrief = 5; stuffcmd (te, "v_cshift 255 255 255 255\n"); stuffcmd (te, "v_idlescale 3\n"); - te.flash = time + 4; + te.flash = time + 12; - spawn_excla(te, 4); + spawn_excla(te, 12); } } te = te.chain; @@ -2580,9 +2581,9 @@ void () FlashExplode = if (dot > 0.3 && CanDamage (self, te)) { - te.flash = 4; - te.attack_finished = time + 4; - spawn_excla(te, 4); + te.flash = 12; + te.attack_finished = time + 12; + spawn_excla(te, 12); } }