reverted clientenvironment.cpp and localplayer.cpp to original because the changes were unnecessary (see client.h)
This commit is contained in:
parent
fb1651b55c
commit
2655abc808
|
@ -92,8 +92,7 @@ void ClientEnvironment::step(float dtime)
|
||||||
stepTimeOfDay(dtime);
|
stepTimeOfDay(dtime);
|
||||||
|
|
||||||
// Get some settings
|
// Get some settings
|
||||||
//bool fly_allowed = m_client->checkLocalPrivilege("fly");
|
bool fly_allowed = m_client->checkLocalPrivilege("fly");
|
||||||
bool fly_allowed = true; //toggled using default keybind
|
|
||||||
bool free_move = fly_allowed && g_settings->getBool("free_move");
|
bool free_move = fly_allowed && g_settings->getBool("free_move");
|
||||||
|
|
||||||
// Get local player
|
// Get local player
|
||||||
|
|
|
@ -194,10 +194,8 @@ void LocalPlayer::move(f32 dtime, Environment *env, f32 pos_max_d,
|
||||||
PlayerSettings &player_settings = getPlayerSettings();
|
PlayerSettings &player_settings = getPlayerSettings();
|
||||||
|
|
||||||
// Skip collision detection if noclip mode is used
|
// Skip collision detection if noclip mode is used
|
||||||
//bool fly_allowed = m_client->checkLocalPrivilege("fly");
|
bool fly_allowed = m_client->checkLocalPrivilege("fly");
|
||||||
bool fly_allowed = true; //toggled using default keybind
|
bool noclip = m_client->checkLocalPrivilege("noclip") && player_settings.noclip;
|
||||||
//bool noclip = m_client->checkLocalPrivilege("noclip") && player_settings.noclip;
|
|
||||||
bool noclip = true && player_settings.noclip; //default keybind
|
|
||||||
bool free_move = player_settings.free_move && fly_allowed;
|
bool free_move = player_settings.free_move && fly_allowed;
|
||||||
|
|
||||||
if (noclip && free_move) {
|
if (noclip && free_move) {
|
||||||
|
@ -490,8 +488,7 @@ void LocalPlayer::applyControl(float dtime, Environment *env)
|
||||||
v3f speedH = v3f(0,0,0); // Horizontal (X, Z)
|
v3f speedH = v3f(0,0,0); // Horizontal (X, Z)
|
||||||
v3f speedV = v3f(0,0,0); // Vertical (Y)
|
v3f speedV = v3f(0,0,0); // Vertical (Y)
|
||||||
|
|
||||||
//bool fly_allowed = m_client->checkLocalPrivilege("fly");
|
bool fly_allowed = m_client->checkLocalPrivilege("fly");
|
||||||
bool fly_allowed = true; //toggled using default keybind
|
|
||||||
bool fast_allowed = m_client->checkLocalPrivilege("fast");
|
bool fast_allowed = m_client->checkLocalPrivilege("fast");
|
||||||
|
|
||||||
bool free_move = fly_allowed && player_settings.free_move;
|
bool free_move = fly_allowed && player_settings.free_move;
|
||||||
|
@ -803,10 +800,8 @@ void LocalPlayer::old_move(f32 dtime, Environment *env, f32 pos_max_d,
|
||||||
PlayerSettings &player_settings = getPlayerSettings();
|
PlayerSettings &player_settings = getPlayerSettings();
|
||||||
|
|
||||||
// Skip collision detection if noclip mode is used
|
// Skip collision detection if noclip mode is used
|
||||||
//bool fly_allowed = m_client->checkLocalPrivilege("fly");
|
bool fly_allowed = m_client->checkLocalPrivilege("fly");
|
||||||
bool fly_allowed = true; //toggled using default keybind
|
bool noclip = m_client->checkLocalPrivilege("noclip") && player_settings.noclip;
|
||||||
//bool noclip = m_client->checkLocalPrivilege("noclip") && player_settings.noclip;
|
|
||||||
bool noclip = true && player_settings.noclip; //default keybind
|
|
||||||
bool free_move = noclip && fly_allowed && player_settings.free_move;
|
bool free_move = noclip && fly_allowed && player_settings.free_move;
|
||||||
if (free_move) {
|
if (free_move) {
|
||||||
position += m_speed * dtime;
|
position += m_speed * dtime;
|
||||||
|
|
Loading…
Reference in New Issue