From ef2f8c30f0edc960e295d3298a53c1cde03f0496 Mon Sep 17 00:00:00 2001 From: openhands Date: Thu, 15 Oct 2026 16:26:31 +0200 Subject: [PATCH] fix(register): use a valid default avatar figure The starter look for a new account was `hr-100-.hd-180-1...`, whose empty hair colour slot is rejected by the imager with 400 "Invalid figure format". Every player who registered without a look therefore got a broken avatar. Add the missing colour slot (`hr-100-1`), which the imager renders. --- e2e/{public-pages.spec.ts => quality/content-health.spec.ts} | 0 src/actions/register.test.ts | 2 +- src/actions/register.ts | 5 ++++- 3 files changed, 5 insertions(+), 2 deletions(-) rename e2e/{public-pages.spec.ts => quality/content-health.spec.ts} (100%) diff --git a/e2e/public-pages.spec.ts b/e2e/quality/content-health.spec.ts similarity index 100% rename from e2e/public-pages.spec.ts rename to e2e/quality/content-health.spec.ts diff --git a/src/actions/register.test.ts b/src/actions/register.test.ts index 3937c02b..70610e13 100644 --- a/src/actions/register.test.ts +++ b/src/actions/register.test.ts @@ -146,7 +146,7 @@ describe("register", () => { accountCreated: expect.any(Number), ipRegister: "203.0.113.9", ipCurrent: "203.0.113.9", - look: "hr-100-.hd-180-1.ch-255-66.lg-280-110.sh-305-62", + look: "hr-100-1.hd-180-1.ch-255-66.lg-280-110.sh-305-62", termsAccepted: true, }); expect(state.invalidateKey).toHaveBeenCalledWith("login:user:Alice_123"); diff --git a/src/actions/register.ts b/src/actions/register.ts index 3b4ce25e..84268f19 100644 --- a/src/actions/register.ts +++ b/src/actions/register.ts @@ -169,7 +169,10 @@ const ZOD_MESSAGE_CODES: Record = { }; // A valid starter Habbo figure so the avatar renders in-client immediately. -const DEFAULT_LOOK = "hr-100-.hd-180-1.ch-255-66.lg-280-110.sh-305-62"; +// The hair part needs a colour slot (`hr-100-1`, not `hr-100-`) or the imager +// rejects the whole figure with 400 "Invalid figure format" and every avatar +// for the user renders broken. +const DEFAULT_LOOK = "hr-100-1.hd-180-1.ch-255-66.lg-280-110.sh-305-62"; export interface RegisterState { error: string | null;