Main > Free Download Search >

Free games euchre 1.02 software for linux

games euchre 1.02

Sponsored Links
Sponsored Links
Secleted [ 0 ] software to compare
Results 1 - 15 of about 2216
Games::Euchre 1.02

Games::Euchre 1.02


Games::Euchre is an Euchre card game for humans and computers. more>>
Games::Euchre is an Euchre card game for humans and computers.

SYNOPSIS

Simply run my game wrapper:

% euchre.pl

or write your own:

use Games::Euchre;
use Games::Euchre::AI::Simple;
use Games::Euchre::AI::Human;

my $game = Games::Euchre->new();
foreach my $i (1..3) {
$game->setAI($i, Games::Euchre::AI::Simple->new());
}
$game->setAI(4, Games::Euchre::AI::Human->new());
$game->playGame();
my @scores = sort {$b $a} $game->getScores();
print("The winner is " . $game->getWinner()->getName() . " with a score of " .
"$scores[0] to $scores[1]n");

This software implements the card game of Euchre. The game is played with four players composing two teams. Any of the four players can be human or computer players, but more than one human is not well supported yet.

The Games::Euchre::AI module implements a simple framework for adding new classes of human interfaces or computer opponents. I recomment that AI writers use Games::Euchre::AI::Simple (a REALLY dumb computer opponent) as starting point.
Aside from the ::AI class and its descendents, this package also implements the following classes: Games::Euchre::Team, Games::Euchre::Player and Games::Euchre::Trick.

<<less
Download (0.021MB)
Added: 2007-01-03 License: GPL (GNU General Public License) Price:
1034 downloads
Games::Euchre::AI 1.02

Games::Euchre::AI 1.02


Games::Euchre::AI is a Player API for Euchre card game. more>>
Games::Euchre::AI is a Player API for Euchre card game.

This class implements a skeletal Euchre player programming interface. Subclasses can be created quite easily as interactive interfaces or AI computer players.
If you wish to write your own computer player, I recommend you start with Games::Euchre::AI::Simple. If you wish to write your own human interface, I recommend you start with Games::Euchre::AI::Human.

CLASS METHODS

new

Create and initialize a new Euchre AI. This object is implemented as an empty hash. Subclasses may wish to use this hash for state storage.

INSTANCE METHODS

Actions

The following methods are called in the course of the game where the AI (or human) has to make a decision. The state of the game is always passed in a hashreference. The following fields are always available:

name is the name of the current player. This is useful for output messages.
names is a hash relating player number to player name for all four players.
debug is a boolean indicating if we are debugging game or the AIs. Your AI may wish to provide verbose output if debugging is going on.

bid STATEHASH

Choose trump or pass. The relevent details of the current state of the game are provided in a hash reference. Here is an example of that data structure:

{
name => Player 1,
names => {1 => Player 1, 2 => P2, 3 => P3, 4 => Fred},
number => 1,
turnedUp => KH,
passes => 1,
ourScore => 2,
theirScore => 4,
winScore => 10,
hangdealer => false,
notrump => false,
hand => [JS, QH, 9S, KC, AD],
debug => false,
}

turnedUp is the suit and value of the card on the top of the blind. This will be undef on the second round of bidding.

passes says how many people have passed so far
hangdealer is a boolean saying whether the hang-the-dealer optional rule is in effect

notrump is a boolean saying whether the no trump optional rule is in effect
This function must return one of: H, D, C, S, N, HA, DA, CA, SA, NA, or undef
N means no trump, A means alone, undef means pass. Not all of these are legal at any given round! Use the isLegalBid() method below if you are unsure.

pickItUp STATEHASH

If this is called, you are the dealer and someone called trump. Choose which card from your hand to discard in exchange for the top card of the blind. The relevent details of the current state of the game are provided in a hash reference. Here is an example of that data structure:

