Skip to content

Commit

Permalink
codegen again
Browse files Browse the repository at this point in the history
  • Loading branch information
holic committed Jul 27, 2023
1 parent 14fa798 commit c5200c9
Show file tree
Hide file tree
Showing 2 changed files with 44 additions and 26 deletions.
Original file line number Diff line number Diff line change
@@ -1,53 +1,62 @@
/* Autogenerated file. Do not edit manually. */

import { TableId } from "@latticexyz/common";
import { defineComponent, Type as RecsType, World } from "@latticexyz/recs";

export function defineContractComponents(world: World) {
return {
CounterTable: (() => {
const tableId = new TableId("", "CounterTable");
return defineComponent(
world,
{
value: RecsType.Number,
},
{
id: "0x00000000000000000000000000000000436f756e7465725461626c6500000000",
metadata: {
contractId: tableId.toHex(),
tableId: tableId.toString(),
componentName: "CounterTable",
tableName: ":CounterTable",
keySchema: { key: "bytes32" },
valueSchema: { value: "uint32" },
},
}
} as const
);
})(),
MessageTable: (() => {
const tableId = new TableId("", "MessageTable");
return defineComponent(
world,
{
value: RecsType.String,
},
{
id: "0x000000000000000000000000000000004d6573736167655461626c6500000000",
metadata: {
contractId: tableId.toHex(),
tableId: tableId.toString(),
componentName: "MessageTable",
tableName: ":MessageTable",
keySchema: {},
valueSchema: { value: "string" },
},
}
} as const
);
})(),
Inventory: (() => {
const tableId = new TableId("", "Inventory");
return defineComponent(
world,
{
amount: RecsType.Number,
},
{
id: "0x00000000000000000000000000000000496e76656e746f727900000000000000",
metadata: {
contractId: tableId.toHex(),
tableId: tableId.toString(),
componentName: "Inventory",
tableName: ":Inventory",
keySchema: {
owner: "address",
item: "uint32",
itemVariant: "uint32",
},
valueSchema: { amount: "uint32" },
},
}
} as const
);
})(),
};
Expand Down
Original file line number Diff line number Diff line change
@@ -1,53 +1,62 @@
/* Autogenerated file. Do not edit manually. */

import { TableId } from "@latticexyz/common";
import { defineComponent, Type as RecsType, World } from "@latticexyz/recs";

export function defineContractComponents(world: World) {
return {
CounterTable: (() => {
const tableId = new TableId("", "CounterTable");
return defineComponent(
world,
{
value: RecsType.Number,
},
{
id: "0x00000000000000000000000000000000436f756e7465725461626c6500000000",
metadata: {
contractId: tableId.toHex(),
tableId: tableId.toString(),
componentName: "CounterTable",
tableName: ":CounterTable",
keySchema: { key: "bytes32" },
valueSchema: { value: "uint32" },
},
}
} as const
);
})(),
MessageTable: (() => {
const tableId = new TableId("", "MessageTable");
return defineComponent(
world,
{
value: RecsType.String,
},
{
id: "0x000000000000000000000000000000004d6573736167655461626c6500000000",
metadata: {
contractId: tableId.toHex(),
tableId: tableId.toString(),
componentName: "MessageTable",
tableName: ":MessageTable",
keySchema: {},
valueSchema: { value: "string" },
},
}
} as const
);
})(),
Inventory: (() => {
const tableId = new TableId("", "Inventory");
return defineComponent(
world,
{
amount: RecsType.Number,
},
{
id: "0x00000000000000000000000000000000496e76656e746f727900000000000000",
metadata: {
contractId: tableId.toHex(),
tableId: tableId.toString(),
componentName: "Inventory",
tableName: ":Inventory",
keySchema: {
owner: "address",
item: "uint32",
itemVariant: "uint32",
},
valueSchema: { amount: "uint32" },
},
}
} as const
);
})(),
};
Expand Down

0 comments on commit c5200c9

Please sign in to comment.