feat: skip BIOS by default

This commit is contained in:
Muhammad Nauman Raza 2024-03-23 20:51:03 +00:00
parent c107fd1447
commit d8dd99c9e4
No known key found for this signature in database
GPG key ID: 31BC90D626D2DBBE
4 changed files with 3 additions and 21 deletions

View file

@ -28,9 +28,6 @@ args:
long: rtc
help: Force cartridge to have RTC
required: false
- skip_bios:
long: skip-bios
help: Skip running bios and start from the ROM instead
- debug:
long: debug
help: Use the custom debugger
@ -49,4 +46,4 @@ args:
help: Text file with debugger commands to run
required: false
requires:
debug
debug

View file

@ -102,10 +102,8 @@ fn main() -> Result<(), Box<dyn std::error::Error>> {
// normal_panic(panic_info);
// }));
if opts.skip_bios {
println!("Skipping bios animation..");
gba.skip_bios();
}
// Skip the BIOS animation
gba.skip_bios();
if opts.gdbserver {
gba.start_gdbserver(opts.gdbserver_port);

View file

@ -21,10 +21,6 @@ pub struct Options {
#[structopt(long, parse(from_os_str), default_value = "gba_bios.bin")]
pub bios: PathBuf,
/// Skip running the bios boot animation and jump straight to the ROM
#[structopt(long)]
pub skip_bios: bool,
/// Do not output sound
#[structopt(long)]
pub silent: bool,

View file

@ -198,15 +198,6 @@ impl Gpu {
}
}
pub fn skip_bios(&mut self) {
for i in 0..2 {
self.bg_aff[i].pa = 0x100;
self.bg_aff[i].pb = 0;
self.bg_aff[i].pc = 0;
self.bg_aff[i].pd = 0x100;
}
}
/// helper method that reads the palette index from a base address and x + y
pub fn read_pixel_index(&mut self, addr: u32, x: u32, y: u32, format: PixelFormat) -> usize {
match format {