added 3D init, and function for genereating a node