|
Joined: Sep 2005
Posts: 116
Vogon poet
|
OP
Vogon poet
Joined: Sep 2005
Posts: 116 |
i would like a "are u usre u wana unload .. .bla ? "
when unlaoding scripts since i accendentily unlaoded a NN script so it completely fooked now
|
|
|
|
mIRCManiac
|
mIRCManiac
|
This would suck. If you don't understand anything about scripts then maybe you shouldn't be screwing around with them and accidently unloading them.
|
|
|
|
Joined: Sep 2005
Posts: 116
Vogon poet
|
OP
Vogon poet
Joined: Sep 2005
Posts: 116 |
sjesus man who says i dont undersntad scripts ?
whne i was testing my script (to see if the loading worked on clean settings) i unloaded and reloaded it just when i wanted to click load i accendentily clicked unload so i unlaoded my script + the one of the nnscripts
|
|
|
|
Joined: Feb 2004
Posts: 2,013
Hoopy frood
|
Hoopy frood
Joined: Feb 2004
Posts: 2,013 |
/help on unload /help $input
|
|
|
|
mIRCManiac
|
mIRCManiac
|
Good idea  on *:UNLOAD: {
if (!$input(Are you sure you want to unload this script?,dwyk20,Unloading $nopath($script))) {
var %i = 1
while ($script(%i)) {
if ($v1 == $script) {
echo -acei2 info * Reloading script $+(',$script,') back into the $ord(%i) position.
.timer 1 0 reload $+(-rs,%i) $qt($script)
return
}
inc %i
}
}
}
|
|
|
|
mIRCManiac
|
mIRCManiac
|
Sorry, didn't mean anything by it. There shouldn't be a warning for unloading scripts IMO. I really would hate to see this unless there were a check box that said something like 'Always show this warning' selected by default, or something. Actually I wish the LOAD event would have the same option, and of course having somewhere in the options dialog to enable/disable these, and only in the options dialog.
Last edited by mIRCManiac; 12/04/06 12:34 PM.
|
|
|
|
Joined: Sep 2005
Posts: 116
Vogon poet
|
OP
Vogon poet
Joined: Sep 2005
Posts: 116 |
oke thanks for your help sorry i backfired so hard on it
|
|
|
|
Joined: Sep 2005
Posts: 2,630
Hoopy frood
|
Hoopy frood
Joined: Sep 2005
Posts: 2,630 |
If the script is as "fooked" as he describes it then reloading the file probably won't help.
|
|
|
|
mIRCManiac
|
mIRCManiac
|
The NN script as a system is probably only "fooked" because this one file was unloaded, especially if there are timers running to call aliases that are in this file. That's what I thought he meant anyway. *shrug*
|
|
|
|
Joined: Feb 2004
Posts: 2,013
Hoopy frood
|
Hoopy frood
Joined: Feb 2004
Posts: 2,013 |
I didn't mention anything about reloading o.O but I guess it was directed to mIRCmaniac :tongue:
|
|
|
|
mIRCManiac
|
mIRCManiac
|
Well reloading was all I could think of, you can't stop the script from being unloaded. Unless you meant just to warn or something.
|
|
|
|
Joined: Sep 2005
Posts: 116
Vogon poet
|
OP
Vogon poet
Joined: Sep 2005
Posts: 116 |
well its acutaly wut i hoped for thanks :tongue:
and yes nns only fooked becase it missed something :tongue:
|
|
|
|
Joined: Dec 2002
Posts: 580
Fjord artisan
|
Fjord artisan
Joined: Dec 2002
Posts: 580 |
Rather than using unload events. I agree if a script is unloaded in mIRC's EDITOR, it should prompt you for a confirmation.
|
|
|
|
Joined: Sep 2005
Posts: 2,630
Hoopy frood
|
Hoopy frood
Joined: Sep 2005
Posts: 2,630 |
No no, it was for you. Assuming that you were offering a scripted way to stop the script from unloading.. the on unload event doesn't let you stop the script from unloaded in any way (/haltdef, /return and /halt all do nothing), so I was pointing out that on unload wouldn't really help.
|
|
|
|
Joined: Feb 2004
Posts: 2,013
Hoopy frood
|
Hoopy frood
Joined: Feb 2004
Posts: 2,013 |
on *:unload:{
if (!$input(Are you sure you want to unload $script ?)) {
.timer 1 0 .reload -rs $shortfn($script)
}
} This doesn't load it in the same position though, but like mircmaniac showed, that's possible as well, I just can't be bothered, as this is an example, not final code.
|
|
|
|
Joined: Sep 2005
Posts: 2,630
Hoopy frood
|
Hoopy frood
Joined: Sep 2005
Posts: 2,630 |
That wouldn't really help if there was any other on unload code in the file as it could be triggered.
|
|
|
|
Joined: Feb 2004
Posts: 2,013
Hoopy frood
|
Hoopy frood
Joined: Feb 2004
Posts: 2,013 |
So? No one is saying it's perfect, but that's about as close as it will get. Atleast I'm trying to help him with something for the time being. He said himself that it is what he hoped for... (mircmaniacs code, my idea). I can't think of one reason why one would criticize the current help he's been given, because its only purpose is to help him, not to solve the feature suggestion, as it's not really possible to do it in a perfect way. We already know that, no need to repeat it all the time.
|
|
|
|
Joined: Sep 2005
Posts: 2,630
Hoopy frood
|
Hoopy frood
Joined: Sep 2005
Posts: 2,630 |
In your original post you said nothing about it not being the exact thing he wanted.
|
|
|
|
|