#!/usr/bin/python  
 | 
# -*- coding: GBK -*-  
 | 
  
 | 
##@package GY_GM_FindPlayerByID  
 | 
# ÔÚÏßGM¹¤¾ß(µÈ¼¶ÎÞÏÞÖÆ) Í¨¹ýÍæ¼ÒID»ñµÃÍæ¼ÒÐÅÏ¢  
 | 
#  
 | 
# @author mark  
 | 
# @date 2010-3-31  
 | 
# @version 1.0  
 | 
#  
 | 
# ÐÞ¸Äʱ¼ä ÐÞ¸ÄÈË ÐÞ¸ÄÄÚÈÝ  
 | 
# VER = "2010-05-14 9:30" zhengyang Ìí¼Ó×¢ÊÍ  
 | 
#  
 | 
# Ä£¿éÏêϸ˵  
 | 
#½Å±¾ËµÃ÷  
 | 
#ÔÚÏßGM¹¤¾ß(µÈ¼¶ÎÞÏÞÖÆ) Í¨¹ýÍæ¼ÒID»ñµÃÍæ¼ÒÐÅÏ¢  
 | 
  
 | 
#·µ»Ø×Öµä<Key:Value>:  
 | 
#Result :  1                     #0  
 | 
#DictName: GY_GM_FindPlayerByID  
 | 
#ID:     ¡®11007¡¯  
 | 
#Name:   ¡®ÎÞµÐÄС¯  
 | 
#MapID:  ¡®5¡¯  
 | 
#PosX:   ¡®207¡¯  
 | 
#PosY:   ¡®208¡¯  
 | 
#---------------------------------------------------------------------  
 | 
#µ¼Èë  
 | 
import GameWorld  
 | 
#---------------------------------------------------------------------  
 | 
#È«¾Ö±äÁ¿  
 | 
#---------------------------------------------------------------------  
 | 
  
 | 
#---------------------------------------------------------------------  
 | 
#Â߼ʵÏÖ  
 | 
## Ö´ÐÐÂß¼  
 | 
#  @param curPlayer µ±Ç°Íæ¼Ò  
 | 
#  @param playerList [playerID]  
 | 
#  @return None  
 | 
#  @remarks º¯ÊýÏêϸ˵Ã÷.  
 | 
def OnExec(curPlayer,playerList):  
 | 
    if len(playerList) != 1:  
 | 
        return  
 | 
      
 | 
    curFindPlayer = GameWorld.GetPlayerManager().FindPlayerByID(playerList[0])  
 | 
      
 | 
    if curFindPlayer == None or curFindPlayer.IsEmpty():  
 | 
        #ÎÞ·¨²éÕÒÍæ¼Ò  
 | 
        resultDisc = {  
 | 
                      'Result'  : '0'                      ,  
 | 
                      'DictName': 'GY_GM_FindPlayerByID'   ,  
 | 
                      }  
 | 
    else:  
 | 
        resultDisc = {      
 | 
                      'Result'  : '1'                                ,  
 | 
                      'DictName': 'GY_GM_FindPlayerByID'             ,  
 | 
                      'ID'      : '%s'%curFindPlayer.GetPlayerID()   ,  
 | 
                      'Name'    : '%s'%curFindPlayer.GetName()       ,  
 | 
                      'MapID'   : '%s'%curFindPlayer.GetMapID()      ,       
 | 
                     }  
 | 
      
 | 
    curPlayer.GMAnswer("%s;%s"%('FindPlayerByID' , resultDisc))  
 | 
    return  
 | 
  
 |