логика выделена в отдельный набор классов

This commit is contained in:
azykov@mail.ru
2026-09-05 10:24:24 +03:00
parent 2f57140899
commit 10041d9593
16 changed files with 1294 additions and 469 deletions
+2 -2
View File
@@ -1,13 +1,13 @@
import { observer } from 'mobx-react-lite';
import type { GameStore } from '../game/GameStore';
import type { RabbitState } from '../game/types';
import type { Rabbit } from '../game/entities/Rabbit';
import { RABBIT_NIGHT_SPRITE, RABBIT_SPRITE } from '../game/sprites';
import HealthBar from './HealthBar';
import PixelSprite from './PixelSprite';
const RABBIT_SIZE = 30;
const RabbitEntity = observer(function RabbitEntity({ rabbit, store }: { rabbit: RabbitState; store: GameStore }) {
const RabbitEntity = observer(function RabbitEntity({ rabbit, store }: { rabbit: Rabbit; store: GameStore }) {
const size = store.isBloodMoon ? RABBIT_SIZE * 2 : RABBIT_SIZE;
return (