mIRC Home    About    Download    Register    News    Help

Print Thread
Some final help [Hopefully] #169124 19/01/07 06:42 PM
Joined: Oct 2006
Posts: 60
M
moshkin Offline OP
Babel fish
OP Offline
Babel fish
M
Joined: Oct 2006
Posts: 60
Im taking a break from learning mIRC scripting, ive got loads of stuff to do, plus im in a really important year in my schooling, so ive decided to just add the finishing touches to my scripts, sort them out so when i come back i can easily pick up where i left off, but right now some of my scripts seem to not work, so i was wondering if you could go over them and see where ive gone wrong. Heres a link to the scripts: http://h1.ripway.com/moshkin/mirc.txt
Some of them dont work when i move them to the top they work, so i think somewhere there are incomplete scripts but i fail to find them.

Yours Truely
Moshkin

Re: Some final help [Hopefully] [Re: moshkin] #169125 19/01/07 06:53 PM
Joined: Jan 2007
Posts: 1,156
D
DJ_Sol Offline
Hoopy frood
Offline
Hoopy frood
D
Joined: Jan 2007
Posts: 1,156
I have enough going finallizing two script but from your description I just wanted to make sure you were aware abotu events.

You can only have one event in a file. mIRC will process the first event, from top down, and ignore any other below it. There are ways around this.

1. Most easiest, put them in seperate files.
2. Group all like events into one event.
3. You may have more than one of the same event in the same file if they have a different level or trigger.

For Instance:

on *:text:*:#:{ < this here will process ALL text events, so no other text event may follow.

on *:text:Hi *:#:{ < this will only trigger if they say Hi *, so if other text events after this would still be run but not during this exact event.

on admin:text:*:#:{ < this will only trigger if an admin speaks so it may share the file with other text events that aren't the admin level.

on admin:text:*:#:{ }
on host:text:*:#:{ }
on *:text:Hi *:#:{ }
on *:text:Goodbye *:#:{ }
on *:text:*:#:{ }

This will work because the text event which encompasses any words from anyone is last. So, in a text event, if they aren't admin, not a host, they dont say Hi * and don't say Goodbye *, then it will process the last event which is anyone saying anything.

This is true for all events. (search help for "On")

Re: Some final help [Hopefully] [Re: DJ_Sol] #169215 20/01/07 12:01 PM
Joined: Oct 2006
Posts: 60
M
moshkin Offline OP
Babel fish
OP Offline
Babel fish
M
Joined: Oct 2006
Posts: 60

Quote:

1. Most easiest, put them in seperate files.

How would i go about doing that?

Re: Some final help [Hopefully] [Re: moshkin] #169218 20/01/07 12:25 PM
Joined: Dec 2006
Posts: 80
Scripto Offline
Babel fish
Offline
Babel fish
Joined: Dec 2006
Posts: 80
Open up your editor... in your toolbar, click 'file', then scroll down and click 'new'. mIRC will create a new file for you to put scripts into.

You can click on ok at the bottom, or click 'file' again, and then click 'save', or 'save as' to rename the new file.

If you have an event twice in the same script, as DJ_Sol said, it will execute from top to bottom, and halt after the first one it sees. The second one needs to be in a new, or different file.


Scripto ---- Life is about the relationships. The correct code being: $replace($them,$you,$me)