public class BloodEffect : MonoBehaviour
{
[SerializeField] public GameObject bl_ParticalBlood;
private void OnTriggerEnter2D(Collider2D collision)
{
float horizontalInput = -0.2f;
float verticalInput = 0.5f;
if (collision.gameObject.layer == 9)
{
Instantiate(bl_ParticalBlood, transform.position + new Vector3(horizontalInput, verticalInput, 0), Quaternion.identity);
}
}
}
Instantiate(bl_ParticalBlood, transform.position + new Vector3(horizontalInput, verticalInput, 0), Quaternion.identity);
Instantiate(bl_ParticalBlood, transform.position + new Vector3(horizontalInput, verticalInput, 0), Quaternion.identity, transform);