diff -r 8eed495fd8da -r 15f722e0b96f project_files/frontlib/hwconsts.h --- a/project_files/frontlib/hwconsts.h Mon Jun 25 15:21:18 2012 +0200 +++ b/project_files/frontlib/hwconsts.h Wed Jun 27 18:02:45 2012 +0200 @@ -1,3 +1,22 @@ +/* + * Hedgewars, a free turn based strategy game + * Copyright (c) 2004-2012 Andrey Korotaev + * Copyright (c) 2012 Simeon Maxein + * + * 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; version 2 of the License + * + * 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, write to the Free Software + * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA + */ + /** * This file contains important constants which might need to be changed to adapt to * changes in the engine or protocols. @@ -6,14 +25,34 @@ #ifndef HWCONSTS_H_ #define HWCONSTS_H_ +#include +#include + #define HEDGEHOGS_PER_TEAM 8 #define NETGAME_DEFAULT_PORT 46631 -#define PROTOCOL_VERSION 41 +#define PROTOCOL_VERSION 42 #define MIN_SERVER_VERSION 1 -#define GAMEMOD_PERHOGAMMO_MASKBIT 22 -#define GAMEMOD_SHAREDAMMO_MASKBIT 16 +// Used for sending scripts to the engine +#define MULTIPLAYER_SCRIPT_PATH "Scripts/Multiplayer/" #define WEAPONS_COUNT 55 +/* A merge of mikade/bugq colours w/ a bit of channel feedback */ +#define HW_TEAMCOLOR_ARRAY { UINT32_C(0xffff0204), /* red */ \ + UINT32_C(0xff4980c1), /* blue */ \ + UINT32_C(0xff1de6ba), /* teal */ \ + UINT32_C(0xffb541ef), /* purple */ \ + UINT32_C(0xffe55bb0), /* pink */ \ + UINT32_C(0xff20bf00), /* green */ \ + UINT32_C(0xfffe8b0e), /* orange */ \ + UINT32_C(0xff5f3605), /* brown */ \ + UINT32_C(0xffffff01), /* yellow */ \ + /* add new colors here */ \ + 0 } /* Keep this 0 at the end or the length will be calculated wrong */ + +// TODO allow setting alternative color lists? +extern const size_t flib_teamcolor_defaults_len; +extern const uint32_t flib_teamcolor_defaults[]; + #endif