Skip to content

Instantly share code, notes, and snippets.

@bwbush
Last active May 13, 2021 03:53
Show Gist options
  • Save bwbush/b17b48cd9545770240b14cb7828fa6c6 to your computer and use it in GitHub Desktop.
Save bwbush/b17b48cd9545770240b14cb7828fa6c6 to your computer and use it in GitHub Desktop.
PIGY Example 2
When
[Case
(Deposit
(Role "BOBS POOL")
(Role "BOBS POOL")
(Token "2aa9c1557fcf8e7caa049fa0911a8724a1cdaf8037fe0b431c6ac664" "PIGY")
(ConstantParam "reward")
)
(When
[Case
(Deposit
(Role "ALICE THE DELEGATOR")
(Role "ALICE THE DELEGATOR")
(Token "" "")
(ConstantParam "deposit")
)
(When
[Case
(Choice
(ChoiceId
"early withdrawl"
(Role "ALICE THE DELEGATOR")
)
[Bound 1 1]
)
Close ]
1296000
(Pay
(Role "BOBS POOL")
(Party (Role "ALICE THE DELEGATOR"))
(Token "2aa9c1557fcf8e7caa049fa0911a8724a1cdaf8037fe0b431c6ac664" "PIGY")
(ConstantParam "reward")
Close
)
)]
432000 Close
)]
431999 Close
{"valueParameterDescriptions":[],"slotParameterDescriptions":[],"roleDescriptions":[],"contractType":"O","contractName":"","contractDescription":"","choiceDescriptions":[]}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment