1 using System.Collections;
2 using System.Collections.Generic;
5 public class LandingSound : MonoBehaviour
8 GameObject groundCheck;
11 GameObject dustEffect;
13 private void OnCollisionEnter2D(Collision2D collision)
15 if(collision.gameObject.CompareTag("Player"))
17 FindObjectOfType<AudioManager>().Play("landung");
18 Vector3 spawnPos = new Vector3(groundCheck.transform.position.x, groundCheck.transform.position.y + 1, groundCheck.transform.position.z);
19 Instantiate(dustEffect, spawnPos, Quaternion.identity);