View Single Post
Dr!fter
The Salt Boss
Join Date: Mar 2007
Old 03-19-2014 , 13:50   Re: CS:GO GiveNamedItem Econ
Reply With Quote #17

Quote:
Originally Posted by Dr!fter View Post
The aim was so that plugins didnt have to add the other options they would select there preferred one in loadout. Example you could add "M4" to the deathmatch menu, then when the player selected it would give the m4 they want (m4a1 or m4a4). It was to simplify how that worked if you wanted something else you would simply change your loadout.

For custom knives I assume you are using a plugin to give them to players. I will think about adding a forward so that you can override the loadout stuff.

I have no idea what fast weapon equip is and I dont see how this would change it. This simply changes the weapon before its given. Nothing else.
Just to clarify what i meant by "override the loadout stuff" Is to allow using the loadout or not. If I dont clear that up Im sure I would get more pm's about changing skins.

Quote:
Originally Posted by klexen View Post
It would be really cool if you could add something to override the loadout stuff.

The "Fast Switch" feature I'm talking about is used in this Deathmatch plugin.

Here is what the function looks like:

Code:
stock players_FastSwitch(clientIndex, weaponId)
{
    new sequence = 0;
    
    if (weaponId == g_iPlayers_WeaponIndex_M4a1S)
        sequence = 1;
    
    SetEntData(clientIndex, g_iPlayers_NextAttackOffset, GetGameTime());
   
    SetEntData(GetEntDataEnt2(clientIndex, g_iPlayers_ViewModelOffset), g_iPlayers_ViewModel_SequenceOffset, sequence);
}
Its not related to this extension, idk if its not calling it or what but, telling the author of the plugin is a better option. All this does is check if a loadout exists if not it grabs the players loadout and uses it when giving the item.

Last edited by Dr!fter; 03-19-2014 at 13:51.
Dr!fter is offline