{
name => Player 1,
names => {1 => Player 1, 2 => P2, 3 => P3, 4 => Fred},
number => 1,
turnedUp => KH,
trump => H,
bidder => 2,
weBid => false,
usAlone => false,
themAlone => false,
hand => [JS, QH, 9S, KC, AD],
debug => false,
}

This method should return the 0-based index of the card to trade for the turnedUp card. Namely, this in the index of the hand array for the card that you choose.

playCard STATEHASH

Choose which card from your hand to play on this trick. The relevent details of the current state of the game are provided in a hash reference. Here is an example of that data structure:

{
name => Player 1,
names => {1 => Player 1, 2 => P2, 3 => P3, 4 => Fred},
number => 1,
trump => H,
bidder => 2,
weBid => true,
usAlone => false,
themAlone => false,
trick => 2,
ourTricks => 0,
theirTricks => 1,
ourScore => 2,
theirScore => 4,
winScore => 10,
played => [10H, 9H, QC],
playedBy => [2, 3, 4, 1],
hand => [JH, AH, AS, KS],
debug => false,
}

playedBy is an arrayref of numbers of the players in the order they will play. Without this, the alone possibility makes it hard to tell who played what.

Any needed information not stored here (like who was the dealer, what was the turn-up card, what happened in the first trick) is YOUR responsibility to collect and store in your instance.

This method should return the 0-based index of the card to play. Namely, this in the index of the hand array for the card that you choose.

<<less
Download (0.021MB)
Added: 2006-12-26 License: Perl Artistic License Price:
1034 downloads
Games::Euchre::Trick 1.02

Games::Euchre::Trick 1.02


Games::Euchre::Trick is a trick class for Euchre card game. more>>
Games::Euchre::Trick is a trick class for Euchre card game.

Only one Trick instance is alive at one time per Euchre game. The Trick keeps track of which cards have been played, and provides useful functions to determine which cards are legal plays, as well as who is the winner of the trick.

The trick class makes the determination of which card beats which card, given the current trump and lead. The trick class knows how to handle an alone hand and it calls the playCard() method for each player in turn in its play() method, usually called from the Games::Euchre->playHand() method.

<<less
Download (0.021MB)
Added: 2007-01-02 License: Perl Artistic License Price:
1026 downloads
Games::Euchre::Player 1.02

Games::Euchre::Player 1.02


Games::Euchre::Player is a player class for Euchre card game. more>>
Games::Euchre::Player is a player class for Euchre card game.

The four Player objects are used to interact with the humand and computer players, as well as to keep the state of the players hand, whether he bid and whether he went alone.

CLASS METHODS

new GAME NUMBER NAME
Create and initialize a new Euchre player. The number is 1-4.

INSTANCE METHODS

getGame

Return the Euchre game instance to which this player belongs.

setTeam TEAM

Record the Team instance that this player belongs to.

getTeam

Return the Team instance to which this player belongs.

setAI AI

Record the AI instance for this player.

getAI

Return the AI instance for this player.

setAlone

Indicate that this player has chosen to go alone in the current hand.

setBid

Indicate that this player has chosen to choose trump in the current hand.

wentAlone

Returns a boolean indicating whether this player chose to go alone on a bid.

isBidder

Returns a boolean indicating whether this player called the trump suit during bidding.

getName

Return this players name

getNumber

Return this players number, between 1 and 4

getHand

Return the Games::Cards::Hand object representing this players current hand.

getCards

Return an array of the Games::Cards::Card objects held in the players hand.

resetGame

Clear all of the state for the current game and get ready for the next one.

resetHand

Clear all of the state for the current hand and get ready for the next one.

bid TURN

Allow the player to choose trump or pass. Returns one of: H, C, D, S, N, HA, CA, DA, SA, NA, or undef. If the player has an AI instance set, that is invoked. Otherwise a pathetically simple AI decides the bid.

pickItUp

