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
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
<$õ[c@s ddlZddlZddlZddlZddlZddlZddlZddlZddlZddl    Z    ddl
Z
ddl Z ddl Z ddl Z ddlZddlZddlZddlZddlZedƒ\ZZZedƒ\ZZZZedƒ\ZZd„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-d„Z.d„Z/d„Z0e1d„Z2d„Z3d„Z4d„Z5d„Z6dS(iÿÿÿÿNiiicCs't||ƒs tjdƒdStjd|ƒ}tj|tjƒ}|t    }||krrt
j |dƒdSt ||t ƒs‰dS|t}|jƒdkrÄt
jd||jƒgƒn|jƒ}||jƒ|dg}t
jdd|ƒt||ƒtj||ƒt|ƒdS(Nsreturn can not Get GoldGift!!!sGoldGiftInfo_%stGeRen_chenxin_998371tiitGeRen_liubo_927007(t__CheckCanGetGiftt    GameWorldtDebugLogt ReadChConfigtGetEvalChConfigt
ItemCommontGetItemPackSpacet IPY_GameWorldtrptItemt Def_NeedSpacet PlayerControlt
NotifyCodet__GiveGoldGiftt Def_GiftInfotDef_NotifyMarktstript WorldNotifyt GetPlayerNametGetVIPLvt__UpdateLVAwardGetRecordtDataRecordPacktDR_GoldGiftGiveItemtSync_GoldGiftGetRecordInfo(t    curPlayertgiftNumt goldGiftInfot    packSpacet    needSpacet
notifyMarktvipLVt msgParamList((s^.\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Player\PlayerGoldGift.pytGetPlayerGoldGiftSs* 
 
 
cCsdS(N((R((s^.\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Player\PlayerGoldGift.pyR~sc
 
Cs‰t||ƒ}|stSxi|D]a}|t}|t}|t}d}t|ƒtkri|t}n|dkr{q n|tkr²tj    ||||t
j gt dt ƒq |t kr tjdƒjdt|ƒƒ}tjd|ƒ|stjd||fƒq nt|ƒdkrKtjd||t|ƒfƒq n|d}    t|ƒ|    d    <tj||    t dt ƒq q Wt S(
Nit showSysInfotAppointItemListt    ItemIndexs__GiveGoldGift itemData=%ss1__GiveGoldGift()itemType=%s,ItemIndex=%s not dataisA__GiveGoldGift()itemType=%s,ItemIndex=%s,recordCount=%s !=1 errortIsBind(t__GetGoldGiftInfoListtFalsetDef_InfoIndex_ItemTypetDef_InfoIndex_ItemCounttDef_InfoIndex_ItemIDtlentDef_InfoIndex_IsBindtDef_ItemType_CommonItemt ItemControlertGivePlayerItemR
R tTruetDef_ItemType_AppointItemt
PyMapTablet GetPyMapTablet    GetRecordtstrRRtErrLogtGivePlayerEquip(
RtgoldGiftInfoDicttgoldGiftInfoListtgiftInfotitemTypet    itemCounttitemIDtisBindtitemDatat itemDictData((s^.\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Player\PlayerGoldGift.pyR‰s8 
 
 
   + !    
 cCsGd}|jƒ}x*|jƒD]}||kr|}PqqW||S(N((tGetJobtkeys(RR9tinfoKeytjobtkey((s^.\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Player\PlayerGoldGift.pyR'¹s  cCsI|jtjdtjƒ}|d|>B}tj|tj|tjƒdS(Nii(tNomalDictGetPropertytChConfigtDef_PDict_GoldGiftGetRecordtDef_PDictType_GoldGiftR tNomalDictSetProperty(RRtcurValue((s^.\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Player\PlayerGoldGift.pyRÈs  
cCsÁtjdƒ}|dks-|t|ƒkrBtjd|ƒtS|jƒ}tjƒ|}|||kr”tj    dd||||fƒtS|j
t j dt j ƒ}|td|ƒ@ S(NtNeedGoldCntListis)__CheckCanGetGift() error£ºnot giftNum=%ss-__CheckCanGetGift() curChangeGold not enough s$giftNum=%s,needGold=%s,changeGold=%si(RRR,RR7R(tGetChangeCoinPointTotalt
PlayerCoint GetCoinRateRRGRHRIRJtpow(RRtneedGoldCntListt curChangeCoint curChangeGoldRL((s^.\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Player\PlayerGoldGift.pyRÖs      cCsr|jƒrdStjddƒ}|s,dStj|tj|ƒtj|tjtt    j    ƒƒƒt
|ƒdS(Nt    FirstGoldi( RNt IpyGameDataPYt
GetFuncCfgR RKRHtDef_PDict_FirstGoldRemainTimetDef_PDict_FirstGoldTipStartTimetintttimetSync_FirstGoldTime(Rt showSysTime((s^.\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Player\PlayerGoldGift.pytDoFirstGoldOpenïs "
cCsÞtj|ƒrdS|jtjƒ}|s/dS|jƒrjtj|tjdƒtj|tjdƒnpt    t
j
ƒƒ}|jtjƒ}t d|||ƒ}tj|tj|ƒ|sÚtj|tjdƒndS(Ni( t    PlayerTJGtGetIsTJGRGRHRXRNR RKRYRZR[tmax(Rt
remainTimetcurTimet    startTime((s^.\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Player\PlayerGoldGift.pytUpdateFirstGoldTimeüs cCsO|jtjƒ}|sdStjƒ}|jƒ||_tj||ƒdS(N(    RGRHRXtChPyNetSendPackttagMCFirstGoldTimetCleartFirstGoldRemainTimet NetPackCommont SendFakePack(RR]tsendPack((s^.\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Player\PlayerGoldGift.pyR\s 
    c
Cs²|jtjƒ}|r2tjd|jƒƒdS|jƒsXtjd|jƒƒdStjddƒ}t    |j
ƒƒ}||kr¦tj d||jƒƒdS||}|sºdSt |ƒ}t j|tj|ƒ}||krþtj|dƒdStj|tjdƒx6|D].\}}}    tj||||    tjgƒqWt |ƒdkr”tjd    d
|jƒ|d    d    |dd    gƒntj|d ƒt|ƒdS( sÁìÈ¡Íæ¼ÒÊ׳佱Àø
    sÒѾ­ÁìÈ¡¹ýÊ׳佱Àø£¡NsûÓгäÖµ¹ý£¬ÎÞ·¨ÁìÈ¡Ê׳佱Àø!RUis#ûÓÐÅäÖøÃÖ°Òµ¶ÔÓ¦µÄÊ׳佱Àø!job=%sRiitFirstPayReward1t FirstGoldGift(RGRHtDef_PDict_GoldGiftFirstRecordRRt GetPlayerIDRNRVtGetFuncEvalCfgR6RBR7R,RR    R
R R RRKR/R0RRRRtSync_FirstGoldInfo(
RtisGettfirstGoldRewardDicttjobStrtrewardItemListRRR>R=R?((s^.\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Player\PlayerGoldGift.pytGetPlayerGoldGiftFirsts8  
  #5
cCstj|tjdƒdS(Ni(R RKRHtDef_PDict_DailyChargeState(R((s^.\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Player\PlayerGoldGift.pytOnDayNscCsOt|ƒt|ƒ|jtjƒrKtj|tjtt    j    ƒƒƒndS(N(
RrR\RGRHRXR RKRYRZR[(R((s^.\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Player\PlayerGoldGift.pytOnLoginls
 
 
%cCsœ|jtjƒ}||}tj|tj|ƒ|jtjdƒ}|r|jtjdƒ}|dkrt|dƒqnt|ƒt    |t
ƒdS(Nii( RGRHtDef_PDict_DailyGoldChargeCntR RKtDef_PDict_DailyGoldChargeStatet$Def_PDict_DailyGoldChargePrizeRecordtUpdateDailyGoldRecordt__GiveGoldGiftByMailtSync_SingleGoldGiftInfoR1(RtaddGoldt dailyGoldCnttupdDailyGoldCnttdailyGoldStatetdailyGoldRecord((s^.\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Player\PlayerGoldGift.pytOnPlayerChargeGoldys
 
 cCsŽtƒ}tjd|||t|ƒfƒ|sCtjdƒdS|d}||krntjd|ƒdS|d}|dkr•t||ƒdS|dkr¥dS|t|ƒkrÌtjd|ƒdS||}|\}}    |jtj    ƒ}
|
|krtjd    ||
fƒdS|jtj
ƒ} tj | |ƒ} | dkr`tjd
| ƒdS|t|    ƒkr‡tjd |ƒdSt j |tjƒ} | s³tjd ƒdStj| ||ƒ}tj|tj
|ƒ|    |d\}}}tj||||tjgtƒ}|s#dSi|d 6|d6|d6|d6|d6|d6}tj|d|ƒt|ƒtjd| ||fƒdS(Ns>µ±ÈÕ³äÖµ½±ÀøÁì½± (µµ%s - %s) giftType=%s,findSingleGoldGift=%ss    ½ñÈÕδÅäÖóäÖµµ¥Ñ¡Àñ°ü!is(    ·Çµ±ÈÕ³äÖµÀñ°üÀàÐÍ£¡todayGiftType=%siiisCµ¥ÈÕ³äÖµµ¥Ñ¡Àñ°üÅäÖôíÎóSingleGoldGift.txt ²»´æÔڸý±Àøµµ!giftLV=%ss<    ½ñÈÕ³äÖµ¶î¶ÈδÂú×㣬ÎÞ·¨Áì½±!needGold=%s,dailyGoldCnt=%ss%    ½ñÈÕÒÑÁìÈ¡!singleGoldGiftIndex=%ssGµ¥ÈÕ³äÖµµ¥Ñ¡Àñ°üÅäÖôíÎóSingleGoldGift.txt giftIndex=%s ²»ÔÚ½±ÀøÁбíÀï!s    ±³°üÒÑÂú£¡tSingleGiftIndextItemIDt    ItemCountR&t SingleGiftLVtGoldGiftAwardRecordtSingleGoldGifts+    awardRecord=%s,updRecord=%s,infoDict=%s(tGetTodaySingleGoldGiftInfoRRR6t__GetUnlimitedGoldGiftR,R7RGRHR{tDef_PDict_SingleGoldGiftIndextGetDataByDigitPlaceRtCheckPackHasSpaceR
R tChangeDataByDigitPlaceR RKR/R0R1RRR€(Rt    giftIndextgiftLVtgiftTypetfindSingleGoldGiftt todayGiftTypeR:tcurGoldGiftInfotneedGoldtchooseGiftListR‚tgoldGiftAwardRecordtsingleGoldGiftIndexthasSpacetupdGoldGiftRecordR>R=R?tisOKtinfoDict((s^.\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Player\PlayerGoldGift.pytGetSingleGoldGift–sd         
 
 
        $
cCsš|jtjƒ}|jtjƒ}|d}|d}||}|dkr`t||ƒ}ntjd|||||fƒ|dkr¡tjd|ƒdS||krÂtjd|ƒdS||}tj|t    j
ƒ}|d}    |    |kr t j |dƒdS|}
|d} x| D]y\} } }tj ƒ}|j| ƒ}|dkrvtjd    | |jƒƒdS|jƒ}|| }t||
ƒ}
q"W||
}t j|tj|ƒ|d} d
}xa| D]Y\} } }tj|| | |
|t    j
t    jgtƒ}d tt|ƒƒ|f}qÖWi|d 6t| ƒd 6|d6|d6|
d6}tj|d|ƒt|ƒtjd||
fƒdS(NiisZÁìÈ¡µ±ÈÕ³äÖµÎÞÏÞÁìÈ¡Àñ°ü£ºdailyGoldCnt=%s / per(%s) = canCnt(%s),hadGetCnt=%s,MaxCntCfg=%ss    ¿ÉÁìÈ¡´ÎÊý=%s,²»¿ÉÁìÈ¡!s    ÒÑ´ïµ½×î´óÁìÈ¡´ÎÊý!%siRis.ÁìÈ¡µ±ÈÕ³äÖµÎÞÏÞÁìÈ¡Àñ°ü£¬ÎïÆ·IDÊý¾Ý´íÎó£¡(%s)Rs%s%stisOKStrt awardItemListt DailyGoldCntt TodayGetCntt    CurGetCnttUnlimitedGoldGifts;    ÁìÈ¡³äÖµÎÞÏÞÁìÈ¡Àñ°ü½±ÀøOK£¡TodayGetCnt=%s,CurGetCnt=%s(RGRHR{tDef_PDict_UnlimitedGoldGiftCnttminRRRR    R
R R Rt GetGameDatatGetItemByTypeIDtNoneR7Rpt GetPackCountRKR/R0t rptAnyWhereR1R6RZRtDR_FuncGiveItemtSync_UnlimitedGoldGiftRecord(RR:R‚t    hadGetCntt    maxGetCntt perNeedGoldt curCanGetCnttgetCntRRt    curGetCntR£R>titemCntR?tgameDatat curItemDatat maxPackCounttperSpaceCanGetCntt    updGetCntR¢RŸt addDataDict((s^.\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Player\PlayerGoldGift.pyRŽàs\
 
 
       
 
 
 
 
 
 
cCsdS(N((R((s^.\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Player\PlayerGoldGift.pyR°,scCs˜|jƒ}tjƒ|}tjd|ƒ|dkr=dStjdƒ}|jƒ}x9t|ƒD]+\}}|d}|d}|d}    |d}
|d} |j    t
j dt
j ƒ} | t d|ƒ@rîtjd||fƒqen||krqentj|    |
| |g|ƒs$qen| t d|ƒB} tj|t
j | t
j ƒtjd    ||t|ƒ| fƒtj|d
||fƒqeWdS( NsÓʼþ·¢ËͳäÖµºÀÀñ£ºgoldTotal=%sitGoldGiftByMailiiiis,Óʼþ·¢ËͳäÖµºÀÀñ£ºÒÑ·¢Ë͹ý£¡i=%s,needGold=%ssCÓʼþ·¢ËͳäÖµºÀÀñ£ºi=%s,needGold=%s,giftItemList=%s,updMailRecord=%ssGoldGiftSendMail_%s_%s(RNRORPRRRRRpt    enumerateRGRHtDef_PDict_GoldGiftMailRecordRJRQR tSendMailRKR6RR(RtcoinPointTotalt    goldTotaltgoldGiftByMailListtplayerIDtiR;R™t giftItemListt    mailTitlet mailContenttgetDayst curMailRecordt updMailRecord((s^.\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Player\PlayerGoldGift.pyR5s:   
 
 
 
 
 
    cCsë|jtjdƒ}|dkr6tjd|ƒdStjdƒ}tj|t    j
ƒ}|t }||kr„t j |dƒdSt||tƒs›dS|t}|rÊt jd||jƒgƒnt|dƒtj|dƒdS(NiisÌìÌìÊ׳䲻¿ÉÁ죡µ±Ç°×´Ì¬=%stGoldGiftInfoFirstDailyRitdailyFirstGoldPrize(RGRHR}RRRRRR    R
R R R RRRRRRR~RR(RR…tdailyFirstGoldPrizeInfoRRR((s^.\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Player\PlayerGoldGift.pytGetPlayerDailyGoldChargeGift`s$ 
 
 cCsdS(N((Rtrecord((s^.\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Player\PlayerGoldGift.pyR~„scCsTtjƒ}|jƒ|jtjƒ|_|jtjƒ|_t    j
||ƒdS(N( RfttagMCFirstGoldInfoRhRGRHRotFirstGoldRewardStatetDef_PDict_FirstGoldTryt FirstGoldTryRjRk(RRl((s^.\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Player\PlayerGoldGift.pyRr‰s  
cCsdS(N((Rt isCheckTime((s^.\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Player\PlayerGoldGift.pyR€•s c Csætjƒjtjƒ}tjdƒ}tjƒ}tjƒ}|j    ƒd}d}xŠ|D]‚}|d}|r¯|d}|d}    ||ko|    knr¯|}Pq¯n|d}
||
kr\|tj kr\|}Pq\q\W|S(NRŒii( Rt GetGameWorldtGetGameWorldDictByKeyt ShareDefinetDef_Notify_WorldKey_ServerDayRRtGetCurrentDataTimeStrtGetCurrentTimetweekdayR¬tDef_OSC_ValidDay( t openServerDaytsingleGoldGiftListtcurDataTimeStrRcRÝR–R;t dateTimeInfoRdtendTimet weekDayInfo((s^.\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Player\PlayerGoldGift.pyR§s&   
 
 
 
c CsÅtjƒj|ƒ}|jtjƒdkr1dStjddiƒ}|j|j    ƒdƒ}|shdSt
j }|j ƒj tjƒ}|j|ƒ}tj|ƒrMtj|tjƒ}    |    dkrtj|ƒ}
tjd|jƒg|
gƒtj||dtƒqMtj|ƒj||    ƒ} | sMtjd|jƒƒdSntj|ddƒ} t j!|| ||ƒr“tj"|tjdƒn$|j#ƒtjd||jƒƒt$|ƒdS(    NitFirstGoldTryItemiiÿÿÿÿRs#    ÊÔÓÃÊ׳äÎäÆ÷ Ð¶ÏÂÔ­×°±¸Ê§°Ü£¡£¡is)    ÊÔÓÃÊ׳äÎäÆ÷ ÊÔ´©Ê§°Ü£¡£¡tryItemID=%s(%RtGetPlayerManagertGetPlayerByIndexRGRHRÔRVRqtgetRBRÙt    retWeapontGetItemManagertGetPackR
trptEquiptGetAtRtCheckItemCanUseR/tGetItemPackSpaceIndexR tGetMailItemDictR t SendMailByKeytGetIDtDelItemR(tPlayerItemControlert UnEquipItemtLogtGetOutPutItemObjtChEquiptDoPlayerEquipItemRKtclearRr( tindext
clientDatattickRt tryItemDictt    tryItemIDt
equipPlacetcurPacktcurItemt
spaceIndextitemObjtresultttryItem((s^.\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Player\PlayerGoldGift.pytOnTryFirstGoldItemÎs6     
 
c    Csyt}tj|ƒ}xÂtjtjgD]®}|jƒj|ƒ}xtd|j    ƒƒD]y}|j
|ƒ}t j |ƒsƒqYn|j ƒtjkržqYnt j|ƒs³qYn|j|tƒsËqYnt}PqYWq(W|sutjddiƒ}|j|jƒdƒ}|sdStjd||jƒƒtj||dttjgtƒsutjd||jƒƒqundS(NiRåis6Ê׳äÊÔÓÃÎïÆ·¹ýÆÚÁË ±³°ü²Ö¿âûÎäÆ÷ÔòËÍÒ»°ÑgiveItemID=%sisCÊ׳äÊÔÓÃÎïÆ·¹ýÆÚÁË ±³°ü²Ö¿âûÎäÆ÷ÔòËÍÒ»°Ñ Ã»¸ø³É¹¦£¡£¡giveItemID=%s(R(R/RôR
R t rptWarehouseRêRëtrangetGetCountRíRRît GetEquipPlaceRÙRétCheckItemCanUseByExpireTimetPlayerCanEquipItemR1RVRqRèRBRRRòR0(    Rt    haveEquiptplayerItemControlt    packIndexRRÆRt giveItemDictt
giveItemID((s^.\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Player\PlayerGoldGift.pytFirstGoldTryItemOutTimeñs2    $ cCsF|jtjƒdkrdStj|tjdƒtj|dƒdS(Nii(RGRHRxR RKtPlayerFamilyRedPackettCreatRedPacketByID(R((s^.\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Player\PlayerGoldGift.pytDayChargeRedPackAwards
(7RR
RR/RHRR RÙRRfRRjR3RORVR_RøR[tFunctionNPCCommonR    RR RR)R+R*R-R.R2R"RRR'RRR^ReR\RwRyRzR†R¡RŽR°RRÐR~RrR(R€RRRR(((s^.\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Player\PlayerGoldGift.pyt<module>%s\                       +         0                              3                 J    L            +    $             '    #