diff --git a/apps/server/src/domains/game/GameManager.ts b/apps/server/src/domains/game/GameManager.ts index 4bbc1f7..f910792 100644 --- a/apps/server/src/domains/game/GameManager.ts +++ b/apps/server/src/domains/game/GameManager.ts @@ -1,5 +1,4 @@ import { GameLoop, type TickData } from "./GameLoop"; -import type { gridMapTypes } from "@repo/shared"; import { Player } from "./entities/Player.js"; import { PlayerRegistry } from "./application/services/PlayerRegistry"; import { GameSessionService } from "./application/services/GameSessionService"; @@ -72,9 +71,4 @@ .map((playerId) => this.playerRegistry.getPlayer(playerId)) .filter((player): player is Player => player !== undefined); } - - // 【一時的】移動したプレイヤーの足元を塗り、差分を返すメソッド - public paintAndGetUpdates(roomId: string, playerId: string): gridMapTypes.CellUpdate[] { - return this.gameSessionService.paintAndGetUpdates(roomId, playerId); - } } \ No newline at end of file diff --git a/apps/server/src/domains/game/application/services/GameSessionService.ts b/apps/server/src/domains/game/application/services/GameSessionService.ts index 83ae1f3..060331a 100644 --- a/apps/server/src/domains/game/application/services/GameSessionService.ts +++ b/apps/server/src/domains/game/application/services/GameSessionService.ts @@ -1,5 +1,4 @@ -import { config, gridMapLogic } from "@repo/shared"; -import type { gridMapTypes } from "@repo/shared"; +import { config } from "@repo/shared"; import { GameLoop, type TickData } from "../../GameLoop"; import { Player } from "../../entities/Player.js"; import { MapStore } from "../../states/MapStore"; @@ -85,19 +84,4 @@ }); } } - - public paintAndGetUpdates(roomId: string, playerId: string): gridMapTypes.CellUpdate[] { - const mapStore = this.mapStores.get(roomId); - if (!mapStore) return []; - - const player = this.players.get(playerId); - if (!player) return []; - - const gridIndex = gridMapLogic.getGridIndexFromPosition(player.x, player.y); - if (gridIndex !== null) { - mapStore.paintCell(gridIndex, player.teamId); - } - - return mapStore.getAndClearUpdates(); - } }