修复InitStringEngine()中的Bug,去除调试信息

This commit is contained in:
Kirigaya Kazuto 2017-05-18 14:39:25 +08:00
parent 7e850436b1
commit 920e716048
2 changed files with 3 additions and 9 deletions

View File

@ -24,6 +24,8 @@ void InitStringEngine()
while (fscanf(fp, "%s%*c", tagbuff) == 1)
{
fgets(content, 1024, fp);
int sz = strlen(content);
if (content[sz - 1] == '\n') content[sz - 1] = 0;
strvec.push_back(make_pair(tagbuff, content));
}
fclose(fp);
@ -60,14 +62,6 @@ void GameMain()
InitUnitData();
global.frame->run(new MapEditorScene);
xml_document<> doc;
xml_node<>* rootnode = doc.allocate_node(node_type::node_element, "en_US");
doc.append_node(rootnode);
rootnode->append_node(doc.allocate_node(node_type::node_element, "Fuck", "Fuck XML"));
std::string s;
print(std::back_inserter(s), doc);
printf("%s\n", s.c_str());
}

View File

@ -58,7 +58,7 @@ void MapEditorMapSizeConfigureScene::start(void* ptr)
shared_ptr<MapEditorMapSizeConfigureSceneReturnButton> pReturnButton(new MapEditorMapSizeConfigureSceneReturnButton);
pReturnButton->text = text_a2;
pReturnButton->pos = Rect(winSize.w / 2 - text_a1.getw()/2, winSize.h / 2 + 20, text_a1.getw(), 20);
pReturnButton->pos = Rect(winSize.w / 2 - text_a2.getw()/2, winSize.h / 2 + 20, text_a2.getw(), 20);
btna.addButton(pReturnButton.get());
lp.run();