VariableIsNullTaskCondition.cs 561 B

1234567891011121314151617181920212223242526
  1. using System.Collections;
  2. using System.Collections.Generic;
  3. using UnityEngine;
  4. using NodeCanvas.Framework;
  5. using ParadoxNotion.Design;
  6. namespace KairoEngine
  7. {
  8. [Category("KairoEngine")]
  9. public class VariableIsNullTaskCondition<T> : ConditionTask
  10. {
  11. public BBParameter<T> variable;
  12. protected override string info {
  13. get { return variable + " == NULL"; }
  14. }
  15. protected override bool OnCheck()
  16. {
  17. if(variable.value == null) return true;
  18. else return false;
  19. }
  20. }
  21. }