Editor: Fix crash if the smoothed terrain vertex belongs to an unloaded cell (#8686)
Closes #8686 (closed). And goes nuts on unnecessary refactoring since I was reformatting everything anyway. There's also a minor precision improvement (the height change is no longer forced to be rounded by integer conversion).
The issue isn't the same as #8299 (closed) because that was about accessing the neighbor cells and this one is about accessing the current cell. The important change is calling allowLandShapeEditing
to create the cell before its data is accessed.