ActJobClassRunePlanPushCtrl.cs 726 B

123456789101112131415161718192021222324252627
  1. using FL.Data;
  2. using XGame.Framework.Network;
  3. namespace FL.Network
  4. {
  5. public class ActJobClassRunePlanPushCtrl : MsgController<ActJobClassRunePlanPush>
  6. {
  7. protected override void OnProcess(ActJobClassRunePlanPush message, object context)
  8. {
  9. if (message.runePlan == null) return;
  10. var runePlanMap = PlayerData.Instance.RunePlanMap;
  11. foreach (var item in message.runePlan)
  12. {
  13. if (runePlanMap.ContainsKey(item.id))
  14. {
  15. runePlanMap[item.id] = item;
  16. }
  17. else
  18. {
  19. runePlanMap.Add(item.id, item);
  20. }
  21. }
  22. }
  23. }
  24. }