Project::OSiRiON - Git repositories
Project::OSiRiON
News . About . Screenshots . Downloads . Forum . Wiki . Tracker . Git
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorStijn Buys <ingar@osirion.org>2010-09-15 21:29:18 +0000
committerStijn Buys <ingar@osirion.org>2010-09-15 21:29:18 +0000
commite55638d081e2e1ff6fbc06e0e8ac0381a04308e7 (patch)
tree511ccb478adf2acd3cc93f66d217b09f3e3a06dc /src/core/gameconnection.cc
parentf612f19e095b8d0ba49f5bcdec6a582824315d69 (diff)
updated comments, updated buy menu, info support for map window, added const to target selection
Diffstat (limited to 'src/core/gameconnection.cc')
-rw-r--r--src/core/gameconnection.cc16
1 files changed, 6 insertions, 10 deletions
diff --git a/src/core/gameconnection.cc b/src/core/gameconnection.cc
index 46b50f5..ce33dc6 100644
--- a/src/core/gameconnection.cc
+++ b/src/core/gameconnection.cc
@@ -105,7 +105,7 @@ Info *GameConnection::info(unsigned int id)
return info;
} else {
info = new Info(id);
- info->text().push_back("Requesting information...");
+ info->add_text("Requesting information...");
}
@@ -113,12 +113,11 @@ Info *GameConnection::info(unsigned int id)
if (connection_network) {
//con_debug << "Requesting info for " << info->id() << std::endl;
info->set_timestamp(connection_timestamp);
- info->set_id(0);
-
+
connection_network->send_info_request(info);
connection_network->transmit();
} else {
- info->text().push_back("^RNot connected.");
+ info->add_text("^RNot connected.");
info->set_timestamp(0);
}
return info;
@@ -151,21 +150,18 @@ Info *GameConnection::info(const std::string &type, const std::string &label)
return info;
} else {
// create a new info record and set the label
- info = new Info(infotype);
- info->set_label(label);
- info->text().push_back("Requesting information...");
+ info = new Info(infotype, label);
+ info->add_text("Requesting information...");
}
// send an information request to the server
if (connection_network) {
//con_debug << "Requesting info for " << info->type()->label() << ":" << info->label() << std::endl;
info->set_timestamp(connection_timestamp);
- info->set_id(0);
-
connection_network->send_info_request(info);
connection_network->transmit();
} else {
- info->text().push_back("^RNot connected.");
+ info->add_text("^RNot connected.");
info->set_timestamp(0);
}
return info;