00:49:41: [HAMSANDWICH] Function TakeDamage not found. L 03/14/2012 - 00:49:41: [AMXX] Displaying debug trace (plugin "codperk_pierwszabrygada.amxx") L 03/14/2012 - 00:49:41: [AMXX] Run time error 10: native error (native "RegisterHam") L 03/14/2012 - 00:49:41: [AMXX] [0] dd_409059.sma::plugin_init (line 24)
sma perku
/* Plugin generated by AMXX-Studio */
#include <amxmodx>
#include <codmod>
#include <hamsandwich>
#include <fun>
#define DMG_BULLET (1<<1)
#define DMG_HE (1<<24)
new bool:ma_perk[33]
new const perk_name[] = "Pierwsza Brygada";
new const perk_desc[] = "Dostajesz M4A1,Ak47,AWP, 1/3 z AWP";
public plugin_init()
{
register_plugin(perk_name, "1.0", "QTM_Peyote");
cod_register_perk(perk_name, perk_desc);
RegisterHam(Ham_TakeDamage, "player", "TakeDamage");
}
public cod_perk_enabled(id)
{
cod_give_weapon(id, CSW_M4A1);
cod_give_weapon(id, CSW_AK47);
cod_give_weapon(id, CSW_AWP);
ma_perk[id] = true;
}
public cod_perk_disabled(id)
{
cod_take_weapon(id, CSW_M4A1);
cod_take_weapon(id, CSW_AK47);
cod_take_weapon(id, CSW_AWP);
ma_perk[id] = false;
}
public TakeDamages(this, idinflictor, idattacker, Float:damage, damagebits)
{
if(!is_user_connected(idattacker))
return HAM_IGNORED;
if(!ma_perk[idattacker])
return HAM_IGNORED;
if(random(3))
return HAM_IGNORED;
if(get_user_team(this) == get_user_team(idattacker))
return HAM_IGNORED;
if(get_user_weapon(idattacker) != CSW_AWP)
return HAM_IGNORED;
if(!(damagebits & DMG_BULLET))
return HAM_IGNORED;
cod_inflict_damage(idattacker, this, 999.0, 0.9, idinflictor, damagebits);
return HAM_IGNORED;
}
Wie ktoś dlaczego ?


Dodatki SourceMod



Temat jest zamknięty









