mIRC Home    About    Download    Register    News    Help

Print Thread
#148457 06/05/06 12:08 PM
Joined: Apr 2005
Posts: 1,009
raZOR Offline OP
Hoopy frood
OP Offline
Hoopy frood
Joined: Apr 2005
Posts: 1,009
how comes that this: //!away
works by hand (manual) to bypass any aliases
and does NOT thru dialog execution ?


IceCapped
#148458 06/05/06 12:43 PM
Joined: Sep 2003
Posts: 4,230
D
Hoopy frood
Offline
Hoopy frood
D
Joined: Sep 2003
Posts: 4,230
I would say its likely because you have screwed something up in the dialog code.

#148459 06/05/06 01:23 PM
Joined: Apr 2005
Posts: 1,009
raZOR Offline OP
Hoopy frood
OP Offline
Hoopy frood
Joined: Apr 2005
Posts: 1,009
Code:
 
alias awaydig {
  dialog -m awaydig awaydig
}

dialog awaydig {
  title "Dialog"
  size -1 -1 170 102
  option dbu
  box "Reason", 1, 12 12 156 34
  edit %awayreason2, 2, 23 29 134 11
  check "Use Detailed Info (Date and Time of departure)", 3, 13 56 124 9
  button "OK", 4, 11 77 32 12, ok
  button "Cancel", 5, 55 77 32 12, cancel
}

alias away { .awaydig }

On *:dialog:setup:sclick:3:{
  if $did($did).state == 0 { .set %dinfo Off }
  if $did($did).state == 1 { .set %dinfo On }
}

on *dialog:awaydig:4:{ 
  if (%dinfo == on) {
    //!away %awayreason2 - away since: $date(dddd) $asctime(HH:nn) ( $+ $date $+ )
  }
  else { //!away %awayreason2 }
}

 


did it only for testing purpose
server doesnt mark me as away at all


IceCapped
#148460 06/05/06 04:29 PM
Joined: Apr 2004
Posts: 759
M
Hoopy frood
Offline
Hoopy frood
M
Joined: Apr 2004
Posts: 759
Try
Code:
on *:dialog:awaydig:4:{ 


When debugging asume human error first.


$maybe
#148461 06/05/06 04:44 PM
Joined: Sep 2005
Posts: 2,881
H
Hoopy frood
Offline
Hoopy frood
H
Joined: Sep 2005
Posts: 2,881
It needs to capture an event too. ie. :sclick:

#148462 06/05/06 04:55 PM
Joined: Nov 2005
Posts: 105
D
Vogon poet
Offline
Vogon poet
D
Joined: Nov 2005
Posts: 105
I don't see where you're setting %awayreason2 to a variable either.

#148463 06/05/06 05:08 PM
Joined: Apr 2004
Posts: 759
M
Hoopy frood
Offline
Hoopy frood
M
Joined: Apr 2004
Posts: 759
I think DaveC was right


$maybe
#148464 06/05/06 06:10 PM
Joined: Apr 2005
Posts: 1,009
raZOR Offline OP
Hoopy frood
OP Offline
Hoopy frood
Joined: Apr 2005
Posts: 1,009
Quote:
It needs to capture an event too. ie. :sclick:


what do you mean?


-
@drc4 its in dialog direct
edit %awayreason2, 2, 23 29 134 11

Last edited by raZOR; 06/05/06 06:12 PM.

IceCapped
#148465 06/05/06 06:12 PM
Joined: Sep 2005
Posts: 2,881
H
Hoopy frood
Offline
Hoopy frood
H
Joined: Sep 2005
Posts: 2,881
Even after mpdreamz's fix, you're not actually capturing an event here:

Code:
on *:dialog:awaydig:4:{ 


If you want to capture a sclick event, for example, on ID 4, you would use:

Code:
on *dialog:awaydig:[color:red]sclick:[/color]4:{ 

#148466 06/05/06 06:27 PM
Joined: Apr 2005
Posts: 1,009
raZOR Offline OP
Hoopy frood
OP Offline
Hoopy frood
Joined: Apr 2005
Posts: 1,009
thank you very much
it work all ok now.


IceCapped

Link Copied to Clipboard