NAME

Game::Floppy::Result - how a game of Floppy ended

VERSION

Version 0.10

SYNOPSIS

my $result = $game->result;

print $result->cause;        # tube
print $result->score;        # 300
print $result->stringify;    # Game over: hit a tube at 300 points after 563 ticks

DESCRIPTION

"result" in Game::Floppy hands one of these back once the game has finished.

METHODS

cause

ground, sky, tube or quit.

score, tubes, ticks

The score, tubes passed, and ticks taken.

died

1 unless the cause is quit.

causes

Every cause.

stringify

One sentence: "Game over: hit a tube at 300 points after 563 ticks", "Game over: fell to the ground ...", "Game over: flew off the top ...", or "Quit at 300 points after 563 ticks".

AUTHOR

LNATION, <email at lnation.org>

LICENSE AND COPYRIGHT

This software is Copyright (c) 2024 by LNATION.

This is free software, licensed under:

The Artistic License 2.0 (GPL Compatible)