Loosened the requirements for constructing a MapPager
This is so that I can configure the size of the pages in the config.cfg file.
This commit is contained in:
@@ -96,6 +96,15 @@ void ServerApplication::Init(int argc, char** argv) {
|
||||
}
|
||||
cout << "Initialized lua's setup script" << endl;
|
||||
|
||||
//setup the map object
|
||||
mapPager.SetRegionWidth(config.Int("map.pager.width"));
|
||||
mapPager.SetRegionHeight(config.Int("map.pager.height"));
|
||||
mapPager.SetRegionDepth(config.Int("map.pager.depth"));
|
||||
//TODO: pass args to the generator & format as needed
|
||||
//NOTE: I might need to rearrange the init process so that lua & SQL can interact
|
||||
// with the map system as needed.
|
||||
cout << "Initialized the map system" << endl;
|
||||
|
||||
//finalize the startup
|
||||
cout << "Startup completed successfully" << endl;
|
||||
}
|
||||
|
||||
@@ -22,20 +22,25 @@
|
||||
#ifndef SERVERAPPLICATION_HPP_
|
||||
#define SERVERAPPLICATION_HPP_
|
||||
|
||||
//maps
|
||||
#include "map_generator.hpp"
|
||||
#include "map_file_format.hpp"
|
||||
#include "region_pager.hpp"
|
||||
|
||||
//networking
|
||||
#include "network_packet.hpp"
|
||||
#include "udp_network_utility.hpp"
|
||||
#include "serial.hpp"
|
||||
|
||||
//common
|
||||
#include "config_utility.hpp"
|
||||
#include "vector2.hpp"
|
||||
|
||||
//APIs
|
||||
#include "lua/lua.hpp"
|
||||
#include "sqlite3/sqlite3.h"
|
||||
#include "SDL/SDL.h"
|
||||
|
||||
//common
|
||||
#include "config_utility.hpp"
|
||||
#include "vector2.hpp"
|
||||
|
||||
//STL
|
||||
#include <map>
|
||||
#include <string>
|
||||
@@ -79,6 +84,9 @@ private:
|
||||
|
||||
void PumpPacket(NetworkPacket);
|
||||
|
||||
//maps
|
||||
RegionPager<MapGenerator, MapFileFormat> mapPager;
|
||||
|
||||
//networking
|
||||
UDPNetworkUtility network;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user