mIRC Home    About    Download    Register    News    Help

Print Thread
Joined: Dec 2002
Posts: 483
Deep3D Offline OP
Pan-dimensional mouse
OP Offline
Pan-dimensional mouse
Joined: Dec 2002
Posts: 483
I have this code
Code:
aop $$input(Edit hostname:, e,Auto OP, $address($$1-,1)) # 

to make it work the IAL has to be updated, so I often have to run /who <nickname> first to make it work.

How can I make the code update the IAL and then add the user?

I've tryed:
Code:
who $$1 | aop $$input(Edit hostname:, e,Auto OP, $address($$1-,1)) # 

but that did not work, I also tryed to add /timer infront of /aop to give mIRC time to do the update, but that didn't work either.

Last edited by Deep3D; 03/03/18 02:10 PM.
Joined: Feb 2003
Posts: 2,812
Hoopy frood
Offline
Hoopy frood
Joined: Feb 2003
Posts: 2,812
You just need to send a /ialfill #channel (basically: /who #channel) only one time after having joined the channel. You can set it up to do this only when you are opped in a channel -- where you're likely to need it.

Code:
On *:OP:#: {
  if ($opnick == $me) {
    if ($chan($chan).ial == $false)
      ialfill $chan
} } }

Again, after having done an /ialfill only once in a channel, your client should remain synchronized from then on and require no additional /who commands to obtain new address details. (things like gecos and nickserv account details can be more challenging depending on the server.)

Be careful not to allow your client to hammer the server with a dozen /ialfill's in a row, or you are likely to be disconnected for flooding (excessive flood). A more advanced script will make sure to space them out by 10 seconds apart from when the previous command finishes (End of /WHO numeric).


Well. At least I won lunch.
Good philosophy, see good in bad, I like!
Joined: Dec 2002
Posts: 483
Deep3D Offline OP
Pan-dimensional mouse
OP Offline
Pan-dimensional mouse
Joined: Dec 2002
Posts: 483
This is what I ended up doing. wink

Popups:
Code:
.Auto Op
..Add User:echo -a - | echo -a Updating The Internal Address List: | who $$1 | .timerauto-op 1 1 auto-op-who $$1


Aliases:
Code:
auto-op-who {
  if users isin $address($$1-,1) { aop $$input(Edit hostname:, e,Auto-Op, $address($$1-,2)) # }
  else { aop $$input(Edit hostname:, e,Auto-Op, $address($$1-,13)) # }
  notice $$1 You ( $+ $! $+ ) have been added with auto op in channel #
}


Link Copied to Clipboard