Skip to content

Commit

Permalink
Fix payouts in rock-paper-scissors
Browse files Browse the repository at this point in the history
  • Loading branch information
bigspider committed May 3, 2024
1 parent bd4d948 commit 9866d73
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions examples/rps/rps_contracts.py
Original file line number Diff line number Diff line change
Expand Up @@ -175,11 +175,11 @@ def make_script(diff: int, ctv_hash: bytes):
('m_a', IntType()),
('r_a', BytesType()),
]
alice_wins = StandardClause("tie", make_script(
0, tmpl_alice_wins.get_standard_template_hash(0)), arg_specs, lambda _, __: tmpl_alice_wins)
tie = StandardClause("tie", make_script(
0, tmpl_tie.get_standard_template_hash(0)), arg_specs, lambda _, __: tmpl_tie)
bob_wins = StandardClause("bob_wins", make_script(
1, tmpl_bob_wins.get_standard_template_hash(0)), arg_specs, lambda _, __: tmpl_bob_wins)
tie = StandardClause("alice_wins", make_script(
alice_wins = StandardClause("alice_wins", make_script(
2, tmpl_tie.get_standard_template_hash(0)), arg_specs, lambda _, __: tmpl_tie)

super().__init__(NUMS_KEY, [alice_wins, [bob_wins, tie]])

0 comments on commit 9866d73

Please sign in to comment.