﻿using System.Collections;
using System.Collections.Generic;
using UnityEngine;
using UnityEngine.SceneManagement;
using UnityEngine.UI;

public class ButtonScript : MonoBehaviour
{

    public GameObject targetTextField;
    // Start is called before the first frame update
    void Start()
    {
        
    }

    // Update is called once per frame
    void Update()
    {
        
    }

    public void ButtonAction()
    {
        Debug.Log("Testni izpis");
        targetTextField.GetComponent<Text>().text = "Hello there";

        GameState.lifePoints -= 1;
        Debug.Log("Life points: " + GameState.lifePoints);

        //SceneManager.LoadScene(2);
    }
}
