Skip to content

Commit

Permalink
Tweaks to MKRE2 code
Browse files Browse the repository at this point in the history
  • Loading branch information
maxim-zhao committed Jul 11, 2023
1 parent 22fa00f commit 0daa7ff
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 6 deletions.
2 changes: 1 addition & 1 deletion compressors/gfxcomp_magicknight.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -218,7 +218,7 @@ extern "C" __declspec(dllexport) int compressTiles(
}

// Else emit the smaller
std::ranges::copy(smaller, std::bit_cast<uint8_t*>(pDestination));
std::ranges::copy(smaller, stdext::checked_array_iterator(pDestination, destinationLength));

return static_cast<int>(smaller.size());
}
6 changes: 1 addition & 5 deletions decompressors/Magic Knight Rayearth 2 decompressor.asm
Original file line number Diff line number Diff line change
Expand Up @@ -142,15 +142,11 @@ _lz:
out (c), l
out (c), h
inc hl
push hl ; Delay
pop hl
in a, ($be)
push hl ; Delay
pop hl
; Write byte
out (c), e
out (c), d
out ($be), a ; No delay here
out ($be), a
ei
inc de
djnz -
Expand Down

0 comments on commit 0daa7ff

Please sign in to comment.