diff --git a/client/src/dojo/setup.ts b/client/src/dojo/setup.ts index d2c1cadb1..90b6305a1 100644 --- a/client/src/dojo/setup.ts +++ b/client/src/dojo/setup.ts @@ -1,4 +1,8 @@ -import { BUILDING_CATEGORY_POPULATION_CONFIG_ID, HYPERSTRUCTURE_CONFIG_ID, WORLD_CONFIG_ID } from "@bibliothecadao/eternum"; +import { + BUILDING_CATEGORY_POPULATION_CONFIG_ID, + HYPERSTRUCTURE_CONFIG_ID, + WORLD_CONFIG_ID, +} from "@bibliothecadao/eternum"; import { DojoConfig } from "@dojoengine/core"; import { getSyncEntities, getSyncEvents, syncEntities } from "@dojoengine/state"; import { Clause } from "@dojoengine/torii-client"; @@ -45,14 +49,13 @@ export async function setup({ ...config }: DojoConfig) { models: [], }, }, - { - Keys: { - keys: [HYPERSTRUCTURE_CONFIG_ID.toString()], - pattern_matching: "VariableLen", - models: [], - }, + { + Keys: { + keys: [HYPERSTRUCTURE_CONFIG_ID.toString()], + pattern_matching: "VariableLen", + models: [], }, - + }, ]; // fetch all existing entities from torii diff --git a/client/src/hooks/store/useWorldLoading.tsx b/client/src/hooks/store/useWorldLoading.tsx index 52c654754..f20cd52cc 100644 --- a/client/src/hooks/store/useWorldLoading.tsx +++ b/client/src/hooks/store/useWorldLoading.tsx @@ -9,4 +9,4 @@ interface WorldState { export const useWorldStore = create((set) => ({ isWorldLoading: true, setWorldLoading: (loading: boolean) => set({ isWorldLoading: loading }), -})); \ No newline at end of file +})); diff --git a/client/src/three/scenes/Worldmap.ts b/client/src/three/scenes/Worldmap.ts index 5f0f50e63..01a95c660 100644 --- a/client/src/three/scenes/Worldmap.ts +++ b/client/src/three/scenes/Worldmap.ts @@ -584,8 +584,6 @@ export default class WorldmapScene extends HexagonScene { const globalRow = startRow + row; const globalCol = startCol + col; - - hexPositions.push(new THREE.Vector3(dummy.position.x, dummy.position.y, dummy.position.z)); const pos = getWorldPositionForHex({ row: globalRow, col: globalCol }); dummy.position.copy(pos); @@ -671,47 +669,51 @@ export default class WorldmapScene extends HexagonScene { const range = this.chunkSize + 4; - const sub = await getEntities(this.dojo.network.toriiClient, { - Composite: { - operator: "Or", - clauses: [ - { - Member: { - model: "s0_eternum-Tile", - member: "col", - operator: "Gte", - value: { Primitive: { U32: startCol - range } }, - }, - }, - { - Member: { - model: "s0_eternum-Tile", - member: "col", - operator: "Lte", - value: { Primitive: { U32: startCol + range } }, - }, - }, - { - Member: { - model: "s0_eternum-Tile", - member: "row", - operator: "Gte", - value: { Primitive: { U32: startRow - range } }, - }, - }, - { - Member: { - model: "s0_eternum-Tile", - member: "row", - operator: "Lte", - value: { Primitive: { U32: startRow + range } }, - }, - }, - ], + const sub = await getEntities( + this.dojo.network.toriiClient, + { + Composite: { + operator: "Or", + clauses: [ + { + Member: { + model: "s0_eternum-Tile", + member: "col", + operator: "Gte", + value: { Primitive: { U32: startCol - range } }, + }, + }, + { + Member: { + model: "s0_eternum-Tile", + member: "col", + operator: "Lte", + value: { Primitive: { U32: startCol + range } }, + }, + }, + { + Member: { + model: "s0_eternum-Tile", + member: "row", + operator: "Gte", + value: { Primitive: { U32: startRow - range } }, + }, + }, + { + Member: { + model: "s0_eternum-Tile", + member: "row", + operator: "Lte", + value: { Primitive: { U32: startRow + range } }, + }, + }, + ], + }, }, - }, this.dojo.network.contractComponents as any, 1000, false); - - + this.dojo.network.contractComponents as any, + 1000, + false, + ); console.log(sub); } diff --git a/client/src/ui/components/resources/EntityResourceTable.tsx b/client/src/ui/components/resources/EntityResourceTable.tsx index 4a713a625..37a04668b 100644 --- a/client/src/ui/components/resources/EntityResourceTable.tsx +++ b/client/src/ui/components/resources/EntityResourceTable.tsx @@ -23,7 +23,6 @@ export const EntityResourceTable = ({ entityId }: { entityId: ID | undefined }) return multiplyByPrecision(quantity * storehouseCapacityKg + storehouseCapacityKg); }, [quantity, entityId]); - if (!entityId || entityId === 0) { return
No Entity Selected
; } diff --git a/client/src/ui/modules/navigation/RightNavigationModule.tsx b/client/src/ui/modules/navigation/RightNavigationModule.tsx index 4532fe384..6998d3403 100644 --- a/client/src/ui/modules/navigation/RightNavigationModule.tsx +++ b/client/src/ui/modules/navigation/RightNavigationModule.tsx @@ -21,8 +21,6 @@ export const RightNavigationModule = () => { const view = useUIStore((state) => state.rightNavigationView); const setView = useUIStore((state) => state.setRightNavigationView); - - const navigation = useMemo( () => [ { diff --git a/config/index.ts b/config/index.ts index 3455cba6f..83b89e712 100644 --- a/config/index.ts +++ b/config/index.ts @@ -7,7 +7,7 @@ import { EternumGlobalConfig, EternumProvider, getContractByName, - NAMESPACE + NAMESPACE, } from "@bibliothecadao/eternum"; import { Account } from "starknet"; @@ -61,7 +61,6 @@ setupConfig.vrf.vrfProviderAddress = VITE_VRF_PROVIDER_ADDRESS!; velords_fee_recipient: BigInt("0x045c587318c9ebcf2fbe21febf288ee2e3597a21cd48676005a5770a50d433c5"), // burner season_pool_fee_recipient: BigInt(getContractByName(manifest, `${NAMESPACE}-season_systems`)), }), - // Season Pass (setupConfig.season = { ...EternumGlobalConfig.season,