Have you tried it on a different computer? Do you have other scripts loaded at the same time? Are you using any DLLs or COM calls? If mIRC crashes when you open the Options window, you may have a corrupted mirc.ini file. Try renaming it (with mIRC closed) and then run mIRC to recreate a new mirc.ini; load your script file only and see if the crashing continues.

-genius_at_work