private void HandleTakeDailyScoreRewardCmd(CommandParser.Command param) { int index = 0; int.TryParse(param.GetParam(1), out index); MC2S_TakeDailyScoreReward mC2S_TakeDailyScoreReward = new MC2S_TakeDailyScoreReward(); mC2S_TakeDailyScoreReward.Index = index; Globals.Instance.CliSession.Send(248, mC2S_TakeDailyScoreReward); }
public static void RequestTalkDailyScoreReward(int index) { if (index == -1) { return; } if (GUIAchievementScene.miscInfo[index] == null) { global::Debug.LogErrorFormat("Daily Score config error {0}", new object[] { index }); return; } LocalPlayer player = Globals.Instance.Player; if (player.Data.DailyScore < GUIAchievementScene.scoreValue[index]) { return; } int dailyRewardFlag = player.Data.DailyRewardFlag; if ((dailyRewardFlag & 1 << index) != 0) { return; } MC2S_TakeDailyScoreReward mC2S_TakeDailyScoreReward = new MC2S_TakeDailyScoreReward(); mC2S_TakeDailyScoreReward.Index = index; Globals.Instance.CliSession.Send(248, mC2S_TakeDailyScoreReward); }