Ejemplo n.º 1
0
    private async Task <RequestResult> ValidateParent(object selectedParent)
    {
        IActionPointParent parent = (IActionPointParent)selectedParent;
        RequestResult      result = new RequestResult(true, "");

        if (parent.GetId() == CurrentActionPoint.GetId())
        {
            result.Success = false;
            result.Message = "Action point cannot be its own parent!";
        }

        return(result);
    }
Ejemplo n.º 2
0
    private async void AssignToParent(object selectedObject)
    {
        IActionPointParent parent = (IActionPointParent)selectedObject;

        if (parent == null)
        {
            return;
        }
        string id = "";

        id = parent.GetId();
        bool result = await Base.GameManager.Instance.UpdateActionPointParent(selectedActionPoint, id);

        if (!result)
        {
            selectedActionPoint.WriteUnlock();
        }
    }
Ejemplo n.º 3
0
    private async void AssignToParent(object selectedObject)
    {
        IActionPointParent parent = (IActionPointParent)selectedObject;

        if (parent == null)
        {
            return;
        }
        bool result = await Base.GameManager.Instance.UpdateActionPointParent(CurrentActionPoint, parent.GetId());

        if (result)
        {
            //
        }
    }