コード例 #1
0
        public static void AddOverlay(this INodeState node)
        {
            var disabledOverlay = new VisualElement {
                name = "disabledOverlay", pickingMode = PickingMode.Ignore
            };

            ((VisualElement)node).hierarchy.Add(disabledOverlay);
        }
コード例 #2
0
 public void ChangeState(INodeState <T> edgeState)
 {
     throw new NotImplementedException();
 }
コード例 #3
0
 public void ChangeState(NodeStateContextContainer <T> contextContainer, INodeState <T> edgeState)
 {
     throw new NotImplementedException();
 }
コード例 #4
0
 public void NodeActive()
 {
     scarabImage.sprite = _goldScarab;
     _theState          = new NodeActiveState();
     _theState.Execute(this);
 }
コード例 #5
0
 public void NodeTouched()
 {
     scarabImage.sprite = _silverScarab;
     _theState          = new NodeTouchedState();
     _theState.Execute(this);
 }
コード例 #6
0
 public void NodeUntouched()
 {
     scarabImage.sprite = _stoneScarab;
     _theState          = new NodeUntouchedState();
     _theState.Execute(this);
 }
コード例 #7
0
 public static void ApplyNodeState(this INodeState node)
 {
     ((VisualElement)node).EnableInClassList(NodeUIState.Unused.ToString(), node.UIState == NodeUIState.Unused);
     ((VisualElement)node).EnableInClassList(NodeUIState.Disabled.ToString(), node.UIState == NodeUIState.Disabled);
 }