You are not a real programmer until you end all your sentences with semicolons; (c) 2000 ROAD Programming
Visit the ROAD Programming Website for more programming help.
Visit the ROAD Programming Website for more programming help.
quote: Original post by Yanroy
Ok... Of all the different scripting projects I have undertaken, I can actually make this one work. I know it. I am going to make a REALLY screwed up ASM interpreter, with some java and basic thrown in for good measure, something like this:
60% improper ASM, core language
25% BASIC, string manipulation, goto, gosub
10% Java, class-like system of accessing stack and registers
5% Other cool features grabbed from different places
I am going to make it instantly interpretable, so I can do a command line type thing. I am also going to have "fields" which are pointers to data stored in the native C++ program. They can be accessed and changed. Just one problem... If my C++ program that uses the scripting language is OO, and the scripting language isn''t, after I pass all of the members of the main class to the script, how do I know what other elements the script needs (aka a player standing next to the main character, a tree, AI code that runs in the background)? I can''t have the script ask for it, because then I would need to have a WindowProc() type function passed into the script, which would mean one script per object, instead of one script per class or even per game.
The language would be used for things like magical spells or trade centers on undiscovered planets. Even as the AI for an added-in creature. It has the ability to call native C++ functions, but can''t pass any parameters. Its only real connection with the "real" world are the fields.
--------------------
You are not a real programmer until you end all your sentences with semicolons; (c) 2000 ROAD ProgrammingVisit the ROAD Programming Website for more programming help.