Exemplo n.º 1
0
 private void LoadAllYokai()
 {
     containerField.QueueFreeChildren();
     for (YokaiId yokai = YokaiId.Hitotsumekozo; yokai != YokaiId.TOTAL; yokai++)
     {
         WantedTable wanted = WantedTable.Instance();
         containerField.AddChild(wanted);
         wanted.Load(yokai.Data());
     }
 }
Exemplo n.º 2
0
    public void HideYokai(YokaiId yokai)
    {
        if (currentVisible == null)
        {
            return;
        }

        currentVisible.Visible = false;
        currentVisible         = null;
    }
Exemplo n.º 3
0
    public void ShowYokai(YokaiId yokai, bool withAnimation = true)
    {
        if (currentVisible != null)
        {
            currentVisible.Visible = false;
        }
        currentVisible = GetNode <AnimatedSprite>(yokai.ToString());

        currentVisible.Visible = true;

        if (withAnimation)
        {
            currentVisible.Playing = true;
        }
        else
        {
            currentVisible.Playing = false;
            currentVisible.Frame   = 0;
        }
    }
Exemplo n.º 4
0
 public YokaiAI(YokaiId yokai)
 {
     Yokai = yokai;
 }
Exemplo n.º 5
0
 public static YokaiData Data(this YokaiId yokai) => YokaiData.YokaiList[yokai];