您最多选择25个主题 主题必须以中文或者字母或数字开头,可以包含连字符 (-),并且长度不得超过35个字符
 
 
 
 

25 行
602 B

using GameplayIngredients;
using GameplayIngredients.Events;
public class ConsoleToggleEvent : EventBase
{
public Callable[] onConsoleShow;
public Callable[] onConsoleHide;
private void OnEnable()
{
ConsoleUtility.Console.onConsoleToggle += Console_onConsoleToggle;
}
private void OnDisable()
{
ConsoleUtility.Console.onConsoleToggle -= Console_onConsoleToggle;
}
private void Console_onConsoleToggle(bool visible)
{
if (visible)
Callable.Call(onConsoleShow);
else
Callable.Call(onConsoleHide);
}
}