From: Perttu Ahola Date: Sun, 1 Apr 2012 10:37:07 +0000 (+0300) Subject: Fix disabling of player movement cheat detection in singleplayer X-Git-Url: http://81.2.79.47:8989/gitweb/?a=commitdiff_plain;h=5bd32eca0f4c8afa8d933f7d7d1946cabaa8dc43;p=zefram%2Fminetest%2Fminetest_engine.git Fix disabling of player movement cheat detection in singleplayer --- diff --git a/src/content_sao.cpp b/src/content_sao.cpp index 810bd5a7..2b3f7c02 100644 --- a/src/content_sao.cpp +++ b/src/content_sao.cpp @@ -867,7 +867,12 @@ void PlayerSAO::step(float dtime, bool send_recommended) m_time_from_last_punch += dtime; - if(!m_is_singleplayer) + if(m_is_singleplayer) + { + m_last_good_position = m_player->getPosition(); + m_last_good_position_age = 0; + } + else { /* Check player movements