• There is NO official Otland's Discord server and NO official Otland's server list. The Otland's Staff does not manage any Discord server or server list. Moderators or administrator of any Discord server or server lists have NO connection to the Otland's Staff. Do not get scammed!

TalkAction Mute script.

WibbenZ

Global Moderator
Staff member
Global Moderator
Joined
Oct 16, 2008
Messages
6,374
Solutions
229
Reaction score
1,503
Location
Sweden
Well its no hard but on a ot I play sometimes guys some and like

Join us osfjsof.servegame.com FAST free cash..


If you dont like it dont post :p

Lua:
function onSay(cid, words, param, channel)
	       local config = {
	    local pid = 40000  
            local u = 2040			
}
		if getPlayerGroupId(cid, <= 3) then
	doMutePlayer(cid, config.pid)
			doCreatureSay(cid,getPlayerName(cid), getPlayerPosition(cid))
		doPlayerGiveItem(cid,..u..,1)
					     doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_BLUE, "You have muted getPlayerTarget(cid), Thanks for helping getPlayerName(cid,)")
	doSendMagicEffect(getPlayerPosition(cid)(itemEx.uid), CONST_ME_MAGIC_BLUE)
			end
    else
        doPlayerSendCancel(cid, "You must hit a target!")
			doSendMagicEffect(getPlayerPosition(cid)(itemEx.uid), CONST_ME_POFF)
    end
    return TRUE
end


lets a player with group id 3+ mute a play for 40000 sec
only becouse they are boring xD

and it will say You must hit a target if he dosent find a player.

Thanks for helping wibbenz......

rep++
/wibbenz
 
o.0

if getPlayerGroupId(cid, <= 3) then

not needed? why not set configurable time? theres already a script released here for this soooo
 
Your script won't even work. I have people that are releasing sh*t. And not tested sh*t.
Code:
function onSay(cid, words, param, channel)
	if param == "" then
		doPlayerSendCancel(cid, "Command requires param!")
		return true
	end
	local c = {}
	c.time = 20
	c.player = getPlayerNameByWildcard(param)
	
	doMutePlayer(c.player, c.time)
	doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_BLUE, "You have muted " .. c.player)
	return true
end
 
Your script won't even work. I have people that are releasing sh*t. And not tested sh*t.
Code:
function onSay(cid, words, param, channel)
	if param == "" then
		doPlayerSendCancel(cid, "Command requires param!")
		return true
	end
	local c = {}
	c.time = 20
	c.player = getPlayerNameByWildcard(param)
	
	doMutePlayer(c.player, c.time)
	doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_BLUE, "You have muted " .. c.player)
	return true
end
doMutePlayer doesn't work.
 
Code:
function doMutePlayer(cid, time)
[B][COLOR="Red"]	local condition = createConditionObject(CONDITION_MUTED)
	setConditionParam(condition, CONDITION_PARAM_TICKS, time * 1000)[/COLOR][/B]
	return doAddCondition(cid, condition)
end
Can't do this inside functions.
 
can you make it that if i use /mute player, he gets muted until i use /desmute player?
thanks
 
getPlayerNameByWildcard(param)
 
Back
Top