ChainDev931105 / anchor-coin-flip

0 stars 1 forks source link

allowed amounts #9

Closed ohaddahan closed 2 years ago

ohaddahan commented 2 years ago

https://github.com/ChainDev931105/anchor-coin-flip/blob/8f39241e7891a2350cc886ce95fb67d9d1b19f71/programs/coin-flip/src/lib.rs#L180

core account should have a vector of allowed bet amounts , need to validate the amount is one of those given. we don't want someone to make a huge bet and clean the house on luck (or exploit)

ohaddahan commented 2 years ago

https://github.com/ChainDev931105/anchor-coin-flip/blob/8f39241e7891a2350cc886ce95fb67d9d1b19f71/programs/coin-flip/src/lib.rs#L443-L448

ChainDev931105 commented 2 years ago

yeah, I've considered about that point. but it can depends on each token. so we need to add constraints for each tokens?

ohaddahan commented 2 years ago

Each core will have mint/fees/amounts of its own