I have been diving into Plutus Smart Contracts lately and one of the main things that I would like to understand better is when and how to use the
For example in guess game on available on the Playground
it is necessary for the person who’s guessing to run StartGame before the number is locked.
This is somewhat counter intuitive, and I had the following questions about the situation:
Is there anyway to just "extract" all funds from an address?
Why doesn't it know the outputs of the address of the game if used after lock?
Isn't this quite limiting in regards of what it is possible to achieve with Plutus smart contracts? What if a player only "knew" about the game after it was "locked"?
Wallet #1 (person who "locks" the number) still lost 1 ADA in this situation, where does that money go? Does it stay in the contract forever? (It's possible to use triggers, but that is still up to the programmer to do, which is suboptimal)
Thank you for your time!
I have also posted a similar post on reddit if anyone is interested