aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/content_cao.cpp5
1 files changed, 1 insertions, 4 deletions
diff --git a/src/content_cao.cpp b/src/content_cao.cpp
index 00e17f328..a8e03d670 100644
--- a/src/content_cao.cpp
+++ b/src/content_cao.cpp
@@ -659,10 +659,7 @@ void GenericCAO::initialize(const std::string &data)
if (player && strcmp(player->getName(), m_name.c_str()) == 0) {
m_is_local_player = true;
m_is_visible = false;
- LocalPlayer* localplayer = player;
-
- assert( localplayer != NULL );
- localplayer->setCAO(this);
+ player->setCAO(this);
}
m_env->addPlayerName(m_name.c_str());
}