zhangsheng 发表于 2007-11-27 03:29:55

回复: 捡钱的声效怎么添加?

发钱声音使用emit_sound来判断就行了.我服务器的发钱声音一直都是队伍才听得到

INSUN 发表于 2007-11-27 23:11:55

回复: 捡钱的声效怎么添加?

Post by zhangsheng
发钱声音使用emit_sound来判断就行了.我服务器的发钱声音一直都是队伍才听得到
希望zhangsheng给出修改后的源码,不胜感激!

Osker Lee 发表于 2007-11-28 10:39:09

回复: 捡钱的声效怎么添加?

就是说要添加这句代码:
emit_sound(id,CHAN_VOICE,"misc/getmoney.wav", 1.0, ATTN_NORM, 0, PITCH_NORM)

zhangsheng 发表于 2007-11-28 11:40:43

回复: 捡钱的声效怎么添加?

代码没写对应该是
emit_sound(id,CHAN_STREAM,"misc/cvt_dropmoney.wav", 1.0, ATTN_NORM, 0, PITCH_NORM)

ceoguang 发表于 2007-11-30 12:19:05

回复: 捡钱的声效怎么添加?

Post by zhangsheng
代码没写对应该是
emit_sound(id,CHAN_STREAM,"misc/cvt_dropmoney.wav", 1.0, ATTN_NORM, 0, PITCH_NORM)
学习了,问一下zhangsheng大哥,enit_sound曾在哪个插件中出现过?:embarrass

zhangsheng 发表于 2007-11-30 12:31:24

回复: 捡钱的声效怎么添加?

在include函数表的amxconst.inc函数中出现过.
里面有调用方法的
/* Constants for emit_sound() */
/* Channels */
#define CHAN_AUTO                0
#define CHAN_WEAPON                1
#define        CHAN_VOICE                2
#define CHAN_ITEM                3
#define        CHAN_BODY                4
#define CHAN_STREAM                5        /* allocate stream channel from the static or dynamic area */
#define CHAN_STATIC                6        /* allocate channel from the static area*/
#define CHAN_NETWORKVOICE_BASE        7        /* voice data coming across the network */
#define CHAN_NETWORKVOICE_END        500        /* network voice data reserves slots (CHAN_NETWORKVOICE_BASE through CHAN_NETWORKVOICE_END). */
页: 1 [2]
查看完整版本: 捡钱的声效怎么添加?