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
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
+úyhc@sMddlZddlZddlZddlZddlZddlZddlZddlZddlZddl    Z    ddl
Z
ddl Z d„Z d„Z d„Zd„Zd„Zd„Zd„Zd    „Zd
d „Zd „Zd
d „Zd„Zd„Zd„Zd„Zd„Zejd„Zd„Zd„Zd„Z d„Z!d„Z"d„Z#d„Z$d„Z%d„Z&d„Z'd„Z(d„Z)d „Z*d!„Z+d"„Z,d#„Z-e.d$„Z/d%„Z0d&„Z1d'„Z2d(„Z3d)„Z4d*„Z5d+„Z6d,„Z7d-„Z8d.„Z9d/„Z:d0„Z;dd1„Z=dS(2iÿÿÿÿNcCst|ƒdS(N(t Sync_HeroInfo(t    curPlayer((siD:\SG_ServerCode\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Player\PlayerHero.pyt OnPlayerLogin!s
cCst|ƒt|ƒdS(N(tOnFirstLoginInitPlayertOnFirstLoginInitHero(R((siD:\SG_ServerCode\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Player\PlayerHero.pytOnPlayerFirstLogin%s
 
c     Csx|jƒjtjƒ}|jƒsO|jƒjtjƒ}|jƒsOdSntjddiƒ}|sndStj    d||j
ƒƒxé|j ƒD]Û\}}tj ƒj |ƒ}|sÂq•n|jƒ}|d}|dks•||jƒkrüq•n|j|ƒ}    |    jƒsq•n|r3i|tj6ni}
tj|dd|d|
ƒ} | scq•n|    j| ƒq•WdS(Nt NewRoleInitis³õʼ»¯ÐÂÊÖ¶¨ÖÆ×°±¸: %siRt setAttrDict(tGetItemManagertGetPackt IPY_GameWorldtrptEquiptGetCountt rptIdentifyt IpyGameDataPYtGetFuncEvalCfgt    GameWorldtDebugLogt GetPlayerIDtitemst GetGameDatatGetItemByTypeIDt GetEquipPlacetGetAttIsEmptyt ShareDefinetDef_CItemKey_AppointIDt ItemControlertGetOutPutItemObjt
AssignItem( Rt    equipPackt identifyPacktdefaultEquipInfotequipIDt    appointIDtitemDatat
equipPlacetequipPlaceIndext    destEquipRtcurItem((siD:\SG_ServerCode\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Player\PlayerHero.pyR*s4   
 c        Csû|jƒjtjƒ}tjd|jƒ|jƒƒ|jƒsHdStj    ddiƒ}|sgdStjd||jƒƒtj
}d}xd|j ƒD]V\}}t |||ƒ}i|gtj 6}tj||dttjgd|ƒqWdS(NsOnFirstLoginInitHero: %sRis³õʼ»¯ÐÂÊÖÎ佫: %siiR(RR    RtrptHeroRRR RRRt Lineup_MainRtComLineupValuetDef_IudetHeroLineupRtGivePlayerItemtFalse(    RtcurPacktdefaultHeroInfotlineupIDt    shapeTypetheroIDtposNumt lineupValueR((siD:\SG_ServerCode\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Player\PlayerHero.pyRIs      )cCsŸ|jtjdƒ|jtjƒr;|jtjdƒn|jtjƒrc|jtjdƒn|jtjƒr‹|jtjdƒn|jtjƒr³|jtjdƒn|jtj    ƒrØ|j
tj    ƒn|jtj ƒrý|j
tj ƒn|jtj ƒr"|j
tj ƒn|jtj ƒrG|j
tj ƒn|jtjƒrl|j
tjƒn|jtjƒr‘|j
tjƒnt|ƒdS(Nii(t SetUserAttrRtDef_IudetHeroLVt GetUserAttrtDef_IudetHeroStartDef_IudetHeroBreakLVtDef_IudetHeroAwakeLVtDef_IudetHeroSkintGetUserAttrCounttDef_IudetHeroTalentIDt ClearUserAttrtDef_IudetHeroTalentIDLVtDef_IudetHeroTalentWashLocktDef_IudetHeroTalentWashIDtDef_IudetHeroTalentIDAwakeRandR+tInitHeroTalent(t
singleItem((siD:\SG_ServerCode\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Player\PlayerHero.pyt InitHeroItem]s.
cCs¦|jƒ}tjd|ƒ}|s(dS|jƒ}tjd|ƒ}|sPdSd}|jƒ}|r}tj|dƒ}ni}g}tjƒ}    x^t|    j    ƒƒD]J}
|    j
|
ƒ} | j ƒ} | j ƒ} |j | | gƒ| || <q¨W|jtjƒ|jtjƒx‰t|ƒD]{}tj|ƒ}|sDq#n|j|dƒ|g}||krx|j|ƒn|jtj|ƒ|jtjdƒq#WdS(s+³õʼ»¯²ÛλÌ츳£¬²»Í¬²ÛλÌ츳ID²»ÄÜÒ»Ñù
    tHeroNt HeroQualityii(t GetItemTypeIDRtGetIpyGameDatat
GetQualitytGetInitTalentWeightRtGetResultByWeightListtIPY_DatatrangetGetHeroTalentCounttGetHeroTalentByIndext GetTalentIDt GetInitWeighttappendR>RR=R?tgettremovet AddUserAttr(RDR2t heroIpyDatatqualitytqualityIpyDatat initTalentCnttinitTalentWeightt talentIDDictttalentWeightListt
ipyDataMgrtindext talentIpyDatattalentIDt
initWeightt_t randTalentIDt randWeightID((siD:\SG_ServerCode\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Player\PlayerHero.pyRCysB       cCsx|jƒ}tjd|ƒ}|s(dSt||ƒstt||dƒtjd||jƒƒt||gƒndS(NRFisÊ״줻îÎ佫: heroID=%s(    RHRRItGetHeroActivitetSetHeroActiviteRRRR(RtheroItemR2RW((siD:\SG_ServerCode\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Player\PlayerHero.pytOnGiveHeroItem¥s cCs|jtj|ƒd}|S(Ni
(tNomalDictGetPropertytChConfigtDef_PDict_HeroBook(RR2tactState((siD:\SG_ServerCode\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Player\PlayerHero.pyRf´sicCs˜|jtj|ƒ}|d}|r9|r0dSd}nd}tj|dd|ƒ}tj|tj||ƒtjd|||f|jƒƒdS(Ni
iis0ÉèÖÃÎ佫¼¤»î״̬:%s,bookState=%s,updBookState=%s(    RjRkRlRtSetValuet PlayerControltNomalDictSetPropertyRR(RR2tisActt    bookStateRmt updBookState((siD:\SG_ServerCode\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Player\PlayerHero.pyRgºs
    #cCs$|jtj|ƒd}|dkS(Ni
i(RjRkRl(RR2t    initState((siD:\SG_ServerCode\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Player\PlayerHero.pytGetHeroBookInitStateÉscCsš|jtj|ƒ}|d}|r/d}n|r;dnd}tj|dd|ƒ}tj|tj||ƒtjd|||f|jƒƒdS(Ni
iiis4ÉèÖÃÎ佫ͼ¼ø¼¤»î״̬:%s,bookState=%s,updBookState=%s(    RjRkRlRRnRoRpRR(RR2RqRrRmRs((siD:\SG_ServerCode\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Player\PlayerHero.pytSetHeroBookInitStateÍs
    #cCs)|jtj|ƒ}tj|ddƒS(Nii(RjRkRlRtGetValue(RR2Rr((siD:\SG_ServerCode\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Player\PlayerHero.pytGetHeroBookStarLVÚscCso|jtj|ƒ}tj|dd|ƒ}tj|tj||ƒtjd|||f|jƒƒdS(Niis4ÉèÖÃÎ佫ͼ¼øÐǼ¶µÈ¼¶:%s,bookState=%s,updBookState=%s(    RjRkRlRRnRoRpRR(RR2tstarLVRrRs((siD:\SG_ServerCode\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Player\PlayerHero.pytSetHeroBookStarLVÞs
#cCs)|jtj|ƒ}tj|ddƒS(Nii(RjRkRlRRw(RR2Rr((siD:\SG_ServerCode\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Player\PlayerHero.pytGetHeroBookBreakLVæscCso|jtj|ƒ}tj|dd|ƒ}tj|tj||ƒtjd|||f|jƒƒdS(Niis4ÉèÖÃÎ佫ͼ¼øÍ»ÆÆµÈ¼¶:%s,bookState=%s,updBookState=%s(    RjRkRlRRnRoRpRR(RR2tbreakLVRrRs((siD:\SG_ServerCode\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Player\PlayerHero.pytSetHeroBookBreakLVês
#cCs}|jƒjtjƒ}|dks6||jƒkr:dS|j|ƒ}| s\|jƒr`dS|jƒtj    krydS|S(Ni(
RR    RR(R RRtGetTypeRktDef_ItemType_Hero(Rt    itemIndexR.Rh((siD:\SG_ServerCode\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Player\PlayerHero.pyt GetHeroItemòscCs|jtjƒ}|sdSx^t|ƒddd…D]C}|jtj|ƒ}t|ƒ\}}}||krxq6n|SWdS(Niiÿÿÿÿ(R<RR+RNtGetUserAttrByIndextGetLineupValue(RhR0t lineupCounttlpIndexR4tlpIDRcR3((siD:\SG_ServerCode\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Player\PlayerHero.pytGetHeroLineupPosNumýs  cCsDtjƒj|ƒ}|jƒ}|j}t||ƒ}|sCdS|jƒ}tjd|ƒ}|skdS|j    ƒ}    |j
t j ƒ}
|j
t j ƒ} t|ƒ} tjd||| |    |
| f|ƒ| | krñtjd| |ƒdStjd|    | ƒ} | sdS| d}tjd|    |ƒsMtjd|    |f|ƒdS| jƒ}|scdS|\}}| s}| rdS|jƒjtjƒ}tj|||ƒ\}}|sÕtjd||fƒdStj||||tdƒ|}tjd    |||f|ƒ|jt j |ƒtj|ƒj|gƒdS(
NRFsMÇëÇóÎ佫Éý¼¶: itemIndex=%s,heroID=%s,heroLV=%s,quality=%s,breakLV=%s,LVMax=%ss¸ÃÎ佫ÒÑÂú¼¶£¡LVMax=%st HeroQualityLVis*²»´æÔÚ¸ÃÎ佫µÈ¼¶: quality=%s,nextHeroLV=%ss7²ÄÁϲ»×㣬Î佫ÎÞ·¨Éý¼¶! costItemID=%s, costItemCount=%stHeroLVUPs-Î佫Éý¼¶: itemIndex=%s,heroID=%s,updHeroLV=%s(RtGetPlayerManagertGetPlayerByIndexRt    ItemIndexRRHRRIRJR7RR9R6t GetHeroLVMaxRt GetUPCostItemRR    R
trptItemt
ItemCommontGetItem_FromPack_ByIDt
ReduceItemtTrueR5t PlayerOnlinetGetOnlinePlayertOnHeroItemUpate(R_t
clientDatattickRtplayerIDR€RhR2RWRXR|theroLVtLVMaxtqualityLVIpyDatat
nextHeroLVt costItemInfot
costItemIDt costItemCounttitemPackt    hasEnought itemIndexListt    updHeroLV((siD:\SG_ServerCode\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Player\PlayerHero.pyt
OnHeroLVUPsV             
  cCsu|jƒ}tjd|ƒ}|s(dS|jƒ}|jtjƒ}tjd||ƒ}|sedS|jƒ}|S(NRFitHeroQualityBreak(RHRRIRJR7RR9tGetLVMax(RhR2RWRXR|tqualityBreakIpyDataR›((siD:\SG_ServerCode\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Player\PlayerHero.pyRBs   c CsÉtjƒj|ƒ}|jƒ}|j}|j}t||ƒ}t||ƒ}| sk| sk||krodS|jƒ}    |jƒ}
