[atlantik-cvs] CVS: kdegames/atlantik/libatlantic atlantic_core.cpp,1.23,1.24 atlantic_core.h,1.20,1.21

[email protected]
Newsgroups gmane.comp.kde.devel.atlantik
Message-ID <[email protected]>
Update of /home/kde/kdegames/atlantik/libatlantic
In directory office:/tmp/cvs-serv5255/libatlantic

Modified Files:
	atlantic_core.cpp atlantic_core.h 
Log Message:
move playerSelf to core, fixes some token issues

Index: atlantic_core.cpp
===================================================================
RCS file: /home/kde/kdegames/atlantik/libatlantic/atlantic_core.cpp,v
retrieving revision 1.23
retrieving revision 1.24
diff -u -d -r1.23 -r1.24
--- atlantic_core.cpp	17 Jun 2003 19:54:35 -0000	1.23
+++ atlantic_core.cpp	14 Jul 2003 01:29:51 -0000	1.24
@@ -26,6 +26,8 @@
 
 AtlanticCore::AtlanticCore(QObject *parent, const char *name) : QObject(parent, name)
 {
+	m_playerSelf = 0;
+
 	connect(this, SIGNAL(deletePlayer(Player *)), this, SLOT(slotDeletePlayer(Player *)));
 	connect(this, SIGNAL(deleteTrade(Trade *)), this, SLOT(slotDeleteTrade(Trade *)));
 }
@@ -51,6 +53,8 @@
 		m_players.setAutoDelete(true);
 		m_players.clear();
 		m_players.setAutoDelete(false);
+
+		m_playerSelf = 0;
 	}
 	else
 	{
@@ -61,6 +65,16 @@
 			player->setDestination(0);
 		}
 	}
+}
+
+void AtlanticCore::setPlayerSelf(Player *player)
+{
+	m_playerSelf = player;
+}
+
+Player *AtlanticCore::playerSelf()
+{
+	return m_playerSelf;
 }
 
 QPtrList<Player> AtlanticCore::players()

Index: atlantic_core.h
===================================================================
RCS file: /home/kde/kdegames/atlantik/libatlantic/atlantic_core.h,v
retrieving revision 1.20
retrieving revision 1.21
diff -u -d -r1.20 -r1.21
--- atlantic_core.h	17 Jun 2003 19:54:35 -0000	1.20
+++ atlantic_core.h	14 Jul 2003 01:29:51 -0000	1.21
@@ -35,6 +35,9 @@
 
 	void reset(bool deletePlayers = false);
 
+	void setPlayerSelf(Player *player);
+	Player *playerSelf();
+
 	QPtrList<Player> players();
 	Player *newPlayer(int playerId);
 	Player *findPlayer(int playerId);
@@ -71,6 +74,7 @@
 	void slotDeleteTrade(Trade *trade);
 
 private:
+	Player *m_playerSelf;
 	QPtrList<Player> m_players;
 	QPtrList<Estate> m_estates;
 	QPtrList<EstateGroup> m_estateGroups;
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.