1
0
mirror of https://github.com/UzixLS/pacemuzx.git synced 2025-07-19 07:11:20 +03:00

pacemuzx v1.0

This commit is contained in:
Simon Owen
2011-11-08 23:49:42 +00:00
commit 9f263276fe
14 changed files with 2937 additions and 0 deletions

26
remove_rom.pl Executable file
View File

@ -0,0 +1,26 @@
#!/usr/bin/perl -w
# First 4K of Pac-Man ROM
$file = 'pacman.6e';
open FILE, "<$file" and binmode FILE or die "$file: $!\n";
read FILE, $rom='', -s $file;
close FILE;
# Full TAP image for emulator, including ROM
$file = 'pacemuzx.tap';
open FILE, "<$file" and binmode FILE or die "$file: $!\n";
read FILE, $data='', -s $file;
close FILE;
$index = index($data, $rom);
die "ROM image not found in TAP file!\n" if $index < 0;
$file = 'start.part';
open FILE, ">$file" and binmode FILE or die "$file: $!\n";
print FILE substr $data, 0, $index;
close FILE;
$file = 'end.part';
open FILE, ">$file" and binmode FILE or die "$file: $!\n";
print FILE substr $data, $index+16384;
close FILE;