Skip to content
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Donate
Collapse

Plutonium

  1. Home
  2. BO1 Modding Releases & Resources
  3. BO3's System for Max Ammo for BO1

BO3's System for Max Ammo for BO1

Scheduled Pinned Locked Moved BO1 Modding Releases & Resources
1 Posts 1 Posters 44 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • Coronavirus-19undefined Offline
    Coronavirus-19undefined Offline
    Coronavirus-19
    wrote last edited by Coronavirus-19
    #1

    This script overrides the max ammo to function like BO3's Max Ammo!

    Installation

    Plutonium/storage/t5/scripts/sp

    Max Ammo GSC

    Raw Code

    #include maps\_utility;
    
    init()
    {
        level thread on_player_connect();
    }
    
    on_player_connect()
    {
        for (;;)
        {
            level waittill("connected", player);
            player thread max_ammo_clip_fix();
        }
    }
    
    max_ammo_clip_fix()
    {
        self endon("disconnect");
    
        lastAmmoCheck = [];
    
        for (;;)
        {
            wait 0.1;
    
            weapons = self getweaponslist();
    
            i = 0;
            while (i < weapons.size)
            {
                weapon = weapons[i];
    
                if (!self hasweapon(weapon))
                {
                    i++;
                    continue;
                }
    
                ammo = self getweaponammostock(weapon);
                maxAmmo = weaponmaxammo(weapon);
    
                // Init tracking
                if (!isDefined(lastAmmoCheck[weapon]))
                    lastAmmoCheck[weapon] = ammo;
    
                // Detect Max Ammo refill
                if (ammo == maxAmmo && lastAmmoCheck[weapon] < maxAmmo)
                {
                    self setweaponammoclip(weapon, weaponclipsize(weapon));
                }
    
                lastAmmoCheck[weapon] = ammo;
                i++;
            }
        }
    }
    
    
    1 Reply Last reply
    0
    Reply
    • Reply as topic
    Log in to reply
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes


    • Login

    • Don't have an account? Register

    • Login or register to search.
    • First post
      Last post
    0
    • Recent
    • Tags
    • Popular
    • Users
    • Groups
    • Donate