#!/usr/bin/python  
 | 
# -*- coding: GBK -*-  
 | 
#-------------------------------------------------------------------------------  
 | 
#  
 | 
##@package GM.Commands.ClearRec  
 | 
#  
 | 
# @todo:Çå³ýͨÓÃÊý¾Ý  
 | 
# @author hxp  
 | 
# @date 2016-7-11  
 | 
# @version 1.0  
 | 
#  
 | 
# ÏêϸÃèÊö: Çå³ýͨÓÃÊý¾Ý  
 | 
#  
 | 
#-------------------------------------------------------------------------------  
 | 
#"""Version = 2016-7-11 20:30"""  
 | 
#-------------------------------------------------------------------------------  
 | 
  
 | 
import ShareDefine  
 | 
import GameWorld  
 | 
  
 | 
## Ö´ÐÐÂß¼  
 | 
#  @param curPlayer µ±Ç°Íæ¼Ò  
 | 
#  @param gmList []  
 | 
#  @return None  
 | 
def OnExec(curPlayer, gmList):  
 | 
    if not gmList:  
 | 
        GameWorld.DebugAnswer(curPlayer, "ClearRec ¼Ç¼ÀàÐÍ")  
 | 
        GameWorld.DebugAnswer(curPlayer, "    È«·þѰ±¦-34")  
 | 
        return  
 | 
      
 | 
    recType = gmList[0]  
 | 
    if recType not in ShareDefine.Def_UniversalGameRecTypeList:  
 | 
        GameWorld.DebugAnswer(curPlayer, "ÀàÐͲ»´æÔÚ")  
 | 
        return  
 | 
      
 | 
    universalRecMgr = GameWorld.GetUniversalRecMgr()  
 | 
    recordList = universalRecMgr.GetTypeList(recType)  
 | 
    recordCnt = 0 if not recordList else recordList.Count()  
 | 
    universalRecMgr.Delete(recType)  
 | 
    GameWorld.DebugAnswer(curPlayer, "³É¹¦É¾³ýÌõÊý: %s" % recordCnt)  
 | 
    return  
 | 
  
 | 
  
 | 
  
 |