How can i auto warn someone who says fuck or something else what's not allowed??
can someone help me??
Cant give you the exact code without knowing what base script your using... But heres the main part you need:
if ( $findtok( fuck shit bastard, $2-, 1, 32 ) ; Warn User
$2- would be the whatever the player said. In my scripts it would be $3- under vcmp.chat.
Sorry i cant give you the code for the other scripts, havn't got access to their signals/parameters right now (Somebody wanna grab them for me? :))
More words can be added by seperating each 'bad word' with a space
ok thanks,
what means findtok?
Meaning for $findtok from mirc
$findtok(text,token,N,C)
Returns the position of the Nth matching token in text.
$findtok(a.b.c.d,c,1,46) returns 3
$findtok(a.b.c.d,e,1,46) returns $null
If you specify zero for N, it returns the total number of matching tokens.
Note: $findtokcs() is the case-sensitive version.
sorry but it doesn't work.
I'm using GUS, can someone help me??
plzz can someone help me????
UNTESTED!
Find:
on *:SIGNAL:vcmp.text:{
Directly below add:
if ($findtok(fuck shit bastard,$2-,1,32)) vcmp.warn $vcmp.getid(%name) Autowarn Using bad language
Or create a new blank script file and add:
on *:SIGNAL:vcmp.text:{
var %name = $left($1,-1)
if ($findtok(fuck shit bastard,$2-,1,32)) vcmp.warn $vcmp.getid(%name) Autowarn Using bad language
}
Hope that helps
-AdTec_224
it helped a lot, but i have only one problem: If i say only "fuck" it warn, when i say "fack u" it doesn't warn??
Screen:
(http://img362.imageshack.us/img362/6872/screenba1.png)
(http://img300.imageshack.us/img300/4391/screeniefn7.png)
i've done it myself:
Quote
on *:SIGNAL:vcmp.text:{
if ($findtok(fuck shit bastard,$2-,1,32)) vcmp.warn $vcmp.getid(%name) Autowarn Using bad language
var %name = $left($1,-1)
vcmp.check.timer %name
vcmp.check.spam %name
echo -a 14 $+ %name $+ : $2- $+
if ($2 == brb) vcmp.say %name will Be Right Back! Reason: $iif($3-,$v1,None)
elseif ($2 == bbs) vcmp.say %name will Be Back Soon! Reason: $iif($3-,$v1,None)
elseif ($2 == bbl) vcmp.say %name will Be Back Later! Reason: $iif($3-,$v1,None)
elseif ($2 == fuck) vcmp.warn $vcmp.getid(%name) Server Using bad language
elseif (($2 == back) && ($3- == $null)) vcmp.say %name is Back!
}
Quote elseif (fuck isin $2) || (*fuck* iswm $2) vcmp.warn $vcmp.getid($left($1,-1)) Server Using bad language
Better...
thanks