From b56df043e01be629f731c5d52ecb64cc7f7f2b60 Mon Sep 17 00:00:00 2001 From: hch <305670599@qq.com> Date: 星期一, 27 五月 2019 20:05:19 +0800 Subject: [PATCH] Merge branch 'master' of http://192.168.0.87:10010/r/SnxxServerCode --- ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/GM/Commands/AddFairyEvent.py | 7 +++++-- 1 files changed, 5 insertions(+), 2 deletions(-) diff --git a/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/GM/Commands/AddFairyEvent.py b/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/GM/Commands/AddFairyEvent.py index 106d354..ed59550 100644 --- a/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/GM/Commands/AddFairyEvent.py +++ b/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/GM/Commands/AddFairyEvent.py @@ -54,8 +54,11 @@ ipyData = IpyGameDataPY.InterpolationSearch('FairyAdventures', 'OpenServerDay', openServerDay, {'EventID':fdEventID}) if ipyData: conditionList = ipyData.GetCondition() - condition = random.choice(conditionList) - index = conditionList.index(condition) + if conditionList: + condition = random.choice(conditionList) + index = conditionList.index(condition) + else: + index = 0 PlayerControl.NomalDictSetProperty(curPlayer, ChConfig.Def_PDict_FairyAdventuresData % fdEventID, ipyData.GetID() * 100 + index) #设置寻访中 -- Gitblit v1.8.0