Skip to content

feat: Update MUD world #101

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions .env.testnet
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
VITE_NETWORK_ID = 11155420
VITE_WORLD_ADDRESS = 0x943e0b3F1926008f2e1bEFCBc55FA2A75CeC2452
VITE_WORLD_BLOCK_NUMBER = 6992231
VITE_WORLD_ADDRESS = 0xed08ac7cbf41f2171e1d260418d24646b6e35519
VITE_WORLD_BLOCK_NUMBER = 9445983
VITE_GRAPH_URI = https://api.studio.thegraph.com/query/51953/geo-web-op-sepolia/version/latest
VITE_ANNUALRATE = 0.1
VITE_IPFS_GATEWAY = https://gateway.ipfs.io
Expand Down
10 changes: 7 additions & 3 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,8 @@
"@apollo/client": "^3.7.16",
"@augmented-worlds/system-babylonjs": "^0.1.16",
"@ensdomains/content-hash": "2.5.7",
"@geo-web/mud-world-base-contracts": "0.1.0",
"@geo-web/mud-world-base-setup": "0.1.2",
"@geo-web/mud-world-base-contracts": "0.2.0",
"@geo-web/mud-world-base-setup": "0.3.1",
"@geo-web/sdk": "^4.4.0",
"@geo-web/types": "^0.2.0",
"@google/model-viewer": "^3.2.1",
Expand Down Expand Up @@ -43,7 +43,11 @@
"prettier": "prettier -w src/**"
},
"browserslist": {
"production": [">0.2%", "not dead", "not op_mini all"],
"production": [
">0.2%",
"not dead",
"not op_mini all"
],
"development": [
">0.2%",
"not dead",
Expand Down
22 changes: 11 additions & 11 deletions src/lib/world.ts
Original file line number Diff line number Diff line change
Expand Up @@ -38,9 +38,9 @@ function useWorld() {
const modelComponents = useStore((state: any) =>
Object.values(state.getRecords(tables.ModelCom))
);
const imageComponents = useStore((state: any) =>
Object.values(state.getRecords(tables.ImageCom))
);
// const imageComponents = useStore((state: any) =>
// Object.values(state.getRecords(tables.ImageCom))
// );

useEffect(() => {
const mediaObjects = [];
Expand All @@ -53,16 +53,16 @@ function useWorld() {
mediaObjects.push(mediaObject);
}

for (const imageComponent of imageComponents) {
const mediaObject = buildMediaObject(
MediaObjectType.Image,
imageComponent
);
mediaObjects.push(mediaObject);
}
// for (const imageComponent of imageComponents) {
// const mediaObject = buildMediaObject(
// MediaObjectType.Image,
// imageComponent
// );
// mediaObjects.push(mediaObject);
// }

setMediaObjects(mediaObjects);
}, [modelComponents.length, imageComponents.length]);
}, [modelComponents.length]);

const getValue = (table: string, key: { key: string }) =>
useStore.getState().getValue(tables[table], key);
Expand Down
Loading