Omnimaga
Calculator Community => TI Calculators => Axe => Topic started by: annoyingcalc on July 02, 2011, 08:36:39 pm
-
Is 3D possible in Axe? If so can I make a game like maze 3D (on ticalc) in Axe? Also post sprites and code I could use (Axe 5.3b)
-
3D is definitely possible in Axe. In fact, I've done it before:
(http://www.omnimaga.org/index.php?action=dlattach;topic=5675.0;attach=4939;image)
You can find the thread I made for this project, which I called YAAR, here (http://ourl.ca/8272). If you want to get an idea for how I did it, I attached a zip file containing the source and executable for it. Feel free to look at my code to learn how it works and maybe write your own engine, or you can just use my engine. If you do the latter, I would request that you please credit me for the raycasting engine in any project you make with it, though.
-
cool I will try it out and can I use some of the source?
-
Sure, I'm not really doing anything with the engine so you can use it if you like. My only request is that if you use this engine, you credit me for my hard work making it. :)
-
cool I will try it out and can I use some of the source?
I wish you good luck in trying to use it. I looked at it and my head exploded lol xP
-
Yes I will give credit WOAH +21 RESPECT FOR ONE POST!
-
Yes my head almost exploded I added sidestepping but not muchI need to figure out what code does piece by piece (I was up all night looking at it(not joking I did))
-
Keep in mind that this is raycasting, which has more limitations in order to have a reasonable speed on the calculator.
-
Yes but still I will add stuff and I will make a fast less feature version and a slower but more features version
-
I wondered from this, if it was possible to have true 3D, the kind where you could look up and down. And I found these.
http://www.falloutsoftware.com/tutorials/gl/gl0.htm (http://www.falloutsoftware.com/tutorials/gl/gl0.htm)
http://gamecode.tripod.com/tut/tut03.htm (http://gamecode.tripod.com/tut/tut03.htm)
It actually doesn't seem that complicated to be able to look up and down, I mean, here's the code to make a point look 3D
// initialize point
POINT3D point = { 5, -3, 2 };
// find the right position on the screen in 2D coordinates
int x2d = HALFWIDTH + point.x * ViewingDistance / point.z;
int y2d = HALFHEIGHT + point.y * ViewingDistance / point.z;
// project the 3D point to the screen
Pixel(x2d, y2d);
And here's the equations to move the camera
x'=z*sin(yaw)+x*cos(yaw)
y'=y
z'=z*cos(yaw)-x*sin(yaw)
x"=x'
y"=y'*cos(pitch)-z'*sin(pitch)
z"=y'*sin(pitch)+z'*cos(pitch)
x"'=y"*sin(roll)+x"*cos(roll)
y"'=y"*cos(roll)-x"*sin(roll)
z"'=z"
Idk how you could do it with planes and textures but, at least with points, it doesn't seem too taxing. :P
I could be completely and utterly wrong though. :S
-
Yes I figured out how to move it easily but planes and textures like you say are hard but up and down I could not think of code to add for it to work I will try that