• 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!
  • New resources must be posted under Resources tab. A discussion thread will be created automatically, you can't open threads manually anymore.

TalkAction Swearing is not allowed on ...

pirl0

Scripter
Joined
Apr 16, 2009
Messages
172
Reaction score
0
Hiho i make script if player swearing then he said

Code:
~~ Swearing is not allowed on [name ots] ~~

Script :

talkactions/scripts/swearing.lua

Lua:
function onSay(cid, words, param)    
if getPlayerAccess(cid) < 3 then    
doCreatureSay(cid, "~~ Swearing is not allowed on ".. getConfigInfo('serverName') .." ~~" ,1)
doPlayerSendCancel(cid, "You can't swearing.")
else
return FALSE
end
return TRUE
end

In talkactions.xml

Code:
<talkaction hide="yes" words="fuck" event="script" value="swearing.lua"/>

Else if is access 3+ then is say normal word.
 
Haha up^ Anyway.. I played some random serverbefore with some script, You could not ssay "fuck" "ass" kurwa" The most common words.. Insteed of thoose it came like "flower" "love" :) Would be great XD
 
Lua:
function onSay(cid, words, param)    
if getPlayerAccess(cid) < 3 then    
doCreatureSay(cid, "~~ Swearing is not allowed on ".. getConfigInfo('serverName') .." ~~" ,1)
doPlayerSendCancel(cid, "You can't swear.")
doTargetCombatHealth(0, cid, COMBAT_FIREDAMAGE, -1, -5, CONST_ME_FIRE)
else
return FALSE
end
return TRUE
end
 
@Up, since when do you write with a CAPITAL letter after a question mark? i don't understand that. :eek:


Nice grammar...
 
@Up, since when do you write with a CAPITAL letter after a question mark? i don't understand that. :eek:


Nice grammar...

Actually you always have a capital letter after a question mark..try reading a book? Hi what is your name? You don't look like you're from around here. That is how you type...if your going to insult someone atleast do it properly.
 
Yay, grammar war!

Back on topic now. Anyway has a solution to filtering any word said?
<talkaction keywords="*"> might give a bit server load :p
 
If you mean Nikolas's script then no, it is as simple, considering you can still say "fuck you" or "mother fucker" etc, so it isnt really an anti-insult script, it just filters some pre-set words. (Nikolas's has a more advanced system thought)

I wish someone made something to filter all the words containing X (i.e x = fuck), then a real anti-insult script could be made. Ive tried but Im not as advanced to do something like that, Im stuck at zero, dont even know what could be done to achieve that.
 
Back
Top