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
 
8hc@sxddlZddlZddlZddlZddlZddlZddlZddlZddlZddl    Z    ddl
Z
ddl Z ddl Z ddl Z ddlZddlZgad„Zd„Zd„Zd„Zd„Zd„Zd„Zd    „Zd
„Zd „Zd „Zd „Zd„Zd„Zd„Zd„Z d„Z!d„Z"gd„Z#dS(iÿÿÿÿNcCsÉtr
tStjdƒ}gax£td|dƒD]Ž}tjd|dƒ}xo|D]g}tjdi|d6tƒ}|s„qVnx6|D].}|jƒ}|tkr‹tj|ƒq‹q‹WqVWq3WtS(Nt GemTypeCountis    GemType%stEquipPlaceIndexMapt
EquipPlace(    tg_stoneCanPlaceListt IpyGameDataPYt
GetFuncCfgtxrangetGetFuncEvalCfgtGetIpyGameDataByConditiontTruet GetGridIndextappend(RtstoneTypeIndext    placeListtplacet ipyDataListtipyDatat    gridIndex((syD:\SG_ServerCode\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Event\EventSrc\Operate_EquipStone.pytGetAllStoneEquipIndexList+s    cCs]tjddƒ}t|ƒ}tjddƒ}t|ƒ}t|ƒttjtj|ƒS(NtGemOpenit
GemOpenVip(RRtlentrangetChConfigtDef_Stone_VipHole(tgemOpenNeedStarListtmaxEquipHoleCnttgemOpenVipListt maxHoleVipCnt((syD:\SG_ServerCode\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Event\EventSrc\Operate_EquipStone.pytGetAllEquipPlaceHoleIndexBs
  cCsGtƒ}g}x1|D])}t|||ƒd}|j|ƒqW|S(Ni(RtGetEquipIndexStoneIDAndIsBandR (t    curPlayert
equipIndext holeIndexListtholeStoneIDListt    holeIndextstoneID((syD:\SG_ServerCode\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Event\EventSrc\Operate_EquipStone.pytGetEquipIndexStoneIDListMs      cCs@|jtj||fƒ}|tj}|tj}||fS(sE»ñµÃ×°±¸Î»¿×λ±¦Ê¯IDºÍ°ó¶¨ÐÅÏ¢
    @return: stoneID, stoneIsBind
    (tNomalDictGetPropertyRtDef_PDict_EquipPartStoneIDtDef_Stone_SaveStoneInfoXNumber(RR R#t    stoneInfoR$t stoneIsBind((syD:\SG_ServerCode\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Event\EventSrc\Operate_EquipStone.pyRXs  c    Cs[t|||ƒ\}}||kr4||kr4dSd}tj|tj||f|tj|ƒtjƒ}d}|r³|j|ƒ}    |    s˜dn|    j    dƒj
dƒ}nd}
|rõ|j|ƒ} | sÚdn| j    dƒj
dƒ}
n|j tj ƒ} t d| |
|ƒ} tj|tj | ƒtjd||||
| | fƒdS(NiisjÉèÖñ¦Ê¯µÈ¼¶: equipIndex=%s,holeIndex=%s,befStoneLV=%s,aftStoneLV=%s,befTotalStoneLV=%s,updTotalStoneLV=%s(Rt PlayerControltNomalDictSetPropertyRR'R(t    GameWorldt GetGameDatatGetItemByTypeIDtGetEffectByIndextGetEffectValueR&tDef_PDict_TotalStoneLVtmaxtDebugLog(RR R#t changeStoneIDtisBindt
befStoneIDt    befIsBindtgameDatat
befStoneLVtbefGemt
aftStoneLVtaftGemtbefTotalStoneLVtupdTotalStoneLV((syD:\SG_ServerCode\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Event\EventSrc\Operate_EquipStone.pytSetEquipIndexStoneIDAndIsBandes, ''cCs%tj}tj}|}|||fS(N(t IPY_GameWorldtrptEquiptrptItem(t
equipPlacet equipPackTypet stonePackTypet
placeIndex((syD:\SG_ServerCode\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Event\EventSrc\Operate_EquipStone.pytGetPackTypeByEquipPlace„s        c    Cs¬tjƒj|ƒ}|jƒ}|j}|j}|j}tjd|||f|ƒt|ƒ\}}    }
|j    ƒj
|ƒ} | j |
ƒ} t j | ƒsµtjd|ƒdS|j    ƒj
|    ƒ} | j |ƒ}t j |ƒsütjd|ƒdS|jƒ}|jƒ}|jdƒ}|jƒ}|tjkretjd|||tjf|ƒdS|jdƒ}tjd|dƒ}tjdi|d    6ƒ}|s­dS|jƒ}|jƒ|krïtjd
||||f|ƒdStj||
| ƒ}t||||ƒsdSt j||dttj i|d 6|d 6ƒ|rVdnd}t!|||||d tƒt"||t|ƒt#||gƒt$||ƒdS(Ns6±¦Ê¯ÏâǶ: equipPackIndex=%s,stoneIndex=%s,holeIndex=%ss Ä¿±ê×°±¸Îª¿Õ»ò²»¿ÉÓã¬ÎÞ·¨ÏâǶ£¡s Ä¿±ê±¦Ê¯Îª¿Õ»ò²»¿ÉÓã¬ÎÞ·¨ÏâǶ£¡isB²»ÊDZ¦Ê¯£¬ÎÞ·¨ÏâǶ£¡stoneIndex=%s,stoneItemID=%s,curEffID=%s != %ss    GemType%siRt    GridIndexs_¸Ã±¦Ê¯²»¿ÉÏâǶÔÚ¸Ã×°±¸Î»£¡stoneItemID=%s,stoneEffType=%s,stoneCanPlaceList=%s,equipPackIndex=%stequipPackIndext    HoleIndext
EquipStone(%R-tGetPlayerManagertGetPlayerByIndext GetPlayerIDt
EquipIndext
StoneIndexRKR4RHtGetItemManagertGetPacktGetAtt
ItemCommontCheckItemCanUsetLogt GetItemTypeIDt    GetIsBindR0t GetEffectIDRtDef_Effect_EquipStoneR1RRRt
GetClassLVt GetEquipPlacetChEquiptGetEquipPartStarByRankt__CheckStoneHoleCanUsetDelItemR    tItemDel_EquipEnchaset__DoChangeEquipHoleStonetRefreshAttrByStoneActiontSycn_StoneHoleInfotDoStoneSuccess(t playerIndext
clientDatattickRtplayerIDRJt
stoneIndexR#RERFRGt    equipPacktcurEquiptitemPacktcurStonet stoneItemIDR6t curStoneEfftcurEffIDt stoneEffTypetstoneCanPlaceListRtclassLVt    equipStar((syD:\SG_ServerCode\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Event\EventSrc\Operate_EquipStone.pytOnEquipEnchase”s^                          cCsŽd}d}tƒ}tjƒ}tj}|jƒj|ƒ}xät|jƒƒD]Ð}xÇ|D]¿}    t    |||    ƒd}
|
dkrq_n|j
|
ƒ} | s¨q_n| j dƒ} | j dƒ| j dƒ} }||7}t jdi|d6ƒ}|r_|jƒ|kr_||7}q_q_WqRWtj|tj|ƒtj|tj|ƒtj|tj||gƒtj|tj|ttƒdS(NiiRRI(RR-R.RARBRRRSRtGetCountRR/R0R1RRR\tOpenServerCampaigntUpdOpenServerCampaignRecordDatat ShareDefinetDef_Campaign_Type_StoneLVt PlayerSuccesstUptateSuccessProgresstSuccType_StoneTotalLVtSuccType_EquipStoneClasstPlayerWeekPartytAddWeekPartyActionCntRtDef_WPAct_StonetFalseR    (RRut totalStoneLVt classStoneLVR!R9tpackTypet playerEquipR R#tcurGemIDtcurGemt    gemEffecttgemTypetgemLVR((syD:\SG_ServerCode\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Event\EventSrc\Operate_EquipStone.pyRfàs2           
cCsŸtjƒj|ƒ}|jƒ}|j}|j}tjd||f|ƒt|ƒ\}}}    |jƒj    |ƒ}
|
j
|    ƒ} t j | ƒs©tj d|ƒdSt j||tƒsÂdSt|||ƒd} | sïtjdƒdStjdi|d6ƒ} | sdS| jƒ}t|||dddtƒt||t|ƒt||gƒt|ƒ}tj|tj|ƒtj|tj |ttƒdS(Ns(±¦Ê¯Õª³ý: equipPackIndex=%s,holeIndex=%ss Ä¿±ê×°±¸Îª¿Õ»ò²»¿ÉÓã¬ÎÞ·¨ÏâǶ£¡is¿×Ϊ¿Õ»ò²»´æÔÚ±¦Ê¯!RRIt    StonePick(!R-RMRNRORPRKR4RHRRRSRTRURVRWtCheckPackHasSpaceR    RRRR\RcRdR„RetGetTotalStoneLVRyRzR{R|RR‚RRƒ(RgRhRiRRjRJR#RERFRGRlRmR$RRuR…((syD:\SG_ServerCode\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Event\EventSrc\Operate_EquipStone.pytOnEquipStonePicks8            cCs|jtjƒS(N(R&RR2(R((syD:\SG_ServerCode\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Event\EventSrc\Operate_EquipStone.pyRBsc Cs¾d}tƒ}tƒ}tjƒ}x“|D]‹}x‚|D]z}t|||ƒd}|dkrfq8n|j|ƒ}    |    sq8n|    jdƒjdƒ}
|
|kr8|d7}q8q8Wq+W|S(Nii(RRR-R.RR/R0R1( RtstoneLVtcntR!tequipIndexListR9R R#R‰RŠR((syD:\SG_ServerCode\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Event\EventSrc\Operate_EquipStone.pytGetStoneCntByLVGs              c<
Cs¦tjƒj|ƒ}|jƒ}|j}|j}tjd||f|ƒt|ƒ\}}}    |jƒj    |ƒ}
|
j
|    ƒ} t j | ƒs©tj d|ƒdSt|||ƒ\} } | dkrÞtjdƒdStjƒj| ƒ}|jƒ}|jdƒ}|jƒ}|tjkrJtj d|||f|ƒdS|jdƒ}|jdƒ}|jdƒ}|d}tjd||||fƒ|sÈtj d    ||||f|ƒdStjd
dƒ}|sädStjd i|d 6ƒ}|sdS|jƒ}tjd
d iƒ}|jƒj    |ƒ}i}i}ii}}ii}} d}!x­t|ddƒD]™}"|"d}#||#f}$|$tjkrÂtjd||#fƒdStj|$}%|!|}&|%| krò|d}&ntjd|"|!|%|&fƒ|j t!|"ƒƒ}'|'rw|'\}(})|)|!}*|j |(dƒ|*||(<tjd|(|*|fƒnt j"|%||&ƒ\}+},}-}.|&|.}/tjd|%|/|.fƒ|/dkrå|,|/g||%<|/||%<n|.dkr|#dkr |.||%<Pq|.}!q|Pq|Wd}0xd|j#ƒD]V\}1}2t j$|1t%j&ƒ}3|3sWdS|0|3|27}0tjd|1|2|3|0fƒq,Wx×|j#ƒD]É\}(}4t j"|(||4ƒ\}5}6}-}7|4|7}8|8dkró|6|8g||(<|8||(<n|7dkr“t j$|(t%j&ƒ}3|3sdS|0|3|77}0|7| |(<tjd|(|4|8|7|3|0fƒq“q“Wi
|d6|d6|d6|d6|d6|d6|d6|d6| d6|d6}9tjd||fƒtjd || fƒ|0rt'j(|t%j&|0tj)|9ƒ rtjd!|0ƒdSx<|j*ƒD].\}:};t j+|||:|;t,tj-|9ƒq$Wt.||||t,d"t,ƒt/||t,|ƒt0||gƒt1||ƒdS(#Ns(±¦Ê¯Éý¼¶: equipPackIndex=%s,holeIndex=%ss Ä¿±ê×°±¸Îª¿Õ»ò²»¿ÉÓã¬ÎÞ·¨ÏâǶ£¡is¿×Ϊ¿Õ»ò²»´æÔÚ±¦Ê¯!s<²»ÊDZ¦Ê¯£¬ÎÞ·¨Éý¼¶£¡stoneIndex=%s,stoneItemID=%s,curEffID=%siisAstoneEffType=%s,stoneLevel=%s,upgradeStoneID=%s,upgradeStoneLV=%ssU¸Ã±¦Ê¯ÒÑÊÇ×î´ó¼¶,²»ÄÜÉý¼¶£¡stoneIndex=%s,stoneItemID=%s,curEffID=%s,upgradeStoneID=%stGemUpCostFormulaRRIiiÿÿÿÿs9ÕÒ²»µ½±¦Ê¯ÀàÐ͵ȼ¶ÎïÆ·ID! stoneEffType=%s, needStoneLV=%ssG    tagLevel=%s,tagLVStoneLackCount=%s,needStoneID=%s,needStoneCount=%ss:        ¶îÍâ²ÄÁÏ: extraItemID=%s,extraItemNeedCount=%s, %ss7        ±¦Ê¯²ÄÁÏ: needStoneID=%s,delCount=%s,lackCnt=%ssC    ¹ºÂò²»×㱦ʯ: buyItemID=%s,buyCount=%s,unitPrice=%s,costGold=%ssc    ¹ºÂò¶îÍâ²ÄÁÏ: extraItemID=%s,exNeedCount=%s,exDelCount=%s,exLackCnt=%s,unitPrice=%s,costGold=%stEquipPackIndexRKtClassLVt StoneItemIDt CurStoneIDLVtUpgradeStoneIDtBuyItemCountDicttDelItemCountDicttBuyExItemCountDicttDelExItemCountDicts'delItemCountDict=%s,buyItemCountDict=%ss+delExItemCountDict=%s,buyExItemCountDict=%ssÏÉÓñ²»×ã!costGold=%st StoneUpgrade(2R-RMRNRORPRKR4RHRRRSRTRURVRWRR.R/RXR0RZRR[R1RRRR\RRt
PyGameDatatg_stoneLevelIDDicttErrLogtgettstrtGetItem_FromPack_ByID_ExExtitemstGetShopItemPriceRAtTYPE_Price_Gold_MoneyR+tPayMoneytDef_Cost_EquipStonetvaluest
ReduceItemR„tItemDel_StoneUpgradeRcRdReRf(<RgRhRiRRjRJR#RERFRGRlRmR$R*t stoneItemDataRpRqRrRst
stoneLeveltupgradeStoneIDtupgradeStoneLVt upNeedCountRRutextraItemInfoDictRntdelItemListDicttexItemNeedCountDicttdelItemCountDicttbuyItemCountDicttdelExItemCountDicttbuyExItemCountDictttagLVStoneLackCountttagLevelt needStoneLVtkeyt needStoneIDtneedStoneCountt extraItemInfot extraItemIDt extraItemCnttextraItemNeedCountt    hasEnought    indexListtfindItemIsBindtlackCnttdelCounttcostGoldt    buyItemIDtbuyCountt    unitPricet exNeedCountt exHasEnought exIndexListt    exLackCntt
exDelCounttinfoDicttdelItemIndexListtdelCnt((syD:\SG_ServerCode\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Event\EventSrc\Operate_EquipStone.pytOnEquipStoneUpgradecsä                 
       
 
 
!
 
    !!
 
    ! c Cs€tƒ}||kr0tjd||fƒtSd}tjddƒ}x2t|dƒD]!\}}||krX|}qXqXW|tjkrI|dkr³tjd||fƒtStjddƒ}    d}
