OOP kind of basic scripting..eehh converter thing?
Blitz3D Forums/Blitz3D Beginners Area/OOP kind of basic scripting..eehh converter thing?
| ||
ok, this is just a show off on something i'm tinkering with: It has no real application but its really uh i'm not sure....scripting maybe... well here it is. Well I got inheritance and part of encapsulation to work, I think. Will convert: to working b3d code: Source |
| ||
nice. it seems mark is trying to do the opposite with bmax2 :) edit: what is out.bb? edit2: nevermind I see... it doesnt work if out.bb isnt made before the file is compiled though.. I think a b3d to bmax converter would be relatively easy to make seing how simple this seems. |
| ||
Yea, it seems that "Include file$" is compiled before any other procedural code. Which is kind of dumb, as it skips program flow, making this which should work, not work. Edit: I mean, it copy's the code into the source file before compiled (kind of), but as the file isn't created yet it errors. Wish there was a way around this. like an ExecuteBlitz3D( file$ ) would be awesome. That way it works sequentially after the main chunk of code is run. |
| ||
Blitz3D isn't interpreted, so there's no way you could execute dynamically generated source at runtime - you need a scripting language for that. |
| ||
oops updated, with stuff. cool!? @Yasha: Maybe Blitz3D code could be made into an interpreted language via a userlib? That might have some usefulness. |
| ||
Sure, that was called BlitzVirtualMachine (now BriskVM) :) |
| ||
Big update for this bit of code. I should explain, I know very little about object oriented programming, and I don't know what I'm missing so if you do please let me know. Thanks. Will Convert: To working Blitz3d Code: Source: |
| ||
There is a more updated version of the above in my worklogs. Wanted to show how the progress is going, and i'm not sure this should be here anymore it's kind of advanced to outside beginners stuff but, whatever i guess. I'm still working out the kinks but i have the beginning to OOPS to C++. will convert OOPS: to working c++: to early to hand out the source cause I have to figure out how to handle string variables better, well class string variables are easy but general strings are going to be a bit harder. keeping track of individual variables is a pain but it can be done. Edit: After a bit of research I found an easy way to do stings. |