I have a small mathematical game. A random number with uniform distribution between 1 and 10 is drawn, the player must guess any number except the the one drawn.The method I have found is by selecting the same number for every draw, the player will win 9 times out of 10. My question is , is...
In a 3D plane, there is a point with it's X,Y and Z coordonates known and a second 3D plane within the first plane with it's origins X,Y and Z coordonates relative to the parent plane origin.
How do I find the X,Y and Z coordonates of that point relative to the origin of the second 3D plane...
I still have a problem with my rotation function.
I rewrote the rotation function because the previous one didn't work as I wanted.
Now if I rotate a line in a 2D space, if I give it fixed values linke this:
line(400,400,rotate(1,400,400,400,600,Ub2),rotate(2,400,400,400,600,Ub2));
...it...
I'm making a 3D rotation of a poligon.The problem is when I rotate some points in 2D, it works, but if I use the same function to rotate the same points in a 3D perspective , while rotating the vertices move to the center of the object and remain there.
I also wrote the 3D rendering part.At...