changed for a real 3D engine