Raised This Month: $ Target: $400
 0% 

[L4D2] Set Ammo


Post New Thread Reply   
 
Thread Tools Display Modes
Author
n491
Junior Member
Join Date: Sep 2015
Plugin ID:
5613
Plugin Version:
1.1
Plugin Category:
Server Management
Plugin Game:
Left 4 Dead
Plugin Dependencies:
    Servers with this Plugin:
     
    Plugin Description:
    This plugin was created for Speedrunner Tools addon to add the desired number of ammo.
    Old 04-28-2017 , 15:53   [L4D2] Set Ammo
    Reply With Quote #1

    Installation:
    server/cfg/sourcemod/plugins/sm_setammo.smx

    Commands:
    sm_setammo arg1 arg2 arg3 arg4 arg5

    Usage:
    Command "sm_setammo" is a server-side, therefore must be used in the server console.
    1st argument - client index (1-32);
    2nd argument - weapon slot, primary or secondary (0, 1);
    3rd argument - clip size (integer);
    4th argument - ammo (integer);
    5th argument - clip size of upgrade ammo (integer).

    Example of usage in "g_STLib.Funcs.Inventory()" of Speedrunner Tools addon:
    Code:
    hPlayer.GiveItem("smg");
    hPlayer.GiveItem("pistol");
    SetAmmo(hPlayer, 0, 25, 650, 25);
    SetAmmo(hPlayer, 1, 5);
    NOTE: Before adding number of upgrade ammo, it is necessary to have it in your weapon.

    Links:
    Speedrunner Tools: http://steamcommunity.com/sharedfile.../?id=510955402
    Attached Files
    File Type: sp Get Plugin or Get Source (sm_setammo.sp - 1875 views - 3.7 KB)

    Last edited by n491; 08-16-2018 at 09:28.
    n491 is offline
    Pyc
    Senior Member
    Join Date: Jan 2014
    Old 04-29-2017 , 17:46   Re: [L4D2] Set Ammo
    Reply With Quote #2

    work clip size with m60?
    Pyc is offline
    n491
    Junior Member
    Join Date: Sep 2015
    Old 04-29-2017 , 21:53   Re: [L4D2] Set Ammo
    Reply With Quote #3

    Quote:
    Originally Posted by Pyc View Post
    work clip size with m60?
    Yes, "sm_setammo 1 0 155".
    n491 is offline
    Pyc
    Senior Member
    Join Date: Jan 2014
    Old 05-05-2017 , 11:45   Re: [L4D2] Set Ammo
    Reply With Quote #4

    Quote:
    Originally Posted by n491 View Post
    Yes, "sm_setammo 1 0 155".
    possible >250 bullets?
    Pyc is offline
    n491
    Junior Member
    Join Date: Sep 2015
    Old 05-05-2017 , 12:06   Re: [L4D2] Set Ammo
    Reply With Quote #5

    Quote:
    Originally Posted by Pyc View Post
    possible >250 bullets?
    Maybe, try to test
    n491 is offline
    Reply



    Posting Rules
    You may not post new threads
    You may not post replies
    You may not post attachments
    You may not edit your posts

    BB code is On
    Smilies are On
    [IMG] code is On
    HTML code is Off

    Forum Jump


    All times are GMT -4. The time now is 11:35.


    Powered by vBulletin®
    Copyright ©2000 - 2024, vBulletin Solutions, Inc.
    Theme made by Freecode