cehua_wcy
2018-10-29 aa9d41680c60795b199ecb1051bce053a0cd3bb7
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
#¹¼[c@sddlZddlZddlZddlZddlZddlZddlZddlZddlZddl    Z    ddl
Z
ddl Z ddl Z ddl Z ddlZddlZddlZddlZddlZdZd„Zd„Zed„Zd„Zd„Zd„Zd    „Zd
„Zd „Zd „Zd „Zd„Z d„Z!d„Z"d„Z#d„Z$dS(iÿÿÿÿNtProcessPlayerCachecCs$|jt|ƒt||tƒdS(N(tSetDicttDef_Process_TicktUpdateGameServerPlayerCachetTrue(t    curPlayerttick((sd.\\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Player\PlayerViewCacheTube.pytOnPlayerLogOut)scCs@||jtƒdkr<t||tƒ|jt|ƒndS(Nii<ièi,ià“(t GetDictByKeyRRtFalseR(RR((sd.\\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Player\PlayerViewCacheTube.pyt ProcessCache3scCs»tjdƒt|ƒ\}}}tjƒ}|jƒ|_|jƒ|_||_    t
|ƒ|_ ||_ t
|ƒ|_ ||_t
|ƒ|_||_tj|ƒtjdƒdS(Ns+ViewCache### UpdateGameServerPlayerCache ins,ViewCache### UpdateGameServerPlayerCache out(t    GameWorldtDebugLogtGetPlayerCachetChMapToGamePyPackttagMGUpdatePlayerCachet GetPlayerIDtPlayerIDtGetLVtPlayerLVtPropDatatlent PropDataSizetItemDatat ItemDataSizetPlusDatat PlusDataSizet IsLogoutingt NetPackCommontSendPyPackToGameServer(RRRtcurPlayerPropDatatcurPlayerItemDatatcurPlayerPlusDatatsendPack((sd.\\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Player\PlayerViewCacheTube.pyR<s                    c Cs`i}|jƒ|d<|jƒ|d<|jƒ|d<|jƒ|d<tj|ƒ|d<|jƒ|d<|jƒ|d<|jƒ|d<|j    ƒ|d    <|j
ƒ|d
<t j |ƒ|d <|j ƒ|d <|jƒ|d <|jƒ|d<|jƒ|d<|jtjƒ|tj<|jtjƒ|tj<|jƒjƒ|d<ttjƒƒ|d<|jtjtjƒ}tj|tjƒ}t||dƒ|dtj<tj|t j!ƒ|dt j!<tj|t j"ƒ|dt j"<tj|t j#ƒ|dt j#<t$|t%j&ƒ}i}i}x:t j'D]/}tj(||ƒ}|r.||d|<q.q.W||d<t)|ƒ|d<t*|ƒ|d<t+|ƒ|d<t,|ƒ|d<t-|ƒ|d<t.|ƒ|d<t/|ƒ|d<t0|ƒ|d<t1|ƒ|d<t2j3|ƒ|d<t4j5|d t6ƒ}    t4j5|d t6ƒ}
t4j5t7|ƒd t6ƒ} |    |
| fS(!NtAccIDtLVtRealmLVtJobtJobRanktVIPLVtNametFamilyIDt
FamilyNamet
FightPowertAppIDtMinAtktMaxAtktDeftMaxHPt GeTuiClientIDtTimeis
CntMark_%ss%stFightPowerDicttEquipPartStarLVtEquipPartStonet    EquipWashtPettHorset    GodWeapontRunet MagicWeapontEquipPartSuitetFruitt ensure_ascii(8tGetAccIDRtGetOfficialRanktGetJobt PlayerControlt
GetJobRanktGetVIPLvt GetPlayerNamet GetFamilyIDt GetFamilyNamet GetFightPowerR tGetPlayerPlatformt    GetMinAtkt    GetMaxAtktGetDeftGetMaxHPtNomalDictGetPropertytChConfigtDef_PDict_GeTuiSettDef_PDict_NoGeTuiTimetGetAccountDatatGetGeTuiClientIDtintttimetDef_Player_Dict_EnterFbCntDaytDef_FBMapID_SealDemontFBCommontGetEnterFBMaxCnttmaxt BossHurtMngtGetCanKillBossCntt ShareDefinetDef_Boss_Func_WorldtDef_Boss_Func_HometDef_Boss_Func_Dogzt__GetPackEquipCacheListt IPY_GameWorldtrptEquiptModuleFightPowerTypeListtGetMFPFightPowert__GetEquipPartStarLVInfot__GetEquipPartStoneInfot__GetEquipWashInfot __GetPetInfot__GetHorseInfot__GetGodWeaponInfot __GetRuneInfot__GetMagicWeaponInfot__GetEquipPartSuiteInfotPlayerAttrFruittGetAttrFruitEatCntDicttjsontdumpsR    t__RemoveEmptyDataKey( RtcurPlayerPropDicttenterCnttmaxCnttcurEquipItemListtcurPlayerPlusDicttfightPowerDicttmfpTypet
fightPowerRRR ((sd.\\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Player\PlayerViewCacheTube.pyR Ss`   
cCs5x.|jƒD] }||s |j|ƒq q W|S(N(tkeystpop(tdataDicttkey((sd.\\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Player\PlayerViewCacheTube.pyRs­s
cCsYtj}tj|}i}x6|D].}tj|||ƒ}|r#|||<q#q#W|S(N(RbRcROtPack_EquipPart_CanPlusStartChEquiptGetEquipPartStarLV(RtpTypet    indexListtstarLVInfoDicttitstarLV((sd.\\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Player\PlayerViewCacheTube.pyRf´s      cCsgi}tjƒ}xN|D]F}tj||ƒ}|r|jdƒt|ƒkr|||<qqW|S(Ni(tOperate_EquipStonetGetAllStoneEquipIndexListtGetEquipIndexStoneIDListtcountR(Rt stoneInfoDicttstoneCanPlaceListt
equipIndext stoneIDList((sd.\\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Player\PlayerViewCacheTube.pyRg¿s  !c    CsÑg}tjƒ}x¸|D]°}|jtj|ƒd}g}t}xVtdtjdƒD]>}|jtj||fƒ}|r\|j    |ƒt
}q\q\W|r|j    i|d6|d6|d6ƒqqW|S(NitPlaceR#tValue( tOperate_EquipWashtGetAllEquipWashPlaceRNROtDef_PDict_EquipWashLVR    txrangetDef_EquipWashMaxAttrCounttDef_PDict_EquipWashValuetappendR(    Rt stoneInfoListt washPlaceListtplacetwashLVt    valueListthasValuetattrNumtvalue((sd.\\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Player\PlayerViewCacheTube.pyRhÉs    )cCsfi}tjdƒ}xJ|jƒD]<}x3|D]+}tj||ƒ}|r/|||<q/q/Wq"W|S(Nt EquipSuitType(t IpyGameDataPYtGetFuncEvalCfgtvaluesRtGetSuiteInfoByPlace(Rt suiteInfoDicttequipSuitTypeDicttequipIndexListR†t    suiteInfo((sd.\\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Player\PlayerViewCacheTube.pyRnÜs cCsÉi}g}|jƒjtjƒ}xt|jƒƒD]m}|j|ƒ}| s7|jƒreq7n|jtj    ƒ}|jtj
ƒ}|j i|d6|d6ƒq7W||d<t j |ƒ|d<|S(NtidtlvtPetLVtAtkSpeed(tGetItemManagertGetPackR]trptPetR•tGetCounttGetAttIsEmptyt GetUserAttrtDef_IudetPet_NPCIDtDef_IudetPet_ClassLVR˜RBt GetAtkSpeed(RtpetInfotpetClassLVListt    equipPacktindextpackItemtpetNPCIDtclassLV((sd.\\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Player\PlayerViewCacheTube.pyRiçs
cCs‘g}tjƒ}xxt|jƒƒD]d}|j|ƒ}|jƒ}|jtj|dtj    ƒ}|r%|j
i|d6|d6ƒq%q%W|S(NiRªR«( R¢tIPY_DataR•t GetHorseCounttGetHorseByIndext
GetHorseIDRNROtDef_PDict_Horser_LVtDef_PDictType_HorseR˜(Rt    horseListt
ipyDataMgrR†tipyDatathorseIDthorseLV((sd.\\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Player\PlayerViewCacheTube.pyRjøs  "cCs|i}tjƒ}|j|jƒdƒjƒ}xDtd|dƒD]/}|jtj|ƒ}|rE|||<qEqEW|S(Ni(    R¢R¿tGetGodWeaponByIndextGetGodWeaponCounttGetTypeR•RNROtDef_PDict_GodWeaponLV(Rt godWeaponDictRÆtmaxTypetgwTypetgwLV((sd.\\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Player\PlayerViewCacheTube.pyRks cCs“i}tjddƒ}xntd|dƒD]Y}|jtj|dƒ}|sWq,ntj|ƒ}tj|ƒ}||g||<q,Wt    |ƒS(Nt
RuneUnlockiii(
R¢t
GetFuncCfgR•RNROtDef_PDict_Rune_Datat ItemControlert GetRuneItemIDtGetRuneItemPlusLVR(RtruneDictt runeHoleCnttholeNumtruneDatat
runeItemIDtruneItemPlusLV((sd.\\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Player\PlayerViewCacheTube.pyRlscCs‰i}tjƒ}xpt|jƒƒD]\}|j|ƒ}|jƒ}|jƒ}tj||ƒr%|j    |dƒd||<q%q%W|S(Nii(
R¢R¿R•tGetTreasureCounttGetTreasureByIndextGetIDtGetTreasureTypetPlayerMagicWeapontGetIsActiveMagicWeapontget(RtmwDictRÆR†ttreasureIpyDatat magicWeaponIDt treasureType((sd.\\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Player\PlayerViewCacheTube.pyRms   !cCsô|jƒj|ƒ}g}xÒt|jƒƒD]¾}|j|ƒ}| s.|jƒr\q.ni}|jƒ|d<|jƒ|d<t|j    ƒƒ|d<t|j
ƒƒ|d<|j ƒ}|rÙ|dkrÙ||d<n|j t |ƒƒq.W|S(Nt    ItemIndextItemIDtIsBindtIsSuites{}tUserData(R®R¯R•R±R²R³tGetItemPlaceIndext GetItemTypeIDRTt    GetIsBindt
GetIsSuitet GetUserDataR˜Rs(RtpackTypeRºtitemListR»tcurEquiptitemDicttuserData((sd.\\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Player\PlayerViewCacheTube.pyRa)s   c
CsGtjdƒtjƒj|ƒ}|j}tjƒj|ƒ}|rt|ƒ\}}}tjƒ}    ||    _||    _    t
|    j    ƒ|    _ ||    _ t
|    j ƒ|    _ ||    _t
|    jƒ|    _tjd|    jƒ|    jƒfƒtj||    ƒtjdƒdStjƒ}    |jƒ|    _||    _tj|    ƒtjdƒdS(Ns"ViewCache### OnCMViewPlayerInfo ins6ViewCache### OnCMViewPlayerInfo len: %s , sendPack: %ss8ViewCache### OnCMViewPlayerInfo Return MapPlayerInfo outs:ViewCache### OnCMViewPlayerInfo SendToGameServer Query out(R R tGetPlayerManagertGetPlayerByIndexRtFindPlayerByIDR tChPyNetSendPackttagSCQueryPlayerCacheResultRRRRRRRt    GetLengtht OutputStringRt SendFakePackRttagMGQueryPlayerCacheRt FindPlayerIDR(
R»t
clientPackRRt findPlayerIDt
findPlayerRRR R!((sd.\\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Player\PlayerViewCacheTube.pytOnCMViewPlayerInfo?s0                      #        (%ROR R]RRBRbRûRRâRˆR’RoRÕR¢RRXR[RURqRRR
R    RR RsRfRgRhRnRiRjRkRlRmRaR(((sd.\\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Player\PlayerViewCacheTube.pyt<module>sF                       
             Z