The copy-paste strikes again.
Import cleanup.
Added setting for hologram render distance.
Added some settings for easier debugging.
Minor refactoring.
Throwing an actual error back to Lua if palette index is invalid (instead of returning nil, message).
More palette index checks to avoid getting into a derpy state.