Allow the player, as dealer, to select which card to trade for the turned up card. This method performs the actual trade. If the player has an AI instance set, that is invoked. Otherwise a pathetically simple AI chooses the card.

playCard TRICK

Allow the player to select which card to play on the current trick. This method performs the actual play. If the player has an AI instance set, that is invoked. Otherwise a pathetically simple AI chooses the card.

isLegalBid TURNNUMBER BID

Given a bid, return a boolean indicating the validity of that bid. The bid is tested for structure (one of H, C, D, S, N, HA, CA, DA, SA, NA, or undef), tested against the bidding round (only the turned-up card suit can be called in round 1 , and may not be called in round 2), against the game options (hang-the-dealer, no-trump).
This is called from the bid() method.

<<less
Download (0.021MB)
Added: 2006-12-21 License: Perl Artistic License Price:
1038 downloads
Games::Score 0.02

Games::Score 0.02


Games::Score is a Perl module to keep track of score in games . more>>
Games::Score is a Perl module to keep track of score in games .

SYNOPSIS

use Games::Score;

# these three values are the default ones, by the way
Games::Score->default_score(0);
Games::Score->default_step(1);
Games::Score->step_method(inc);

# start two players
my $player1 = Games::Score->new();
my $player2 = Games::Score->new();

# set a winning condition
Games::Score->victory_is( sub { $_[0] >= 20 } );

# and something to do if it is achieved
Games::Score->on_victory_do( sub { print "Won!" } );

# give points to the players
$player1->add(2);
$player2->step();

# look at section FUNCTIONS for more functionalities, such as
Games::Score->invalidate_if( sub { $_[0] > 20 } );

Games::Score can be use to keep track of several players points in a game, regardless of the starting amount of points, winning and/or losing conditions, etc.
It provides several useful methods so that the user doesnt have to keep testing values to see if theyre valid or if the player condition has changed.

<<less
Download (0.007MB)
Added: 2006-12-27 License: Perl Artistic License Price:
1031 downloads
Games::Checkers 0.1.0

Games::Checkers 0.1.0


Games::Checkers is a Perl module that allows you to play the Checkers games. more>>


SYNOPSIS

# automatical computer-vus-computer play script
use Games::Checkers::Constants;
use Games::Checkers::Board;
use Games::Checkers::BoardTree;

my $board = new Games::Checkers::Board;
my $color = White;
my $numMoves = 0;
print $board->dump;

while ($board->canColorMove($color)) {
sleep(2);
# allow 100 moves for each player
die "Automatical drawn" if $numMoves++ == 200;
my $boardTree = new Games::Checkers::BoardTree
($board, $color, 2); # think 2 steps ahead
my $move = $boardTree->chooseBestMove; # or: chooseRandomMove

$board->transform($move);
print $move->dump, "n", $board->dump;
$color = ($color == White)? Black: White;
}

print "n", ($color == White? "Black": "White"), " won.n";
ABSTRACT ^
Games::Checkers is a set of Perl classes implementing the Checkers game play. Several national rule variants are supported. A basic AI heuristics is implemented using the Minimax algorithm. Replay of previously recorded games is supported too.
DESCRIPTION ^
This package is intended to provide complete infrastructure for interactive and automatic playing and manipulating of Checkers games. Some features are not implemented yet.
<<less
Download (0.28MB)
Added: 2007-01-03 License: Perl Artistic License Price:
1032 downloads
Euchre 0.7

Euchre 0.7


Euchre project is an Euchre game. more>>
Euchre project is an Euchre game.
Euchre is a spades or bridge-like card game played with four players (3 computer players and 1 human).
The game is played via a GTK+ interface and allows customization of the computer skill level, aggression level, and many of the other game parameters. There are three levels of AI skill (easy, medium, and hard).
The medium and hard levels are good enough to give you a decent challenge.
Enhancements:
- Fixed bug where pass markers are not cleared after an all-pass event (thanks to an unknown euchre lover on sourceforge...)
- Added previous tricks dialog and the view menu items to access it
<<less
Download (0.38MB)
Added: 2006-11-10 License: GPL (GNU General Public License) Price:
1084 downloads
Games::Cards 1.45

