$execute on passengers if data entity @s {data:{amount:0}} as @a[nbt={UUID:$(player)}] run return run function ws:misc/casino/slot_machine.won_nothing
$scoreboard players add @a[nbt={UUID:$(player)}] casino.chips $(amount)
$tellraw @a[nbt={UUID:$(player)}] [{"translate":"casino.won","bold":true},{"text":"$(amount)","color":"dark_red"},{"translate":"casino.won.chips"}] 
$execute at @a[nbt={UUID:$(player)}] run playsound minecraft:entity.player.levelup player @a