Fixed the `debugPanel` not showing up and other small improvements