|
Joined: Jun 2003
Posts: 77
Babel fish
|
OP
Babel fish
Joined: Jun 2003
Posts: 77 |
Im wondering if its possible to add an event "on SNICK" or similar to be a trigger for when a nickname is selected in the nicklist.
I have a dialog and I want an editbox to update with a nick selected from the nicklist. People have given me answers such as using timers and stuff, while that does work, there's no way to trigger these timers etc. when a nick is selected.
.
|
|
|
|
Joined: May 2003
Posts: 730
Hoopy frood
|
Hoopy frood
Joined: May 2003
Posts: 730 |
if u are talking about dialog, so when u are selecting a line in a list the 'sclick' dialog event is triggered, for example: on *:dialog:NAME:sclick:ID:{ command } NAME - dialog name ID - the list's id
|
|
|
|
Joined: May 2003
Posts: 2,265
Hoopy frood
|
Hoopy frood
Joined: May 2003
Posts: 2,265 |
no he means the identifiers - $snick and $snicks
new username: tidy_trax
|
|
|
|
Joined: May 2003
Posts: 730
Hoopy frood
|
Hoopy frood
Joined: May 2003
Posts: 730 |
well, after that he said 'dialog' so i think he mean a dialog list, but i'm not sure
|
|
|
|
Joined: Jun 2003
Posts: 77
Babel fish
|
OP
Babel fish
Joined: Jun 2003
Posts: 77 |
My idea would be something like: on *:SNICK:{ do stuff }
in my specifc case: on *:SNICK:{ did -o user 5 $snick($active,1) } 5 being the id of the editbox
.
|
|
|
|
Joined: May 2003
Posts: 730
Hoopy frood
|
Hoopy frood
Joined: May 2003
Posts: 730 |
the select is on the listbox of a channel or a dialog list ?
|
|
|
|
Joined: Jun 2003
Posts: 77
Babel fish
|
OP
Babel fish
Joined: Jun 2003
Posts: 77 |
Of the channel.
I have one in the dialog, except its on another tab, and its a bit of a pain going back and forth from tab to tab everytime i need to (for example) kick/ban a user.
.
|
|
|
|
Joined: May 2003
Posts: 730
Hoopy frood
|
Hoopy frood
Joined: May 2003
Posts: 730 |
ok.. the only way is a timer
|
|
|
|
Joined: May 2003
Posts: 2,265
Hoopy frood
|
Hoopy frood
Joined: May 2003
Posts: 2,265 |
menu nicklist { Add Dialog: did -a dialog id $$1 } put in remote but change dilog to name of dialog and id to id of edit box
new username: tidy_trax
|
|
|
|
Joined: Jun 2003
Posts: 77
Babel fish
|
OP
Babel fish
Joined: Jun 2003
Posts: 77 |
Yeah thats what the were adament about telling me on mircscripts.org except theres 1 SMALL problem...There is nothing to trigger the timer when a new nick is selected. And no START, JOIN etc. dont do what im asking for
.
|
|
|
|
Joined: Dec 2002
Posts: 2,809
Hoopy frood
|
Hoopy frood
Joined: Dec 2002
Posts: 2,809 |
I guess that could be useful, however I'd suggest it be added a little different, instead of ON *:SNICK:commands, I'd say ON *:SNICK:#channel:commands so that way you can limit it to only functioning on certain channels.
|
|
|
|
Joined: Feb 2003
Posts: 2,812
Hoopy frood
|
Hoopy frood
Joined: Feb 2003
Posts: 2,812 |
This could be done with the mouse events in a Nicklist menu, if only they were permitted. Why so many mouse/keyboard events are prohibited from being used in #channel windows, is beyond me. (If it's because they can encourage unscrupulous spy scripts... well, there are plenty which do so already)
MENU Nicklist { sclick: if (%mouse.lb) editbox -a $snick($active,1) }
Or better yet:
Menu Nicklist { lbclick: editbox -a $snick($active,1) }
- Raccoon
Well. At least I won lunch. Good philosophy, see good in bad, I like!
|
|
|
|
Joined: Dec 2002
Posts: 774
Hoopy frood
|
Hoopy frood
Joined: Dec 2002
Posts: 774 |
I think this would be ideal:
menu nicklist { lbclick : selected $1 in nicklist }
if you look into "/help MOUSE event" this would be uniform w/ it...
//if ( khaled isgod ) echo yes | else echo no
|
|
|
|
Joined: Feb 2003
Posts: 2,812
Hoopy frood
|
Hoopy frood
Joined: Feb 2003
Posts: 2,812 |
... or what I said. :tongue:
Well. At least I won lunch. Good philosophy, see good in bad, I like!
|
|
|
|
Joined: Dec 2002
Posts: 774
Hoopy frood
|
Hoopy frood
Joined: Dec 2002
Posts: 774 |
indeed..., did i actually edit my post over 17minutes?
//if ( khaled isgod ) echo yes | else echo no
|
|
|
|
Joined: Jun 2003
Posts: 77
Babel fish
|
OP
Babel fish
Joined: Jun 2003
Posts: 77 |
I personally dont mind how it would work, i suppose thats up to khaled, just as long as it is a trigger for when nicks are selected in the nicklist.
.
|
|
|
|
Joined: Dec 2002
Posts: 29
Ameglian cow
|
Ameglian cow
Joined: Dec 2002
Posts: 29 |
I am quite supprised that you don`t get simple thing as that. You want new selected nick in nicklist to show up in your dialog editbox,while your dialog is open. Timer is your event.But you need to start timer first.and you dont start timer every time you select nick you start timer once when you join channel where you are Operator. When times come to do some action you open your dialog and then select nick in nicklist and that nick will show up in dialog editbox.Then select another nick and that nick will show up in dialog editbox,and so on until you decide to Stop timer or you close your mIRC.You didn`t even try code you got,and you are whining about that.
|
|
|
|
Joined: Jun 2003
Posts: 77
Babel fish
|
OP
Babel fish
Joined: Jun 2003
Posts: 77 |
Ok... i get what you're saying, but I dont get how the timer is the event, and how it would work when a new nick is selected.
Could you explain a bit further, better yet give me some general idea of what code to use?
.
|
|
|
|
Joined: May 2003
Posts: 730
Hoopy frood
|
Hoopy frood
Joined: May 2003
Posts: 730 |
for example: //timer 0 1 if ($active ischan) && ($snick($active,1)) && ($dialog(YOUR DIALOG NAME)) did -a $!ifmatch ID $!snick($active,1) this will check every second what nick is selected
|
|
|
|
Joined: Dec 2002
Posts: 29
Ameglian cow
|
Ameglian cow
Joined: Dec 2002
Posts: 29 |
Ok this goes in remote section of mIRC. on *:join:#: { if ($nick == $me) { .timersnick -m 0 500 selectednick } } Replace this caracter # in on join event with name of the channel where are you operator. Now this is a sample with simple dialog just to show you what it does. dialog test { title "Test" size -1 -1 86 27 option dbu edit "", 1, 4 3 78 10 button "Close", 2, 26 15 37 11, cancel } alias t { $iif(!$dialog(test),dialog -m test test) } alias selectednick { if ($snick(#)) && ($dialog(test)) { did -ra test 1 $snick(#) } } Now put this in remote section and join channel ,to open test dialog type /t then start selecting nicknames in nicklist. to stop timer type /timersnick off
|
|
|
|
|