xdh
2018-11-22 cecebcc3370139c937b6a72be5d3a151ddd5be9f
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
k,õ[c@swddlZddlZddlZddlZddlZddlZddlZddlZddlZddl    Z    ddl
Z
ddl Z ddl Z ddl Z ddlZddlZddlZddlZddlZddlZddlZd„Zd„Zd„Zd„Zged„Zd„Zd„Zd    „Zd
„Zd „Zd „Z d „Z!d„Z"d„Z#d„Z$d„Z%dd„Z'd„Z(d„Z)d„Z*d„Z+ed„Z,d„Z-d„Z.d„Z/d„Z0d„Z1d„Z2d„Z3d„Z4d „Z5d!„Z6d"„Z7d#„Z8d$„Z9d%„Z:d&„Z;d'„Z<id(„Z=d)„Z>dS(*iÿÿÿÿNcCs|jƒ}|dkrdS|jƒtjkr5dStjƒj|jƒƒ}|j    ƒ}|j
t j |ƒ|j dƒ|jtjƒtS(Ni(t GetActionObjtNonetGetGameObjTypet IPY_GameWorldtgotNPCt    GameWorldt GetNPCManagert GetNPCByIndextGetIndextGetNPCIDtSetDicttChConfigtDef_PlayerKey_TradeTagNPCtSetForbiddenResetItemtBeginSpecialEventt ShareDefinetTYPE_Event_ShoptTrue(t    curPlayerttickt curActionObjt curActionNPCtcurActionNPCID((si.\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Event\EventSrc\FunctionNPCCommon.pyt
StartTradeOs    cCsdS(Ni((((si.\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Event\EventSrc\FunctionNPCCommon.pytGetDirectNpcIDgscCstj|ƒtS(N(t
EventShellt DoExitEventR(RR((si.\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Event\EventSrc\FunctionNPCCommon.pyt    ExitEventps cCs¡tjƒj|ƒ}||jtjƒtjtjkr?dS|jtj|ƒ|j}tj    ƒj
|ƒtj    ƒj ƒ}|dkrdS|j |ƒdS(Ni( RtGetPlayerManagertGetPlayerByIndext GetTickByTypeR tTYPE_Player_Tick_QueryFuncDatatTYPE_Player_Tick_Timet SetTickByTypet    NPCShopIDt GetGameDatatFilterShopItemByShopTypetGetFilterShopItemCountt BeginShopEx(t playerIndext
clientDataRRt tradeTagNPCt shopItemCount((si.\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Event\EventSrc\FunctionNPCCommon.pytQueryNPCShopItemzs      c
Cstjƒ}g|_|rExÁ|D]}t|||j|ƒq"Wnštjƒ}x‹t|jƒƒD]w}|j|ƒ}|j    ƒs‹qdnt
j |j ƒ}|j |ƒ}    |    dkr¿qdnt||j ƒ|j|ƒqdWt|jƒ|_tj||ƒdS(Ni(tChPyNetSendPackttagMCShopItemDayBuyCntInfot DayBuyCntListt__AppendShopItemDayBuyCntInfot IpyGameDataPYtIPY_Datatxranget GetStoreCounttGetStoreByIndext GetLimitCntR tDef_PDict_ShopItemDayBuyCnttGetIDtNomalDictGetPropertytlentCountt NetPackCommont SendFakePack(
Rt itemIndexListtisResett dayBuyCntInfot    itemIndext
ipyDataMgrtitshopItemt dayBuyCntKeyt curDayBuyCnt((si.\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Event\EventSrc\FunctionNPCCommon.pytSyncShopItemTodayBuyCountœs$          cCsZtjƒ}||_tj|}|j|ƒ}||_t|ƒ|_|j    |ƒdS(N(
R,ttagMCShopItemDayBuyCntt    ItemIndexR R6R8tBuyCnttinttIsResettappend(RR@t dayBuyCntListR>t itemDayBuyCntRDRE((si.\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Event\EventSrc\FunctionNPCCommon.pyR/·s           cCstj|tjtjƒsktj|tjtjdƒ|jtjƒ}|rktj    |tj
dƒqknt |ƒt |ƒt |ƒdS(Ni(RtGetDictValueByBitR tDef_Player_Dict_VersionFixtDef_VerFix_SuperGifttSetDictValueByBitR8tDef_PDict_GoldGiftFirstRecordt PlayerControltNomalDictSetPropertytDef_PDict_SuperGiftHasOpentSyncMysticalShopInfoRFtSyncSuperGiftInfo(RtisGet((si.\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Event\EventSrc\FunctionNPCCommon.pytShopItemOnLoginÂs
 
 
cCs™|tjkr2t|tƒt|ƒdg}nV|tjkr„dg}tjƒjtj    ƒ}|ddkrˆddg}qˆndSt
||ƒdS(Niiii( RtDef_OnEventTypetUpdataSuperGiftTimeRtOSSaleOpenMailtDef_OnEventTypeExRt GetGameWorldtGetGameWorldDictByKeytDef_Notify_WorldKey_ServerDayt__ResetShopItemBuyCount(Rt onEventTypet refreshTypet openServerDay((si.\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Event\EventSrc\FunctionNPCCommon.pyt ShopItemOnDayÒs 
      cCst||gƒdS(N(Rb(RRc((si.\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Event\EventSrc\FunctionNPCCommon.pytShopItemOnWeekäscCsH|tjkrd}n|tjkr0d}ndSt||gƒdS(Nii(RR[R^Rb(RRcRd((si.\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Event\EventSrc\FunctionNPCCommon.pytShopItemOnMonthës        cCsßg}tjƒ}x­t|jƒƒD]™}|j|ƒ}|jƒsLq%n|jƒ|krdq%ntj|j    ƒ}|j
|ƒ}|dkr˜q%nt j ||dƒ|j |j    ƒƒq%W|rÛt||tƒndS(Ni(R0R1R2R3R4R5tGetRefreshTypeR R6R7R8RTRURLRFR(RtonEventTypeListt syncIndexListRARBRCRDRE((si.\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Event\EventSrc\FunctionNPCCommon.pyRbõs"   cCsßg}tjƒ}x­t|jƒƒD]™}|j|ƒ}|jƒsLq%n|jƒ|krdq%ntj|j    ƒ}|j
|ƒ}|dkr˜q%nt j ||dƒ|j |j    ƒƒq%W|rÛt||tƒndS(Ni(R0R1R2R3R4R5t GetShopTypeR R6R7R8RTRURLRFR(Rt shopTypeListRkRARBRCRDRE((si.\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Event\EventSrc\FunctionNPCCommon.pytResetShopItemBuyCountByShopType    s"   c    CsÚtjdidd6tƒ}|s&dSttjƒƒ}g}x‚|D]z}|jƒ}||krE||krE|jƒ}tj|t    j
||ƒ|j |ƒt j d||jƒƒqEqEW|rÖt|ƒndS(NtStoreitShopTypesÉñÃØÏÞ¹ºÉÌÆ·%s ¿ªÂô(R0tGetIpyGameDataByConditionRRJttimet
GetLimitLVR7RTRUR tDef_PDict_ShopItemStartTimeRLRtDebugLogRW(    RtbefLVtaftLVt ipyDataListtcurTimet syncGoodsListtipyDatatlimitLVtgoodsID((si.\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Event\EventSrc\FunctionNPCCommon.pytMysticalShopOpens    ! cCstjƒ}g|_tjdidd6tƒ}ttjƒƒ}x|D]•}|jƒ}|j    t
j |ƒ}|s~qJn|||j ƒkr±t j|t
j |dƒqJtjƒ}||_||_|jj|ƒqJW|jsðdSt|jƒ|_tj||ƒdS(NRoiRpi(R,ttagMCMysticalShopTimeInfot ShopTimeListR0RqRRJRrR7R8R Rtt GetLimitValueRTRUttagMCMysticalShopTimetGoodsIDt    StartTimeRLR9R:R;R<(RtpackDataRxRyR{R}t    startTimet    goodsTime((si.\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Event\EventSrc\FunctionNPCCommon.pyRW/s(                    c     Cs¶|j}|jƒjtjƒ}||jƒkr7dS|j|ƒ}| sY|jƒr]dS|jƒ}tj    |ƒ}|j
tj |j ƒ||j ƒƒs¼tj|dtj gƒdSt||ƒ\}}    t|ƒ|}|     sï| ródSi|j ƒtj6}
tj||    |tj|
ƒs+dS|jtj |ddtigƒt|jtjƒƒ} | jt|dƒdƒ} | dkr–d} ntj|tjt| ƒƒdS(NtGeRen_chenxin_676165teventt BuyItemBackitt0(tIndextGetItemManagertGetPackRt
rptRecycletGetCounttGetAttIsEmptyt ItemControlertPlayerItemControlert CanPutInItemtrptItemt GetItemTypeIDt    GetIsBindRTt
NotifyCodet__GetItemSellPriceRJR tDef_Cost_Reason_SonKeytPayMoneytDef_Cost_BuyItemBackt    PutInItemtFalsetstrR8tDef_Player_Dict_DelPackIndextreplaceRU( Rt
clientPackRtindextbackPacktcurItemt realPutCountt itemControlt    itemPricet    priceTypetinfoDictt
itemIndexs((si.\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Event\EventSrc\FunctionNPCCommon.pyRŠKs:          "     c/ Cs    tjƒ}|jƒ}|dkr(dS|jƒ}|s>dStjd|ƒ}|sZdS|jƒ}|jƒ}|dkrltj    j
t j iƒ}|j
t j dƒ}    |    sÏtjd|    |jƒƒdStj|j
t jdƒ|j
t jdƒƒ}
|
s    dS|    t|
ƒkr%|
dn |
|    d} || krItjd|    || |
f|jƒƒdSnÝ|dkrItj    j
t jiƒ}|j
t j dƒ}    |    sÉtjd|    |jƒƒdStj|j
t jdƒ|j
t jdƒ|    ƒ}
|
sdS|
d} || krItjd    |    || |
f|jƒƒdSn|jƒ} | rq|jƒ| krqdS|jƒ} |jƒ}d}| s›|rU| s­dg} n|s¿dg}nt| ƒt|ƒkrètjd
ƒdS|jƒ}d}x4t| ƒD]&\}}||kr#Pn||}qW|dkrUtjd |ƒdSnd}tj |}|dkrò|j!|ƒ}t"d||ƒ}|dkr½tjd ||fƒdS||kròtjd ||||fƒ|}qòn|j#ƒ}|dkrt$||ƒ}n|j%ƒ|j&ƒ|j'ƒ}}}|j(ƒ}|j)ƒ|j*ƒ}}||9}|j+ƒ}|j,ƒ}g}|rÄt-|||ƒ} |j.| |||gƒnxC|D];\}!}"}#t-||!|ƒ} |j.| |"||#gƒqËW|s.tj/d|||fƒdSd}$i}%x½t|ƒD]¯\}}&|&d}|&d}'tj0ƒj1|ƒ}(|(stj/d||fƒdStj2|(j3ƒƒ})t4j5|)|(|'ƒ}*|%j
|)dƒ|*|%|)<|dkrG|}$qGqGW|$sdStjd|||||$|%f|jƒƒ|j6ƒ}+t7},xu|%j8ƒD]g\})}*|*t9j:||)|*ƒkrOt;},|+r†Pq¶|j<|tj=ƒt>j?|d|)gƒdSqOqOW|,rÌ|+rÌ|+nd}-t@||||$|jAƒƒrtjd|||jAƒf|jƒƒdSt>jB|||ƒsI|j<|tjCƒdS|dkræ|jDtjEƒdkr‚tjd|ƒdSd|||||$||-g}.tjFƒjG|jHƒddd|.t|.ƒƒ|jItjEdƒdStJ|||||$||-|ƒdS(NiRoisÏÞÊ±ÌØ»Ý·Ç»î¶¯ÖУ¡state=%siÿÿÿÿsOÏÞÊ±ÌØ»Ý·Ç»î¶¯ÖеÄÉ̵êÀàÐÍ£¡state=%s,shopType=%s,actShopType=%s,shopTypeList=%sisÏÞʱÇÀ¹º·Ç»î¶¯ÖУ¡state=%ssOÏÞʱÇÀ¹º·Ç»î¶¯ÖеÄÉ̵êÀàÐÍ£¡state=%s,shopType=%s,actShopType=%s,shopTypeList=%ss)    ¹ºÂòÎïÆ·LimitVIPLV  LimitCnt ³¤¶È²»Í¬s    vip%s²ÅÄܹºÂòs6BuyShopItem ½ñÈÕ¹ºÂò´ÎÊýÒÑÂú£¡shopType=%s,itemIndex=%ssQBuyShopItem ÐÞÕý¹ºÂò´ÎÊý£¡shopType=%s,itemIndex=%s,clientBuyCount=%s,canBuyCnt=%ss@Store shop item error! shopType=%s,totalItemList=%s,itemPrice=%ss,Store shop item error! shopType=%s,itemID=%ssh¹ºÂòÎïÆ·: shopType=%s,itemIndex=%s,clientBuyCount=%s,totalItemList=%s,mainItemID=%s,needPackSpaceDict=%sRˆR‹sAStore shop item buy limit! shopType=%s,itemIndex=%s,limitValue=%ss1È«·þ¹ºÂò´ÎÊýÒѾ­ÔÚ²éѯÖÐ, ²»Öظ´²éѯ itemIndex=%ss%stGetStoreServerBuyCnt(KRtIPY_CBuyItemListtGetBuyItemIndext GetBuyCountR0tGetIpyGameDataRltGetOperationActionShopt
PyGameDatatg_operationActionDicttgetRtOperationActionName_SpringSalet ActKey_StateRRut GetPlayerIDtPlayerSpringSaletGetShopTypeListt ActKey_CfgIDtActKey_DayIndexR9tOperationActionName_FlashSaletPlayerFlashSaleRstGetLVt GetLimitVIPLVR5tLogtGetVIPLvt    enumerateR R6R8tmaxtGetServerLimitCnttmint    GetItemIDt
GetItemCntR™t GetItemListExt GetMoneyTypet GetMoneyNumtGetJobt
GetJobItemt__GetShopJobItemRLtErrLogR#tGetItemByTypeIDtGetItemPackTypetGetTypeR”tGetItemNeedPackCountt
GetMailKeyR titemst
ItemCommontGetItemPackSpaceRt
ShopResultt
tsrNoPlaceRTRštCheckBuyItemLimitExRt    HaveMoneyt
tsrNoMoneyt GetDictByKeytDef_PlayerKey_StoreQueryStateRtGameServer_QueryPlayerResultR7R
tDoBuyStoreItem(/RRt buyItemListR@tclientBuyCountR{tshopTypetoperationActionShopTypetactInfotstateRmt actShopTypeR|tLimitVIPLVListt LimitCntListt limitBuyCnttcurVIPlvRBtviplvRERDt    canBuyCnttserverLimitCnttitemIDt    itemCounttisBindt
itemListExR«Rªtjobt jobItemListt totalItemListt    jobItemIDtitemIDExt itemCountExtisBindExt
mainItemIDtneedPackSpaceDicttitemInfotitemCntR§tpackTypet    needSpacetmailKeyt
isLackPackt sendMailKeytcmdStr((si.\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Event\EventSrc\FunctionNPCCommon.pytBuyItem{s       0*      3
                          & 
 
 
      #        cCså|stjd|ƒ}n|jƒ|jƒ}}    |    |9}    |jƒ}
tj||ƒ} i|d6|d6|
d6|d6|tj6} tj    |||    tj
| |ƒtj||ƒ} |dkr tj |}|j |ƒ}tj ||||ƒt||gƒni|
d6|d6|d6|    d6|d6| d    6| d
6}|tjgk}tj|ƒ}xö|D]î\}}}tj|||ƒ}|sšqjn|jƒ}|søtj|jƒƒ}|j||d tj||gƒs|jƒqjqn
|jƒtj|||ƒ|jƒrj||krjtjd|jƒ|jƒ||gƒqjqjW|r‡tj||j ƒg|d |ƒntj!||
ƒt"|||ƒ|tj#d diƒj$ƒkrát%j&|tj'|ƒndS(NRot TotalItemListtClientBuyCountRpt ShopItemIndexit    ItemPricet    MoneyTypet BeforeMoneyt
AfterMoneyR‰tdetailtCeremonyFirePartyi((R0R²RËRÌRlRTtGetMoneyR RœRtDef_Cost_BuyStoreItemR6R8RURFRtTYPE_Price_Silver_MoneyR”R•tGetOutPutItemObjt GetUserDataRÒRÓRŸtItemGive_BuyItemtClearRtEventRespons_BuyItemt GetNotifyMarkt WorldNotifytGetNamet SendMailByKeyR7tEventRespons_ShopBuytSyncShoppingResulttGetFuncEvalCfgtvaluestPlayerFairyCeremonytAddFCPartyActionCnttDef_PPAct_Fireworks(RR@RãRöRûRëRR{R«RªRät beforeMoneyR¬t
afterMoneyRDREtdataDictt isForceEventR©RðRñRòt
curItemObjtuserDataRÿ((si.\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Event\EventSrc\FunctionNPCCommon.pyRá sR
    $
    
/%!cCs™x’|D]Š}t|ƒttgkr@tjd||fƒ|S||kr|dksj|t|ƒkr…tjd||fƒ|S||dSqW|S(Ns3É̳ÇÖ°ÒµÎïÆ·×é¸ñʽ´íÎó!shopItemID=%s,jobItemList=%sis>É̳ÇÖ°ÒµÎïÆ·ÅäÖôíÎó,ûÓиÃÖ°Òµ¶ÔÓ¦ÎïÆ·ID!shopItemID=%s,job=%si(ttypetlistttupleRRÐR9(RôRðRõt jobItemIDList((si.\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Event\EventSrc\FunctionNPCCommon.pyRÏUs  cCs2tjƒ}||_||_tj||ƒdS(N(R,ttagMCShoppingResultRHtItemCntR;R<(RR@Rþt
resultInfo((si.\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Event\EventSrc\FunctionNPCCommon.pyRbs
         c    CsP|dkrtj||ƒ S|d krv|jƒdkr?tS|jƒ}|dkrl|jtjƒ}n||kS|d kr¨tj    ƒj
t j ƒd}||kS|t jddiƒjƒkrÚtj||ƒ S|tt jd    ƒƒkrt||ƒ S|d
krL|jtj|ƒ}ttjƒƒ}| pK|||kStS( Niii    i
iiiRtSuperGiftTimeListi(ii    i
(i(t
PlayerRunetGetIsOpenByRuneIDt GetFamilyIDRt GetFamilyLVR8R tDef_Player_Dict_FamilyLVRR_R`RRaR0RRRtIsCanBuyFireworkstdicttCheckSuperGiftBuyRtRJRrR (    Rt    shopNPCIDR@t    curItemIDt
limitValuet curFamilyLVReR†Ry((si.\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Event\EventSrc\FunctionNPCCommon.pyRÛms*    
 
! cCs€tj|tjƒsdStjƒjtjƒd}|tj    dƒkrNdStj    ddƒ}t
j d|j ƒg|ƒdS(NiR]it    SellMail1( t GameFuncCommt GetFuncCanUseRtGameFuncID_OSSailRR_R`RaR0RRTRR7(RRet addItemList((si.\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Event\EventSrc\FunctionNPCCommon.pyR]¡scCsþttjƒƒ}|r–|jtjƒ}|s4dStjdƒ}tg|D]}|d^qMƒ}|||dkrútj    |tjdƒqúnd|jtj
ƒr¬dStj    |tj|ƒtjddƒ}tj d|j ƒg|ƒt |ƒtS(NR/ii€Qiit    SellMail2(RJRrR8R tDef_PDict_SuperGiftStartTimeR0RRÅRTRURVRR7RXR(RtisOndayRyR†tsuperGiftTimeListtinfotmaxDayR@((si.\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Event\EventSrc\FunctionNPCCommon.pyR\­s #
cCsE|jtjƒ}|sdStjƒ}||_tj||ƒdS(N(R8R RBR,ttagMCSuperGiftInfoR„R;R<(RR†R…((si.\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Event\EventSrc\FunctionNPCCommon.pyRXÃs     cCs{|jtjƒ}|sdSttjdƒƒ}|j|dƒ}|sMdSttjƒƒ}||d|krwdSt    S(NR/ii€Q(
R8R RBR6R0RR¶RJRrR(RtgiftIDR†tsuperGiftTimeDictttotalDayRy((si.\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Event\EventSrc\FunctionNPCCommon.pyR7ËscCsVd}|jtjƒ}|s%tƒSt||ƒr8|Stjd||jƒƒ|S(Niÿÿÿÿs.GetCurStoreItemList:trade tag NPC not match:%s(RÞR R RtCheckTradeTagNPCRRÐR¹(RRR)((si.\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Event\EventSrc\FunctionNPCCommon.pytGetCurTradeTagNPCÞs  cCsd|jƒ}|stS|jƒtjkr/tStjƒj|jƒƒ}|j    ƒ|kr`tSt
S(N( RR RRRRRRRR    R(RR)RR((si.\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Event\EventSrc\FunctionNPCCommon.pyRKõs cCsCtjƒ}|jƒ}|jƒ}tj}t|||g|ƒS(N(RtIPY_CPlayerSellItemt GetPackTypet GetItemIndexR tDef_ShopType_NpcShopt SellPackItem(RRtsendDataRÿR@Rä((si.\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Event\EventSrc\FunctionNPCCommon.pytSellItem2s
       cCsotjƒj|ƒ}|j}|j}|s1dStj}t||||ƒ}|rk|jt    j
dƒndS(Ni( RRRtPackTypeRHR RPRQtSync_MakeItemAnswerRtDef_mitKeySell(R¥R(RRRÿt ItemIndexListRätisOk((si.\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Event\EventSrc\FunctionNPCCommon.pytOnSellManyItemDs            c
CsRd}|jƒj|ƒ}|dkr+tSt}ttjtjƒ}x·|D]¯}|j|ƒ}    t    ||    ƒswqMnt
}|    j ƒ}
t ||    ƒ\} } t | ƒ|
} || 7}|    jƒ|ko×tj|    ƒ }tj||    |
ttjd|ƒqMW|s
tSi}tj|tj|tj|tƒtj|dtj|gƒt
S(Nit    isForceDRt
GetMoney01(RŽRRR trangeR tDef_ItemType_retWeapontDef_ItemType_retNeckR’t__CheckItemSellRR‘R›RJRÓR”tItemNotNeedRecordR×tDelItemtItemDel_SellPackItemRTt    GiveMoneyRRtDef_GiveMoney_SellPackItemRš(RRÿR=RättotalSellPriceR¦t    hasSellOKtnotForceRecordEquipTypeListR@R§t curItemCounttcurItemSellPricetcurItemSellTypetcurAllItemSellPriceRZt addDataDict((si.\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Event\EventSrc\FunctionNPCCommon.pyRQXs.   
 
"&"cCsûdSt|jtjƒƒ}|jƒjtjƒ}tj    |tjƒ}|dkrt
|dƒd}|j |ƒ}|j ƒ|d}n+|j t|dƒdƒ}|j |ƒ}d||df}|j|ƒtj|tjt
|ƒƒdS(NiÿÿÿÿiiR‹s%s%s(R¡R8R R¢RŽRRRR×tGetEmptyIndexInPackRJR’RR£tPutInRTRU(RR§R­R¦t
emptyIndextitem((si.\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Event\EventSrc\FunctionNPCCommon.pytPutItemInBuyBackPack‡s 
  cCsÖtj|ƒs#tj|dƒdStj|ƒrFtj|dƒdS|jƒdkrltj|dƒdSt||ƒ\}}t|ƒ|j    ƒ}| s¥| r¹tj|dƒdStj
|||ƒsÒdSt S(NtGeRen_chenxin_644055titemuse_chenxin_31379itGeRen_lhs_272921( R×tCheckItemCanUseRTRšR”t IsEventItemt
GetCanSellR›RJR‘t CanGiveMoneyR(RR§RªR«((si.\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Event\EventSrc\FunctionNPCCommon.pyR_¤s"cCstj}|jƒ}||fS(N(RRtGetSilverPrice(RR§R«t curItemPrice((si.\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Event\EventSrc\FunctionNPCCommon.pyR›Çs     cCs-|jƒtjkr)tj|dƒtStS(NtGeRen_chenxin_740826(tGetPlayerActionR tDef_Player_DoEvent_StateRTRšR R(R((si.\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Event\EventSrc\FunctionNPCCommon.pytCheckPlayerCanStateEventóscCs|jƒtjkS(N(RÓR tDef_Compose_Can_Put_List(R§((si.\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Event\EventSrc\FunctionNPCCommon.pyt__CheckItemCanPutInComposePacksc    Cs’t||||ƒ}|dkr%dStj|ƒ}|j||jƒ||jƒƒsrtj|d|gƒdStj    ||||||ƒdS(NRˆ(
t__GetBackPackOperateItemRR”R•R–R˜R™RTRštDragItem(    Rt srcBackpackt desBackPacktsrcIndext    destIndext putItemCountRtscrItemR©((si.\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Event\EventSrc\FunctionNPCCommon.pytBackpackOperates $cCsI|tjkrEt|ƒsEtjd|jƒ|jƒfƒtSntS(Ns+BackpackOperate ItemErr = %s, ItemType = %s(    R tDef_ComposePack_ListR€RRÐR˜RÓR R(RˆR„((si.\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Event\EventSrc\FunctionNPCCommon.pyt__CheckBackPackOperate$s
 #cCsŠ|tjks|tjkrBtjd||f|jƒƒdS|jƒj|ƒj|ƒ}tj    |ƒssdSt
||ƒs†dS|S(NsHPackItemExchange packErr, srcBackpack = %s,             desBackPack = %s( R tDef_BackpackOperate_ListRRÐR7RŽRR’R×RuR‹(RRƒR„R…Rˆ((si.\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Event\EventSrc\FunctionNPCCommon.pyR4scCsyt||||ƒ}|dkr%dS|jƒj|ƒj|ƒ}|dks[|jƒr_dStj||||ƒdS(N(RRRŽRR’t GetIsLockedR×tDoLogicSwitchItem(RRƒt destBackPackR…R†RRˆtdestItem((si.\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Event\EventSrc\FunctionNPCCommon.pytPackItemExchangeQs cCs}t|ƒ}xjtd|dƒD]V}||}||d}|j|ƒ}|dkre|||<q||c|7<qW|S(Niii(R9R\R¶R(t    moneyListt payMoneyDicttlengthR¥t    moneyTypetmoneytpayMoney((si.\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Event\EventSrc\FunctionNPCCommon.pytGetPayMoneyDictgs 
  cCs:x3|jƒD]%\}}tj|||ƒs tSq WtS(N(RÖRTRÜR R(RR“R•R–((si.\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Event\EventSrc\FunctionNPCCommon.pyt CheckPayMoney|s(?R,R;RRRR”R RTR×RR¿tChItemR0R0R=RRºR´trandomtmathRrRRRR+R RFR/RZRfRgRhRbRnR~RWRŠRRRáRÏRRÛR]R\RXR7RLRKRSRYRQRqR_R›R~R€R‰R‹RR‘R˜R™(((si.\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Event\EventSrc\FunctionNPCCommon.pyt<module>2sx                                     
    "                     
                    0    ¥ 5              4                     =            /        #    ,