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
#!/usr/bin/python
# -*- coding: GBK -*-
#-------------------------------------------------------------------------------
#
#-------------------------------------------------------------------------------
#
##@package GM.Commands.SetRein
#
# @todo:ÉèÖÃתÉú
# @author hxp
# @date 2016-2-24
# @version 1.0
#
# ÏêϸÃèÊö: ÉèÖÃתÉú
#
#---------------------------------------------------------------------
"""Version = 2016-2-24 16:00"""
#---------------------------------------------------------------------
 
import ReadChConfig
import PlayerBillboard
import PlayerControl
import ChConfig
import GameWorld
 
#Âß¼­ÊµÏÖ
## GMÃüÁîÖ´ÐÐÈë¿Ú
#  @param curPlayer µ±Ç°Íæ¼Ò
#  @param msgList ²ÎÊýÁбí [classLV, starLV, exp]
#  @return None
#  @remarks º¯ÊýÏêϸ˵Ã÷.
def OnExec(curPlayer, msgList):
    #ÊäÈëÃüÁî¸ñʽ´íÎó
    if len(msgList) < 1:
        return
    
    reinLV = msgList[0]
 
    Reincarnation_Condition = ReadChConfig.GetEvalChConfig("Reincarnation_Condition")
    if reinLV not in Reincarnation_Condition:
        GameWorld.DebugAnswer(curPlayer, "²»´æÔÚ¸ÃתÉú!")
        return
    
    LV = Reincarnation_Condition[reinLV][0]
    curPlayer.SetLV(LV + 1)
    
    curPlayer.SetReincarnationLv(reinLV)
    PlayerBillboard.UpdatePlayerBillboardOnLeaveServer(curPlayer)
    #Í¬Ê±ÖØÖý±Àø
    PlayerControl.NomalDictSetProperty(curPlayer, ChConfig.Def_PDict_Reinc_AwardRecord, 0)
    return