View Single Post
FlaminSarge
Veteran Member
Join Date: Jul 2010
Old 09-05-2011 , 20:34   Re: [TF2Items] Give Weapon (v2.7, 02/24/2011)
Reply With Quote #6

Quote:
Originally Posted by FlaminSarge View Post
The ammo literally *sets* on giving the weapon, so I set it to what it would be after applying possible ammo attributes.
Quote:
Originally Posted by Bwuce Lee View Post
when is your bethehorsemann going to be released?
Clearly the quote is related to your question. Clearly.

I sent a tester the plugin, and he's gonna test it for a bit. It's done.

GorRageBoy: I'll paste the code here for what you're trying to do.

PHP Code:
public Action:Command_WeaponBase(clientweaponLookupIndexweaponSlot)
{
    switch (
weaponLookupIndex)
    {
        case 
2171:
        {
            if (
TF2_GetPlayerClass(client) != TFClass_Sniper)
            {
                  
PrintToChat(client"[TF2Items] Item index %d cannot be used with your current class."weaponLookupIndex);
                  return;
            }
        }
    }
    
decl String:strSteamID[32];
    new 
weaponIndex;
    while ((
weaponIndex GetPlayerWeaponSlot(clientweaponSlot)) != -1)
    {... 
If it's givew_ex'd, they'd get the message every time they respawned/touched a locker.
__________________
Bread EOTL GunMettle Invasion Jungle Inferno 64-bit will break everything. Don't even ask.

All plugins: Randomizer/GiveWeapon, ModelManager, etc.
Post in plugin threads with questions.
Steam is for playing games.
You will be fed to javalia otherwise.
Psyduck likes replays.

Last edited by FlaminSarge; 09-05-2011 at 20:56.
FlaminSarge is offline