mIRC Home    About    Download    Register    News    Help

Print Thread
Joined: Jan 2003
Posts: 39
Q
quiglag Offline OP
Ameglian cow
OP Offline
Ameglian cow
Q
Joined: Jan 2003
Posts: 39
I got both of these scripts from these boards and work seperate, but when both are loaded they interfere. Problem: The message i type is said twice, and now the acros dont work. Ex.
<Quiglag> fhfh
14«0@Quiglag14» fhfh

can anyone help me? Thanks
Code:
on ^*:TEXT:*:*:{
  var %nick = $iif($chan,$left($remove($nick($chan,$nick).pnick,$nick),1) $+ $nick,$nick)
  var %window = $iif($chan,$chan,$nick)
  echo -tmi2 %window 14«0 $+ %nick $+ 14» $1-
  haltdef
}
on *:INPUT:*: {
  if (($left($1,1) == / || $left($1,1) == $readini($mircini,text,commandchar)) &amp;&amp; (!$ctrlenter)) return
  /msg $active $1-
  var %nick = $iif($chan,$left($remove($nick($chan,$nick).pnick,$nick),1) $+ $nick,$nick)
  echo $color(own) -atmi2 14«0 $+ %nick $+ 14» $1-
  halt 
}

---------------------------------------------------------------------------
Second script (Acros)

On *:input:#:{
  if /* iswm $1 || $ctrlenter { return }
  var %i = 1, %total = $0, %word, %string
  while %i &lt;= %total {
    %word = $ [ $+ [ %i ] ]
    if $readini(acro.mrc,acro,%word) {
      %string = %string $ifmatch
    }
    else %string = %string %word
    %i = %i + 1
  }
  say %string
  halt
}
  

Joined: Feb 2003
Posts: 143
N
Vogon poet
Offline
Vogon poet
N
Joined: Feb 2003
Posts: 143
If both the on inputs are in the same script file they wont work. Try moving them to another file or make it all one thing.


We don't just write the scripts, we put them to the test! (ScriptBusters)
Joined: Jan 2003
Posts: 39
Q
quiglag Offline OP
Ameglian cow
OP Offline
Ameglian cow
Q
Joined: Jan 2003
Posts: 39
They are in different files, and how would I go about combining the two.

Joined: Dec 2002
Posts: 774
T
Hoopy frood
Offline
Hoopy frood
T
Joined: Dec 2002
Posts: 774
Code:
 on *:INPUT:*: {
  if (($left($1,1) == / || $left($1,1) == $readini($mircini,text,commandchar)) &amp;&amp; (!$ctrlenter)) return
  var %i = 1, %total = $0, %word, %string
  while %i &lt;= %total {
    %word = $ [ $+ [ %i ] ]
    if $readini(acro.mrc,acro,%word) {
      %string = %string $ifmatch
    }
    else %string = %string %word
    %i = %i + 1
  }
  .msg $active %string
  var %nick = $iif($chan,$left($remove($nick($chan,$nick).pnick,$nick),1) $+ $nick,$nick)
  echo $color(own) -atmi2 14«0 $+ %nick $+ 14» %string
  halt 
} 


Code:
//if ( khaled isgod ) echo yes | else echo no
Joined: Jan 2003
Posts: 39
Q
quiglag Offline OP
Ameglian cow
OP Offline
Ameglian cow
Q
Joined: Jan 2003
Posts: 39
Using your code theRat anything I type is messeged "1"

Joined: Jan 2003
Posts: 39
Q
quiglag Offline OP
Ameglian cow
OP Offline
Ameglian cow
Q
Joined: Jan 2003
Posts: 39
Nevermind, I typed the code out wrong. Works great. Thanks. smile


Link Copied to Clipboard