From ff8efc0ccf9fa6d66d873673afd07d2adfd87252 Mon Sep 17 00:00:00 2001
From: hxp <ale99527@vip.qq.com>
Date: 星期三, 18 十二月 2024 15:43:33 +0800
Subject: [PATCH] 10297 【越南】【英语】【砍树】【tqxbqy】轮回殿-服务端(增加GM命令: Lunhui)
---
ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/Player/PlayerActLunhuidian.py | 8 +++++---
ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/GM/Commands/Lunhui.py | 48 ++++++++++++++++++++++++++++++++++++++++++++++++
2 files changed, 53 insertions(+), 3 deletions(-)
diff --git a/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/GM/Commands/Lunhui.py b/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/GM/Commands/Lunhui.py
new file mode 100644
index 0000000..f62204e
--- /dev/null
+++ b/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/GM/Commands/Lunhui.py
@@ -0,0 +1,48 @@
+#!/usr/bin/python
+# -*- coding: GBK -*-
+#-------------------------------------------------------------------------------
+#
+##@package GM.Commands.Lunhui
+#
+# @todo:轮回殿
+# @author hxp
+# @date 2024-12-18
+# @version 1.0
+#
+# 详细描述: 轮回殿
+#
+#-------------------------------------------------------------------------------
+#"""Version = 2024-12-18 16:00"""
+#-------------------------------------------------------------------------------
+
+import GameWorld
+import PlayerActLunhuidian
+
+#逻辑实现
+## GM命令执行入口
+# @param curPlayer 当前玩家
+# @param msgList 参数列表
+# @return None
+# @remarks 函数详细说明.
+def OnExec(curPlayer, msgList):
+ if not msgList:
+ GameWorld.DebugAnswer(curPlayer, "增加进度: Lunhui 奖励类型 奖励值 增加值")
+ GameWorld.DebugAnswer(curPlayer, "奖励类型: 1-货币;2-寻宝;3-物品")
+ GameWorld.DebugAnswer(curPlayer, "奖励值:货币对应货币类型")
+ GameWorld.DebugAnswer(curPlayer, "奖励值:寻宝对应寻宝类型")
+ GameWorld.DebugAnswer(curPlayer, "奖励值:物品对应物品ID")
+ GameWorld.DebugAnswer(curPlayer, "注:轮回活动类型只能通过调时间测试")
+ return
+
+ awardType = msgList[0]
+ awardTypeValue = msgList[1] if len(msgList) > 1 else 0
+ addValue = msgList[2] if len(msgList) > 2 else 0
+ if awardType not in PlayerActLunhuidian.AwardTypeList:
+ GameWorld.DebugAnswer(curPlayer, "仅支持奖励类型为:%s" % PlayerActLunhuidian.AwardTypeList)
+ return
+ if not awardTypeValue or not addValue:
+ GameWorld.DebugAnswer(curPlayer, "参数值异常")
+ return
+ PlayerActLunhuidian.AddLunhuidianValue(curPlayer, awardType, awardTypeValue, addValue)
+ return
+
diff --git a/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/Player/PlayerActLunhuidian.py b/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/Player/PlayerActLunhuidian.py
index 5cf3682..c1135d0 100644
--- a/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/Player/PlayerActLunhuidian.py
+++ b/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/Player/PlayerActLunhuidian.py
@@ -35,9 +35,11 @@
) = range(3)
# 轮回奖励类型
-AwardType_PayMoney = 1
-AwardType_Treasure = 2
-AwardType_UseItem = 3
+AwardTypeList = (
+AwardType_PayMoney, # 1 消耗货币
+AwardType_Treasure, # 2 寻宝
+AwardType_UseItem, # 3 消耗物品
+) = range(1, 1 + 3)
def OnPlayerLogin(curPlayer):
--
Gitblit v1.8.0