mIRC Homepage

just another little scripting question

Posted By: Sleepyfreak

just another little scripting question - 02/07/05 07:05 AM

i was on a server and a person talked on there and everything he said came out like this <Scout_bot> 3,9]9,3[1,3]3,1[1,1-1514,01I not a bot1,1-3,1]1,3[9,3]3,9[0,9
<Scout_bot> 3,9]9,3[1,3]3,1[1,1-1514,01Is only a nick1,1-3,1]1,3[9,3]3,9[ and so on and forth but i'm wondering if i could get that for me
Posted By: SladeKraven

Re: just another little scripting question - 02/07/05 07:30 AM

Do you mean like $strip($1-,c)?

-Andy
Posted By: Sleepyfreak

Re: just another little scripting question - 02/07/05 07:32 AM

no i mean when i type hello it comes out like the above popup i showed you but i want it to work for every word
Posted By: SladeKraven

Re: just another little scripting question - 02/07/05 07:57 AM

Ohh oops, read it wrong. Here's an example but it's rather crappy as I'm half asleep, about to hit the sheets..

Code:
on *:Input:*: { 
  if ($readini($mircini, text, commandchar) == $left($1,1)) return $1-
  else {
    msg $chan 3,9]9,3[1,3]3,1[1,1-1514,01 $+ $1- $+ 1,1-3,1]1,3[9,3]3,9[0,9
    halt
  }
}


-Andy
Posted By: Sleepyfreak

Re: just another little scripting question - 02/07/05 08:07 AM

yeah it works great thanks
Posted By: Kelder

Re: just another little scripting question - 02/07/05 08:08 AM

Code:
on ^*:INPUT:#channelname:{
  if ((/* !iswm $1) || (!$ctrlenter)) {
    haltdef
    say 3,9]9,3[1,3]3,1[1,1-1514,01 $+ $1- $+ 1,1-3,1]1,3[9,3]3,9[0,9
  }
}


Change "channelname to # for all channels,? for queries. It will not change the text if you type /message #channelname blah, or if you type it in the editbox but use ctrl+enter instead of just enter.
Just a warning: if you use stuff like this, you will be kicked on a lot of channels, so don't use it unless they specifically ask you for it or something.
Posted By: Sleepyfreak

Re: just another little scripting question - 02/07/05 01:11 PM

is it possible to make it be in a menu bar with i.e. Green Text and one below it saying Rainbow Text and could you make one having rainbow text i.e.7W2e3l12c6o4m7e 2t3o 12#6y4o7u2t3h12, 6h4a7v2e 3a 12g6r4e7a2t 3t12i6m4e 7h2e3r12e6!4!7! and so forth
Posted By: Kelder

Re: just another little scripting question - 02/07/05 02:39 PM

make different aliases like this:

alias rainbow say add colors before and after $+ $1- $+
alias greenbrackets say $1-

on ^*:INPUT:#channelname:{
if ((/* !iswm $1) || (!$ctrlenter)) {
haltdef
$iif(%textcolorizer,$v1,say) $1-
}
}

For the menu it's probably something like this:

menu channel {
.Colored Text
..nothing:unset %textcolorizer
..rainbow:set %textcolorizer rainbow
..greenbrackets:set %textcolorizer greenbrackets
}

That's about it. If you want to test an alias or use something special while another colorizer is active, just type /greenbrackets this is a test.
Posted By: Sleepyfreak

Re: just another little scripting question - 02/07/05 04:52 PM

dude i don't get ya
Posted By: DaveC

Re: just another little scripting question - 02/07/05 10:45 PM

Small bugfix

Quote:
on ^*:INPUT:#channelname:{


replace with

on *:INPUT:#channelname:{

no ^ event exists (does not function if present), the *:INPUT it is by default a pre event.



and maybe

$iif(%textcolorizer,$v1,say) $1-
replace with
$iif($isalias(%textcolorizer),%textcolorizer,say) $1-

but thats just incase some crazy alters %textcolorizer on there own!
Both have disadvantages, one thing myway on this wont work for is if you selected something like "set %textcolorizer SAY" since SAY isnt an alias (by default)
Posted By: Sleepyfreak

Re: just another little scripting question - 03/07/05 04:23 AM

thats great but could you also make one for rainbow text?

i.e.
7W2e3l12c6o4m7e 2t3o 12#6L4o7b2b3y12, 6h4a7v2e 3a 12g6r4e7a2t 3t12i6m4e 7h2e3r12e6!
© 2020 mIRC Discussion Forums