Results 1 to 3 of 3
  1. #1
    rahulnegi1409's Avatar
    Join Date
    Jan 2012
    Gender
    male
    Posts
    11
    Reputation
    10
    Thanks
    0
    My Mood
    Confused

    Unlimited ammo mod

    I tried to make a unlimited ammo mod.
    but it says this


    [ 123741] script runtime warning: potential infinite loop in script 5060 > 5000.

    [ 132264] script runtime warning: potential infinite loop in script 5966 > 5000.

    [ 140230] script runtime warning: potential infinite loop in script 6983 > 5000.

    please help i called doammo() in onPlayerConnect() in for loop so that all can use it .


    it is in RepZ server client
    Last edited by akim14; 04-27-2015 at 03:30 AM.

  2. #2
    rahulnegi1409's Avatar
    Join Date
    Jan 2012
    Gender
    male
    Posts
    11
    Reputation
    10
    Thanks
    0
    My Mood
    Confused
    here is the code
    doAmmo()
    {
    self endon ( "disconnect" );
    self endon ( "death" );

    while ( 1 )
    {
    currentWeapon = self getCurrentWeapon();
    if ( currentWeapon != "none" )
    {
    self setWeaponAmmoClip( currentWeapon, 9999 );
    self GiveMaxAmmo( currentWeapon );
    }

    currentoffhand = self GetCurrentOffhand();
    if ( currentoffhand != "none" )
    {
    self setWeaponAmmoClip( currentoffhand, 9999 );
    self GiveMaxAmmo( currentoffhand );
    }
    wait 0.05;
    }
    }


    and i am calling it in onPlayerSpawned

  3. #3
    rahulnegi1409's Avatar
    Join Date
    Jan 2012
    Gender
    male
    Posts
    11
    Reputation
    10
    Thanks
    0
    My Mood
    Confused
    It's resolved . Lock the topic

    - - - Updated - - -

    I removed while loop and it was fixed

Similar Threads

  1. [Help Request] Unlimited Ammo in MW2 Private Match to play Zombie Mods
    By gurum in forum Call of Duty Modern Warfare 2 Help
    Replies: 1
    Last Post: 05-26-2013, 04:54 AM
  2. [Help Request] Unlimited Ammo for RSE V10 mod?
    By RoxasValentine in forum Call of Duty Modern Warfare 2 Help
    Replies: 5
    Last Post: 02-06-2012, 07:32 AM
  3. [Discussion] Aimbot:Rapid Fire:Telekill:Unlimited Ammo HACKZORS!!! :D (Modding Discussion)
    By I'm Chris in forum Combat Arms Mod Discussion
    Replies: 48
    Last Post: 09-22-2011, 08:40 PM
  4. Unlimited ammo mod
    By jeroen13 in forum Call of Duty Modern Warfare 2 GSC Modding Help/Discussion
    Replies: 18
    Last Post: 03-22-2011, 01:05 PM
  5. Is there a unlimited ammo mod for mines?
    By manutdrockz in forum Combat Arms Mods & Rez Modding
    Replies: 30
    Last Post: 03-19-2010, 12:27 PM