mIRC Home    About    Download    Register    News    Help

Print Thread
Page 1 of 2 1 2
Joined: Aug 2018
Posts: 15
D
Pikka bird
OP Offline
Pikka bird
D
Joined: Aug 2018
Posts: 15
Hi,
I would like to solve this problem:
The MOTD ascii is not displayed correctly on mirc.
Could someone help me? Thanks.

Ex.: MindForge

• _______ _____ __ _ _____ _______ _____ _______ _______ _______
• / / / / / \ / / \ /_____ / / /_____/ / ____ /_____
• / / / __/__ / \_/ /_____/ / /_____/ / \_ /_____/ /______

Joined: Dec 2015
Posts: 148
Vogon poet
Offline
Vogon poet
Joined: Dec 2015
Posts: 148
There's two things that can affect it: your font selection and custom raw script that echoes it (and removes consecutive spaces).

Try:
Code:
/font -s -9 fixedsys

Changes status window font to Fixedsys size 9.

Joined: Aug 2018
Posts: 15
D
Pikka bird
OP Offline
Pikka bird
D
Joined: Aug 2018
Posts: 15
The font change did not work.

Joined: Dec 2008
Posts: 1,515
Hoopy frood
Offline
Hoopy frood
Joined: Dec 2008
Posts: 1,515
Follow this video: http://j.mp/2w3MrX9


Need Online mIRC help or an mIRC Scripting Freelancer? -> https://irc.chathub.org <-
Joined: Aug 2018
Posts: 15
D
Pikka bird
OP Offline
Pikka bird
D
Joined: Aug 2018
Posts: 15
How to removes consecutive spaces?

Last edited by DTRSTRMNM; 23/08/18 02:58 PM.
Joined: Jan 2004
Posts: 2,127
Hoopy frood
Offline
Hoopy frood
Joined: Jan 2004
Posts: 2,127
If the font change didn't work, that probably means you have a script that replaces the normal display of MOTD with your scripted one. To see if this is the case:

1. disable all scripts with: /remote off
2. reconnect to that server, and see if the display is correct while using font FixedSys.
3. re-enable your scripts before you forget: /remote on.

If the display works, you probably have a script which traps the 'raw' event numeric 372. Without knowing what your script handler looks like, it's hard to know how to fix it. The extra spaces are already removed by the time $1- sees the text, so you must use $parms to access the 'true' string. This shows a little of how you would fix, using $parms inside the event, instead of %a.

//var %a a $+ $str($chr(32),5) $+ b | echo -a consecutive spaces. without: %a with: $replace(%a,$chr(32),$chr(160))

Joined: Nov 2004
Posts: 842
Hoopy frood
Offline
Hoopy frood
Joined: Nov 2004
Posts: 842
The problem could on the server end.


What do you do at the end of the world? Are you busy? Will you save us?
Joined: Aug 2018
Posts: 15
D
Pikka bird
OP Offline
Pikka bird
D
Joined: Aug 2018
Posts: 15
Disabling the remote works.
However the script I use is this: http://gamersirc.net/category/news-eng/

Joined: Aug 2018
Posts: 15
D
Pikka bird
OP Offline
Pikka bird
D
Joined: Aug 2018
Posts: 15
The error appears on all servers.

Joined: Aug 2018
Posts: 15
D
Pikka bird
OP Offline
Pikka bird
D
Joined: Aug 2018
Posts: 15
Could someone try it to find the error? Tnx...

Joined: Jan 2004
Posts: 2,127
Hoopy frood
Offline
Hoopy frood
Joined: Jan 2004
Posts: 2,127
I couldn't find the event in the 470kb script file (yikes), so either it's somewhere in another script used by that program, or it's in a different script you're running. The raw event is most likely a line containing "raw *" or "raw 372". Does pasting this into the status window this show any line like that?

Code:

//var %i $script(0) | while (%i) { var %f $qt($script(%i)) | !filter -fs %f *raw * | if ($filtered) !echo 4 -s above lines in %f | dec %i }


