Skip to content

Commit

Permalink
Fix UI palette text control code. Palette indices now go from 1 to 8
Browse files Browse the repository at this point in the history
  • Loading branch information
chrismaltby committed Nov 23, 2024
1 parent 614be7b commit 5b80639
Show file tree
Hide file tree
Showing 4 changed files with 10 additions and 2 deletions.
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
- Fix issue where changing the dimensions of a sprite png image could cause the sprite editor's tile palette to display incorrectly
- Fix line numbers in code editor for GBVM scripts with more than 999 lines
- Fix issue preventing projects being created with the name "project"
- Fix UI palette text control code. Palette indices now go from 1 to 8, because zero byte is a string terminator [@untoxa](https://github.com/untoxa)

## [4.1.3] - 2024-09-16

Expand Down
2 changes: 1 addition & 1 deletion appData/src/gb/engine.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"version": "4.2.0-e4",
"version": "4.2.0-e5",
"fields": [
{
"key": "INPUT_PLATFORM_JUMP",
Expand Down
2 changes: 1 addition & 1 deletion appData/src/gb/src/core/ui.c
Original file line number Diff line number Diff line change
Expand Up @@ -389,7 +389,7 @@ UBYTE ui_draw_text_buffer_char(void) BANKED {
if (vwf_current_offset) ui_print_reset();
break;
case 0x0b:
text_palette = (*++ui_text_ptr & 0x07);
text_palette = (((*++ui_text_ptr) - 1u) & 0x07u);
break;
case '\r': // 0x0d
// line feed
Expand Down
7 changes: 7 additions & 0 deletions src/lib/project/ejectEngineChangelog.ts
Original file line number Diff line number Diff line change
Expand Up @@ -793,6 +793,13 @@ const changes: EngineChange[] = [
"src/core/vm_music.c",
],
},
{
version: "4.2.0-e5",
description: createDescription("Fixes", [
"Fix UI palette text control code. Palette indices now go from 1 to 8, because zero byte is a string terminator",
]),
modifiedFiles: ["src/core/ui.c"],
},
];

export const isKnownEngineVersion = (currentVersion: string): boolean => {
Expand Down

0 comments on commit 5b80639

Please sign in to comment.