Questions tagged [games]

The tag has no usage guidance.

Filter by
Sorted by
Tagged with
0 votes
1 answer
20 views

How to use a Server to run OnlyOwner functions?

I'm working on a game PoC and I've got questions about player rewards good practices. Sure I understand that those functions cannot be public and onlyOwner-restricted, but how does it work actually ? ...
Building Dwarf's user avatar
1 vote
2 answers
117 views

Chainlink VRF2, Automation - Raffle Game

i am writing a raffle game contract, I integrated Chainlink keepers to check how much time has passed and pick the winner to move on to next round. function checkUpkeep( bytes calldata ...
Bengican Altunsu's user avatar
1 vote
1 answer
41 views

Struggling to pick token standards for a game

Hello Ethereum community, We are building a game and struggle to figure out which token standards to use. Here is a high level overview of what "tokens" we need: Crystal (Tradable, FT, ...
Milos Krstic's user avatar
0 votes
1 answer
23 views

Amateur Questions

I am trying to develop a cryptocurrency for use in a game I am also developing. So I am not looking to monetize off of this cryptocurrency. Its primary purpose is game functionality. If so, should I ...
HoboJeff's user avatar
0 votes
1 answer
38 views

How can I make a game that allows players to earn a certain NFT or crypto currency after they beat a boss?

I am an aspiring game developer and my friends and I have recently decided to make a game that centers around a main storyline and characters that can be defeated for crypto or NFT's. Could you give a ...
YadaYadaYada乌乌's user avatar
1 vote
1 answer
29 views

Can you make an NFT game based on a already released collection?

If a collection already exists out there and it’s smart contract has been deployed and everything, could one later then develop a game for that NFT collection and integrate the NFTs as a utility in ...
floooo2's user avatar
  • 11
1 vote
0 answers
30 views

ERC20 Claimable Utility Tokens / InGame Currency Standard Implementation

Can anyone point me to a resource where I can see a standard implementation of a UTILITY TOKEN (claimable unlimited supply) that are used as...well... utility in game. I've checked multiple Utility ...
Nio Martinez's user avatar
1 vote
0 answers
155 views

When updating NFT metadata for a game, how can I ensure that the content in the passed tokenURI reflects the on-chain metadata?

I'm working on a game. There is a "equipment" item that has some stats such as experience, level, and rarity. The equipment is an NFT. I'm storing these stats (metadata) on-chain via a ...
sentiinex's user avatar
1 vote
0 answers
33 views

Security for play-to-earn action game

So I'm making a play-to-earn game, that is a web game and its logic runs on the user's machine. After the player finishes a session, the game will call the following mint function: contract GoldCoin ...
Angel Guastaferro's user avatar
1 vote
1 answer
111 views

How to make Smart Contract function only accessible from Application?

Let's say i want to make gaming NFT with variable Level. i have game which using that NFT, when we play the game the NFT will level up. i want the NFT only can be leveling up from the game. as i know ...
satrio galih's user avatar
0 votes
1 answer
60 views

How do crypto games make users not pay gas

I am researching blockchain games, such as Axie Infinity, Crypto Cars, etc. As I understand it, when connecting a website to the ethereum/BSC blockchain to submit a transaction, the user will have to ...
João A. Veiga's user avatar
1 vote
0 answers
523 views

Missunderstanding about ERC1155 for Game Dev

After using ERC721 to develop some Collectable collections of NFTs, i'm trying to implement an ERC1155 smart contract to manage a game collection of elements. First, the needs In a simplified version ...
Arthur's user avatar
  • 194
0 votes
0 answers
34 views

How to model NFTs for a game

I am struggling to understand how the different pieces of an NFT game should work. I have some doubts about how many ERC20, ERC721 and ERC1155 should I create. I want to create a game where users can ...
Enrique Fernández-Polo's user avatar
0 votes
1 answer
32 views

How i put some erc721 token on markelace in a game?

Hi I'm building a game and wanted to implement a marketplace. The user puts the token on the marketplace and then someone buys it. I've already managed to implement something to create the market ...
Marcelo Ferreira's user avatar
0 votes
1 answer
123 views

How to pay with costum erc20 tokens when execute something in a er721 contract? [duplicate]

I'm building a game and I want when the player clicks to buy a erc721 token to pay with my costum erc20 token. Can anyone explain how to do it?
Marcelo Ferreira's user avatar
1 vote
1 answer
98 views

Is it possible to create a game that can withdraw a coin balances tracked off-chain?

I have a game where the data is saved in a MYSQL database Is it possible to create a "play to earn" game, that the balance is saved in the database and the user can make the withdraw using ...
jureg chave's user avatar
0 votes
0 answers
194 views

Token not returned: Warning! Error encountered during contract execution [execution reverted]

Polygon Weth token not returned after failed transaction. I press "buy" again the Hero in Idle Mystic game after refreshing it since it says failed in metamask. The token payment for the ...
Glitchy Circuit's user avatar
1 vote
0 answers
99 views

Is using blockhash a good source of randomness on PoS blockchains with a lot of blocks mined in a short period of time?

I am trying to make a casino-like game using a smart contract and employing only on-chain data. I understand that on a blockchain like Ethereum a malicious miner can cheat the system by withholding ...
Kuzmich Mikhail's user avatar
2 votes
2 answers
658 views

What is the best way for a smart contract to constantly listen to a price feed and execute immediately once the price is reached?

I have compiled a smart contract that is supposed to take bets from 2 addresses, a bet creator and a bet taker. The bet is on the price of ETH/USD (via ChainLink). What would be the best way to for ...
Teo's user avatar
  • 43
1 vote
0 answers
136 views

Possibilities of ERC721 image generation [closed]

What image generation techniques could you suggest for a DApp game that utilizes ERC721? I know that CrypoKitties has a unique DNA sequence and different pieces of the sequence correspond to the ...
EtherPaul's user avatar
  • 257
0 votes
0 answers
38 views

What’s the transaction ordering inside a block? [duplicate]

The game I found a game where each gambler needs to pay 0.02 ᴇᴛʜ to register a secret before the game before the games switch to status==reveal each day. Then, during the status==reveal period no ...
user2284570's user avatar
2 votes
2 answers
255 views

Is there a way to deal with desistance in a off-chain game?

Suppose I want to use blockchain to play chess for money. So, I can register, on the blockchain, a smart contract (a chess game) associated to some amount of ether. If someone wants to join, he or she ...
Tiago Nascimento's user avatar
0 votes
1 answer
647 views

Solidity Vs JavaScript?

I'm currently in the process of writing a game however a question has popped up in my head. A while back I started writing my game in Solidity (i.e the characters, names, stats etc.) and I had ...
Samuel Catley's user avatar
0 votes
1 answer
233 views

Design pattern for game development

I am developing a game which currently uses a GameFactory contract to create instances of a Game contract. The Factory pattern would allow any number of players to play their own single player game ...
koukotsu's user avatar
  • 351
1 vote
2 answers
1k views

Rock scissors paper game in Solidity

For a homework problem, I need to write a contract for a rock-paper-scissors game for two players who would deposit the same amount of money then the winner will get both deposits. I am new to ...
Jack.Mc's user avatar
  • 21
1 vote
2 answers
354 views

How to use fiat exchange rate oracle in DAPP?

my team is trying to develop a DAPP about fiat exchange rate. How to get the latest fiat exchange rate (USD/EURO etc.) accurately from external Oracles(Or are there better ways doing this)?
user avatar
1 vote
0 answers
40 views

What are the formal specifications for the temporal reward in Casper?

Casper has a temporal reward where those who place bets early (on the block that ends up as the winner) get more reward. What are the formal specifications of that, how is the temporal reward ...
crittenden's user avatar
1 vote
1 answer
802 views

Tic-tac-toe and smart contracts

I am developing Tic-tac-toe game where players can play for ETH. I created a smart contract where a player sends ETH and balances is updates, the player receives some life. Then I thought when the ...
rel1x's user avatar
  • 125
0 votes
1 answer
109 views

working with balance management in a game

I'm working in a online game project, Where users will deposit ETH into their account for playing game. My problem is, Once a user deposit some ETH into his wallet. Example 0.10 ETH So how we can ...
shawn's user avatar
  • 399
1 vote
1 answer
1k views

Loading smart contract x with tokens; sending eth to smart contract x; receiving tokens for that eth

Hello dear Eth community, I am a complete noob, please go easy on me ;) I am an IT teacher and I want to create a reward system for my class for a game that we play weekly. The game is not ...
Pandation's user avatar
1 vote
0 answers
148 views

Can the blockchain run a billion dollar lottery?

As many games and other applications, a lottery needs a reliable random number generator. Especially when the prize is high. There are some sophisticated algorithms to achieve this goal, such as ...
philippe_b's user avatar
1 vote
2 answers
511 views

Is it possible to write an online browser game in ASP.net and integrate a smart contract to buy assets in that game for example?

I am fairly new to solidity, and i am exploring decentralized game development. This said, let us go more into the details. Imagine i want to develop a 2d game, where you can buy for example assets, ...
Papi Junior's user avatar
11 votes
2 answers
6k views

How does cryptokitties work with smart contracts and is there a random element to it?

I'm totally new to cryptokitties, but my understanding of cryptokitties so far is: It's a smart contract that generates new kitties according to your ethereum address. My questions are: If you are ...
Patoshi パトシ's user avatar