Exemple #1
0
    public static int get_Task(IntPtr l)
    {
        int result;

        try
        {
            HeroAssistantsTaskAssignment heroAssistantsTaskAssignment = (HeroAssistantsTaskAssignment)LuaObject.checkSelf(l);
            LuaObject.pushValue(l, true);
            LuaObject.pushValue(l, heroAssistantsTaskAssignment.Task);
            result = 2;
        }
        catch (Exception e)
        {
            result = LuaObject.error(l, e);
        }
        return(result);
    }
Exemple #2
0
    public static int constructor(IntPtr l)
    {
        int result;

        try
        {
            HeroAssistantsTaskAssignment o = new HeroAssistantsTaskAssignment();
            LuaObject.pushValue(l, true);
            LuaObject.pushValue(l, o);
            result = 2;
        }
        catch (Exception e)
        {
            result = LuaObject.error(l, e);
        }
        return(result);
    }
 // Token: 0x0600E154 RID: 57684 RVA: 0x003CABE4 File Offset: 0x003C8DE4
 public void InitAssistanceTeamInfo(HeroAssistantsTaskAssignment task, int slot)
 {
     if (!BJLuaObjHelper.IsSkipLuaHotfix && this.TryInitHotFix("") && this.m_InitAssistanceTeamInfoHeroAssistantsTaskAssignmentInt32_hotfix != null)
     {
         this.m_InitAssistanceTeamInfoHeroAssistantsTaskAssignmentInt32_hotfix.call(new object[]
         {
             this,
             task,
             slot
         });
         return;
     }
     BJLuaObjHelper.IsSkipLuaHotfix = false;
     this.m_heroAssistantsTask      = task;
     this.m_slot = slot;
     if (task == null)
     {
         this.m_stateCtrl.SetToUIState("None", false, true);
     }
     else
     {
         if (task.EndTime <= this.m_playerContext.GetServerTime())
         {
             this.m_stateCtrl.SetToUIState("Finish", false, true);
             this.SetSoldierSpine();
             this.m_playerHeroGraphic.PlayAnimation("idle", true, 0);
         }
         else
         {
             this.m_stateCtrl.SetToUIState("Processing", false, true);
             this.SetSoldierSpine();
             this.m_playerHeroGraphic.PlayAnimation("run", true, 0);
         }
         List <HeroAssistantsTask> heroAssistantsTasksByWeekDay = this.m_playerContext.GetHeroAssistantsTasksByWeekDay(this.m_heroAssistantsTask.Task.Weekday);
         int num = heroAssistantsTasksByWeekDay.FindIndex((HeroAssistantsTask t) => t == this.m_heroAssistantsTask.Task) + 1;
         if (num == -1)
         {
             global::Debug.LogError("Task Difficulty Error, TaskId:" + this.m_heroAssistantsTask.TaskId);
             num = 1;
         }
         this.m_difficultyText.text = num.ToString();
     }
     this.m_charGameObject.SetActive(task != null);
 }
Exemple #4
0
    public static int set_TaskId(IntPtr l)
    {
        int result;

        try
        {
            HeroAssistantsTaskAssignment heroAssistantsTaskAssignment = (HeroAssistantsTaskAssignment)LuaObject.checkSelf(l);
            int taskId;
            LuaObject.checkType(l, 2, out taskId);
            heroAssistantsTaskAssignment.TaskId = taskId;
            LuaObject.pushValue(l, true);
            result = 1;
        }
        catch (Exception e)
        {
            result = LuaObject.error(l, e);
        }
        return(result);
    }
Exemple #5
0
    public static int set_EndTime(IntPtr l)
    {
        int result;

        try
        {
            HeroAssistantsTaskAssignment heroAssistantsTaskAssignment = (HeroAssistantsTaskAssignment)LuaObject.checkSelf(l);
            DateTime endTime;
            LuaObject.checkValueType <DateTime>(l, 2, out endTime);
            heroAssistantsTaskAssignment.EndTime = endTime;
            LuaObject.pushValue(l, true);
            result = 1;
        }
        catch (Exception e)
        {
            result = LuaObject.error(l, e);
        }
        return(result);
    }
Exemple #6
0
    public static int set_AssignedHeroIds(IntPtr l)
    {
        int result;

        try
        {
            HeroAssistantsTaskAssignment heroAssistantsTaskAssignment = (HeroAssistantsTaskAssignment)LuaObject.checkSelf(l);
            List <int> assignedHeroIds;
            LuaObject.checkType <List <int> >(l, 2, out assignedHeroIds);
            heroAssistantsTaskAssignment.AssignedHeroIds = assignedHeroIds;
            LuaObject.pushValue(l, true);
            result = 1;
        }
        catch (Exception e)
        {
            result = LuaObject.error(l, e);
        }
        return(result);
    }