tjd||    ||
f|ƒ|    |
krÇtjd|ƒdS|j    ƒrñtjd||    f|ƒdS|j
t j ƒ} | r'tj d||    f|ƒdS|j
t jƒ} | r]tj d||    f|ƒdS|jt jƒ} |jt jƒ}| s|r«tjd| |f|ƒdStjd|    ƒ}|sÇdS|jƒ}|jt jƒ}|jt jƒ}t|ƒ}tjd|    ||||f|ƒ||krJtjd    ||ƒdS|jt jƒ}|d
}||}tjd ||    ||||f|ƒtj|||jƒtd ƒt|||ƒdS( NsAÇëÇóÎ佫ÉýÐÇ: itemIndex=%s,heroID=%s,useItemIndex=%s,useHeroID=%ssÎ佫²ÄÁϷDZ¾Ì壬ÎÞ·¨ÉýÐÇ!s1²ÄÁÏ¿¨Ëø¶¨ÖУ¬ÎÞ·¨ÉýÐÇ! useItemIndex=%s,heroID=%ss4Î佫ϴÁ¶½á¹ûδ´¦Àí£¬ÎÞ·¨ÉýÐÇ! itemIndex=%s,heroID=%ss8Î佫¾õÐѽâËøÌ츳δѡÔñ£¬ÎÞ·¨ÉýÐÇ! itemIndex=%s,heroID=%ssB²ÄÁÏ¿¨Í»ÆÆ»ò¾õÐѵȼ¶²»Îª0ÔÝʱÎÞ·¨ÉýÐÇ£¡useBreakLV=%s,useAwakeLV=%sRFs2heroID=%s,star=%s,quality=%s,awakeLV=%s,starMax=%ss¸ÃÎ佫ÒÑÂúÐÇ£¡starMax=%sisIÎ佫ÉýÐÇ: itemIndex=%s,heroID=%s,star=%s,useStar=%s,addStar=%s,updStar=%st
HeroStarUP(RRŠR‹RRŒt UseItemIndexRRHRt GetIsLockedR<RRAtErrLogRBR7R9R:RRIRJR8tGetHeroStarMaxRtDelItemR R-t DoHeroUpdStar(R_R—R˜RR™R€t useItemIndexRhtuseItemR2t    useHeroIDt    washIDCntt awakeRandCntt
useBreakLVt
useAwakeLVRWRXtstartawakeLVtstarMaxtuseStartaddStartupdStar((siD:\SG_ServerCode\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Player\PlayerHero.pyt OnHeroStarUPXsd                    # 
 
    c CsÔ|jƒ}tjd|ƒ}|s(dS|jƒ}tjd|ƒ}|sPdS|jƒ}d}tjd|ƒ}|rÆ|jtjƒ}x7|D],}    |    j    ƒ|kr¯Pn||    j
