From 210de0f61fd5f7acd758cd2e01168ea2438cf969 Mon Sep 17 00:00:00 2001
From: xdh <xiefantasy@qq.com>
Date: 星期一, 29 四月 2019 15:20:05 +0800
Subject: [PATCH] 6607 【2.0】【后端】技能升级功能改版(加等级限制)
---
ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/Skill/SkillShell.py | 11 +++++++----
ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/IpyGameDataPY.py | 7 +++++--
PySysDB/PySysDBPY.h | 1 +
3 files changed, 13 insertions(+), 6 deletions(-)
diff --git a/PySysDB/PySysDBPY.h b/PySysDB/PySysDBPY.h
index b4a6982..2d29f3f 100644
--- a/PySysDB/PySysDBPY.h
+++ b/PySysDB/PySysDBPY.h
@@ -1892,4 +1892,5 @@
{
DWORD _ElementSkillID; //专精技能ID
DWORD MainSkillID; //主技能ID
+ DWORD NeedLV; //选择需要等级
};
\ No newline at end of file
diff --git a/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/IpyGameDataPY.py b/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/IpyGameDataPY.py
index 0c31f0b..16a4d6f 100644
--- a/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/IpyGameDataPY.py
+++ b/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/IpyGameDataPY.py
@@ -1459,6 +1459,7 @@
"SkillElement":(
("DWORD", "ElementSkillID", 1),
("DWORD", "MainSkillID", 0),
+ ("DWORD", "NeedLV", 0),
),
}
@@ -4464,11 +4465,13 @@
def __init__(self):
self.ElementSkillID = 0
- self.MainSkillID = 0
+ self.MainSkillID = 0
+ self.NeedLV = 0
return
def GetElementSkillID(self): return self.ElementSkillID # 专精技能ID
- def GetMainSkillID(self): return self.MainSkillID # 主技能ID
+ def GetMainSkillID(self): return self.MainSkillID # 主技能ID
+ def GetNeedLV(self): return self.NeedLV # 选择需要等级
def Log(msg, playerID=0, par=0):
diff --git a/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/Skill/SkillShell.py b/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/Skill/SkillShell.py
index c056640..6dac2ad 100644
--- a/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/Skill/SkillShell.py
+++ b/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/Skill/SkillShell.py
@@ -2052,7 +2052,10 @@
if not ipyData:
return
mainSkillID = ipyData.GetMainSkillID()
-
+ if curPlayer.GetLV() < ipyData.GetNeedLV():
+ GameWorld.DebugLog('选择技能五行专精等级不足!')
+ return
+
curElementSkillID = curPlayer.NomalDictGetProperty(ChConfig.Def_PDict_SkillElementID % mainSkillID)
if selectSkillID == curElementSkillID:
GameWorld.DebugLog('已经是该专精技能!')
@@ -2071,9 +2074,9 @@
#更新新技能
RefreshElementSkill(curPlayer, selectSkillID)
# 重刷被动技能
- PassiveBuffEffMng.GetPassiveEffManager().RegistPassiveEff(curPlayer)
+ PassiveBuffEffMng.GetPassiveEffManager().RegistPassiveEff(curPlayer)
# 重刷技能战力
- PlayerControl.PlayerControl(curPlayer).RefreshAllSkill()
+ PlayerControl.PlayerControl(curPlayer).RefreshPlayerAttrState()
NotifyElementSkillInfo(curPlayer, mainSkillID)
return
@@ -2145,7 +2148,7 @@
# 重刷被动技能
PassiveBuffEffMng.GetPassiveEffManager().RegistPassiveEff(curPlayer)
# 重刷技能战力
- PlayerControl.PlayerControl(curPlayer).RefreshAllSkill()
+ PlayerControl.PlayerControl(curPlayer).RefreshPlayerAttrState()
return
def GetElementSkillCnt(curPlayer):
--
Gitblit v1.8.0