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>2008-11-08 10:17:37 +0000
committerStijn Buys <ingar@osirion.org>2008-11-08 10:17:37 +0000
commit4cad4a27677b0490d3ba0018bc3404961f925ed5 (patch)
treef9d59542f27f66a9fb4c8938f40aec66994449fc /src/core/zone.cc
parent27ab3566118e77754fefb32a41ee06cf24a59dfe (diff)
docking, bumps network protocol version
Diffstat (limited to 'src/core/zone.cc')
-rw-r--r--src/core/zone.cc8
1 files changed, 7 insertions, 1 deletions
diff --git a/src/core/zone.cc b/src/core/zone.cc
index 2dfc5c2..5d9c48f 100644
--- a/src/core/zone.cc
+++ b/src/core/zone.cc
@@ -118,7 +118,7 @@ void Zone ::clear()
zone_registry.clear();
}
-/* ---- The Zone class --------------------------------------------- */
+/* ---- class Zone ------------------------------------------------- */
Zone::Zone(std::string const & label) :
zone_label(label)
@@ -127,6 +127,7 @@ Zone::Zone(std::string const & label) :
zone_name.clear();
zone_sky.clear();
zone_sky_texture = 0;
+ zone_defaultview = 0;
}
Zone::Zone(std::istream & is)
@@ -197,6 +198,7 @@ void Zone::serialize_server_update(std::ostream & os) const
os << zone_label << " ";
os << "\"" << zone_name << "\" ";
os << "\"" << zone_sky << "\" ";
+ os << (zone_defaultview ? zone_defaultview->id() : 0 );
}
@@ -205,6 +207,7 @@ void Zone::receive_server_update(std::istream &is)
is >> zone_label;
std::string n;
+ unsigned int id = 0;
char c;
while ( (is.get(c)) && (c != '"'));
@@ -218,6 +221,9 @@ void Zone::receive_server_update(std::istream &is)
n += c;
zone_sky.assign(n);
n.clear();
+
+ is >> id;
+ zone_defaultview = Entity::find(id);
}
}