Fixes for AlegeMod

Change-Id: I654b3d05c766ea1a51bf3f9539b0bb34fa7ddb93