Garry's Mod

Garry's Mod

Customizable Taunt Menu for Prop Hunt
Vash Baldeus 2017 年 3 月 21 日 上午 8:56
Taunt delay code.
Just replace the end of SERVER with this:
util.AddNetworkString("send_taunt") net.Receive( "send_taunt", function( _, ply ) local taunt = net.ReadString() if ((ply.Delay or 0) < CurTime()) then sound.Add( { name = "playerTauntSound", channel = CHAN_AUTO, volume = 1.0, level = 150, pitch = 100, sound = taunt } ) ply:EmitSound("playerTauntSound") ply.Delay = CurTime() + SoundDuration(taunt) + 3 end end ) end

It will make a dealy, forbid spam.
< >
正在显示第 1 - 2 条,共 2 条留言
M̶O̶N͞4̵͢D͘  [开发者] 2017 年 3 月 25 日 下午 1:15 
Nice! I will include this in the next version if thats ok :steamhappy:
Vash Baldeus 2017 年 3 月 25 日 下午 1:23 
引用自 Catzen
Nice! I will include this in the next version if thats ok :steamhappy:
Sure, just note that some taunts might not work correct as according to GLUA wiki the function I used is not precise (SoundLength)
< >
正在显示第 1 - 2 条,共 2 条留言
每页显示数: 1530 50