|j    ƒ} x2t|    dƒD]!\}} | | krç|}
qçqçW||
tjkr|tjd| ||
f|j
ƒƒtSn3||kr|tjd|||f|j
ƒƒtSt S(    Ns-ÏâǶ¿×Ë÷Òý´íÎó!holeIndex=%s, holeIndexList=%siRisJ×°±¸Î´¿ªÆôÈÎºÎÆÕͨ±¦Ê¯¿×£¬ÎÞ·¨¿ªÆôVIP¿×λ! equipStar=%s,openCommHoleCnt=%sRs>×°±¸VIP±¦Ê¯¿×먦·Å!curVipLV=%s,holeIndex=%s,openVIPHoleCnt=%ss@¸Ã×°±¸±¦Ê¯¿×Ϊ¿ª·Å£¡equipStar=%s,holeIndex=%s,openCommHoleCnt=%s( RR-RWR„RRt    enumerateRRtGetVIPLvROR    ( RRvR#RER!topenCommHoleCntRtholeCnttopenStarRtopenVIPHoleCnttcurVipLVtvipLv((syD:\SG_ServerCode\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Event\EventSrc\Operate_EquipStone.pyR`ûs8                    c Cst|||ƒ\}}t|||||ƒ|rÑ|rÑt|ƒ\}    }
} d} tj||
ƒr¦tj||| d|
gdtjt    i|d6|d6gƒqÑt
j d|j ƒg|d|ggƒnt j||i|d6|d6|d6|d    6ƒdS(
NiiteventRJRKt GemToPlayerR#R$R5(RR@RHRURt ItemControlertGivePlayerItemRtItemGive_StonePickoffR„R+t SendMailByKeyROtDataRecordPacktDR_StoneItemChange( RRJR#R5R6t    eventNamet    isPickoffR$R*RERFRGt    itemCount((syD:\SG_ServerCode\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Event\EventSrc\Operate_EquipStone.pyRc+s         +  cCsa|tjgkr]|r1|jtjtjƒntj||ƒtj|ƒ}|j    ƒndS(N(
RARBtSetDictRt Def_PlayerKey_AttrActivatyNotifytDef_AttrActivatyNotify_StoneR^tRefreshPlayerEquipAttributeR+tRefreshPlayerAttrState(RR‡t isNeedNotifyRut playControl((syD:\SG_ServerCode\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Event\EventSrc\Operate_EquipStone.pyRdEs cCsÇt|ƒ\}}}|jƒj|ƒ}|j|ƒ}tj|ƒsLdStjddƒ}t|ƒ}d}    t    j
|||ƒ}
x2t |dƒD]!\} } |
| kr•| }    q•q•Wg} xat |ƒD]S}||    kråqÍnt |||ƒd}|dkr qÍn| j||gƒqÍW|    sªtjddƒ}t|ƒ}x_t tjtj|ƒD]A}t |||ƒd}|dkrqbn| j||gƒqbWnt|||| dtƒdS(NRiiRt EquipChange(RHRRRSRTRURVRRRR^R_R×RRR RRt__DoSysPickoffEquipStoneR„(RRJRERFRGRlRmRRtopenEquipHoleCnttpartStarRÚRÛtpickoffHoleListR#R‰Rt maxVipHoleCnt((syD:\SG_ServerCode\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Event\EventSrc\Operate_EquipStone.pytDoMoveEquipStoneTs<        cCsdS(N((R((syD:\SG_ServerCode\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Event\EventSrc\Operate_EquipStone.pyt OnVIPTimeOutƒsc     Cs—|s
dStjd||f|jƒƒg}t|ƒ}tj|||ƒ}||kr¯x|D]D\}    }
t||    |
dd|tƒ|    |krd|j|    ƒqdqdWnÎg} x©|D]¡\}    }
t    ||    |
ƒ} | j| dd| dgƒt
||    |
ddƒt j ||idd6|    d6|
d6| dd6ƒ|    |kr¼|j|    ƒq¼q¼Wt jd|jƒg| ƒ|r“t||ƒndS(    Ns#ϵͳժ³ý±¦Ê¯: %s,pickoffHoleList=%siiR5R R#R$Rà(R-R4RORRUtGetItemPackSpaceRcR    R RR@RåRæR+RäRe( RRERFRõRçt isRefreshAttrR”t
stoneCountt    packSpaceR R#tmailItemInfoListR)((syD:\SG_ServerCode\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Event\EventSrc\Operate_EquipStone.pyRò‰s2      c
Csötƒ}t|ƒ}|s'tƒ}ntjƒ}g|_x‘|D]‰}tjƒ}||_||_t    ||ƒ|_
g}x1|D])}t |||ƒd}    |j |    ƒq†W||_ |jj |ƒqCWt|jƒ|_tj||ƒdS(Ni(RRRtChPyNetSendPackttagMCStoneInfotInfoListt tagMCStoneMsgRt MaxStoneCountR%t    StoneInfoRR t    StoneBindt
EquipCountt NetPackCommont SendFakePack(
RR”R!t maxHoleCounttsendPackR tstoneMsgtholeStoneBindListR#R6((syD:\SG_ServerCode\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Event\EventSrc\Operate_EquipStone.pyRe°s(                          ($R-RUR+RARáRRR^RyRþRRåR}RR{R¡RRRR%RR@RHRwRfR‘RR•RÖR`RcRdR÷RøRòRe(((syD:\SG_ServerCode\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Event\EventSrc\Operate_EquipStone.pyt<module>sF                                               L    2    0            ˜    0            /        '