Skip to content
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

New battle article #202

Merged
merged 5 commits into from
Nov 4, 2024
Merged
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
10 changes: 5 additions & 5 deletions docs/about/features/message-automation.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,19 +11,19 @@ One of the well-known drawbacks of other platforms' smart contracts is that they

While classic smart contract logic may rely on users to initiate transactions and awaken the contract, many cases require a trigger when certain conditions are met, such as reaching a specific point in time or the occurrence of a particular event. In the past, this has either limited the capabilities of smart contracts or required developers to introduce a centralized service to trigger smart contracts.

Now thanks to Gear Protocol's support for asynchronous messaging, program developers can implement arbitrary logic with [delayed messages](/build/gstd/delayed-messages.md) that can wake the program after a specified period of time or in response to certain events. This enables a much more extensive range of use cases for programs, unlocks new decentralized functionality, and unlocks more value for users in the blockchain ecosystem.
Now thanks to Gear Protocol's support for asynchronous messaging, program developers can implement arbitrary logic with [delayed messages](/docs/build/gstd/delayed-messages.md) that can wake the program after a specified period of time or in response to certain events. This enables a much more extensive range of use cases for programs, unlocks new decentralized functionality, and unlocks more value for users in the blockchain ecosystem.

## Continuing messaging automation

The execution of any messages in Vara, including the [system messages](/build/gstd/system-signals.md), consumes "gas". The Gear Protocol introduces the concept of [gas reservation](/build/gstd/gas-reservation.md), which allows for the creation of gas pools that can be used by programs for further execution. Each pool is unique to the program that creates it, and the gas from the pool can be consumed by the program if its "gas_available" is not sufficient.
The execution of any messages in Vara, including the [system messages](/docs/build/gstd/system-signals.md), consumes "gas". The Gear Protocol introduces the concept of [gas reservation](/docs/build/gstd/gas-reservation.md), which allows for the creation of gas pools that can be used by programs for further execution. Each pool is unique to the program that creates it, and the gas from the pool can be consumed by the program if its "gas_available" is not sufficient.

One of the key benefits of the gas reservation is the ability to send **delayed messages** that can be triggered automatically at a specific time in the future. These messages, like any other message in Vara, can invoke another program in the network or appear in the user's mailbox.

Perhaps most interestingly, gas reservation allows a program to send a message to itself at a later time, allowing it to continue execution after a defined period. This effectively enables a program to execute itself an **unlimited** number of times (provided that enough gas is available for the execution).

This opens up a wide range of possibilities for the implementation of functional logic related to **continuing messaging automation** in programs. Delayed messages are similar to cron jobs, which cannot be implemented in programs on other blockchain platforms without the use of external resources. The remarkable advantage of this solution is that it eliminates the need for centralized components in dApps, ensuring they function **completely on-chain** and are fully decentralized and autonomous.

Applications that use delayed messages in their business logic and their source code are shown in the [Program Examples](/examples/examples.mdx) section. These include applications such as: [Tamagotchi battle](/examples/Gaming/tamagotchi-battle.md), [VaraTube](/examples/Infra/varatube.md), [Dynamic NFT](/examples/NFTs/dynamic-nft.md).
Applications that use delayed messages in their business logic and their source code are shown in the [Program Examples](/examples/examples.mdx) section. These include applications such as: [Game Battle](/examples/Gaming/battle.md), [VaraTube](/examples/Infra/varatube.md), [Dynamic NFT](/examples/NFTs/dynamic-nft.md).

## Use cases

Expand All @@ -46,7 +46,7 @@ Overall, the ability to update NFTs dynamically opens up a wide range of possibi

Everyone knows that the most successful games are those that are exciting, that you play with pleasure.

The success of such games depends on the right game mechanics established by the developers. The Gear Protocol offers a tool for developing such games and running them on [Vara](https://vara.network/). Features such as [delayed messages](/build/gstd/delayed-messages.md), [gasless and signless transactions](/docs/api/vouchers.md), and [gas reservation](/build/gstd/gas-reservation.md) become essential tools for developers aiming to create successful games on the Vara Network.
The success of such games depends on the right game mechanics established by the developers. The Gear Protocol offers a tool for developing such games and running them on [Vara](https://vara.network/). Features such as [delayed messages](/docs/build/gstd/delayed-messages.md), [gasless and signless transactions](/docs/api/vouchers.md), and [gas reservation](/docs/build/gstd/gas-reservation.md) become essential tools for developers aiming to create successful games on the Vara Network.

Here are a few of the many examples where such functionality would be useful:

Expand All @@ -60,4 +60,4 @@ Decentralized finance (DeFi) applications can improve the user experience by imp

With the Vara, users can enjoy a set-and-forget DeFi experience where their earnings are automatically deposited into their accounts without any manual intervention. Rewards are regularly harvested, swapped for the original vault asset, and deposited again for compound farming, allowing users to earn even more without having to take any additional action.

In general, the use of delayed messages in DeFi can greatly improve the user experience by making it easier for users to earn rewards and take advantage of the benefits of DeFi without constantly having to monitor and manage their assets. This can help drive broader adoption of DeFi and unlock new opportunities for growth in the industry.
In general, the use of delayed messages in DeFi can greatly improve the user experience by making it easier for users to earn rewards and take advantage of the benefits of DeFi without constantly having to monitor and manage their assets. This can help drive broader adoption of DeFi and unlock new opportunities for growth in the industry.
Loading