Add emulator message system, reorganize stuff