White paper

GGWP Gateway

What is GGWP Gateway?

It is a module for game projects integration into the GGWP ecosystem. Projects that are integrated into GGWP comply with our policy and use $GGWP and $GPASS tokens.

The main goal of GGWP Gateway is to provide the integration of gaming projects into the ecosystem using the GGWP Gateway smart contract interaction protocol.

Users get the access to a vast range of games, and game developers get royalties from transactional activities within their game.

Problems or why project integration is not a trivial task:

  1. Trust between the links of the system: between players and a third-party game, between a third-party game and the GGWP ecosystem. Third-party developers can falsify the data coming into the GGWP Gateway smart contract, changing the results of games and thereby appropriating rewards for themselves. Just as players can use the vulnerability of the game to get undeserved benefits.
  2. Game diversity, different game genres offer different mechanics, which imposes restrictions on the unification of the approach.
  3. Technical restrictions on the launch and monitoring of smart contracts. For example, if 1 smart contract serves all games, then stopping 1 game becomes more difficult and can affect other games in the ecosystem. If the managing smart contract stops, then it will negatively affect all games at once.

Solutions:

  1. The monitoring system (GGWP Sentry) monitors the activity of the ecosystem participants in games connected via the GGWP Gateway in real time, fixing anomalies and, if necessary, stopping the operation of the connected game where problems are observed.
  2. The problem of substitution of results in the game is solved by introducing a security fund for rewards for each game when it is connected. If GGWP Sentry stops the game, then the players' losses are compensated by the security fund.
  3. GGWP Gateway captures the session results of the game without diversifying the gameplay to transfer data to a smart contract. Coupled with the work of GGWP Sentry, this is quite enough to ensure the versatility of the protocol and at the same time maintaining the safety of players.
  4. Part of the functionality is transferred from the managing smart contract to separate subsystems. This allows updates and extensions of functionality to be carried out more smoothly for the ecosystem in general.

Package contents for game developers from us:

  1. API for integration of games at the smart contract level and implementation of GGWP Gateway smart contracts.
  2. Rules for validation and management of data included in the smart contract from third-party games.
  3. Documentation for developers on integration into the GGWP ecosystem.
  4. Monitoring system for activity inside the projects connected to GGWP.

Integration of game projects into the GGWP ecosystem

The GGWP Gateway is implemented in a smart contract that provides an API for connecting new games and developers to the ecosystem.

The integration process goes through several stages:

  1. The game developer fills out an application for connection, and we manually check the compatibility of your project with the GGWP ecosystem.
  2. In case of successful verification, we register your game in the GGWP Gateway smart contract.
  3. Next, the GGWP Gateway tools are connected from your side in such a way that users buy access to the game for $GPASS, and receive $GGWP as a reward for gaming activity.
  4. The game developer gets access to their personal account where they have access to statistics on the game in the GGWP ecosystem, as well as payments from royalty.

GGWP Gateway API key features

The smart contract assumes the role of a repository for the results of gaming sessions. For the beginning of the game, as a payment, it charges GPASS from players and issues GGWP /NFT as a reward for winning the game.

The logic of the game itself, game mechanics and player profiles by type (personal account, achievements, ranks, tournaments, etc.) are implemented on the side of the connected game.

The player's profile in the GGWP ecosystem is their Aptos wallet and their game data related to smart contracts GGWP Core, GGWP Coin and others.

Open API for games

Gas Fee for the operation of transactions is paid by the user specified in the API &signer.

Sign_up(contributor: &signer);

Instructions for registering a new game project inside the GGWP Gateway. It is called once when registering a project in the ecosystem. After calling the instruction, the project must follow it. When you call it again, there will already be a project in the records of the blockchain (distributor) and an error will be displayed.

Project parameters are being filled in:

  • name: String – a unique project name (up to 128 symbols).
  • gpass_cost: u64 – the cost of a gaming session in GPASS.

ProjectInfo is recorded in the blockchain of the distributor account. A SignUpEvent data storage is created separately with a new identifier for the project and the connection date. The data is stored in the GGWP Gateway smart contract.

Remove(contributor: &signer);

Instructions for the voluntary withdrawal of the project from the GGWP Gateway ecosystem. Data about the ProjectInfo project is erased from the blockchain records and the distributor account. RemoveEvent data records with the ID of the deleted project and the date of withdrawal are requested.

start_game(player: &signer);

Sending information about the start of the game session, the player is debited GPASS in the amount of gpass_cost. Information about the gaming session with the pending status appears on the network.

To start a gaming session, the player must be connected to the GGWP ecosystem and have $GPASS in the account.

Parameters:

  • player_addr: AccountAddress – player’s account address.
  • project_id: u64 – ID of the project (game).

GameSessionInfo – the player's information is recorded in the HashMap by the project ID. The StartGameEvent action history repository is requested with the information about the game session (sesion_id, project_id) and the date.

finalize_game(player/contributor: &signer);

If the player wins, the instruction finalizes the game session by paying a reward to the winner in GGWP and setting the session status as Finalized.

Parameters:

  • player_addr: AccountAddress – player’s account address.
  • project_id: u64 – ID of the project (game).
  • session_id: u64 – ID of the session.
  • result: u8 – game result.

There is a request for the FinalizeGame command with the information about the payment and the date. The information is recorded in the blockchain.

Moderation of incoming data in GGWP Gateway

Records of gaming sessions from games connected to the GGWP ecosystem will be sent to the smart contract. In case of an attempt to deceive the system by substituting data and appropriating GGWP funds for gaming sessions, sanctions will be imposed on the project.

The analysis of incoming data is carried out at the time of operation of the smart contract and upon recording data about the gaming session in the blockchain using analytical software.