Core/Misc: Removed unused defines, added missing include and removed a few warnings