What are properties/items that a player has?

The second two are already going to be NFTs, these will have their own table schema:

Vehicle:

id (chain id, PK) address (chain) class (name of vehicle type) owner (address, FK) location (FK) durability

All of these parameters are attached to the NFT. Eventually I want to add more (like true evolution (e.g. Pokemon) while retaining this rough schema) parameters, but let’s keep it simple with this schema for now.

For the actual inventory items, I think these can be represented via JSON format e.g.:

items {
	"raw materials" : {
		"gold": 5
		"minerals": 3
	}
}

The user’s vehicles and planets can be represented in an array format, as all of their data is tied to their NFT value. Example player1 ’s ships are the following ids: [0x1, 0x4] and this is then tied (as foreign keys) to a table in the Postgres database that stores the full values of each NFT. This way, the values of each NFT are stored in a separate table from the User/Profile (keeping that table clean), but all the properties are still available. One problem here though is what if we have a different contract address for each ship type? I think the evolution format in https://github.com/signal-k/sytizen/issues/6 means we might be able to base everything on the chain id of the NFT, as long as the parameters are the same (not the value, but the type of).

Locations (aka planet) will be structured in Postgres the same as Vehicles, just with a different list of properties.

Something else to keep in mind is that we want vehicles to be able to be between “locations” (aka heavenly bodies), so in the actual game we might want to have a bool ref to see if the vehicle is on an ownable location, if not, list the coordinates (based on nearest star).

Other docs