Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Release Obtain weapons and perks
#11
(09-02-2012, 20:31)Cyborgking Wrote:
(09-02-2012, 20:25)wise Wrote: probably late to the game but I'm tweaking Cyborg's AI mod and added several new purchaseable weapons/perks. Only problem is, I can't seem to set the max ammo of the weapons.

I'm using the following snippet:

Code:
else if( response == "buy_commando")
        {
            if (self.money >= 250)
            {
                self playSoundToPlayer("zmb_cha_ching", self);
                self closeMenu( game[ "modmenu1" ] );
                self giveWeapon("commando_dualclip_mp");  
                self.money -= 250;
                self setWeaponAmmoStock("commando_dualclip_mp",720);
                self.hud_score_value setValue(self.money);              
                self thread maps\mp\gametypes\aico::ScoreHUD( -250 );
                self playSoundToPlayer("zmb_cha_ching", self);
                self iPrintln("Commando purchased");
                
            }
            else
                self playSoundToPlayer("zmb_no_cha_ching", self);
        }

it'll give me the weapon and take 250 "points" from the player, but never gives them more than the 240/120 ammo.

any ideas?
It'll always give as much ammo as the max ammo. If you want to increase the max ammo you'd want to create a custom version of the commando.

So the way you do it for unlimited ammo is created a custom weapon for each?

that doesn't seem very efficient or am I missing something with that whole process?
Reply



Possibly Related Threads…
Thread Author Replies Views Last Post
  [Release] [SOURCE] Random Weapons. [HARD] Tony. 1 4,106 11-08-2013, 11:11
Last Post: Nekochan
  Help source random weapons [HARD] Tony. 4 4,699 11-08-2013, 05:25
Last Post: [HARD] Tony.
  MW3 Hide WEAPONS [HARD] Tony. 7 7,170 10-09-2013, 15:16
Last Post: [HARD] Tony.
  Porting some weapons, ADS broken? DidUknowiPwn 0 2,390 09-10-2013, 01:13
Last Post: DidUknowiPwn
  [Request] Mw2 lock weapons seraph1995 1 3,330 08-18-2013, 15:31
Last Post: DidUknowiPwn
  [Release] Pack-A-Punch Weapons TheSchitt 40 31,587 08-07-2013, 04:51
Last Post: FrostLight
  Help DONATE points for weapons [HARD] Tony. 10 7,449 05-24-2013, 10:59
Last Post: Pozzuh
  [Tutorial] How to import Weapons from SP to MP in Black Ops using Mod Tools d0h! 114 76,779 05-21-2013, 16:33
Last Post: ZURA.
  [Tutorial] How to port weapons rotceh_dnih 13 15,495 04-13-2013, 23:43
Last Post: rotceh_dnih
  Help Perks do not work (( x1412 6 4,393 04-06-2013, 18:09
Last Post: x1412

Forum Jump:


Users browsing this thread:
1 Guest(s)

Forum Powered By MyBB, Theme by © 2002-2024 Melroy van den Berg.