Created
August 17, 2020 04:59
-
-
Save todorok1/9c4c669e571e0c5cd2b852a089dbae97 to your computer and use it in GitHub Desktop.
イベントシステムを使用してメッセージを受け取るサンプル
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using System.Collections; | |
using System.Collections.Generic; | |
using UnityEngine; | |
/// <Summary> | |
/// EventSystemsを使用してメソッドを呼び出されるスクリプトです。 | |
/// </Summary> | |
public class EventSystemsTarget : MonoBehaviour, IEventCaller | |
{ | |
void Start() | |
{ | |
} | |
void Update() | |
{ | |
} | |
/// <Summary> | |
/// EventSystemsを使用してこのメソッドを呼び出します。 | |
/// </Summary> | |
public void EventCall() | |
{ | |
// ログを表示します。 | |
Debug.Log("EventSystemsによるイベントが通知された!"); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment