/// <summary> /// 创建指令 /// </summary> public static void Do(int areaId) { var command = new UnlockZooAreaCommand(); command.ZooAreaId = areaId; var sequence = GameEntry.Command.Sequence(); sequence.AppendCommand(command); sequence.AppendCommand(new DataUpdatedCommand()); sequence.AppendResultHandler(command.HandleResult); }
private void OnClickUnlockArea(EventContext context) { var btn = context.sender as GComponent; UnlockZooAreaCommand.Do((int)btn.data); }