mIRC Home    About    Download    Register    News    Help

Print Thread
Joined: Sep 2003
Posts: 19
N
Pikka bird
OP Offline
Pikka bird
N
Joined: Sep 2003
Posts: 19
im creating a custom away script (don't like all the others i have seen.. not much for multi-server suport) and im having trouble creating the poup menu.
here is what i have so far:
Code:
menu channel {
  Settings $readini(C:\mirc\text\ini\main.ini,n,$network,back_nick)
  .AWAY:/ascript
  .BACK:/ascript
  .-
  .NS-Ident:/ns identify $readini(C:\mirc\text\ini\main.ini,n,$network,ns_pass)
} 


/ascript is the command for the core part of the script (that works, arleady checked it) bur what i want to do is on the 'main' level of the menu, have the nick displayed for that server by reading it out of the appropriate section of the ini file instead of having to code up a seperate section for each server.

the 'back_nick' section of the ini contains the standard nickname.
is there maybe some command switch im missing that makes the 'menu' processe the identifiers, or is there something im missing yet?


w00f!
Joined: Mar 2004
Posts: 457
D
Fjord artisan
Offline
Fjord artisan
D
Joined: Mar 2004
Posts: 457
it should work, i can't think of any reason it doesn't other than the line in $readini is wrong.

Joined: Sep 2003
Posts: 19
N
Pikka bird
OP Offline
Pikka bird
N
Joined: Sep 2003
Posts: 19
http://wulfpawz.dyndns.org:8000/popup_output.jpg

there is a pic of what is generated, the section outlined in red is what hapens

( http://img.photobucket.com/albums/v152/nyght_wulf/popup_output.jpg << same picutre, different location, just incase you can't to the above listed one. )


w00f!
Joined: Mar 2004
Posts: 457
D
Fjord artisan
Offline
Fjord artisan
D
Joined: Mar 2004
Posts: 457
hhmm, i see what you mean. if you add the full path (C:\mirc) then it just ignores the "settings $readini" bit. So indeed it does look like a bug.

EG.
menu channel {
Settings $readini(C:\mirc\mirc.ini,text,nothin)
.AWAY:/ascript
.BACK:/ascript
.-
.NS-Ident:/ns identify $readini(C:\mirc\text\ini\main.ini,n,$network,ns_pass)
}
ignores the "Settings $readini(C:\mirc\mirc.ini,text,nothin)" and shows:

away
back
-
ns-ident

in the main menu. However, changing it to "$readini(mirc.ini,text,nothin)" and it works fine.

Joined: Sep 2003
Posts: 19
N
Pikka bird
OP Offline
Pikka bird
N
Joined: Sep 2003
Posts: 19


w00f!
Joined: Dec 2002
Posts: 230
G
Fjord artisan
Offline
Fjord artisan
G
Joined: Dec 2002
Posts: 230
mIRC tries to use the part after the colon as the command, so in reality the parser looks at it like this:

Popup entry: "Settings $readini(C"
Command: "\mirc\mirc.ini,text,nothin)"

So it obviously does not work. I wouldn't exactly call it a bug, since it is known that a colon delimits popup entries and their respective commands.
Khaled could of course look if the colon is inside an identifier - it's not that I don't want this problem fixed - I just don't see it happen as it might raise other problems.

A way around it is of course using a custom alias to do the $readini work smile

Joined: Sep 2003
Posts: 19
N
Pikka bird
OP Offline
Pikka bird
N
Joined: Sep 2003
Posts: 19
ahhhhhh laugh

i 've been talking about this with a few other scriptors, that didn't even ocure to us :tongue:

now i kinda feel stupid >.< ahwell. ..


w00f!

Link Copied to Clipboard