mIRC Home    About    Download    Register    News    Help

Print Thread
Joined: May 2004
Posts: 5
S
Nutrimatic drinks dispenser
OP Offline
Nutrimatic drinks dispenser
S
Joined: May 2004
Posts: 5
Well, to be honest, I pretty much hate the mIRC-script language, especially if the script exceeds more then 2 lines on-event-do-one-thing.

My problem is: My scripts are written in perl but I still want to use them together with mIRC (it's not a bad client, just the script-language isn't quite my thing).
To do so I found a Perl-Module wich sends commands to mIRC (I can use any mIRC-command from perl) but it doesn't work the other way.
But I still need some events from mIRC. So I thought I could use something like that:
Code:
on *:EVENT:*:*:/send-a-command-to-the-perl-script-function $1-

Well.. what I need is some sort of "send-a-command-to-the-perl-script-function"
Some people I've asked suggested a .dll but I don't know anything about .dlls so that's not an option for me. frown
If anyone has such a .dll please tell me.
If anyone knows about another way to let mIRC communicate with another process, please urgenlty tell me. (I thought about communication-files but that's again quite a code in mIRC-script frown and then again I would have to good old problem to synchronize such a communication crazy )

So long, and thanks in advance for anything usefull.
SnakeByte.

PS: I'm quite used to write c++ so if someone could teach me (give me a tutorial/good(!!!) documentation) how to write a .dll for mIRC I would do it.

Last edited by SnakeByte; 29/05/04 09:23 AM.
Joined: Feb 2004
Posts: 2,019
Hoopy frood
Offline
Hoopy frood
Joined: Feb 2004
Posts: 2,019
Quote:
especially if the script exceeds more then 2 lines on-event-do-one-thing.


Hi,

I'm sorry I can't help you with writing dll's for mIRC but there are people here on the boards that can. Maybe you can use the Search function from this message board, I'm sure some interesting things will pop up. Same goes for Google. Maybe COM Objects can help you as well, don't know that for sure, but can't hurt to check it out: in mIRC /help Com objects

I quoted your sentence there because I am curious to know what you mean with that. If you mean that you don't like having more than 1 line of code on an event, then you can do this extremely easy by doing:

on *:EVENT:*:*: ProcessInput $target $1-

then simply create an alias which does all the work that you want it to, without having to code it on the event itsself.

alias ProcessInput {
...
}

Or do you mean that it is not possible to script more than 2 lines in an event?

on *:EVENT:*:*: {
...
...
...
}

Because of the braces you can put multiple commands into one event, no matter how many lines you use, as long as they are enclosed by the { } braces.

However as stated, I don't really know what you mean, so my apologies to you if this was not at all what you were saying.

Greets

Last edited by FiberOPtics; 29/05/04 11:21 AM.

Gone.
Joined: Dec 2002
Posts: 54
S
Babel fish
Offline
Babel fish
S
Joined: Dec 2002
Posts: 54
maybe you can use command line inputs

aka: /run "c:\bla bla\script.pm" some extra inputs here

and then use stdio.dll if you want to hide the console (msdos) window

Joined: May 2004
Posts: 5
S
Nutrimatic drinks dispenser
OP Offline
Nutrimatic drinks dispenser
S
Joined: May 2004
Posts: 5
but that would mean: one process for one input...
but I want one process which gets all the input..

So long.

Joined: Jun 2004
Posts: 7
I
Nutrimatic drinks dispenser
Offline
Nutrimatic drinks dispenser
I
Joined: Jun 2004
Posts: 7
What about using a socket for communication between your perl scripts and mIRC?

And about DLLs, I recently managed to create a DLL for mIRC with the GNU C Compiler (under Cygwin with mingw32 headers, for now). Due to lack of time I'm not able to write documentation for this, but if you like I could just give the whole folder to you, maybe that would help?
Also, there are quite some DLLs around of which you could get the source code as well.

Last edited by indiko; 03/06/04 01:06 AM.

Link Copied to Clipboard