|
@@ -1,15 +1,12 @@
|
|
|
import { useEffect } from "react";
|
|
|
-import { useLastRound, usePlayerName } from "../../../domain/gameStore";
|
|
|
+import { usePlayerName } from "../../../domain/gameStore";
|
|
|
import useMap from "../../../hooks/useMap";
|
|
|
import useGameInfo from "../../../hooks/useGameInfo";
|
|
|
import { makeQuestionMarker, makeFlagMarker, makeLine } from "./markers";
|
|
|
import getColorGenerator from "./getColorGenerator";
|
|
|
import { useRef } from "react";
|
|
|
|
|
|
-const useMapWithMarkers = (mapDivRef) => {
|
|
|
- // get the info about the last round
|
|
|
- const { roundNum, targetPoint } = useLastRound();
|
|
|
-
|
|
|
+const useMapWithMarkers = (mapDivRef, roundNum, targetPoint) => {
|
|
|
// create the map
|
|
|
const mapRef = useMap(mapDivRef, targetPoint.lat, targetPoint.lng, 4);
|
|
|
|