mirror of
https://github.com/glest/glest-source.git
synced 2025-02-24 03:32:35 +01:00
map editor: new maps set player name as default author
This commit is contained in:
parent
17a412aa9a
commit
b4fabc2717
@ -14,8 +14,10 @@
|
||||
#include "util.h"
|
||||
#include <iostream>
|
||||
#include "platform_util.h"
|
||||
#include "config.h"
|
||||
|
||||
using namespace Shared::Util;
|
||||
using namespace Glest::Game;
|
||||
|
||||
namespace MapEditor {
|
||||
|
||||
@ -154,6 +156,10 @@ Program::Program(int w, int h) {
|
||||
map = new MapPreview();
|
||||
resetFactions(8);
|
||||
renderer.initMapSurface(w, h);
|
||||
Config &config = Config::getInstance();
|
||||
// set player name as default author
|
||||
string playerName = config.getString("NetPlayerName","");
|
||||
map->setAuthor(playerName);
|
||||
}
|
||||
|
||||
void Program::init() {
|
||||
|
Loading…
x
Reference in New Issue
Block a user