Skip to content

Instantly share code, notes, and snippets.

@todorok1
Created August 17, 2020 04:59
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save todorok1/9c4c669e571e0c5cd2b852a089dbae97 to your computer and use it in GitHub Desktop.
Save todorok1/9c4c669e571e0c5cd2b852a089dbae97 to your computer and use it in GitHub Desktop.
イベントシステムを使用してメッセージを受け取るサンプル
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