Release Healer Man 0.1.9
This commit is contained in:
1 parent
c245a199b6
commit
d060296ade
74 files changed
+5901
-334
No files matched your search
@@ -1,6 +1,7 @@
|
||||
import { lazy, Suspense, type CSSProperties } from "react";
|
||||
import { classById, raceById } from "../app/characterCatalog";
|
||||
import type { CharacterDraft, CharacterProfile } from "../app/types";
|
||||
import { normalizePreviewFrameRateLimit } from "../game/frameRateSettings";
|
||||
|
||||
const CharacterPreview3D = lazy(() => import("./CharacterPreview3D"));
|
||||
|
||||
@@ -33,6 +34,9 @@ export function CharacterPreview({ character, draft, compact = false }: {
|
||||
const characterClass = classById(source.classId);
|
||||
const name = "name" in source && source.name ? source.name : "New adventurer";
|
||||
const rotation = "rotation" in source ? source.rotation : -8;
|
||||
const previewFrameRate = normalizePreviewFrameRateLimit(
|
||||
"settings" in source ? source.settings?.previewFrameRate : undefined,
|
||||
);
|
||||
const style = {
|
||||
"--race-accent": race.accent,
|
||||
"--class-color": characterClass.color,
|
||||
@@ -45,7 +49,7 @@ export function CharacterPreview({ character, draft, compact = false }: {
|
||||
<AvatarSilhouette gender={source.gender} raceSigil={race.sigil} />
|
||||
) : (
|
||||
<Suspense fallback={<AvatarSilhouette gender={source.gender} raceSigil={race.sigil} />}>
|
||||
<CharacterPreview3D source={source} />
|
||||
<CharacterPreview3D source={source} frameRateLimit={previewFrameRate} />
|
||||
</Suspense>
|
||||
)}
|
||||
<span className="sr-only">{source.gender} {race.name} {characterClass.name} preview</span>
|
||||
|
||||
Reference in new issue
Block a user