CCharacterCore: Join Init() methods

This commit is contained in:
Alexander Akulich 2021-01-13 02:25:26 +03:00
parent 33dc79d190
commit e0affc3f34
2 changed files with 1 additions and 13 deletions

View file

@ -56,17 +56,6 @@ float VelocityRamp(float Value, float Start, float Range, float Curvature)
return 1.0f / powf(Curvature, (Value - Start) / Range); return 1.0f / powf(Curvature, (Value - Start) / Range);
} }
void CCharacterCore::Init(CWorldCore *pWorld, CCollision *pCollision, CTeamsCore *pTeams)
{
m_pWorld = pWorld;
m_pCollision = pCollision;
m_pTeleOuts = NULL;
m_pTeams = pTeams;
m_Id = -1;
Reset();
}
void CCharacterCore::Init(CWorldCore *pWorld, CCollision *pCollision, CTeamsCore *pTeams, std::map<int, std::vector<vec2>> *pTeleOuts) void CCharacterCore::Init(CWorldCore *pWorld, CCollision *pCollision, CTeamsCore *pTeams, std::map<int, std::vector<vec2>> *pTeleOuts)
{ {
m_pWorld = pWorld; m_pWorld = pWorld;

View file

@ -226,8 +226,7 @@ public:
int m_TriggeredEvents; int m_TriggeredEvents;
void Init(CWorldCore *pWorld, CCollision *pCollision, CTeamsCore *pTeams); void Init(CWorldCore *pWorld, CCollision *pCollision, CTeamsCore *pTeams = nullptr, std::map<int, std::vector<vec2>> *pTeleOuts = nullptr);
void Init(CWorldCore *pWorld, CCollision *pCollision, CTeamsCore *pTeams, std::map<int, std::vector<vec2>> *pTeleOuts);
void Reset(); void Reset();
void Tick(bool UseInput); void Tick(bool UseInput);
void Move(); void Move();