Complete rewrite of  https://github.com/GarageGames/Torque3D/pull/566

Removed all the C++ 11 code
Fixed a bug where you couldn't paint the last pixel on the edges.
This either needs to be moved below TerrainBlock class declaration as `TerrainBlock` type doesn't exist until afterward, which is what is causing the build failures, or insert a `class TerrainBlock;` above this line to make the compiler happy.