Original Post
Hey all. I want to draw a 3D Sphere out of a bunch of blocks. What I’m looking for is a function that will return me a list of 3D coordinates where if I placed a block at each coordinate it’ll create the shape of a 3D sphere. I’m assuming I’d pass into this function the radius of the sphere and the density (ie: size of block relative to radius, is it 5 blocks wide or 100 blocks wide). The result would be a list of 3D coordinates. Let’s assume this is in object space, so the center most point will be 0,0,0. I also want a second version that just returns the outer coordinates, without any of the inner points. I hope that makes sense. If anyone is willing to help me with this I’d really appreciate it. I’m not asking you to write the entire function, but at least help with the math enough for me to understand it then I can run with it. Of course if you feel so obliged to write the whole function I’d be most appreciative as it would allow me to focus more on the logic and game play, but I understand if you just want to point me in the right direction. I’ll leave it to your own prerogative. Thanks!