From 6c170d31b0991b3604530fb4411a7b0bf3349de6 Mon Sep 17 00:00:00 2001 From: Gary Talent Date: Wed, 29 May 2024 00:19:58 -0500 Subject: [PATCH] [nostalgia/developer-handbook] Update serialization notes --- developer-handbook.md | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/developer-handbook.md b/developer-handbook.md index 68a20d82..1e72f909 100644 --- a/developer-handbook.md +++ b/developer-handbook.md @@ -546,11 +546,11 @@ a wrapper around the bare formats. ```cpp #include -ox::Result loadPalette1(ox::Buffer const&buff) noexcept { +ox::Result loadPalette1(ox::BufferView const&buff) noexcept { return ox::readMC(buff); } -ox::Result loadPalette2(ox::Buffer const&buff) noexcept { +ox::Result loadPalette2(ox::BufferView const&buff) noexcept { NostalgiaPalette pal; oxReturnError(ox::readMC(buff, pal)); return pal; @@ -582,11 +582,11 @@ ox::Result writeSpritePalette2(NostalgiaPalette *pal) noexcept { ```cpp #include -ox::Result loadPalette1(ox::Buffer const&buff) noexcept { +ox::Result loadPalette1(ox::BufferView const&buff) noexcept { return ox::readOC(buff); } -ox::Result loadPalette2(ox::Buffer const&buff) noexcept { +ox::Result loadPalette2(ox::BufferView const&buff) noexcept { NostalgiaPalette pal; oxReturnError(ox::readOC(buff, &pal)); return pal; @@ -616,11 +616,11 @@ ox::Result writeSpritePalette2(NostalgiaPalette const&pal) noexcept ```cpp #include -ox::Result loadPalette1(ox::Buffer const&buff) noexcept { +ox::Result loadPalette1(ox::BufferView const&buff) noexcept { return ox::readClaw(buff); } -ox::Result loadPalette2(ox::Buffer const&buff) noexcept { +ox::Result loadPalette2(ox::BufferView const&buff) noexcept { NostalgiaPalette pal; oxReturnError(ox::readClaw(buff, pal)); return pal;