Joined: Aug 2018
Posts: 15
D
Pikka bird
OP Offline
Pikka bird
D
Joined: Aug 2018
Posts: 15
This is what comes out putting that command:

Code:
rraw 002:*:set -u1 %::value $ [ $+ [ $0 ] ] | _doraw $1-
raw 003:*:if ($2-5 == this server was created) { set -u1 %::value $6- } | _doraw $1-
raw 221:*:set -u1 %::nick $me | set -u1 %::modes $2 | _doraw $1-
raw 250:*:set -u1 %::value $5 | _doraw $1-
raw 251:*:set -u1 %::users $4 | set -u1 %::text $7 | set -u1 %::value $10 | _doraw $1-
raw 255:*:set -u1 %::users $4 | set -u1 %::value $7 | _doraw $1-
raw 265:*:set -u1 %::users $5 | set -u1 %::value $7 | _doraw $1-
raw 266:*:set -u1 %::users $5 | set -u1 %::value $7 | _doraw $1-
raw 301:*:{
  else { set -u1 %::nick $2 | set -nu1 %::away $3- | set -nu1 %::text $3- | _doraw $1- }
raw 302:*:{
    ._doraw $1-
raw 321:*:if (!$halted) && ($isalias(kte::Raw.321)) { _doraw $1- }
raw 322:*:if (!$halted) && ($isalias(kte::Raw.322)) { _doraw $1- }
raw 323:*:if (!$halted) && ($isalias(kte::Raw.323)) { _doraw $1- }
raw 364:*:if (!$halted) && ($isalias(kte::Raw.364)) { _doraw $1- }
raw 365:*:if (!$halted) && ($isalias(kte::Raw.365)) { _doraw $1- }
raw 324:*:set -u1 %::chan $2 | set -u1 %::value $3- | set -u1 %::modes $3- | set -u1 %::text $3- | _doraw $1-
raw 329:*:set -u1 %::chan $2 | set -u1 %::value $asctime($3) | set -u1 %::text $3- | _doraw $1-
raw 333:*:set -u1 %::chan $2 | set -u1 %::nick $3 | set -u1 %::value $asctime($4) | set -u1 %::text %::value | _doraw $1-
raw 341:*:set -u1 %::nick $2 | set -u1 %::chan $3 | _doraw $1-
raw 352:*:{
  _doraw $1-
raw 353:*:set -u1 %::chan $2 | set -u1 %::text $3- | _doraw $1-
raw 372:*:set -nu1 %::text $3- | _doraw $1-
raw 391:*:set -u1 %::text $3- | _doraw $1-
raw 311:*:{
    ._doraw $1-
raw 314:*:{
    set -u1 %::nick $2 | set -u1 %::address $+($3, @, $4) | set -nu1 %::realname $6- | ._doraw $1-
raw 319:*:{
  if ($isalias(kte::Raw.319)) { set -u1 %::nick $2 | set -nu1 %::chan $3- | ._doraw $1- }
raw 312:*:{
  if ($isalias(kte::Raw.312)) { set -u1 %::nick $2 | set -u1 %::wserver $3 | set -nu1 %::serverinfo $4- | ._doraw $1- }
raw 307:*:{
  if ($isalias(kte::Raw.307)) { set -u1 %::nick $2 | set -u1 %::isregd is | ._doraw $1- }
raw 313:*:{
  if ($isalias(kte::Raw.313)) { set -u1 %::nick $2 | set -u1 %::isoper is | set -nu1 %::operline $3- | ._doraw $1- }
raw 317:*:{
    ._doraw $1-
raw 318:*:{
  if ($isalias(kte::Raw.318)) { set -nu1 %::nick $2 | ._doraw $1- }
raw 369:*:{
  if ($isalias(kte::Raw.369)) { set -nu1 %::nick $2 | ._doraw $1- }
raw *:*:{
  _doraw $1-
; /_doraw str <params>
alias -l _doraw {
above lines in "C:\Users\Giorgio\AppData\Roaming\mIRC\bin\kte\Kte-Dyn.mrc"
dialog kthmedit.addraw {
above lines in "C:\Users\Giorgio\AppData\Roaming\mIRC\bin\kte\kthmedit.mrc"
raw 001:*:kte_hidewcome
raw 002:*:kte_hidewcome
raw 003:*:kte_hidewcome
raw 004:*:kte_hidewcome
raw 005:*:if (!$kte_v(connected)) { kte_hidewcome }
raw 250:*:kte_hidelusers
raw 251:*:kte_hidelusers
raw 252:*:kte_hidelusers
raw 253:*:kte_hidelusers
raw 254:*:kte_hidelusers
raw 255:*:kte_hidelusers
raw 256:*:kte_hidelusers
raw 265:*:kte_hidelusers
raw 266:*:kte_hidelusers
raw 372:*:kte_hidemotd
raw 375:*:kte_hidemotd
raw 376:*:kte_hidemotd
raw 377:*:kte_hidemotd
raw 378:*:kte_hidemotd
raw 422:*:kte_hidemotd
raw 353:*:kte_hidenames $3
raw 366:*:kte_hidenames $2
raw 331:*:kte_hidejinfo $2
raw 332:*:kte_hidejinfo $2
raw 333:*:kte_hidejinfo $2
raw 324:*:kte_hidejinfo $2
raw 329:*:kte_raw329 $2
above lines in "C:\Users\Giorgio\AppData\Roaming\mIRC\bin\kte\kte.mrc"
; RAW aliases
alias -l toolbar_draw {
; raw events
raw 1:*:{
raw 2:*:{
raw 3:*:{
raw 4:*:{
raw 5:*:{
raw 301:*:{
raw 302:*: {
raw 315:*:{
raw 318:*:{
raw 331:*:{
raw 333:*:{
raw 352:*:{
raw 354:*:{
raw 396:*:{
raw 401:*:{
raw 403:*:{

Last edited by DTRSTRMNM; 23/08/18 06:44 PM.
Joined: Dec 2008
Posts: 1,515
Hoopy frood
Offline
Hoopy frood
Joined: Dec 2008
Posts: 1,515
add } in line 11 and hit CTRL+h

Edit: Also it seems all is broken, you must notice that when you open an bracket you must close it also using { and }

e.g:

Code:
alias test {
  echo -a Hello!
}

Last edited by westor; 23/08/18 06:41 PM.

Need Online mIRC help or an mIRC Scripting Freelancer? -> https://irc.chathub.org <-
Joined: Jan 2004
Posts: 2,127
Hoopy frood
Offline
Hoopy frood
Joined: Jan 2004
Posts: 2,127
Ah, this is another huge script hiding in another folder. The offending line is:

raw 372:*:set -nu1 %::text $3- | _doraw $1-

This should have the script process the MOTD line only if it does NOT contain double-spaces. Place this line on the line ABOVE the existing raw 372 line:
Code:
raw 372:*:if (!$regex(%a,\s\s)) { set -nu1 %::text $3- | _doraw $1- }

If it still suppresses the consecutive spaces, then there may be another script doing that with a "raw *" event handler.

edit: to be clear, the script filename is

Kte-Dyn.mrc

And this file should be edited from the Alt+R remotes editor.

Last edited by maroon; 23/08/18 07:53 PM.
Joined: Aug 2018
Posts: 15
D
Pikka bird
OP Offline
Pikka bird
D
Joined: Aug 2018
Posts: 15
Doesn't work.

Joined: Jan 2004
Posts: 2,127
Hoopy frood
Offline
Hoopy frood
Joined: Jan 2004
Posts: 2,127
ok, try putting this in the script above that line with raw 372 in it.

Code:
raw 372:*:{
  if (!$regex(%a,\s\s)) {
    echo 3 -s MOTD: $replace($parms,$chr(32),$chr(160))
    ; set -nu1 %::text $3- | _doraw $1-
  }
  else {
    echo 4 -s MOTD: $replace($parms,$chr(32),$chr(160))
  }
haltdef
}


This should replace your existing scripted display of MOTD. It should display it in red or green, depending on whether or not the line contains multiple consecutive spaces in it. Let me know if there's any red or green lines displaying the MOTD.

Joined: Aug 2018
Posts: 15
D
Pikka bird
OP Offline
Pikka bird
D
Joined: Aug 2018
Posts: 15
Comes out in green but the ascii motd works only with fixedsys.

Code:
MOTD: DaturaStramonium` -  _______ _____ __    _ _____   _______  _____  _______ _______ _______
MOTD: DaturaStramonium` -  /  /  /   /   / \   / /    \  /_____  /     / /_____/ /  ____ /_____
MOTD: DaturaStramonium` - /  /  / __/__ /   \_/ /_____/ /       /_____/ /    \_ /_____/ /______
MOTD: DaturaStramonium` - -

Last edited by DTRSTRMNM; 24/08/18 10:52 AM.
Joined: Aug 2018
Posts: 15
D
Pikka bird
OP Offline
Pikka bird
D
Joined: Aug 2018
Posts: 15
it also works with lucida console...

Joined: Jan 2004
Posts: 2,127
Hoopy frood
Offline
Hoopy frood
Joined: Jan 2004
Posts: 2,127
Fixedsys has the problem of being available in only 1 size. Here's a list of all fixed pitch fonts on your system. If you have Consolas, you might also try that one.

Code:
//var %i 1 | while (%i < $font(0)) { if ($font(%i).pitch == fixed) echo -a %i $font(%i) | inc %i }


You can remove the 3 and 4 to make it stop coloring in green/red.

Joined: Aug 2018
Posts: 15
D
Pikka bird
OP Offline
Pikka bird
D
Joined: Aug 2018
Posts: 15
Ok, now it works,
Is it possible to remove "MOTD: Nickname -" which appears before the ascii code?

P.s.: In theory should be displayed like this with the time:
Code:
[17:50] ::: -    _______ _____ __    _ _____   _______  _____  _______ _______ _______
[17:50] ::: -    /  /  /   /   / \   / /    \  /_____  /     / /_____/ /  ____ /_____
[17:50] ::: -   /  /  / __/__ /   \_/ /_____/ /       /_____/ /    \_ /_____/ /______
[17:50] ::: - -

Last edited by DTRSTRMNM; 24/08/18 03:58 PM.
Joined: Jan 2004
Posts: 2,127
Hoopy frood
Offline
Hoopy frood
Joined: Jan 2004
Posts: 2,127
I tested this against their MOTD that has some lines with leading spaces in front of the logo. If you don't want the timestamp on those lines while timestamping is enabled, change the -st to -s

Code:
raw 372:*:{
  if (!$regex($parms,\s\s)) { echo 3 -st $3- }
  else {
    var %text $replace($parms,$chr(32),$chr(160)) , %r $regex(junk,$parms,^(\S+)\s+(-))
    var %text2 $mid(%text,$calc(2+$regml(junk,2).pos))
    if (%text2) echo 4 -st %text2
    else echo 2 -st $3-
  }
  haltdef
}

Joined: Aug 2018
Posts: 15
D
Pikka bird
OP Offline
Pikka bird
D
Joined: Aug 2018
Posts: 15
Sorry, I realized only now that this code works only on Mindforge, can you help me again?

Joined: Jan 2004
Posts: 2,127
Hoopy frood
Offline
Hoopy frood
Joined: Jan 2004
Posts: 2,127
What does 'not work' mean? Does it do 'nothing' or 'wrong thing'? Nothing in my code referenced any $network name, so if it doesn't 'work' at another network, it could be not sending the MOTD, or using something besides 372 to send the MOTD.

You can also try temporarily flooding your @debug window to snoop at the hex content of messages going to/from the server. If the 44/52 colors don't contrast against your background, you can change them. Typing /debugghex will begin logging all traffic to/from the $server attached to that window, so do that before reconnecting to see the handshaking.

Code:
alias debugghex { window -ze2Dj5000k @debug | titlebar @debug active= $+ $scid($window(@debug).cid).network logging: $addtok($gettok($window(@debug).titlebar,3-,32),$network,32) | debug -pir44o52 @debug $!+([,$time,],[,$network,] $!debuggsubhex($ $+ parms)) } ; Raccoon's altered by maroon

alias debuggsubhex { return $1 hex: $regsubex(junk,$1,/(.)/gu,$base($asc(\1),10,16) $+ $chr(32)) }


Joined: Aug 2018
Posts: 15
D
Pikka bird
OP Offline
Pikka bird
D
Joined: Aug 2018
Posts: 15
This is what I see on another server:

Code:
08:26] ::: rbx3.simosnap.com message of the day
[08:26] ****************************************************************************
-
* /echo: insufficient parameters (line 798, Kte-Dyn.mrc)
-
[08:26] - 
[08:26]      __  _                          __               _____  __    ___ 
[08:26]     / _\(_)_ __ ___   ___  ___   /\ \ \__ _ _ __     \_   \/__\  / __\
[08:26]     \ \ | | '_ ` _ \ / _ \/ __| /  \/ / _` | '_ \     / /\/ \// / /   
[08:26]     _\ \| | | | | | | (_) \__ \/ /\  / (_| | |_) | /\/ /_/ _  \/ /___ 
[08:26]     \__/|_|_| |_| |_|\___/|___/\_\ \/ \__,_| .__/  \____/\/ \_/\____/ 
[08:26]                                            |_|                        
[08:26]                       __     _                      _    
[08:26]                    /\ \ \___| |___      _____  _ __| | __
[08:26]                   /  \/ / _ \ __\ \ /\ / / _ \| '__| |/ /
[08:26]                  / /\  /  __/ |_ \ V  V / (_) | |  |   < 
[08:26]                  \_\ \/ \___|\__| \_/\_/ \___/|_|  |_|\_\
[08:26]                                                          
-
* /echo: insufficient parameters (line 798, Kte-Dyn.mrc)
-
[08:26] - 
[08:26] *******************************************************************************
-
* /echo: insufficient parameters (line 798, Kte-Dyn.mrc)
-
[08:26] - 
[08:26] Benvenuti in SimosNap IRC Network.
-
* /echo: insufficient parameters (line 798, Kte-Dyn.mrc)
-
[08:26] - 
[08:26] Visita il sito ufficiale della network: http://www.simosnap.org/
-
* /echo: insufficient parameters (line 798, Kte-Dyn.mrc)
-
[08:26] - 
[08:26] Per l'utilizzo dei  server e  dei servizi di SimosNap IRC Network l'utente DEVE
[08:26] conoscere  e  rispettare il  regolamento e i  termini  stabiliti  dallo  Staff. 
[08:26] L'utente e' quindi pregato di prenderne visione all'indirizzo:
-
* /echo: insufficient parameters (line 798, Kte-Dyn.mrc)
-
[08:26] - 
[08:26]                          http://www.simosnap.org/rules/
-
* /echo: insufficient parameters (line 798, Kte-Dyn.mrc)
-
[08:26] - 
[08:26] Puoi visualizzare il regolamento in ogni momento digitando /rules.
-
* /echo: insufficient parameters (line 798, Kte-Dyn.mrc)
-
[08:26] - 
[08:26] Procedendo si  ritiene  fatta accettazione  di tali  termini, chi  non fosse in
[08:26] accordo con tali termini e' pregato di non usare questo servizio.
-
* /echo: insufficient parameters (line 798, Kte-Dyn.mrc)
-
[08:26] - 
-
* /echo: insufficient parameters (line 798, Kte-Dyn.mrc)
-
[08:26] - 
-
* /echo: insufficient parameters (line 798, Kte-Dyn.mrc)
-
[08:26] - 
[08:26] *******************************************************************************
-
* /echo: insufficient parameters (line 798, Kte-Dyn.mrc)
-
[08:26] - 
[08:26] In  questo  Network  la scelta  degli operatori  e' fatta  dallo  staff  e  non
[08:26] mediante test o  simili. L'unico  modo di diventare  operatore, nel  caso ce ne 
[08:26] fosse il bisogno, e' fare  parte da tempo  degli assidui  del Network  e essere 
[08:26] ritenuti dallo staff in grado di tale incarico. Pertanto e' INUTILE CHIEDERE LE
[08:26] FLAG DA OPERATORE O HELPER !!!
-
* /echo: insufficient parameters (line 798, Kte-Dyn.mrc)
-
[08:26] - 
[08:26]                                        SimosNap IRC Network Staff
-
* /echo: insufficient parameters (line 798, Kte-Dyn.mrc)
-
[08:26] - 
-
* /echo: insufficient parameters (line 798, Kte-Dyn.mrc)
-
[08:26] - 
[08:26] *******************************************************************************
-
* /echo: insufficient parameters (line 798, Kte-Dyn.mrc)
-
[08:26] - 
[08:26]          Staff:
-
* /echo: insufficient parameters (line 798, Kte-Dyn.mrc)
-
[08:26] - 
[08:26]                  NetworkAdmins:
[08:26]                          Simos   (admin@simosnap.org)
[08:26]                          DjGolia (djgolia@simosnap.org)
[08:26]                          Pipps   (pipps@simosnap.org)
-
* /echo: insufficient parameters (line 798, Kte-Dyn.mrc)
-
[08:26] - 
-
* /echo: insufficient parameters (line 798, Kte-Dyn.mrc)
-
[08:26] - 
[08:26]                  Server Admins:
[08:26]                          Digita il comando /quote admin 
-
* /echo: insufficient parameters (line 798, Kte-Dyn.mrc)
-
[08:26] - 
[08:26] *******************************************************************************
-
* /echo: insufficient parameters (line 798, Kte-Dyn.mrc)
-
[08:26] - 
[08:26]         Porte disponibili:
[08:26]                  6666, 6667, 6668, 6669: Connessioni normali
-
* /echo: insufficient parameters (line 798, Kte-Dyn.mrc)
-
[08:26] - 
[08:26]          SSL:
[08:26]                  9999
-
* /echo: insufficient parameters (line 798, Kte-Dyn.mrc)
-
[08:26] - 
[08:26] *******************************************************************************
-
* /echo: insufficient parameters (line 798, Kte-Dyn.mrc)
-
[08:26] - 
[08:26] *******************************************************************************
-
* /echo: insufficient parameters (line 798, Kte-Dyn.mrc)
-
[08:26] - 
[08:26]         Round Robin per la connessione al network:
[08:26]                  irc.simosnap.com: Connessioni IPV4
[08:26]                  irc6.simosnap.com: Connessioni IPV6
-
* /echo: insufficient parameters (line 798, Kte-Dyn.mrc)
-
[08:26] - 
[08:26] *******************************************************************************
[08:26] ::: End of message of the day.

Joined: Jan 2004
Posts: 2,127
Hoopy frood
Offline
Hoopy frood
Joined: Jan 2004
Posts: 2,127
Is there another public network where this fails? Perhaps one that doesn't ban me as part of a spammer Z-line range? I'm not going to try appealing via email, just so I can see what happens when trying to connect.

Also, your post shows a bunch of error messages, so it would have been helpful to tell which line is 798

Joined: Aug 2018
Posts: 15
D
Pikka bird
OP Offline
Pikka bird
D
Joined: Aug 2018
Posts: 15
In any server.

Last edited by DTRSTRMNM; 11/03/19 10:30 AM.
Joined: Jan 2004
Posts: 2,127
Hoopy frood
Offline
Hoopy frood
Joined: Jan 2004
Posts: 2,127
This isn't an answer. The one site you pasted won't let me connect, and I sampled several other websites and couldn't find one which caused my code to generate these echoes. And you didn't say what's on the line number causing your error.

Page 1 of 2 1 2

Link Copied to Clipboard