Gravity Whitepaper
  • Gravity
    • Mission
    • Market
      • PC Market Overview
      • Market opportunity
      • Web3 gaming adoption
    • Why now?
    • Value Proposition
    • Key Features
  • Technology
    • Log-in tool
    • Scholarship Dashboard
    • Renting/leasing system
    • Marketplace
    • On-chain Inventory
    • Archivement System
    • Pay with fiat
  • Game Platform
  • Tournament Platform
  • G-Panel
    • Launchpad
    • Airdrops
    • Staking
  • Ecosystem Features
    • Second-Hand Market
    • Revenue Redistribution
    • Price Fluctuation Management
    • Investment Fund
    • Players Earnings
    • Users Compensations
    • Community Treasury
  • Gravity Token
    • Tokenomics
    • Allocations and Unlock schedule
      • Founders & Advisors
      • Staking Funds
      • Private Sale
      • Public Sale
      • Ecosystem Funds
      • Content Acquisition
      • Company Reserve
      • Growth & Rewards
      • Liquidity
    • Usecases GVT
  • Onboarding Strategy
    • Content Acquisition
    • Onboarding Developers
      • Developer Sponsorship
    • Onboarding Users
      • User Rewards
    • Operators
    • Influencer Scheme
  • Landscape Market Comparison
  • Decentralized Organization
  • Orbeast Fantasy
  • Compatible Systems
  • Team
Powered by GitBook
On this page
  1. Technology

On-chain Inventory

PreviousMarketplaceNextArchivement System

Last updated 1 year ago

The On-chain Inventory is a smart contract that enables players of web3 games to equip items onto their character NFTs.

As the name suggests, the On-chain Inventory exclusively tracks equipment on the blockchain, eliminating the need for off-chain metadata. This enhances the composability of game NFTs, allowing their state to be utilized not only by off-chain programs but also by smart contracts.

The Inventory has two user categories: administrators and players.

Administrators have the following abilities:

  1. Defining inventory slots for an ERC721 contract (NFT collection).

  2. Specifying the persistence of each slot, determining whether items can be unequipped from them.

  3. Establishing the tokens that can be equipped in each slot.

Players can perform the following actions:

  1. Equipping items into the inventory slots of the NFTs they own.

  2. Unequipping items from their owned NFTs' inventory slots (with the exception of persistent slots).

When an item is equipped onto an NFT, ownership of the item is transferred to the inventory contract. This prevents the simultaneous use of item tokens by multiple entities. Additionally, if a player transfers an NFT to another player, the equipped items on that NFT are implicitly transferred to the new owner.

The Inventory contract is specifically designed for utilization in web3 games. If a game interprets inventory slots as holding character attributes in general, the Inventory can also be utilized to track aspects such as hit points, experience points, reputation, abilities, and skills, in addition to items and equipment.