Merge: Merged various changes from LZKernel by TeamFahQ