Java coin flip using ticks