A little cleanup, and some work on LpxClient
This commit is contained in:
@@ -161,7 +161,7 @@ Tangible *World::tangible_make(lua_State *L, int64_t id, const std::string &plan
|
||||
LuaStack LS(L, tangibles, database, metatab);
|
||||
|
||||
// Create the C++ part of the structure.
|
||||
std::unique_ptr<Tangible> &t = tangibles_[id];
|
||||
UniqueTangible &t = tangibles_[id];
|
||||
assert (t == nullptr);
|
||||
t.reset(new Tangible(this, id));
|
||||
|
||||
@@ -564,7 +564,7 @@ void World::deserialize(StreamBuffer *sb) {
|
||||
size_t ntan = sb->read_uint32();
|
||||
for (size_t i = 0; i < ntan; i++) {
|
||||
int64_t id = sb->read_int64();
|
||||
std::unique_ptr<Tangible> &t = tangibles_[id];
|
||||
UniqueTangible &t = tangibles_[id];
|
||||
if (t == nullptr) {
|
||||
t.reset(new Tangible(this, id));
|
||||
} else {
|
||||
|
||||
Reference in New Issue
Block a user