void LookForCommandBubble() { CommandBubbleController cbc = (CommandBubbleController)commandBubble.GetComponent("CommandBubbleController"); bool isInsideBubble = IsInsideCommandBubble(); if (cbc.isActive && isInsideBubble) { state = AiState.ATTACK; } else if (cbc.isActive && !isInsideBubble) { state = AiState.MOVE; } else { state = AiState.STANDBY; } }
void CreateCommandBubble(Vector3 location) { CommandBubbleController cbc = (CommandBubbleController)commandBubble.gameObject.GetComponent("CommandBubbleController"); cbc.Enable(location); }