首页 > 国内 >

环球热讯:【CSGO】简便的实现一键静音demo语音

前言

静音某个玩家的指令为

(这个指令不能使用toggle前缀实现一键切换状态,原因我也不道)


(资料图)

voice_player_volume 0 0

取消静音为

voice_player_volume 0 1

末尾的0/1为开关,中间的0代表玩家编号

基于上述内容我们可以实现一键静音以及一键解除静音

进入CSGO安装目录

打开“csgo”文件夹再打开"cfg"文件夹

创建两个cfg文件,名称全英文,自定义即可,最好自己能认识,用拼音也可以,两个文件的作用分别为一键静音和取消静音

(也可以使用alias命令在一个文件内编辑,比如autoexec文件,但是我觉得太麻烦了,不如直接两个文件来得方便)

用记事本或者任意编辑器打开第一个cfg文件(我使用vscode)

在一键静音文件内输入以下内容,一行一条就行

voice_player_volume 0 0

voice_player_volume 1 0

voice_player_volume 2 0

voice_player_volume 3 0

voice_player_volume 4 0

voice_player_volume 5 0

voice_player_volume 6 0

voice_player_volume 7 0

voice_player_volume 8 0

voice_player_volume 9 0

voice_player_volume 10 0

voice_player_volume 11 0

voice_player_volume 12 0

voice_player_volume 13 0

voice_player_volume 14 0

上屏后如图

另一个文件输入以下内容,格式同上

voice_player_volume 0 1

voice_player_volume 1 1

voice_player_volume 2 1

voice_player_volume 3 1

voice_player_volume 4 1

voice_player_volume 5 1

voice_player_volume 6 1

voice_player_volume 7 1

voice_player_volume 8 1

voice_player_volume 9 1

voice_player_volume 10 1

voice_player_volume 11 1

voice_player_volume 12 1

voice_player_volume 13 1

voice_player_volume 14 1

接着直接在控制台输入以下两个指令即可

bind X "exec xxxxx"

bind X "exec xxxxx"

两条命令对应两个文件两个按键,红色的X替换为自己想要的按键,按键列表可以看评论我发的链接,绿色的一串代表文件名,注意要去掉.cfg的后缀,例如文件名为mute.cfg,那对应的命令应为exec mute

注意事项

如果按下按键后控制台有如下提示

Player# is invalid. Use voice_player_volume to find a list of players

就是告诉你找不到编号为这个数字的玩家,叫你用“voice_player_volume”命令查看玩家对应的编号,因为这个编号每局都不同,且如果有人挂机,退出重进之类的会有变动,所以我直接打到了0-14,在按下按键之后可以看到控制台输出以下内容“set volume for xxxx to 0.00”一局十个玩家,都静音了就会像图上一样输出十条

如果少了一个或几个就用“voice_player_volume”命令看,然后“voice_player_volume x 0”

以上只是一种思路,还有很多方法实现,自行探索

关键词:

责任编辑:Rex_22

推荐阅读

关于我们  联系我们  商务合作  诚聘英才  网站地图

Copyright @ 2008-2020 icebox.rexun.cn Corporation, All Rights Reserved

热讯经济网 版权所有 豫ICP备20005723号-6
文章投诉邮箱:2 9 5 9 1 1 5 7 8@qq.com 违法信息举报邮箱:jubao@123777.net.cn

营业执照公示信息