What exactly is a malicious miner doing when bamboozling a random outcome for a game by throwing away a block?

I’m a noob with dev.
Please explain this to me.
I keep reading that it costs money to throw away a block in an attempt to bamboozle a random outcome for a game contract, assuming the random number was based on seemingly random information in a future block.
So if the potential winnings are lower than the cost of cheating it wouldn’t be worth it to the malicious actor.
For instance – how can I can I calculate or understand the cost of throwing away a block?
I would appreciate any information on this.
submitted by /u/badtimemachine
[link] [comments]