public void OnCraftCancelled(CraftingProgressContainer.CraftInfo craftInfo, float progress)
 {
     if (eventHandler != null)
     {
         eventHandler.OnCraftCanceled(craftInfo, progress);
     }
 }
 public void OnCraftFailed(CraftingProgressContainer.CraftInfo craftInfo)
 {
     if (eventHandler != null)
     {
         eventHandler.OnCraftFailed(craftInfo);
     }
 }
예제 #3
0
        protected virtual void CraftingWindowOnCraftProgress(CraftingProgressContainer.CraftInfo craftInfo, float progress)
        {
            int index = Mathf.CeilToInt(progress * images.Length);

            for (int i = 0; i < index; i++)
            {
                images[i].color = activeColor;
            }
        }
 public void OnCraftSuccess(CraftingProgressContainer.CraftInfo craftInfo)
 {
     if (onCraftingSuccess.Count > 0)
     {
         RunEvents(onCraftingSuccess,
                   new plyEventArg("category", craftInfo.category),
                   new plyEventArg("categoryID", (int)craftInfo.category.ID),
                   new plyEventArg("blueprint", craftInfo.blueprint),
                   new plyEventArg("blueprintID", (int)craftInfo.blueprint.ID));
     }
 }
 public void OnCraftFailed(CraftingProgressContainer.CraftInfo craftInfo)
 {
     if (onCraftingFailed.Count > 0)
     {
         RunEvents(onCraftingFailed,
                   new plyEventArg("itemID", (int)craftInfo.blueprint.resultItems.First().item.ID),
                   new plyEventArg("category", craftInfo.category),
                   new plyEventArg("categoryID", (int)craftInfo.category.ID),
                   new plyEventArg("blueprint", craftInfo.blueprint),
                   new plyEventArg("blueprintID", (int)craftInfo.blueprint.ID));
     }
 }
 public void OnCraftProgress(CraftingProgressContainer.CraftInfo craftInfo, float progress)
 {
     if (onCraftingProgress.Count > 0)
     {
         RunEvents(onCraftingProgress,
                   new plyEventArg("itemID", (int)craftInfo.blueprint.resultItems.First().item.ID),
                   new plyEventArg("category", craftInfo.category),
                   new plyEventArg("categoryID", (int)craftInfo.category.ID),
                   new plyEventArg("blueprint", craftInfo.blueprint),
                   new plyEventArg("blueprintID", (int)craftInfo.blueprint.ID),
                   new plyEventArg("progress", progress));
     }
 }
예제 #7
0
 private void CraftEnded(CraftingProgressContainer.CraftInfo craftinfo)
 {
     Reset();
 }
예제 #8
0
 private void CraftEndedProgress(CraftingProgressContainer.CraftInfo craftinfo, float progress)
 {
     Reset();
 }
예제 #9
0
 private void OnCraftSuccess(CraftingProgressContainer.CraftInfo craftinfo)
 {
     GetComponent <Animator>().Play(animationClip.name);
 }
예제 #10
0
 private void CraftStart(CraftingProgressContainer.CraftInfo craftInfo)
 {
     ShowParticles();
 }
예제 #11
0
 private void CraftSuccess(CraftingProgressContainer.CraftInfo craftInfo)
 {
     HideParticles();
 }
예제 #12
0
 private void CraftCancelled(CraftingProgressContainer.CraftInfo craftInfo, float progress)
 {
     HideParticles();
 }