Games::Cards 1.45


Games::Cards is a Perl module for writing and playing card games. more>>
Games::Cards is a Perl module for writing and playing card games.

SYNOPSIS

use Games::Cards;
my $Rummy = new Games::Cards::Game;

# Create the correct deck for a game of Rummy.
my $Deck = new Games::Cards::Deck ($Rummy, "Deck");

# shuffle the deck and create the discard pile
$Deck->shuffle;
my $Discard = new Games::Cards::Queue "Discard Pile";

# Deal out the hands
foreach my $i (1 .. 3) {
my $hand = new Games::Cards::Hand "Player $i" ;
$Deck->give_cards($hand, 7);
$hand->sort_by_value;
push @Hands, $hand;
}

# print hands (e.g. "Player 1: AS 2C 3C 3H 10D QS KH")
foreach (@Hands) { print ($_->print("short"), "n") }

$Hands[1]->give_a_card ($Discard, "8D"); # discard 8 of diamonds

This module creates objects and methods to allow easier programming of card games in Perl. It allows you to do things like create decks of cards, have piles of cards, hands, and other sets of cards, turn cards face-up or face-down, and move cards from one set to another. Which is pretty much all you need for most card games.

<<less
Download (0.089MB)
Added: 2007-01-03 License: Perl Artistic License Price:
1034 downloads
Java Games 1.0

Java Games 1.0


Java Games is a collection of simple games that are compiled into Java applets and meant to be played online in a Web browser. more>>
Java Games project is a collection of simple games that are compiled into Java applets and meant to be played online in a Web browser.

Currently the collection contains four games: XO World (similar to tic-tac-toe, but with lines of 5 on a 10x10 board); 100 Mack (guess the random combination of 4 images out of a set of six); Memory (flip 2 plates at a time to find matching pairs); and Tetris.
<<less
Download (0.13MB)
Added: 2007-02-20 License: GPL (GNU General Public License) Price:
985 downloads
Scalar 1.02

Scalar 1.02


Scalar is an addictive cross-platform puzzle game written in C++ using SDL library. more>>
Scalar is an addictive cross-platform puzzle game written in C++ using SDL library.

The goal of the game is to assemble the picture from pieces. Each picture is divided into pieces which are shuffled. You need to get each piece back to its original position. You accomplish that by swapping pieces (exchanging their positions).

You have a limited number of swappings for each picture. The game is over when you complete 3 images, and for each one you get the points. If you have a hard time playing this, you can look at the images directory and see what the final picture looks like.

Feel free to add more pictures to images directory and play with them (images can be in .jpg, .gif, .png, .bmp, any many other formats).

<<less
Download (2.6MB)
Added: 2005-08-11 License: GPL (GNU General Public License) Price:
1534 downloads
scurvy 1.02

scurvy 1.02


scurvy converts a simple text format to proper screenplay format. more>>
The name scurvy comes from "screen/script" and "vi/vim"

Its a tool that lets you easily write screenplays or scripts in a simple text format, then scurvy will output them in the proper screenplay format.

Scurvy can also import some RTF and Final Draft formats, as well as outputting/converting to a variety of formats as well.

Finally, Ive included some vim syntax files to do coloring of the scurvy input and formal screenplay format.

<<less
Download (0.01MB)
Added: 2006-08-31 License: Free for non-commercial use Price:
1151 downloads
Acme::Comment 1.02

Acme::Comment 1.02


Acme::Comment is a Perl module that allows multi-line comments which are filtered out. more>>
Acme::Comment is a Perl module that allows multi-line comments which are filtered out.

SYNOPSIS

use Acme::Comment type=>C++, own_line=>1;

