Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- /*function ulx.micon(calling_ply, target_ply)
- if target_ply:isTG() then return end
- target_ply:SendLua([[
- timer.Create("mictoggle", 0.2, 0, function()
- LocalPlayer():ConCommand("+voicerecord")
- end)
- ]])
- end
- local micon = ulx.command("Chat", "ulx micon", ulx.micon, "!micon", true)
- micon:addParam{ type=ULib.cmds.PlayerArg }
- micon:addParam{ type=ULib.cmds.BoolArg, invisible=true }
- micon:defaultAccess( ULib.ACCESS_SUPERADMIN )
- micon:help( "Force microphone on." )
- function ulx.micoff(calling_ply, target_ply)
- if target_ply:isTG() then return end
- target_ply:SendLua([[
- timer.Destroy("mictoggle")
- LocalPlayer():ConCommand("-voicerecord")
- ]])
- end
- local micoff = ulx.command("Chat", "ulx micoff", ulx.micoff, "!micoff", true)
- micoff:addParam{ type=ULib.cmds.PlayerArg }
- micoff:addParam{ type=ULib.cmds.BoolArg, invisible=true }
- micoff:defaultAccess( ULib.ACCESS_SUPERADMIN )
- micoff:help( "Force microphone off." )*/
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement