move some parameters into GameParams.h

This commit is contained in:
josh committed 2012-11-04 08:14:59 -05:00
1 parent 412b84e268
commit bab60ed0bb
5 files changed
+13 -8

No files matched your search

+1
View File
@@ -7,6 +7,7 @@
#include "Client.h" #include "Client.h"
#include "ccfs.h" #include "ccfs.h"
#include "HexTile.h" #include "HexTile.h"
#include "GameParams.h"
using namespace std; using namespace std;
+1 -5
View File
@@ -7,14 +7,10 @@
#include <math.h> #include <math.h>
#include "Client.h" #include "Client.h"
#include "Types.h" #include "Types.h"
#include "GameParams.h"
using namespace std; using namespace std;
/* TODO: this should be moved to common somewhere */
#define MAX_SHOT_DISTANCE 250.0
#define SHOT_EXPAND_SPEED 75.0
#define DEFAULT_PORT 59243
Client::Client(const string & exe_path) Client::Client(const string & exe_path)
{ {
m_client_has_focus = true; m_client_has_focus = true;
-2
View File
@@ -17,8 +17,6 @@
#include "Network.h" #include "Network.h"
#include <SFGUI/SFGUI.hpp> #include <SFGUI/SFGUI.hpp>
#define SHOT_RING_WIDTH 10.0f
enum enum
{ {
MAIN_MENU_NONE, MAIN_MENU_NONE,
+9
View File
@@ -0,0 +1,9 @@
#ifndef GAMEPARAMS_H
#define GAMEPARAMS_H
#define DEFAULT_PORT 59243
#define MAX_SHOT_DISTANCE 250.0
#define SHOT_EXPAND_SPEED 75.0
#define SHOT_RING_WIDTH 10.0f
#endif
+2 -1
View File
@@ -1,10 +1,11 @@
#include <getopt.h> #include <getopt.h>
#include <stdlib.h> #include <stdlib.h>
#include "Server.h" #include "Server.h"
#include "GameParams.h"
int main(int argc, char *argv[]) int main(int argc, char *argv[])
{ {
int port = 59243; int port = DEFAULT_PORT;
for (;;) for (;;)
{ {
static struct option long_options[] = { static struct option long_options[] = {