using System.Collections;
using System.Collections.Generic;
using UnityEngine;

public class pahalane : MonoBehaviour
{
    // Start is called before the first frame update
    void Start()
    {
        
    }

    // Update is called once per frame
    void Update()
    {
        transform.position += new Vector3(-20, 0) * Time.deltaTime;
        


    }
    private void OnTriggerEnter(Collider collision)
    {
        if (collision.gameObject.tag == "player")
        {
            collision.gameObject.GetComponent<player>().Surm();
        }
    }

}
