From 487d3be4cc8761e5697d4fb95d85e9da8dcaa42e Mon Sep 17 00:00:00 2001 From: Andrei Karas Date: Fri, 5 Sep 2014 17:30:36 +0300 Subject: Add serverfeatures class for check is server support one or another features. --- src/net/tmwa/serverfeatures.cpp | 35 +++++++++++++++++++++++++++++++++++ 1 file changed, 35 insertions(+) create mode 100644 src/net/tmwa/serverfeatures.cpp (limited to 'src/net/tmwa/serverfeatures.cpp') diff --git a/src/net/tmwa/serverfeatures.cpp b/src/net/tmwa/serverfeatures.cpp new file mode 100644 index 000000000..d2aba176b --- /dev/null +++ b/src/net/tmwa/serverfeatures.cpp @@ -0,0 +1,35 @@ +/* + * The ManaPlus Client + * Copyright (C) 2011-2014 The ManaPlus Developers + * + * This file is part of The ManaPlus Client. + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ + +#include "net/tmwa/serverfeatures.h" + +#include "debug.h" + +extern int serverVersion; + +namespace TmwAthena +{ + +bool ServerFeatures::haveOnlineList() const +{ + return serverVersion >= 3; +} + +} // TmwAthena -- cgit v1.2.3-60-g2f50