Improving 3D plot

It can now somehow plot received array, but some improvements+cleanup
are still required