ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/GM/Commands/Face.py
@@ -52,10 +52,6 @@
            for index in range(ipyDataMgr.GetPlayerFaceCount()):
                ipyData = ipyDataMgr.GetPlayerFaceByIndex(index)
                faceID = ipyData.GetFaceID()
                if ipyData.GetUnlockDefault():
                    continue
                if ipyData.GetCustomPlayerID():
                    continue
                if not GameWorld.GetDictValueByBit(curPlayer, ChConfig.Def_PDict_FaceState, faceID):
                    continue
                GameWorld.SetDictValueByBit(curPlayer, ChConfig.Def_PDict_FaceState, faceID, 0)
@@ -67,12 +63,6 @@
            if not ipyData:
                GameWorld.DebugAnswer(curPlayer, "该头像不存在:%s" % faceID)
                return
            if ipyData.GetUnlockDefault():
                GameWorld.DebugAnswer(curPlayer, "该头像默认激活:%s" % faceID)
                return
            if ipyData.GetCustomPlayerID():
                GameWorld.DebugAnswer(curPlayer, "定制头像不处理:%s" % faceID)
                return
            GameWorld.SetDictValueByBit(curPlayer, ChConfig.Def_PDict_FaceState, faceID, 0)
            PlayerControl.NomalDictSetProperty(curPlayer, ChConfig.Def_PDict_FaceEndTime % faceID, 0)
            PlayerControl.NomalDictSetProperty(curPlayer, ChConfig.Def_PDict_FaceStar % faceID, 0)
@@ -83,21 +73,22 @@
    elif value1 == "f1":
        faceID = msgList[1] if len(msgList) > 1 else 0
        expireTimes = msgList[2] if len(msgList) > 2 else None
        if PlayerFace.AddFace(curPlayer, faceID, expireTimes):
        if PlayerFace.AddFace(curPlayer, faceID, expireTimes, True):
            endTime = curPlayer.NomalDictGetProperty(ChConfig.Def_PDict_FaceEndTime % faceID)
            endTimeStr = "永久" if not endTime else GameWorld.ChangeTimeNumToStr(endTime)
            GameWorld.DebugAnswer(curPlayer, "添加头像成功:%s,到期:%s" % (faceID, endTimeStr))
        else:
            GameWorld.DebugAnswer(curPlayer, "添加头像失败:%s" % (faceID))
    # 头像星级
    elif value1 == "fs":
        faceID = msgList[1] if len(msgList) > 1 else 0
        faceStar = msgList[2] if len(msgList) > 2 else 0
        starIpyData = IpyGameDataPY.GetIpyGameData("PlayerFaceStar", faceID, faceStar)
        if not starIpyData:
            GameWorld.DebugAnswer(curPlayer, "头像星级不存在:%s,star:%s" % (faceID, faceStar))
        ipyData = IpyGameDataPY.GetIpyGameData("PlayerFace", faceID)
        if not ipyData:
            GameWorld.DebugAnswer(curPlayer, "该头像不存在:%s" % faceID)
            return
        faceStar = min(faceStar, ipyData.GetStarMax())
        GameWorld.DebugAnswer(curPlayer, "设置头像星级:%s,星:%s" % (faceID, faceStar))
        PlayerControl.NomalDictSetProperty(curPlayer, ChConfig.Def_PDict_FaceStar % faceID, faceStar)
        syncFaceIDList.append(faceID)
@@ -109,8 +100,6 @@
            for index in range(ipyDataMgr.GetPlayerFacePicCount()):
                ipyData = ipyDataMgr.GetPlayerFacePicByIndex(index)
                facePicID = ipyData.GetFacePicID()
                if ipyData.GetUnlockDefault():
                    continue
                if not GameWorld.GetDictValueByBit(curPlayer, ChConfig.Def_PDict_FacePicState, facePicID):
                    continue
                GameWorld.SetDictValueByBit(curPlayer, ChConfig.Def_PDict_FacePicState, facePicID, 0)
@@ -122,9 +111,6 @@
            if not ipyData:
                GameWorld.DebugAnswer(curPlayer, "该头像框不存在:%s" % facePicID)
                return
            if ipyData.GetUnlockDefault():
                GameWorld.DebugAnswer(curPlayer, "该头像框默认激活:%s" % facePicID)
                return
            GameWorld.SetDictValueByBit(curPlayer, ChConfig.Def_PDict_FacePicState, facePicID, 0)
            PlayerControl.NomalDictSetProperty(curPlayer, ChConfig.Def_PDict_FacePicEndTime % facePicID, 0)
            PlayerControl.NomalDictSetProperty(curPlayer, ChConfig.Def_PDict_FacePicStar % facePicID, 0)
@@ -135,7 +121,7 @@
    elif value1 == "p1":
        facePicID = msgList[1] if len(msgList) > 1 else 0
        expireTimes = msgList[2] if len(msgList) > 2 else None
        if PlayerFace.AddFacePic(curPlayer, facePicID, expireTimes):
        if PlayerFace.AddFacePic(curPlayer, facePicID, expireTimes, True):
            endTime = curPlayer.NomalDictGetProperty(ChConfig.Def_PDict_FacePicEndTime % facePicID)
            endTimeStr = "永久" if not endTime else GameWorld.ChangeTimeNumToStr(endTime)
            GameWorld.DebugAnswer(curPlayer, "添加头像框成功:%s,到期:%s" % (facePicID, endTimeStr))
@@ -146,10 +132,11 @@
    elif value1 == "ps":
        facePicID = msgList[1] if len(msgList) > 1 else 0
        facePicStar = msgList[2] if len(msgList) > 2 else 0
        starIpyData = IpyGameDataPY.GetIpyGameData("PlayerFacePicStar", facePicID, facePicStar)
        if not starIpyData:
            GameWorld.DebugAnswer(curPlayer, "头像框星级不存在:%s,star:%s" % (facePicID, facePicStar))
        ipyData = IpyGameDataPY.GetIpyGameData("PlayerFacePic", facePicID)
        if not ipyData:
            GameWorld.DebugAnswer(curPlayer, "该头像框不存在:%s" % facePicID)
            return
        facePicStar = min(facePicStar, ipyData.GetStarMax())
        GameWorld.DebugAnswer(curPlayer, "设置头像框星级:%s,星:%s" % (facePicID, facePicStar))
        PlayerControl.NomalDictSetProperty(curPlayer, ChConfig.Def_PDict_FacePicStar % facePicID, facePicStar)
        syncFacePicIDList.append(facePicID)