[Bug Fix] Fix Issue with SetFlyMode() (#3961)

# Notes
- Variable and parameter had the same name, meaning this could fail.
This commit is contained in:
Alex King 2024-01-12 02:35:30 -05:00 committed by GitHub
parent 62b5f8a488
commit ef635cb257
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 3 additions and 3 deletions

View File

@ -5612,9 +5612,9 @@ void Mob::SetEntityVariable(std::string variable_name, std::string variable_valu
m_EntityVariables[variable_name] = variable_value;
}
void Mob::SetFlyMode(GravityBehavior flymode)
void Mob::SetFlyMode(GravityBehavior in_flymode)
{
flymode = flymode;
flymode = in_flymode;
}
void Mob::Teleport(const glm::vec3 &pos)

View File

@ -729,7 +729,7 @@ public:
void SetSpawned() { spawned = true; };
bool Spawned() { return spawned; };
virtual bool ShouldISpawnFor(Client *c) { return true; }
void SetFlyMode(GravityBehavior flymode);
void SetFlyMode(GravityBehavior in_flymode);
void Teleport(const glm::vec3 &pos);
void Teleport(const glm::vec4 &pos);
void TryMoveAlong(float distance, float angle, bool send = true);