summaryrefslogtreecommitdiff
path: root/src/client.cpp
diff options
context:
space:
mode:
authorEugenio Favalli <elvenprogrammer@gmail.com>2006-01-13 21:58:21 +0000
committerEugenio Favalli <elvenprogrammer@gmail.com>2006-01-13 21:58:21 +0000
commitf0a3f100f1c21e41447a420f8a729f2fb46c31eb (patch)
tree4a459a14d1df17c31ed9f14580ccea13ac6f58c9 /src/client.cpp
parent50f46449cc04e085b3fbbc821f9108be5e23f715 (diff)
downloadmanaserv-f0a3f100f1c21e41447a420f8a729f2fb46c31eb.tar.gz
manaserv-f0a3f100f1c21e41447a420f8a729f2fb46c31eb.tar.bz2
manaserv-f0a3f100f1c21e41447a420f8a729f2fb46c31eb.tar.xz
manaserv-f0a3f100f1c21e41447a420f8a729f2fb46c31eb.zip
Made minimum client version and default map id configurable, set/getMapId are now preferred.
Diffstat (limited to 'src/client.cpp')
-rw-r--r--src/client.cpp17
1 files changed, 5 insertions, 12 deletions
diff --git a/src/client.cpp b/src/client.cpp
index c1f968ba..bac385b5 100644
--- a/src/client.cpp
+++ b/src/client.cpp
@@ -27,17 +27,18 @@
#include "messageout.h"
#include "messagein.h"
+#if defined WIN32
+#include "../testclient_private.h"
+#define PACKAGE_VERSION PRODUCT_VERSION
+#endif
+
int main(int argc, char *argv[])
{
#if (defined __USE_UNIX98 || defined __FreeBSD__)
#include "../config.h"
#endif
-#ifdef PACKAGE_VERSION
std::cout << "The Mana World Test Client v" << PACKAGE_VERSION << std::endl;
-#else
- std::cout << "The Mana World Test Client v" << DEFAULT_PACKAGE_VERSION << std::endl;
-#endif
// Initialize SDL
if (SDL_Init(SDL_INIT_VIDEO | SDL_INIT_TIMER) == -1) {
@@ -96,11 +97,7 @@ int main(int argc, char *argv[])
// Register
msg.writeShort(CMSG_REGISTER);
// We send the client version
-#ifdef PACKAGE_VERSION
msg.writeString(PACKAGE_VERSION);
-#else
- msg.writeString(DEFAULT_PACKAGE_VERSION);
-#endif
std::cout << "Account name: ";
std::cin >> line;
msg.writeString(line);
@@ -127,11 +124,7 @@ int main(int argc, char *argv[])
// Login
msg.writeShort(CMSG_LOGIN);
// We send the client version
-#ifdef PACKAGE_VERSION
msg.writeString(PACKAGE_VERSION);
-#else
- msg.writeString(DEFAULT_PACKAGE_VERSION);
-#endif
std::cout << "Account name: ";
std::cin >> line;
msg.writeString(line);