From 00619cbe538c9ff651ff436439c9f212e0c313a5 Mon Sep 17 00:00:00 2001 From: slack Date: Mon, 30 Jun 2008 02:21:50 +0200 Subject: [PATCH] Fix al mostrar entrypoint --- GBRom.cc | 8 ++++++-- GBRom.h | 2 +- 2 files changed, 7 insertions(+), 3 deletions(-) diff --git a/GBRom.cc b/GBRom.cc index 8d0ddb8..87eb926 100644 --- a/GBRom.cc +++ b/GBRom.cc @@ -18,8 +18,12 @@ void log_rom_header(GBRom *rom, Logger::log_level level) out << "Logging ROM header data:" << endl; out << std::hex << std::right << std::setfill('0'); - out << "Entrypoint: 0x" << std::setw(8) << - rom->header.entry_point << endl; + out << "Entrypoint: " << std::setfill('0') << + std::setw(2) << int(rom->header.entry_point[0]) << " " << + std::setw(2) << int(rom->header.entry_point[1]) << " " << + std::setw(2) << int(rom->header.entry_point[2]) << " " << + std::setw(2) << int(rom->header.entry_point[3]) << " " << + endl; out << "SGB flag: " << int(rom->header.sgb_flag) << endl; out << "Cartridge type: " << int(rom->header.cartridge_type) << endl; diff --git a/GBRom.h b/GBRom.h index 365f900..8065e32 100644 --- a/GBRom.h +++ b/GBRom.h @@ -41,7 +41,7 @@ namespace cartridge_types { struct GBRomHeader { u8 dummy[256]; // ROM beginning, before header - u32 entry_point; // 0100-0103 + u8 entry_point[4]; // 0100-0103 u8 nintendo_logo[48]; // 0104-0133 union { struct { -- 2.34.1