Transfers view
UTXO view
Obyte.org
Unit Legend
- not on main chain, not stable
- main chain, not stable
- bad unit
- not on main chain, stable/confirmed/final
- main chain, stable/confirmed/final
- not on main chain, selected
- main chain, selected
Close
Close
Unit ID
y+UE4iA5fHDLDChx7iUsv+z2Msv2Xb9scQQdOMFKsJQ=
Received
09.10.2019 07:45:32
Confirmation delay (full node)
4 minutes 57 seconds
Confirmation delay (light node)
7 minutes 26 seconds
Authors
DPYEPM34AUBLZFLCJKKGSJ3R34373IUA
Children
2P4wfAjlgJC+ihi2NSN8sV0NpHhG6KkoSK4Mvo9pg40=
Parents
DcIKEaN9nGz206tRezzCpMUCeAFRw+Fami6UepO18Hc=
Messages
Definition
Address:
RQI2WE6EVSK6CY3NRNLHGQXUNJGZGU35
Definition:
[ "autonomous agent", { "init": "{ // =============== OBYSTACK AA ================= // ============================================= // OBYTE STACK GAME from Whistling Frogs // ============================================= // First published by Crypto Girl on 21 Sep 2019 // ============================================= // Version: 1.0 - 9 Oct 2019 // ============================================= // For best game experience should be used with the OBYSTACK GAME BOT v1.0 // Pairing code: //
[email protected]
/bb-test#StackGame // ============================================= // The object of the game is to win the Stack. // Users make bids. Min bid is 1,000,000 bytes. // 1st bid initiates the Stack. // Each subsequent bid starts the timer. // The game ends when the timer rans out. // The Stack (less commission) is shared equally // between the last bidder and the 1st bidder. // The new game is initiated by the next bid. // A 1% commission (10,000 bytes) is charged on each bid. // ============================================ // Visit https://whistling-frogs.herokuapp.com/obyStack // for a full description of the game. // ============================================ // // setting game parameters $bot_address = 'QUONK7CUHPTGLNTZ6JE57SDVSFVDBCMM'; $commission_payout_threshold = 50000; $commission = 10000; $seed_amnt = 10000; $min_bid_amnt = 1000000; $fees = 1000; // setting game variables $bid_amnt = trigger.output[[asset=base]]; $game_finished = (trigger.initial_address == $bot_address) otherwise false; if ( ($game_finished == false) AND ($bid_amnt < $min_bid_amnt) ) bounce('Your bid is too small.'); $game_status = var['game_status'] otherwise 'not started'; }", "messages": { "cases": [ { "if": "{$game_finished == false AND $game_status == 'not started'}", "messages": [ { "app": "state", "state": "{ var['stack_amnt'] = $bid_amnt - $commission; var['commission_pot'] += $commission - $fees; var['author'] = trigger.initial_address; var['leader'] = trigger.initial_address; var['game_status'] = 'running'; response['message'] = 'Thank you for playing'; }" } ] }, { "if": "{$game_finished == false AND $game_status == 'running'}", "messages": [ { "app": "state", "state": "{ var['stack_amnt'] += ($bid_amnt - $commission); var['commission_pot'] += $commission; var['leader'] = trigger.initial_address; response['message'] = 'Thank you for playing'; }" } ] }, { "if": "{$game_finished}", "messages": [ { "app": "payment", "payload": { "cases": [ { "if": "{(var['author'] == var['leader']) AND (var['commission_pot'] >= $commission_payout_threshold)}", "payload": { "asset": "base", "outputs": [ { "address": "{ var['leader'] }", "amount": "{ var['stack_amnt'] }" }, { "address": "{ $bot_address }", "amount": "{ balance[base] - var['stack_amnt'] - $seed_amnt }" } ] } }, { "if": "{(var['author'] == var['leader']) AND (var['commission_pot'] < $commission_payout_threshold)}", "payload": { "asset": "base", "outputs": [ { "address": "{ var['leader'] }", "amount": "{ var['stack_amnt'] }" } ] } }, { "if": "{(var['author'] != var['leader']) AND (var['commission_pot'] >= $commission_payout_threshold)}", "payload": { "asset": "base", "outputs": [ { "address": "{ var['author'] }", "amount": "{ var['stack_amnt'] / 2 }" }, { "address": "{ var['leader'] }", "amount": "{ var['stack_amnt'] / 2 }" }, { "address": "{ $bot_address }", "amount": "{ balance[base] - var['stack_amnt'] - $seed_amnt }" } ] } }, { "if": "{(var['author'] != var['leader']) AND (var['commission_pot'] < $commission_payout_threshold)}", "payload": { "asset": "base", "outputs": [ { "address": "{ var['author'] }", "amount": "{ var['stack_amnt'] / 2 }" }, { "address": "{ var['leader'] }", "amount": "{ var['stack_amnt'] / 2 }" } ] } } ] } }, { "app": "state", "state": "{ // game is finished var['game_status'] = 'not started'; if (var['commission_pot'] >= $commission_payout_threshold) var['commission_pot'] = 0; var['commission_pot'] += $bid_amnt; // add money from the bot to the commission pot var['stack_amnt'] = 0; var['author'] = ''; var['leader'] = ''; response['message'] = 'Game finished.'; }" } ] } ] } } ]
Witnesses
2FF7PSL7FYXVU5UIQHCVDTTPUOOG75GX
2GPBEZTAXKWEXMWCTGZALIZDNWS5B3V7
4H2AMKF6YO2IWJ5MYWJS3N7Y2YU2T4Z5
DFVODTYGTS3ILVOQ5MFKJIERH6LGKELP
ERMF7V2RLCPABMX5AMNGUQBAH4CD5TK4
F4KHJUCLJKY4JV7M5F754LAJX4EB7M4N
IOF6PTBDTLSTBS5NWHUSD7I2NHK3BQ2T
O4K4QILG6VPGTYLRAI2RGYRFJZ7N2Q2O
OPNUXBRSSQQGHKQNEPD2GLWQYEUY5XLD
PA4QK46276MJJD5DBOLIBMYKNNXMUVDP
RJDYXC4YQ4AZKFYTJVCR5GQJF5J6KPRI
WELOXP3EOA75JWNO6S5ZJHOO3EYFKPIR
Technical information
Fees:
4,400
bytes
(353 headers, 4047 payload)
Level:
1098410
Witnessed level:
1098403
Last ball unit:
5ycAIaAwbA+bA8Cfkd1MPupbWUyTuoHeOuYkIxvdvvM=
Main chain index:
1097170
Latest included mc index:
1097169
Status:
stable/confirmed/final