gnolang / gno

Gno: An interpreted, stack-based Go virtual machine to build succinct and composable apps + gno.land: a blockchain for timeless code and fair open-source.
https://gno.land/
Other
898 stars 374 forks source link

[examples] Encrypt player choices during `r/demo/games/shifumi` #2758

Open leohhhn opened 2 months ago

leohhhn commented 2 months ago

Description

I propose an improvement on the r/demo/games/shifumi realm (code). Currently, the user's choices of rock/paper/scissors are visible on the network, making it very easy to cheat at the game.

A great improvement and a good Gno practice issue would be to try to encrypt the plays and reveal them only when both users have played their hand.

kristovatlas commented 2 months ago

https://telefonicatech.com/en/blog/rock-paper-scissors-commit-now-reveal-later

linhpn99 commented 2 months ago

https://github.com/gnolang/gno/pull/2760

amha-mersha commented 2 months ago

Hello @leohhhn can I take this one and work on it.