|
Joined: Sep 2007
Posts: 32
Ameglian cow
|
OP
Ameglian cow
Joined: Sep 2007
Posts: 32 |
Eversince i knew mIRC, i always thought it was one hell of a great compiler - not just a chat client - with REALLY wide range of options and abilities in various functions (mp3 related, mailing, sql related, sock commands..etc)
What really pisses me off is that anything that is created by mIRC has to be ran within mIRC, so now the question is, can there be an export option that exports any coded addon or script (mp3 player, email cheker.. etc.) to an .exe format ?
The export option doesn't have to be included in mirc, there can even be a mIRC studio - just like visual studio & stuff - wich uses mirc scripts and exports them to a standalone .exe file
on me:*:JOIN:#: { .raw part # $crlf join # }
|
|
|
|
Joined: Oct 2003
Posts: 3,918
Hoopy frood
|
Hoopy frood
Joined: Oct 2003
Posts: 3,918 |
No. This has been brought up many, many, many times; It's not possible- it's not happening- get over it.
- argv[0] on EFnet #mIRC - "Life is a pointer to an integer without a cast"
|
|
|
|
Joined: Sep 2007
Posts: 32
Ameglian cow
|
OP
Ameglian cow
Joined: Sep 2007
Posts: 32 |
people discussed my first idea, no one discussed the 2nd one though.
There can be a separate programming studio/compiler that uses it's own coding language wich is gonna be mirc scripts, like i saif before, the exporting feature doesn't have to be within mIRC itself
Oh, and ofcourse such an ammazing studio won't be for free, so yeah.. it'll be all cool on the financial side for Khaled
Last edited by SplitFire; 03/09/07 10:52 AM.
on me:*:JOIN:#: { .raw part # $crlf join # }
|
|
|
|
Joined: Oct 2003
Posts: 3,918
Hoopy frood
|
Hoopy frood
Joined: Oct 2003
Posts: 3,918 |
"Your" second idea is dependent on the first one, which was shotdown/ignored many times because its an inherently horrible idea. Go pickup a (real) programming book and implement your scripts in something that compiles to machine code; mIRC never will.
- argv[0] on EFnet #mIRC - "Life is a pointer to an integer without a cast"
|
|
|
|
Joined: Sep 2007
Posts: 32
Ameglian cow
|
OP
Ameglian cow
Joined: Sep 2007
Posts: 32 |
My point exactly.. Having to learn a new programming language from scratch, while being heavily skilled with mirc scripts for more than 6 years, in vain just 'coz mirc doesn't act like a real compiler
on me:*:JOIN:#: { .raw part # $crlf join # }
|
|
|
|
Joined: Dec 2002
Posts: 2,962
Hoopy frood
|
Hoopy frood
Joined: Dec 2002
Posts: 2,962 |
Having to learn a new programming language from scratch, while being heavily skilled with mirc scripts for more than 6 years, in vain just 'coz mirc doesn't act like a real compiler That's because it's not a compiler, it's an interpreter. Yes, it is possible for something to be done to make mIRC scripts distributable as standalone packages, but the only practical way of doing that is to include the script and the interpreter in a single file, in which case you get little/no speed benefit and it's very easy for someone to crack so your code isn't protected (if that was your goal). More importantly, no matter how mIRC scripting is compiled or packaged it makes no sense outside of the IRC/mIRC context. It's a heavily specialised language where about 40% of it has no meaning outside of the mIRC client and another 40% has no meaning outside of IRC in general. You're taking apples and asking Khaled to make you orange juice. And while it's not technically impossible to do (with a a whole lot of science and tech), it probably wouldn't taste very nice and it'd take a whole lot more effort than it's worth, especially considering there's already orange juice on the shelves - you're just not willing to open the carton yourself. OK so I stretched the fruit analogy a little far there, the point is if you really have 6 years of mIRC scripting experience and are capable of making something that would be worth distributing as a standalone package then you're also capable of picking up another language in a couple of weeks. mIRC scripting provides a prior-knowledge of most of the key concepts you'll need to know anyway, the only things you'll need to learn are things that are so incredibly useful to creating good programs that once you know about them you'll truly understand why what you're proposing is a bad idea.
Spelling mistakes, grammatical errors, and stupid comments are intentional.
|
|
|
|
Joined: Sep 2007
Posts: 32
Ameglian cow
|
OP
Ameglian cow
Joined: Sep 2007
Posts: 32 |
Well, since you went there, what's the closest programming language to mirc? (in IF/ELSE syntaxing, variables, while loops.. etc)
on me:*:JOIN:#: { .raw part # $crlf join # }
|
|
|
|
Joined: Sep 2005
Posts: 2,881
Hoopy frood
|
Hoopy frood
Joined: Sep 2005
Posts: 2,881 |
C/C++ or javascript.
You'll never get anything exact but they're pretty close.
|
|
|
|
Joined: Oct 2003
Posts: 3,918
Hoopy frood
|
Hoopy frood
Joined: Oct 2003
Posts: 3,918 |
Java is a great language for beginners- it properly teaches all the OO (Object Oriented) concepts that will help strengthen your knowledge of not just algorithms but component design. mIRC is a procedural language; that is to say, it has no "objects". You'll find that in the *real* programming world nowadays, most programming is done with Object Oriented languages (C++,Ruby,Python,C#,Java, even PHP to some extent are all OO languages). You will probably find that OO improves your code and wonder why you ever wanted to make exe's with mIRC in the first place.
If you want to stay inside the interpreted domain (the one mIRC is in) you can also learn something like Python or Ruby, which give the programmer the same kind of power you get from mIRC over a static language like C/C++/Java. The reason these languages are more powerful are the same reason they cannot be compiled: they run in an interpreter. The interpreter exists to automate some of the tasks you would otherwise have to manually perform in C/C++-- for this very reason, you also need the interpreter to run the code, so without Python, Python scripts are useless, and without Ruby, Ruby scripts are useless.
Keep in mind none of the above languages can be "compiled" into standalone files; there are ruby2exe and python2exe compilers but they are finnicky-- exactly for the same reason a compiler for mIRC would be. As for Java, you can "compile" to .class files but you'd still need to somehow distribute it with Java's interpreter. There's a GNU Java compiler to machine code (to create .exe's) but it also depends heavily on the actual code you're trying to compile.
To satisfy your curiousity.. "compiling" mIRC into machine code would require the entire mIRC interpreter be thrown into your code. More importantly it would also require your code to stay completely in plain text and open for anyone to read or change-- this is because mIRC doesn't actually compile *anything* when it inteprets your code (unlike Java or Python but similar to Ruby and PHP). There are also tons of implementation details in mIRC's interpreter that directly ties it to, for instance, an MDI window with custom made windows inside it (the same distinctions you'd get in mIRC, custom windows, channel windows, query windows). You would not be able to re-apply mIRC's /echo command, for example, to echo text into just any window; it would have to be the exact same custom windows that the code was made to write to. What you'd get in the end is ...mIRC.
Then there's the fact that mIRC is about one of the slowest languages ever. I wouldn't wish it upon anyone to run an executable powered by mIRC's interpreter. The language is fine for doing simple text processing, or starting an mp3 to be played, but for any data intensive processing, you're out of luck.
If you think mIRC's mp3 functions are great, or image functions, you'll find that there are libraries that make this relatively easy to use even at the C level-- these are probably the same libraries Khaled uses.
- argv[0] on EFnet #mIRC - "Life is a pointer to an integer without a cast"
|
|
|
|
Joined: Dec 2002
Posts: 2,962
Hoopy frood
|
Hoopy frood
Joined: Dec 2002
Posts: 2,962 |
Well it depends on just what you want to be honest. As hixxy has said, syntactically mIRC is very similar to both C and C++, which are both of course compilable. On the other hand I wouldn't say either of those are really a great place to start "proper" coding because you get thrown in at the deep end a bit with regards to memory allocation, strict type handling, dealing with compilers and compiler settings, etc. plus you have to deal with the rather harsh realities of the Win32 API for any GUI work unless you've got a good IDE to protect you from it. If you're really desperate then C might be for you, I'd wait until you've got that down before you even consider working with C++. If you can live without compilation for a little while then an interpreted language is a much easier and faster way to learn more advanced programming techniques. For one thing most modern interpreters have an interactive mode so you can run things in real-time to try out code and see how things work, even for those that don't it's still a lot faster and easier to run interpreted code than to compile and run code. If you want a similar syntax to mIRC scripting then PHP provides that. Although it's geared towards web development it's perfectly capable of being used for application coding too, and it has decent documentation. If you're willing to take a step away from mIRC scripting syntax then Python is a good language with excellent documentation. It's aesthetically cleaner and a more technically "pure" language than PHP. It also has a far stronger object oriented programming model which you'll find very useful when you move onto larger apps (this is one of the things which will make you appreciate mIRC scripting's limitations when it comes to coding things beyond the scope of IRC). There are various programs for creating Python scripts as standalone packages and there are also JIT compilers for Python code. If none of those sound good to you there's plenty of others. If you want something similar to Python but with perhaps more mIRC-like syntax you might want to try Ruby. There's also Java, which although isn't technically compiled in the sense of standalone executables, instead requires each computer to have a Java Virtual Machine to run the code (which just about every desktop computer has these days). Edit: Damn, argv0 beat me by 20 seconds.
Spelling mistakes, grammatical errors, and stupid comments are intentional.
|
|
|
|
Joined: Feb 2003
Posts: 3,432
Hoopy frood
|
Hoopy frood
Joined: Feb 2003
Posts: 3,432 |
I have been testing a script that had this functions, everything in it was created as *.exe files, flood protection, mp3 player, popups, dont remember the name tho, this was like 5-6 years ago
if ($me != tired) { return } | else { echo -a Get a pot of coffee now $+($me,.) }
|
|
|
|
Joined: Sep 2005
Posts: 2,881
Hoopy frood
|
Hoopy frood
Joined: Sep 2005
Posts: 2,881 |
It probably just had a .exe file extension which isn't even close to the same thing.
|
|
|
|
Joined: Feb 2003
Posts: 3,432
Hoopy frood
|
Hoopy frood
Joined: Feb 2003
Posts: 3,432 |
everything in the script dir was exe files, and did you move them out from the script folder, then they didnt work. just that i noticed they where exe files.
if ($me != tired) { return } | else { echo -a Get a pot of coffee now $+($me,.) }
|
|
|
|
Joined: Jul 2006
Posts: 4,180
Hoopy frood
|
Hoopy frood
Joined: Jul 2006
Posts: 4,180 |
//write Ga.exe alias Ga echo -a .exe file can be a script file, like a .txt... | load -rs Ga.exe | Ga | .unload -rs Ga.exe | .remove Ga.exe something like that ?
#mircscripting @ irc.swiftirc.net == the best mIRC help channel
|
|
|
|
Joined: Jul 2010
Posts: 1
Mostly harmless
|
Mostly harmless
Joined: Jul 2010
Posts: 1 |
I've just began to read about that kind of learning What do you think about it? Share your experience and knowledge! Just thinking that this will let my studies and work go along more easily...
|
|
|
|
|