hxp
2019-03-05 79a23de6692781dfe4b18fdb57bc4b3e69f34014
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
#!/usr/bin/python
# -*- coding: GBK -*-
#-------------------------------------------------------------------------------
#
##@package GM.Commands.SetBossKilledCnt
#
# @todo:ÉèÖÃboss±»»÷ɱ´ÎÊý
# @author hxp
# @date 2016-8-12
# @version 1.0
#
# ÏêϸÃèÊö: ÉèÖÃboss±»»÷ɱ´ÎÊý
#
#-------------------------------------------------------------------------------
#"""Version = 2016-8-12 14:00"""
#-------------------------------------------------------------------------------
 
import GameWorldBoss
import ShareDefine
import GameWorld
 
 
#Âß¼­ÊµÏÖ
## Ö´ÐÐÂß¼­
#  @param curPlayer µ±Ç°Íæ¼Ò
#  @param list []
#  @return None
#  @remarks º¯ÊýÏêϸ˵Ã÷.
def OnExec(curPlayer, paramList):
    
    if len(paramList) == 1 and paramList[0] == 0:
        GameWorld.GetUniversalRecMgr().Delete(ShareDefine.Def_UniversalGameRecType_BossInfo)
        GameWorldBoss.Sync_BossInfo(curPlayer)
        GameWorldBoss.OnMapServerInitOK()
        GameWorld.DebugAnswer(curPlayer, "Çå¿Õboss»÷ɱÐÅÏ¢!")
        
    elif len(paramList) == 2:
        bossID, killedCnt = paramList
        recData = GameWorldBoss.__GetBossRecDataByID(bossID)
        GameWorldBoss.__SetKilledCnt(recData, killedCnt)
        
        GameWorld.SendMapServerMsgEx(ShareDefine.Def_Notify_WorldKey_BossKilledCnt % bossID, killedCnt)        
        GameWorldBoss.Sync_BossInfo(curPlayer)
        GameWorld.DebugAnswer(curPlayer, "ÉèÖÃBossID: %s »÷ɱ´ÎÊý %s!" % (bossID, killedCnt))
    else:
        GameWorld.DebugAnswer(curPlayer, "SetBossKilledCnt bossID »÷ɱ´ÎÊý")
        return
    
    return