cehua_ZWJ
2019-01-30 6afaa4408f4e09e3e95dbd92f0d1cd5a1fb2942b
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
x{[c@s“dZddlZddlZddlZddlZddlZddlZdefd„ƒYZdd    d„ƒYZ    da d„Z d„Z dS(
sVersion = 2015-08-12 16:00iÿÿÿÿNt ExpandPackCfgcBsDeZd„Zd„Zd„Zd„Zd„Zdgd„ZRS(cCsHi|_i|_||_||_|||_||_|jƒdS(N(t_ExpandPackCfg__cfgInfot)_ExpandPackCfg__totalAddAttrInfoWithCountt_ExpandPackCfg__defCountt_ExpandPackCfg__maxCountt_ExpandPackCfg__canAddCountt_ExpandPackCfg__cfgNamet_ExpandPackCfg__LoadCfg(tselftcfgNametdefCounttmaxCount((sf.\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Player\PlayerExpandPackCfgMgr.pyt__init__'s                     c    Cs4tj|jƒ}d|kr"dS||_t|jƒ}igd6}xætd|jƒD]Ò}|d}}||krƒ|}n|jj|iƒ}xf|j    ƒD]X}|dkr×||j
|j|dƒƒq¥|j|dƒ|j|dƒ||<q¥W|j j |ƒsZt j|ƒ|j |<qZqZWdS(NtExpiit0(t ReadChConfigtGetEvalChConfigRtNoneRtlentrangeRtgettiterkeystappendRthas_keytcopytdeepcopy(    RtcfgInfotcfgCountt    totalDicttitcounttindext gridCfgInfotkey((sf.\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Player\PlayerExpandPackCfgMgr.pyt    __LoadCfg4s"             *cCs|jS(N(R(R((sf.\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Player\PlayerExpandPackCfgMgr.pytGetCanAddCountRscCs7t|jƒ}||kr$|}n|jj|dƒS(N(RRRR(RtbuyIndexR((sf.\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Player\PlayerExpandPackCfgMgr.pytGetAttrInfoByInexUs     cCs|jj|dƒS(N(RRR(RtbuyCount((sf.\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Player\PlayerExpandPackCfgMgr.pytGetTotalAddAttrInfoByCount_sR cCs|dks|dkr)tjdƒdS||jkrItjdƒdS||krftjdƒdS||kr t|jƒ}||kr–|}n|jj|iƒ}i}xT|D]L}|dkrötj|ƒ}    t    ||ƒ}
|
||<q¸||||<q¸W|S|j
|ƒ} |j
|dƒ} | dksF| dkratjd||gƒdSd|kr|| j ƒ}ni}x…|D]}}|dkrðtj|ƒ}    | ||d} d}
x| D]}|
t    |ƒ7}
qÉW|
||<q‰| || |||<q‰W|S(    Nis5GetTotalCanAddAttrInfo fromIndex <= 0 or toIndex <= 0s3GetTotalCanAddAttrInfo toIndex > self.__canAddCounts*GetTotalCanAddAttrInfo fromIndex > toIndexR is GetTotalCanAddAttrInfo NoData %stall( t    GameWorldtErrLogRRRRRt PlayerControltGetPlayerReExptevalR'tkeys(Rt    curPlayert    fromIndexttoIndextattrListRtfindInfotretInfotattrtReExptaddExpttoInfotfromInfotexpFormulaListtformula((sf.\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Player\PlayerExpandPackCfgMgr.pytGetTotalCanAddAttrInfoisP                  (t__name__t
__module__R RR#R%R'R<(((sf.\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Player\PlayerExpandPackCfgMgr.pyR s                  
    
tExpandPackCfgMgrcBs5eZd„Zd„Zd„Zd„Zd„ZRS(cCs i|_dS(N(t$_ExpandPackCfgMgr__expandPackCfgDict(R((sf.\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Player\PlayerExpandPackCfgMgr.pyR ³scCsŠtj}|jƒjtjƒ}td||jƒƒ|jtj<tj    }|jƒjtj
ƒ}td||jƒƒ|jtj
<dS(NtExpandItemPacktExpandWareHousePack( tChConfigtDef_PlayerFirstLoginOpenBackCnttGetItemManagertGetPackt IPY_GameWorldtrptItemRt GetMaxCountR@tDef_FirstLogin_OpenWareHouseCntt rptWarehouse(RR/tdefItemPackCounttitemPack((sf.\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Player\PlayerExpandPackCfgMgr.pytLoadºs                cCs|jj|dƒS(N(R@RR(RtpackType((sf.\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Player\PlayerExpandPackCfgMgr.pytGetExpandPackCfgÊscCs0|j||tjƒ|j||tjƒdS(N(t_ExpandPackCfgMgr__CalcPackAttrRGRHRK(RR/t allAttrList((sf.\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Player\PlayerExpandPackCfgMgr.pytCalcAttrÒsc Csœ|j|ƒ}|sdStj|tj}|j|ƒ}|dkrLdS|j|ƒ}tjdƒ}x+|D]#}    ||    }
tj    |    |
|ƒqqWdS(NitExpandPackAddAttr(
RPRCtDef_Type_CanBuyPack_PlayerDicttDef_PlayerPackDict_Index_KeytNomalDictGetPropertyR'RRR+tCalcAttrDict_Type( RR/RRROtpackCfgtkeyNametcurCounttattrInfotexpandPackAddAttrtattrNametaddValue((sf.\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Player\PlayerExpandPackCfgMgr.pyt__CalcPackAttrÞs  
(R=R>R RNRPRSRQ(((sf.\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Player\PlayerExpandPackCfgMgr.pyR?®s
                 cCs#tstƒatj|ƒntS(N(tg_expandPackCfgMgrR?RN(R/((sf.\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Player\PlayerExpandPackCfgMgr.pytGetExpandPackCfgMgrøs    cCst|ƒj|ƒS(N(RbRP(R/RO((sf.\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Player\PlayerExpandPackCfgMgr.pyRPs((t__doc__RR)RGR+RCRtobjectRR?RRaRbRP(((sf.\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Player\PlayerExpandPackCfgMgr.pyt<module>s      ŽE