public void SetNodePanel(NodeMain node) { _node = node; if (node == null) { node_panel.gameObject.SetActive(false); colony_actions.gameObject.SetActive(false); ship_panel.gameObject.SetActive(false); } else { node_panel.gameObject.SetActive(true); node_panel.SetNode(node); if (node.Data.hasShips()) { ship_panel.gameObject.SetActive(true); ship_panel.setNode(node.Data); } else { ship_panel.gameObject.SetActive(false); } if (node.Data.HasColony() && !node.Data.Colony.Faction.AI) { colony_actions.gameObject.SetActive(true); colony_actions.setColony(node.Data.Colony); } else { colony_actions.gameObject.SetActive(false); } } }
public void Link(NodeMain node) { if (links.Contains(node)) { links.Remove(node); return; } links.Add(node); }
void DeselectNode() { if (selected_node == null) { return; } selected_node = null; node_selection_circle.SetActive(false); Menu.SetNodePanel(null); ClearSelectedShips(); }
void SelectNode(NodeMain node) { if (selected_node == node) { return; } //DeselectNode(); selected_node = node; //set hud Menu.SetNodePanel(node); node_selection_circle.SetActive(true); node_selection_circle.transform.position = node.transform.position; ClearSelectedShips(); }
protected virtual void StartNode(byte[] secretKey) { if (secretKey == null) { throw new System.ArgumentNullException(nameof(secretKey)); } _log.Info("Starting Node"); try { NodeMain nodeMain = ServiceLocator.Current.GetInstance <NodeMain>(); nodeMain.Initialize(secretKey, _cancellationToken); nodeMain.Start(); } finally { _log.Info("Starting Node completed"); } }
void setCameraTarget(NodeMain node) { cam.SetTarget(node.transform); camera_selection_circle.SetActive(true); camera_selection_circle.transform.position = node.transform.position; }
public void SetNode(NodeMain node) { _node = node; UpdateHud(); }
public void setNode(NodeMain node) { Node = node; }