[atlantik-cvs] CVS: kdegames/atlantik/libatlantic player.cpp,1.14,1.15 player.h,1.11,1.12
[email protected] Fri, 20 Dec 2002 00:27:30 +0100 (CET)
Newsgroups
gmane.comp.kde.devel.atlantik
Message-ID
<[email protected] >
Update of /home/kde/kdegames/atlantik/libatlantic
In directory office:/tmp/cvs-serv9935/libatlantic
Modified Files:
player.cpp player.h
Log Message:
core and network support for playerupdate master, still need to make use of it in SelectConfiguration widget, though
Index: player.cpp
===================================================================
RCS file: /home/kde/kdegames/atlantik/libatlantic/player.cpp,v
retrieving revision 1.14
retrieving revision 1.15
diff -u -d -r1.14 -r1.15
--- player.cpp 19 Dec 2002 20:00:03 -0000 1.14
+++ player.cpp 19 Dec 2002 23:27:27 -0000 1.15
@@ -27,7 +27,7 @@
m_location = m_destination = 0;
m_money = 0;
m_changed = m_isSelf = false;
- m_hasTurn = m_canRoll = m_canBuy = m_inJail = false;
+ m_master = m_hasTurn = m_canRoll = m_canBuy = m_inJail = false;
}
void Player::setLocation(Estate *location)
@@ -44,6 +44,15 @@
if (m_destination != destination)
{
m_destination = destination;
+ m_changed = true;
+ }
+}
+
+void Player::setMaster(bool master)
+{
+ if (m_master != master)
+ {
+ m_master = master;
m_changed = true;
}
}
Index: player.h
===================================================================
RCS file: /home/kde/kdegames/atlantik/libatlantic/player.h,v
retrieving revision 1.11
retrieving revision 1.12
diff -u -d -r1.11 -r1.12
--- player.h 19 Dec 2002 20:00:03 -0000 1.11
+++ player.h 19 Dec 2002 23:27:27 -0000 1.12
@@ -36,6 +36,8 @@
Estate *destination() { return m_destination; }
void setIsSelf(const bool isSelf) { m_isSelf = isSelf; }
bool isSelf() const { return m_isSelf; }
+ void setMaster(bool master);
+ bool master() { return m_master; }
void setHasTurn(const bool hasTurn);
bool hasTurn() const { return m_hasTurn; }
void setCanRoll(bool canRoll);
@@ -60,7 +62,7 @@
private:
int m_id;
bool m_changed, m_isSelf;
- bool m_hasTurn, m_canRoll, m_canBuy, m_inJail;
+ bool m_master, m_hasTurn, m_canRoll, m_canBuy, m_inJail;
unsigned int m_money;
QString m_name, m_host, m_image;
Estate *m_location, *m_destination;