Example #1
0
    public void Combat()
    {
        var entites = CombatSystem.GetPositions();

        entites.Add(player.position);
        var centroid = entites.GetCentroid();

        target = new Vector3(centroid.x, centroid.y, Camera.transform.position.z);
        Camera.transform.position = Vector3.Lerp(Camera.transform.position, target, transitionSmoothening * Time.deltaTime);
    }