|
发表于 2008-3-16 18:02:17
|
显示全部楼层
来自 中国–广东–惠州
回复: 以"Create_TE_BEAMFOLLOW"的方式定义手雷拖尾
Post by Osker Lee
测试了,发现没有任何效果,手雷居然不能拖尾了~ 没理由吧,再试下
[php]
#include <amxmodx>
#include <engine>
#include <csx>
#define TE_BEAMFOLLOW 22
new m_iTrail
public plugin_init()
{
register_plugin("Grenade Trail","1.0","X-man")
register_cvar("amx_grentrail","1")
}
public plugin_precache() {
m_iTrail = precache_model("sprites/smoke.spr")
}
public grenade_throw(id,greindex,wpn)
{
if( !get_cvar_num("amx_grentrail") )
return PLUGIN_HANDLED
Create_TE_BEAMFOLLOW(greindex, m_iTrail, 20, 10, 255, 255, 0, 196)
return PLUGIN_CONTINUE
}
stock Create_TE_BEAMFOLLOW(id, m_iTrail, life, width, r, g, b, brightness)
{
message_begin(MSG_BROADCAST, SVC_TEMPENTITY)
write_byte(TE_BEAMFOLLOW)
write_short(id)
write_short(m_iTrail)
write_byte(life)
write_byte(width)
write_byte(r)
write_byte(g)
write_byte(b)
write_byte(brightness)
message_end()
}
[/php] |
|