hi, it's me agaiin. i've ran into a few problems with adding commands into the admin menu for my plugin.
a cut out version of my code:
Code:
public Action:Give_Weapon(client, arg)
{
decl String:target[10], String:weapon_Name[40], playerId;
GetCmdArg(1, weapon_Name, sizeof(weapon_Name));
GetCmdArg(2, target, sizeof(target));
playerId = StringToInt(target);
new Ent = CreateEntityByName(weapon_Name);
if(IsValidEntity(Ent))
{
DispatchSpawn(Ent);
EquipPlayerWeapon(playerId, Ent);
Bypass_And_Execute(playerId, "givecurrentammo", "");
}
}
when i tried to use this from the ingame chat or console itself (typed myself) it works, it spawns a weapon for the player, and when the player kills with that weapon, it displays the correct image on the top right hand corner when i killed someone. but when i added the command to the custom admin menu config, whenever i try to spawn a weapon from the admin menu and uses it to kill someone, it shows a skull image on the top right hand corner instead of the usual image which resembles the weapon i use to kill. i tried using the "give" command from the game to give weapons, it seems that counter strike source removed the cheat flag from the command but gave it some other, nothing happens when i strips the cheat flag from it and try to give weapon with that command. can anyone please help me?