more code for local playing

This commit is contained in:
Max-Wilhelm Bruker 2010-08-14 17:01:14 +02:00
parent f6a340ddf3
commit 5ff099f4bc
15 changed files with 267 additions and 137 deletions

View file

@ -1,5 +1,4 @@
#include "player.h"
#include "abstractclient.h"
#include "cardzone.h"
#include "playertarget.h"
#include "counter.h"
@ -21,8 +20,8 @@
#include <QMenu>
#include <QDebug>
Player::Player(const QString &_name, int _id, bool _local, AbstractClient *_client, TabGame *_parent)
: QObject(_parent), defaultNumberTopCards(3), lastTokenDestroy(true), name(_name), id(_id), active(false), local(_local), mirrored(false), client(_client)
Player::Player(const QString &_name, int _id, bool _local, TabGame *_parent)
: QObject(_parent), defaultNumberTopCards(3), lastTokenDestroy(true), name(_name), id(_id), active(false), local(_local), mirrored(false)
{
setCacheMode(DeviceCoordinateCache);
@ -977,12 +976,12 @@ void Player::rearrangeCounters()
void Player::sendGameCommand(GameCommand *command)
{
static_cast<TabGame *>(parent())->sendGameCommand(command);
static_cast<TabGame *>(parent())->sendGameCommand(command, id);
}
void Player::sendCommandContainer(CommandContainer *cont)
{
static_cast<TabGame *>(parent())->sendCommandContainer(cont);
static_cast<TabGame *>(parent())->sendCommandContainer(cont, id);
}
void Player::cardMenuAction()