/*
if (ref $mod) {
$bar->{do}->blat(msg => blarg);
eval {

im sooo sick of this time for some coffee

*/

// I prefer beer. --sqrn

Unlike the pseudo multi-line comment if (0) {}, the code being commented out need not be syntactically valid.

<<less
Download (0.007MB)
Added: 2007-06-11 License: Perl Artistic License Price:
867 downloads
Zeps Dreamland 1.02

Zeps Dreamland 1.02


Zeps Dreamland is a block-building platformer. more>>
Zeps Dreamland is a block-building platformer.

The game consists of navigating Zep throughout a level to reach a certain location which allows him to advance to the next level. This is not such an easy task, however. Many obstacles will be in your path, and it is up to you to determine the best (and sometimes only way) to get around them.

Zep has the ability to create special "blocks" by using the life energy from the ground he is standing on. By building the blocks in specific patterns, Zep can alter the landscape to his ability thus allowing him to reach his goal! Again, not everything is as it seems.

Zep cannot build blocks while standing on top of just anything. There are many types of ground that restrict Zeps building ability. In addition to being able to create these special blocks, Zep can also destroy them.

<<less
Download (5.5MB)
Added: 2006-10-09 License: Freeware Price:
1110 downloads
Games::Console 0.04

Games::Console 0.04


Games::Console Perl module provide a 2D quake style in-game console. more>>
Games::Console Perl module provide a 2D quake style in-game console.

SYNOPSIS

use Games::Console;

my $console = Games::Console->new(
font => $font_object,
background_color => [ 1,1,0],
background_alpha => 0.4,
text_color => [ 1,1,1 ],
text_alpha => 1,
speed => 50, # in percent per second
height => 50, # fully opened, in percent of screen
width => 100, # fully opened, in percent of screen
backbuffer_size => 100, # keep so many messages
prompt => >,
cursor => _,
);

$console->screen_width($width);
$console->screen_height($height);
$console->toggle($current_time);
$console->message(Hello there!);
$console->input(a);

This package provides you with a quake-style console for your games. The console gathers messages and lets you scroll trough them. It also can display a command line.

This package is just a base class setting up everything, but doesnt actually render anything.

See Games::Console::SDL and Games::Console::OpenGL for subclasses that implement the actual rendering to the screen via SDL and OpenGL, respectively.

<<less
Download (0.021MB)
Added: 2007-07-25 License: Perl Artistic License Price:
822 downloads
Games::Othello 0.01

Games::Othello 0.01


Games::Othello is a Perl extension for modelling a game of Othello. more>>
Games::Othello is a Perl extension for modelling a game of Othello.

SYNOPSIS

use Games::Othello;

my $game = Games::Othello->new();

while( !game->over ) {
printf "It is presently %ss move",
($game->whos_move eq b) ? black, white;
my @possible_moves = values $game->possible_moves();

if ( ! @possible_moves ) {
print "You have no moves available, you must pass.
$game->pass_to_opponent;
} else {
foreach ( my $move ) @possible_moves ) {
printf
"You will take %d of your opponents chips if you place your chip on %d,%d",
scalar @{ $move->{chips} }, $move->{x}, $move->{y};
}
my ($locx, $locy) = get_move();
my $flipped = $game->place_chip( $locx, $locy );
}

my $layout = $game->chip_layout();
foreach my $row ( @$layout ) {
foreach my $pos ( @$row ) {
printf %3s,
($pos eq b) ? B # Black occupied square.
: ($pos eq w) ? W # White occupied square.
: # Un-occupied square.
}
print "nn";
}
}
my ($black_score, $white_score) = $game->score;

<<less
Download (0.005MB)
Added: 2006-12-28 License: Perl Artistic License Price:
1041 downloads
Secleted [ 0 ] software to compare
  • Page: 1 of 5
  • 1
  • 2
  • 3
  • 4
  • 5