Project::OSiRiON - Git repositories
Project::OSiRiON
News . About . Screenshots . Downloads . Forum . Wiki . Tracker . Git
summaryrefslogtreecommitdiff
path: root/src/core
diff options
context:
space:
mode:
authorStijn Buys <ingar@osirion.org>2012-10-10 18:11:03 +0000
committerStijn Buys <ingar@osirion.org>2012-10-10 18:11:03 +0000
commit54c29f6e8ae8f504e455de79ecbb1a16d0e634a1 (patch)
tree732330a1049b06a18ad7c71e5a95c7c92500eaeb /src/core
parent90be07acb8d2a2c481761ef754d938559510ae0f (diff)
Added zone info parameters to the zone update network message, updated the network protocol version to 24.
Diffstat (limited to 'src/core')
-rw-r--r--src/core/entity.cc4
-rw-r--r--src/core/net.h2
-rw-r--r--src/core/zone.cc10
3 files changed, 12 insertions, 4 deletions
diff --git a/src/core/entity.cc b/src/core/entity.cc
index 7bb5278..1b879f3 100644
--- a/src/core/entity.cc
+++ b/src/core/entity.cc
@@ -443,7 +443,7 @@ void Entity::receive_server_create(std::istream &is)
if (is >> o) {
if (!o) {
if (inventory()) {
- con_warn << "Receive no inventory for entity " << id() << " " << label() << " with inventory!" << std::endl;
+ con_warn << "No inventory received for entity " << id() << " " << label() << " with inventory!" << std::endl;
entity_inventory->clear();
}
} else {
@@ -453,7 +453,7 @@ void Entity::receive_server_create(std::istream &is)
}
} else {
if (inventory()) {
- con_warn << "Receive no inventory for entity " << id() << " " << label() << " with inventory!" << std::endl;
+ con_warn << "No inventory received for entity " << id() << " " << label() << " with inventory!" << std::endl;
entity_inventory->clear();
}
}
diff --git a/src/core/net.h b/src/core/net.h
index 8f3175d..0e36806 100644
--- a/src/core/net.h
+++ b/src/core/net.h
@@ -11,7 +11,7 @@ namespace core
{
/// network protocol version
-const unsigned int PROTOCOLVERSION = 23;
+const unsigned int PROTOCOLVERSION = 24;
/// maximum lenght of a (compressed) network message block
const unsigned int FRAMESIZE = 1152;
diff --git a/src/core/zone.cc b/src/core/zone.cc
index 2059e03..b038d82 100644
--- a/src/core/zone.cc
+++ b/src/core/zone.cc
@@ -281,7 +281,9 @@ void Zone::serialize_server_update(std::ostream & os) const
os << zone_ambient_color.r << " ";
os << zone_ambient_color.g << " ";
os << zone_ambient_color.b << " ";
- os << (zone_defaultview ? zone_defaultview->id() : 0);
+ os << (zone_defaultview ? zone_defaultview->id() : 0) << " ";
+ os << zone_location << " ";
+ os << zone_flags;
}
@@ -318,6 +320,12 @@ void Zone::receive_server_update(std::istream &is)
// default view
is >> id;
zone_defaultview = Entity::find(id);
+
+ // location
+ is >> zone_location;
+
+ // flags
+ is >> zone_flags;
}
}