Query editor
with bro as (selectblock_time, tx_hash, tx_from, tx_to, varbinary_to_uint256 (topic1) as game_id, substr(topic2, 13) as player, REGEXP_EXTRACT_ALL(SUBSTR(TRY_CAST(data as VARCHAR), 3), '.{64}') as segmentedfrom monad.logswhere contract_address = 0xDF7A89Fc62e5120C4617f143C7AcDDAB0D1Ca7A2and topic0 = 0xef1af4d8b7c000d734740755f526074f6a4ea51fa25ad0d3be2dff6304a4fb41), prices as (selecttimestamp, contract_address, pricefrom prices.hourwhere blockchain = 'monad'), bro_decoded as (selectblock_time, tx_hash, tx_from, tx_to, game_id, player, 0x0000000000000000000000000000000000000000 as token_bet, try_cast(VARBINARY_TO_UINT256 (TRY_CAST(FROM_HEX(segmented[2]) as VARBINARY)) as double) / 1e18 as bet_amountfrom bro), create_game as (selectblock_time, tx_hash, tx_from, tx_to, game_id, player, bet_amount, bet_amount * price as bet_amount_usdfrom bro_decodedleft join prices on token_bet = contract_addressand date_trunc('hour', block_time) = timestamp), first_time as (selectplayer, date_trunc('day', min(block_time)) as min_timefrom create_gamegroup byplayer), everytime as (selectplayer