Created
October 27, 2020 20:33
-
-
Save TrevorBenson/b7f92159e0655a80906a0f04dedffbe2 to your computer and use it in GitHub Desktop.
Plutus Playground Smart Contract
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import qualified Language.PlutusTx as PlutusTx | |
import qualified Ledger.Interval as Interval | |
import Ledger.Slot (SlotRange) | |
import qualified Ledger.Slot as Slot | |
import Language.PlutusTx.Prelude as P | |
import Ledger | |
import qualified Ledger.Ada as Ada | |
import Ledger.Ada (Ada) | |
import Ledger.Validation | |
import Playground.Contract | |
import Wallet as Wallet | |
myValidatorScript :: ValidatorScript | |
myValidatorScript = ValidatorScript $$(Ledger.compileScript [|| | |
\(ds :: ()) (rs :: ()) (_ :: PendingTx) -> () | |
||]) | |
helloAction :: MonadWallet m => m () | |
helloAction = Wallet.logMsg "Hello World!" | |
$(mkFunctions ['helloAction]) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[0,[{"wallets":[{"simulatorWalletWallet":{"getWallet":1},"simulatorWalletBalance":{"getValue":[[{"unCurrencySymbol":""},[[{"unTokenName":""},10]]]]}},{"simulatorWalletWallet":{"getWallet":2},"simulatorWalletBalance":{"getValue":[[{"unCurrencySymbol":""},[[{"unTokenName":""},10]]]]}}],"signatures":[{"functionName":"helloAction","argumentSchema":[]},{"functionName":"payToWallet_","argumentSchema":[{"tag":"FormSchemaValue"},{"contents":[["getWallet",{"tag":"FormSchemaInt"}]],"tag":"FormSchemaObject"}]}],"currencies":[{"knownTokens":[{"unTokenName":""}],"hash":"","friendlyName":"Ada"}],"actions":[{"simulatorWallet":{"simulatorWalletWallet":{"getWallet":1},"simulatorWalletBalance":{"getValue":[[{"unCurrencySymbol":""},[[{"unTokenName":""},10]]]]}},"functionSchema":{"functionName":"helloAction","argumentSchema":[]},"tag":"Action"},{"blocks":10,"tag":"Wait"},{"simulatorWallet":{"simulatorWalletWallet":{"getWallet":2},"simulatorWalletBalance":{"getValue":[[{"unCurrencySymbol":""},[[{"unTokenName":""},10]]]]}},"functionSchema":{"functionName":"helloAction","argumentSchema":[]},"tag":"Action"},{"blocks":1,"tag":"Wait"}]}]] |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Basic helloWorld