When I was exploring haddock of Plutus I have found that Plutus script can have Rewarding ScriptPurpose:
data ScriptPurpose
= Minting CurrencySymbol
| Spending TxOutRef
| Rewarding StakingCredential
| Certifying DCert
deriving stock (Generic, Haskell.Show, Haskell.Eq)
This raised me a lot of questions like:
- How do Rewarding scripts differ from Spending scripts?
- How to use Rewarding script, how are Rewarding scripts interacted with?
- Can Rewarding scripts be used with native tokens? Could I for example create smartcontract for staking KUGIS native tokens and getting KUGIS coins as a reward?
I have tried searching for resources but couldn’t find a single resource on this except one example of the adafinance cardano staking contract on github.