mIRC Home    About    Download    Register    News    Help

Print Thread
Joined: Feb 2004
Posts: 5
C
Cronus Offline OP
Nutrimatic drinks dispenser
OP Offline
Nutrimatic drinks dispenser
C
Joined: Feb 2004
Posts: 5
Hi, I've been writing a script but i've hit a wall, i need to modify the message that will be sent by DCC SEND so i can modify the IP address mirc expects to be connected to by to receive, i figured i could hook onto the CTCP reply but then i need to change the message itself, since it can be outputted as $1- i was hoping there was a way to change the contents of $1- if not then i think there should be in the next version

Joined: Nov 2003
Posts: 2,327
T
Hoopy frood
Offline
Hoopy frood
T
Joined: Nov 2003
Posts: 2,327
Code:
alias test {
tokenize 32 i hope this is what you wanted
echo -s $1-
}

/test


New username: hixxy
Joined: Dec 2002
Posts: 349
S
Fjord artisan
Offline
Fjord artisan
S
Joined: Dec 2002
Posts: 349
This would be a nice feature (it's been suggested before, usually to allow 'encryption' scripts to modify an on *:text as it comes in so other scripts can play with the 'real' text too), or on a larger scale as a /parse command (which wouldn't *modify* the information coming from the irc server but instead allow the user/script to 'fake' messages coming from the server). Khaled has said he has no intention to add /parse as it could lead to some major desyncs between client and server.

I like your suggestion because it could perhaps be applied to certain events only, and would hopefully not be allowed to confuse mIRC (and ultimately the user) to such an extent a /parse command could.

A 'scripted' solution to this is to create a 'middle-man' with sockets and hide/modify/resend information from there.

Joined: Sep 2003
Posts: 4,230
D
Hoopy frood
Offline
Hoopy frood
D
Joined: Sep 2003
Posts: 4,230
you want to change the IP address of a DCC SEND of a file to you?

You can make a work around that well do that, but changing the IP, would cause you to attempt to open a connection to the wrong IP, i dont really see a purpose to it.

Is that what your trying to do?

Joined: Sep 2003
Posts: 4,230
D
Hoopy frood
Offline
Hoopy frood
D
Joined: Sep 2003
Posts: 4,230
Quote:
A 'scripted' solution to this is to create a 'middle-man' with sockets and hide/modify/resend information from there


were you meaning this as a general side step to not being able to rephase the $1- etc or specificly for dcc sends? If its for all things I would be interested in it, as i have run into the "i need to modify the original event contents" problem several times.

Currently im stuck with workarounds, and they only work for some events for obvious reasons.

Joined: Dec 2002
Posts: 349
S
Fjord artisan
Offline
Fjord artisan
S
Joined: Dec 2002
Posts: 349
If you were to create the socket layer you would essentialy be able to handle any event -- limited only by your patience and sanity. smile

Joined: Feb 2004
Posts: 5
C
Cronus Offline OP
Nutrimatic drinks dispenser
OP Offline
Nutrimatic drinks dispenser
C
Joined: Feb 2004
Posts: 5
aha, yes!! thank you very much, i must have completely gone past that when i was trawling through the help files.

cheers laugh

...
...

oh well, it seems /tokenize is local to the function it's being executed it doesn't change what mirc sees when it processes it frown

Last edited by Cronus; 21/02/04 03:10 PM.
Joined: Feb 2004
Posts: 201
J
Jae Offline
Fjord artisan
Offline
Fjord artisan
J
Joined: Feb 2004
Posts: 201
u can always put the tokenize statement at the top of each section of code. or make an alias to run through and process it accordingly. none the less. cheers smile

Joined: Sep 2003
Posts: 4,230
D
Hoopy frood
Offline
Hoopy frood
D
Joined: Sep 2003
Posts: 4,230
he needs the defualt action to use his new $1-, that he cant do he can only block the defualt action.

Joined: Sep 2003
Posts: 4,230
D
Hoopy frood
Offline
Hoopy frood
D
Joined: Sep 2003
Posts: 4,230
if you want to do this, intercept the dcc send, and send one to your self with the new data inserted into it., while halting the original from being processed.


Link Copied to Clipboard