/* public void setColliderScale(float cScale) * { * Vector2[] colliderPoints = GetComponent<PolygonCollider2D>().points; * Vector2[] scaledPoints = new Vector2[colliderPoints.Length]; * for (int p = 0; p < colliderPoints.Length; p++) * { * Vector2 np = GetComponent<PolygonCollider2D>().points[p] * colliderScale; * scaledPoints[p] = np; * } * GetComponent<PolygonCollider2D>().SetPath(0, scaledPoints); * }*/ public void damage(int damage, Color col) { life -= damage; audioz.enemyDamagedSE(); if (!vfxInProcess) { StartCoroutine(damageVFXboss()); } }
public void damage(int damage, Color col) { life -= damage; audioz.enemyDamagedSE(); StartCoroutine(damageVFXenemy(col)); }