ƒ7}q“Wn||}
|
S(NRFiRGt    HeroAwake( RHRRIRJtGetInitStarUppertGetIpyGameDataListR7RR:t
GetAwakeLVtGetAddStarUpper( RhR2RWRXRYt InitStarUppert addStarUppertheroAwakeIpyDataListR¸tipyDataR¹((siD:\SG_ServerCode\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Player\PlayerHero.pyR­s&    
cCsŠ|jtjƒ}||}|jƒ}|jtj|ƒ|dkrWt||ƒn|jƒ|jƒ}tj    |ƒj
|gƒdS(Ni( R7RR8tGetItemR5t__DoHeroStarTalentUpt    Sync_ItemtGetItemPlaceIndexR”R•R–(RRhR¼tcurStarR»titemR€((siD:\SG_ServerCode\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Player\PlayerHero.pyR¯¦s
 
 cCsZtjddƒ}tjddƒ}|jtjƒ}|jtjƒ}gg}}g}t}    x}tt||ƒƒD]f}
|j    tj|
ƒ} |j    tj|
ƒ} |j
| ƒ|j
| ƒ| |krw|j
| ƒqwqwWt |ƒ|kr,|dg|t |ƒ7}|dg|t |ƒ7}nt j d|ƒt j d||fƒt j d|ƒd|kr×i} g}tjƒ}xpt|jƒƒD]\}
|j|
ƒ}|jƒ} | |krÏqœn|jƒ}|j
|| gƒ|| | <qœWt j d|ƒxÇt|ƒD]¶}d|kr0Pnt j|ƒ}|sKqn| j|dƒ|g}||kr|j|ƒn|jdƒ}|||<d||<|j
|ƒt j d    |ƒ|d8}t}    qWn|dkrÄxÞt|ƒD]Í}|sPntj|ƒ}||kr.|j|ƒqðn|j|ƒ}||}||kr„|d7}|||<t j d
|||fƒn||kr·|j|ƒt j d ||fƒnt}    qðWn|    sÎdSt j d ||fƒ|jtjƒ|jtjƒxNt|ƒD]@\}
} | s(Pn|jtj| ƒ|jtj||
ƒqWdS( NtHeroStarTalentiiis"Ö´ÐÐÎ佫ÐǼ¶Ì츳µÈ¼¶ÌáÉý: addLV=%ss!µ±Ç°ÐǼ¶Ì츳: idList=%s,lvList=%ssδÂú¼¶ÐǼ¶Ì츳ID: %ss³£¹æ¿Õ²ÛλÔö¼ÓÌ츳Êý£º%ssÐÂÔöÐǼ¶Ì츳ID: %ss#Éý¼¶ÐǼ¶Ì츳ID: %s,idLV=%s,index=%ss&    ÒƳýδÂú¼¶ID: %s,unfullLVIDList=%ss!¸üÐÂÐǼ¶Ì츳: idList=%s,lvList=%s(Rt
GetFuncCfgR<RR=R?R-RNtminR‚RStlenRRRMRORPRQt GetWashWeightRLRTRUR_R“trandomtchoiceR>t    enumerateRV(RDtaddLVtcommTalentSlott talentMaxLVtidCounttlvCounttidListtlvListtunfullLVIDListthaveUpR_RattalentLVt idWeightDictR]R^R`tweightRcRdRet    zeroIndextrandIDt    randIndextidLV((siD:\SG_ServerCode\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Player\PlayerHero.pyRÈ´sœ           
 
 
 
 
 
   cCsðtjƒj|ƒ}|jƒ}|j}t||ƒ}|sCdS|jƒ}tjd|ƒ}|skdS|j    ƒ}    |j
t j ƒ}
tj d|||    |
f|ƒtjd|    |
ƒ} | sÈdS|
d} tjd|    | ƒstj d|    |
f|ƒdS| jƒ} | sdS| \}}| s5| r9dS|jƒjtjƒ}tj|||ƒ\}}|stj d||fƒdStj||||tdƒtj d||| f|ƒt|| ƒtj|ƒj|gƒdS(    NRFs:ÇëÇóÎä½«Í»ÆÆ: itemIndex=%s,heroID=%s,quality=%s,breakLV=%sR¦is%Í»ÆÆµÈ¼¶ÒÑÂú¼¶: quality=%s,breakLV=%ss7²ÄÁϲ»×㣬Î佫ÎÞ·¨Í»ÆÆ! costItemID=%s, costItemCount=%st    HeroBreaks/Îä½«Í»ÆÆ: itemIndex=%s,heroID=%s,nextBreakLV=%s(RRŠR‹RRŒRRHRRIRJR7RR9RRŽRR    R
RRR‘R’R“tSetHeroBreakLVR”R•R–(R_R—R˜RR™R€RhR2RWRXR|RÆt nextBreakLVRžRŸR R¡R¢R£((siD:\SG_ServerCode\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Player\PlayerHero.pyt OnHeroBreaksJ           
   cCs|jtj|ƒdS(N(R5RR9(RhR|((siD:\SG_ServerCode\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Player\PlayerHero.pyRæBsc    Csbtjƒj|ƒ}|jƒ}|j}t||ƒ}|sCdS|jƒ}tjd|ƒ}|skdS|j    ƒ}    |j
t j ƒ}
|j
t j ƒ} tjd|||    | |
f|ƒtjddƒ} tjddƒ} |
| ksú|
| krtjd|
| | f|ƒdStjd|    | ƒ}|s:dS| d}tjd|    |ƒswtjd|    | f|ƒdS|jƒ}|sdS|\}}| s§| r«dS|jƒjtjƒ}tj|||ƒ\}}|sÿtjd    ||fƒdStj||||td
ƒtjd |||f|ƒt||ƒtj|ƒj|gƒdS( NRFsDÇëÇóÎ佫¾õÐÑ: itemIndex=%s,heroID=%s,quality=%s,awakeLV=%s,starLV=%sRÍiis$µ±Ç°ÐǼ¶²»¿É¾õÐÑ: starLV=%s < %s, %stHeroQualityAwakes%¾õÐѵȼ¶ÒÑÂú¼¶: quality=%s,awakeLV=%ss7²ÄÁϲ»×㣬Î佫ÎÞ·¨¾õÐÑ! costItemID=%s, costItemCount=%sR¾s/Î佫¾õÐÑ: itemIndex=%s,heroID=%s,nextAwakeLV=%s(RRŠR‹RRŒRRHRRIRJR7RR8R:RRÎRŽRR    R
RRR‘R’R“tSetHeroAwakeLVR”R•R–(R_R—R˜RR™R€RhR2RWRXRyR¸tawakeLimitStarRÖRÆt nextAwakeLVRžRŸR R¡R¢R£((siD:\SG_ServerCode\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Player\PlayerHero.pyt OnHeroAwakeNsV           
   cCs7|jƒ}|jtj|ƒt|ƒ|jƒdS(N(RÇR5RR:tunlockTalentSlotByAwakeRÉ(RhR¸RÌ((siD:\SG_ServerCode\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Player\PlayerHero.pyRê|s
 
 
cCsl|jƒ}|jtjƒ}tjd|ƒ}|s:dSd}x;|| ddd…D]"}|jƒ}|rX|}PqXqXW|sˆdS|jtjƒ}||krªdStj    ddƒ}||krÌdS|jtj
ƒ}    |    rèdSg}
x6t |ƒD](} |j tj| ƒ} |
j | ƒqûWtjd|||
fƒi} g}tjƒ}xpt |jƒƒD]\} |j| ƒ}|jƒ} | |
krŸqln|jƒ}|j || gƒ|| | <qlWtj    ddƒ}x‡t |ƒD]y}tj|ƒ}|s qën| j|dƒ|g}||kr@|j|ƒn|jtj
|ƒtjd|ƒqëWdS(    NR¾iiÿÿÿÿRÍis5¾õÐѽâËøÌ츳²Û: awakeLV=%s,maxUnlockSlot=%s,idList=%sis!Ëæ»ú¾õÐÑÌ츳ѡÏî: randTalentID=%s(RHR7RR:RRÀtGetUnlockTalentSlotR<R=RÎRBRNR‚RSRRRMRORPRQtGetAweakWeightRLRTRURV(RDR2R¸tawakeIpyDataListt maxUnlockSlotRÆtunlockTalentSlotRØRÖR´RÚR_RaRßR]R^R`Ràt randTalentCntRcRdRe((siD:\SG_ServerCode\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Player\PlayerHero.pyRî„sb         cCsµtjƒj|ƒ}|jƒ}|j}|j}t||ƒ}|sLdS|jƒ}|jt    j
ƒ}    |     s}||    kržtj d|||    f|ƒdS|j t    j
|ƒ}
|
s½dS|j ƒ} | jt    jƒ} | jt    jƒ} gg}}xatt| | ƒƒD]J}| j t    j|ƒ}| j t    j|ƒ}|j|ƒ|j|ƒqWtjddƒ}| |kr©|dg|| 7}|dg|| 7}n|
|krÙtjd|||
|f|ƒdS|j|
ƒ|jdƒ| jt    j
ƒtj d|
||fƒ| jt    jƒ| jt    jƒxDt|ƒD]6\}}| jt    j|ƒ| jt    j||ƒqJWt| ƒ|jƒtj|ƒj|gƒdS(NsB²»´æÔڸþõÐÑÌì¸³Ëæ»úÑ¡Ïî! heroID=%s,selectIndex=%s,awakeRandCnt=%sRÍiisDÑ¡ÔñÌ츳ID²»ÄÜÖØ¸´! heroID=%s,selectIndex=%s,selectTalentID=%s in %ss3¸üÐÂÑ¡ÔñÌ츳: selectTalentID=%s,idList=%s,lvList=%s(RRŠR‹RRŒt SelectIndexRRHR<RRBRR‚RÇR=R?RNRÏRSRRÎR¬R>RÔRVRîRÉR”R•R–(R_R—R˜RR™R€t selectIndexRhR2R´tselectTalentIDRDRØRÙRÚRÛRaRÞRÖ((siD:\SG_ServerCode\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Player\PlayerHero.pytOnHeroAwakeSelectTalentÉsZ                     
 
cCsžtjƒj|ƒ}|j}|j}|j}t||ƒ}|sIdS|dkrht|||ƒn2|dkr‡|jt    j
ƒnt ||||ƒdS(Nii( RRŠR‹RŒtLockTalentIndexstOPTypeRtHeroTalentWashReplaceR>RRAtHeroTalentWash(R_R—R˜RR€tlockTalentIndexstopTypeRh((siD:\SG_ServerCode\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Player\PlayerHero.pyt
OnHeroWash
s              cCsÌ|jƒ}tjd|||fƒ|jtjƒ}|rStjd|ƒdStjddƒ}tjddƒ}| s…| r‰dS|\}}    |\}
} |j    ƒj
t j ƒ} t j|| |    ƒ\} }| sõtjd||    fƒdSg}d}|rYt|ƒ| }t j|
| |ƒ\} }| sYtjd|
| |fƒdSnt j|| ||    td    ƒt j|| ||td    ƒ|jƒ}|jtjƒ}g}xRt|ƒD]D}||krù|jtj|ƒ}|j|ƒqÂ|jdƒqÂWtjd
|ƒi}g}tjƒ}xpt|jƒƒD]\}|j|ƒ}|jƒ}||kryqFn|jƒ}|j||gƒ|||<qFWxt|ƒD]q\}}|rËq³ntj|ƒ}|sæq³n|j|dƒ|g}||kr|j|ƒn|||<q³Wtjd |ƒ|j tjƒx!|D]}|j!tj|ƒqPW|j tj"ƒx!|D]}|j!tj"|ƒq„W|j#ƒtjd ||||fƒdS( Ns4Î佫ϴÁ¶: itemIndex=%s,heroID=%s,lockTalentIndexs=%ss*Î佫ϴÁ¶½á¹ûδ´¦Àí£¬ÎÞ·¨Ï´Á¶! washIDCnt=%stHeroWashiis>Ï´Á¶²ÄÁϲ»×㣬Î佫ÎÞ·¨Ï´Á¶! washItemID=%s,washCostItemCount=%sisXËø¶¨²ÄÁϲ»×㣬Î佫ÎÞ·¨Ï´Á¶! lockItemID=%s,lockCostItemCount=%s,lockCostItemCountTotal=%sRüs
Ï´Á¶Ç°: %ss
Ï´Á¶ºó: %ssFÎ佫ϴÁ¶½á¹û! itemIndex=%s,heroID=%s,washIDList=%s,lockTalentIndexs=%s($RHRRR<RRAR¬RRRR    R
RRR‘RÐR’R“RÇR=RNR‚RSRMRORPRQRÑRÔRLRTRUR>RVR@RÉ(RR€RhRýR2R³twashCostItemInfotlockCostItemInfot
washItemIDtwashCostItemCountt
lockItemIDtlockCostItemCountR¡R¢twashItemIndexListtlockItemIndexListtlockCostItemCountTotalRDRØt
washIDListR_RaRßR]R^R`RàRdRe((siD:\SG_ServerCode\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Player\PlayerHero.pyRüsŠ                
    c    CsÝ|jƒ}|jƒ}g}|jtjƒ}|jtjƒxIt|ƒD];}|jtj|ƒ}|j    |ƒ|j
tj|ƒqMW|jtjƒ|j ƒt j d|||fƒtj|ƒj|gƒdS(Ns2Î佫ϴÁ¶Ìæ»»! itemIndex=%s,heroID=%s,washIDList=%s(RHRÇR<RRAR>R=RNR‚RSRVRÉRRR”R•R–(    RR€RhR2RDR
RØR_Ra((siD:\SG_ServerCode\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Player\PlayerHero.pyRûss   
c Cs'tjƒj|ƒ}|j}|j}t||ƒ}|s@dS|jƒ}tjd|ƒ}|shdS|j    ƒ}    |dkr÷|t
|    ƒkr­tj d||fƒdS|j t j|ƒ}
|
td|ƒ@s÷tj d|||
fƒdSn|jtj|ƒtj|ƒj|gƒdS(NRFis*¸ÃÎ佫²»´æÔÚ¸ÃÆ¤·ô! heroID=%s,skinIndex=%sis5¸ÃÎ佫Ƥ·ôδ½âËø! heroID=%s,skinIndex=%s,skinState=%s(RRŠR‹RŒt    SkinIndexRRHRRIt GetSkinIDListRÐRRjRktDef_PDict_HeroSkintpowR5RR;R”R•R–( R_R—R˜RR€t    skinIndexRhR2RWt
skinIDListt    skinState((siD:\SG_ServerCode\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Player\PlayerHero.pytOnHeroWearSkins,           cCsË|jtj|ƒ}|rX|td|ƒB}tjd||||f|jƒƒn;tj||dƒ}tjd||||f|jƒƒtj    |tj||ƒt
||gƒt |ƒdS(Nis=¼¤»îÎ佫Ƥ·ô: heroID=%s,skinIndex=%s,skinState=%s,updState=%sis=ʧЧÎ佫Ƥ·ô: heroID=%s,skinIndex=%s,skinState=%s,updState=%s( RjRkR RRRRt SetBitValueRoRpRtRefreshLordAttr(RR2RtisActiveRtupdState((siD:\SG_ServerCode\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Player\PlayerHero.pytActiveHeroSkin©s         
cCstjƒj|ƒ}|j}|j}|j}|dkrOt|||ƒn,|dkrnt|||ƒn t||ƒdS(Nii(    RRŠR‹tHeroIDRŒtBookTypet__doHeroBookStarLVUPt__doHeroBookBreakLVUPt__doHeroBookAct(R_R—R˜RR2R€tbookType((siD:\SG_ServerCode\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Player\PlayerHero.pyt OnHeroBookUPÂs               c    Cs>|jƒ}t||ƒr3tjd||ƒdStjd||ƒtjd|ƒ}|scdS|jƒ}tjd|ƒ}|s‹dSt||ƒdkr¸tjd||ƒdSt||dƒ|j    ƒ}|r t
|ƒdkr |\}}|r |r t j |||dƒq nt ||gƒt|ƒdS(    Ns¸ÃÎ佫ͼ¼øÒѼ¤»î! heroID=%ssÎ佫ͼ¼ø¼¤»î! heroID=%sRFRGis%Î佫δ»ñµÃ¹ý£¬²»¿É¼¤»îͼ¼ø! heroID=%sit HeroBookAct(RRuRRRRIRJRfRvtGetBookActAwardMoneyRÐRot    GiveMoneyRR(    RR2R™RWRXRYtawardMoneyInfot    moneyTypet
moneyValue((siD:\SG_ServerCode\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Player\PlayerHero.pyRÐs0     
cCs|jƒ}t||ƒs3tjd||ƒdSt||ƒ}|sLdS|jƒ|kr‚tjd||jƒf|ƒdS|jtjƒ}t    ||ƒ}||krÐtjd|||f|ƒdStjd|||f|ƒt
|||dƒt ||gƒt |ƒdS(Ns¸ÃÎ佫ͼ¼øÎ´¼¤»î! heroID=%ss)·Ç¸ÃÎ佫ͼ¼ø¹ØÁªÎïÆ·! heroID=%s,itemID=%ssA¸ÃÎ佫ͼ¼øÐǼ¶ÒѴﵱǰӢÐÛÐǼ¶! heroID=%s,bookStar=%s,heroStar=%ss3Î佫ͼ¼øÐǼ¶Éý¼¶! heroID=%s,bookStar=%s,heroStar=%si( RRuRRRRHR7RR8RxRzRR(RR2R€R™RhtheroStartbookStar((siD:\SG_ServerCode\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Player\PlayerHero.pyRîs(   
cCs|jƒ}t||ƒs3tjd||ƒdSt||ƒ}|sLdS|jƒ|kr‚tjd||jƒf|ƒdS|jtjƒ}t    ||ƒ}||krÐtjd|||f|ƒdStjd|||f|ƒt
|||dƒt ||gƒt |ƒdS(Ns¸ÃÎ佫ͼ¼øÎ´¼¤»î! heroID=%ss)·Ç¸ÃÎ佫ͼ¼ø¹ØÁªÎïÆ·! heroID=%s,itemID=%ssO¸ÃÎ佫ͼ¼øÍ»ÆÆµÈ¼¶ÒѴﵱǰӢÐÛÍ»ÆÆµÈ¼¶! heroID=%s,bookBreakLV=%s,heroBreakLV=%ss9Î佫ͼ¼øÍ»ÆÆÉý¼¶! heroID=%s,bookBreakLV=%s,heroBreakLV=%si( RRuRRRRHR7RR9R{R}RR(RR2R€R™Rht heroBreakLVt bookBreakLV((siD:\SG_ServerCode\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Player\PlayerHero.pyRs(   
cCs]tjƒj|ƒ}|j}|j}t||ƒ}|s@dS|j|rRdndƒdS(Nii(RRŠR‹RŒtIsLockRt SetIsLocked(R_R—R˜RR€tisLockRh((siD:\SG_ServerCode\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Player\PlayerHero.pyt
OnHeroLock&s        cCsFtjƒj|ƒ}|j}|j}|j}i}g}xI|D]A}    |    j}
|    j} | |krmqCn|j| ƒ| ||
<qCW|t    j
kr¬tj d|ƒdStj d||f|j ƒƒ|j ƒjt    jƒ} d} i}xût| jƒƒD]ç}| j|ƒ}| s|jƒr1qn|jt    jƒ}|sOqn|jƒ}xŒt|ƒddd…D]q}|jt    j|ƒ}t|ƒd|kr¬qun|jt    j|ƒ| d7} | t    jkrÜPn|||<quWqWg}i}xü|jƒD]î\}
} | dks| | jƒkr7qn| j| ƒ}| s|jƒr_qn|jƒ}||kr”tj d| |fƒqn|j|ƒ|jƒ}t|||
ƒ}|jt    j|ƒ| |krë||| <n|
|| <qWx|jƒD]}|j ƒqWt!j"|ƒj#|ƒ}|j$||ƒdS(Ns#²»´æÔÚ¸ÃÕóÈÝ£¬ÎÞ·¨±£´æ! lineupID=%ss±£´æÕóÈÝ: lineupID=%s, %siiÿÿÿÿis,ͬ¸öÎ佫ֻÄÜÉÏÕóÒ»¸ö! itemIndex=%s,itemID=%s(%RRŠR‹tLineupIDt    ShapeTypet HeroPosListtPosNumRŒRSRt
LineupListRRRR    R(RNR RRR<R+RÇR‚Rƒt DelUserAttrt LineupObjMaxRRHR*RVtvaluesRÉR”R•t    GetLineupt    UpdLineup(R_R—R˜RR0R1t heroPosListt heroPosDictt    indexListtposInfoR3R€R.tdelCountt syncItemDictRhR„RÌR…R4t
heroIDListt heroItemDicttitemIDtsyncItemtlineup((siD:\SG_ServerCode\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Player\PlayerHero.pytOnHeroLineupSave@sz                          
      cCs|d|d|S(Ni'id((R0R1R3((siD:\SG_ServerCode\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Player\PlayerHero.pyR*ŒscCs/|d}|dd}|d}|||fS(Ni'id((R4R0R1R3((siD:\SG_ServerCode\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Player\PlayerHero.pyRƒs
 
cCs!t|ƒtj|ƒjƒdS(N(tCalcHeroAddAttrR”R•tRefreshRoleAttr(R((siD:\SG_ServerCode\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Player\PlayerHero.pyR™s
cCsOi}|jƒ}tjƒ}xút|jƒƒD]æ}|j|ƒ}|jƒ}t||ƒsgq1n|jƒ}tj    d|ƒ}|s‘q1n|j
ƒ}    |j ƒ}
|j ƒ} t ||ƒ} t||ƒ} xAtjD]6}|    | |
| | }|j|dƒ|||<qÝWq1Wtjd||ƒtj|ƒjtj|ƒdS(NRGisÎ佫ͼ¼øÊôÐÔ: %s(tGetIDRRMRNt GetHeroCounttGetHeroByIndext    GetHeroIDRuRJRItGetBookInitAddPertGetBookStarAddPertGetBookBreakLVAddPerRxR{RktBaseAttrPerIDListRTRRR”R•t SetCalcAttrtDef_CalcAttr_HeroBook(RtheroBookAttrDictR™R^R_RÆR2RXRYtbookInitAddPertbookStarAddPertbookBreakLVAddPerR&R(t    attrPerIDtaddPer((siD:\SG_ServerCode\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Player\PlayerHero.pyRCŸs.       "cCsdS(N((R((siD:\SG_ServerCode\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Player\PlayerHero.pytRefreshLineupHeroAttr½scCsdS(N((((siD:\SG_ServerCode\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Player\PlayerHero.pytCaclHeroCardAttrÃsc Cs|dkr|}nQg}tjƒ}x<t|jƒƒD](}|j|ƒ}|j|jƒƒq:W|spdSg}xÑ|D]É}tjd|ƒ}|s¡q}n|dkrÊ|j    t
j |ƒ rÊq}nt j ƒ}    ||    _|j    t
j|ƒ|    _|j    t
j |ƒd|    _t||ƒ|    _t||ƒ|    _|j|    ƒq}W|sTdSt jƒ}
||
_t|
jƒ|
_tj||
ƒdS(NRFi
(tNoneRRMRNRFRGRSRHRIRjRkRltChPyNetSendPackt    tagSCHeroRR t    SkinStatet BookInitStateRxt
BookStarLVR{t BookBreakLVt tagSCHeroInfot HeroInfoListRÐtHeroCntt NetPackCommont SendFakePack( RR=tsyncHeroIDListR^R_RÆt syncInfoListR2RWtherot
clientPack((siD:\SG_ServerCode\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Player\PlayerHero.pyRÆs<       #          (>RRRR
RRXRaRoR”RRkRÒRRRRRERCRiRfRgRuRvRxRzR{R}RR)R‡R¥RR½R­R¯RÈRèRæRíRêRîRøRÿRüRûRR“RRRRRR,RBR*RƒRRCRURVRWR(((siD:\SG_ServerCode\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Player\PlayerHero.pyt<module>st                                    ,                                       /        5            f    (         .        E    A        V                                  L