|
以下是攻擊者擊中敵人時顯示的
如何修改成被攻擊者顯示被誰攻擊
想了很久也不會..過於簡單...反而很難:cry:
另問一下vIndex 是什麼.....
[PHP]#include <amxmodx>
public damage_msg(vIndex)
{
if ( get_cvar_float("bullet_damage") ) {
new aIndex = get_user_attacker(vIndex)
new damage = read_data(2)
set_hudmessage(0, 100, 200, -1.0, 0.55, 2, 0.1, 4.0, 0.02, 0.02, 7)
show_hudmessage(aIndex,"%i", damage)
}
return PLUGIN_CONTINUE
}
public plugin_init() {
register_plugin("Bullet Damage","1.0","ToKyo")
register_event("Damage", "damage_msg", "b", "2!0", "3=0", "4!0")
register_cvar("amx_bullet_damage","1")
return PLUGIN_CONTINUE
}[/PHP] |
|