cehua-TT
2018-11-26 af0fb12700f599ce5cf3c1ca83590a1352fdc1f8
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
Íbû[c@sZddlZddlZddlZddlZddlZddlZddlZddlZddlZddl    Z    ddl
Z
ddl Z ddl Z ddl Z ddlZddlZd„Zd„Zd„Zd„Zd„Zd„Zd„Zd    „Zd
„Zd d ed „Zd „Zd„Zd„Zd„Zd dd„ZdS(iÿÿÿÿNcCsk|jtjƒ}|d}|d}|rg|ddd}tj|tj|ƒt|dtƒndS(Ni
ii(tNomalDictGetPropertytChConfigt Def_PDict_HelpBattleCheckInCountt PlayerControltNomalDictSetPropertytSyncCheckInStatetFalse(t    curPlayert checkInInfot checkInCountttodayIsCheckIn((s~E:\SnxxServerCode\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\GameWorldLogic\FBProcess\FBHelpBattle.pyt DoPlayerOnDay#s
 
cCs9|jtjƒ}|d}|r5t|dtƒndS(Ni
i(RRRRtTrue(RRR
((s~E:\SnxxServerCode\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\GameWorldLogic\FBProcess\FBHelpBattle.pyt DoPlayerLogin-s
 
cCs8tjƒ}||_t|ƒ|_tj||ƒdS(N(tChPyNetSendPackttagMCHelpBattleCheckInResulttIsOKtinttIsLogint NetPackCommont SendFakePack(Rt checkInStatetisLogint checkInPack((s~E:\SnxxServerCode\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\GameWorldLogic\FBProcess\FBHelpBattle.pyR4s
     cCsu|s
dS|d}|dkr3t|||ƒn|dkrRt|||ƒn|dkrqt|||ƒndS(NitCheckIntRefresht
HelpRecord(t__OnHelpBattleCheckInResultt__OnHelpBattleRefreshResultt__OnHelpBattleRecord(RtmsgListtticktcmd((s~E:\SnxxServerCode\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\GameWorldLogic\FBProcess\FBHelpBattle.pytGameServer_FBHelpBattleResult<s
   c    Cs®tjƒj|ƒ}|jtjƒ}|d}|d}|r[tjd|jƒƒdS|jƒ}t    d||gƒ}tjƒj
|j ƒddd|t |ƒƒdS(Ni
sµ±ÌìÒѵǼǣ¬²»ÐèÒªÖØ¸´µÇ¼Ç£¡Rit FBHelpBattle( t    GameWorldtGetPlayerManagertGetPlayerByIndexRRRtDebugLogt GetPlayerIDt GetFightPowertstrtGameServer_QueryPlayerResulttGetIDtlen(    tindext
clientDataRRRR    R
t
fightPowertmsgInfo((s~E:\SnxxServerCode\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\GameWorldLogic\FBProcess\FBHelpBattle.pytOnHelpBattleCheckInWs
 
 .c    CsŸ|\}}}}}|rb|ddd}tj|tj|ƒ|sbtj||tƒqbnt|dtƒtj    d|||||f|j
ƒƒdS(Nii
sMFBHelpBattleResult: %s,checkInCount=%s,fightPower=%s,isOK=%s,haveViewCache=%s( RRRRtPlayerViewCacheTubetUpdateGameServerPlayerCacheRRR#R&R'(    RRRR R    R/tisOKt haveViewCacheR((s~E:\SnxxServerCode\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\GameWorldLogic\FBProcess\FBHelpBattle.pyRds     c+    Csstjƒj|ƒ}|j}|j}|jƒ}tjƒ}tj|j    ƒƒ}tj
ƒ}    t j d||    ƒ}
|
sdSt jj|iƒ} t jddƒ} d} g}g}x| jƒD]s\}}|jtj|ƒ}|rú| d7} qÅ|jddƒsÅd|kr(|j|ƒq8|j|ƒqÅqÅW| | kr`tjd| |ƒdSi}|rO| | }|rátj|t|t|ƒƒƒ}|t|ƒ8}x1|D]&}| |}|jd    dƒ||<q´Wn|dkr|rx|| D]}d||<qþWn| t|ƒ| kr*tjd
| || f|ƒdSnÛ|| krstjd ||ƒdS| |}|jddƒrt jdd ƒ}tj|tj|ƒ}|sÃdSi|d 6|    d6dd6}x3|D](\}}tj |||tj!|ƒqåWn|jd    dƒ||<t jddƒ}|j"ƒ|j#ƒ}}x|j$ƒD]}|| krzqbn| |}|jddƒ} d|kr¹|d}!|d}"n%|
j%ƒ}!|
j&ƒ}"|j'|ƒ|
j(ƒ}#t)j*||ddƒ}$|$j"ƒ|$j#ƒ}%}&t+j,||%|&ƒ}'|'s<qbn|'j-ƒ}tjd|||!f|ƒ|j.tj||ƒ| d7} t+j/|'ƒ}(|(j0|!ƒt1|'|#| |"ƒt2j3ƒ})||)_4||)_t5j6||)ƒqbW| | krt7j8||ƒn|rot9d||    |gƒ}*tjƒj:|j-ƒddd|*t|*ƒƒtjd|*|j-ƒƒndS(NR"tHelpBattleCalliiit NeedGoldCalltNames*ÒѾ­ÕÙ»½ÂúÈËÊý£¡ÎÞ·¨ÔÙÕÙ»½£¡calledCount=%stRelationsOÎÞ·¨Ò»¼üÕÙ»½!ÈËÊý²»×ã! calledCount=%s,calledPlayerDict=%s,maxHelpPlayerCount=%ss-²»´æÔÚ¸ÃÖúÕ½Íæ¼Ò£¬ÎÞ·¨ÕÙ»½£¡calledPlayerID=%sitMapIDtlineIDtCalltTypetHelpBattleRobottJobt
FightPowertLVis6ÕÙ»½ÖúÕ½³É¹¦: calledPlayerID=%s,objID=%s,fightPower=%ss GameServer_QueryPlayerResult: %s(;R#R$R%t IsOneKeyCalltPlayerIDR't    GetGameFBtFBCommontGetRecordMapIDtGetMapIDtGetFBPropertyMarkt IpyGameDataPYtGetIpyGameDatat
PyGameDatatg_fbHelpBattlePlayerDicttgett
GetFuncCfgtitemstGetGameFBDictByKeyRtDef_FB_HelpBattleFBObjIDtappendtLogtrandomtsampletminR,tErrLogRt HaveMoneyExt ShareDefinetTYPE_Price_Gold_Paper_MoneytPayMoneytDef_Cost_FBHelpBattletGetPosXtGetPosYtkeystGetRobotFightPowert
GetRobotLVtpoptGetRobotSkillsDicttGameMaptGetEmptyPlaceInAreaExt    NPCCommont SummonMapNpcR+t SetGameFBDictt
NPCControltSetHelpBattleRobotRebornAttrt__DoGiveHelpBattleRobotSkillRttagMCHelpBattleCallResulttObjIDRRtFBLogictOnCallHelpBattleOKR)R*(+R-R.RRt isOneKeyCalltcalledPlayerIDtplayerIDtgameFBtmapIDt
funcLineIDtipyDatathelpBattlePlayerDicttmaxHelpPlayerCountt calledCounttfreePlayerIDListthelpNPCRobotIDListt helpPlayerIDthelpPlayerInfoDicttobjIDtcalledPlayerDictt    lackCountt
randIDListtrandIDtrobotIDt goldCallCostt costMoneyListtinfoDictt    moneyTypetmoneyNumt
robotNPCIDtposXtposYtjobR/tnpcLVt jobSkillDicttpositiontnpcPosXtnpcPosYt helpBattleNPCt
npcControltcallResultPackR0((s~E:\SnxxServerCode\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\GameWorldLogic\FBProcess\FBHelpBattle.pytOnHelpBattleCall~s¸              
! 
     
# 
 
 
           .c
CsÆ|jƒ}||krdS||}g}x[|jƒD]M\}}||krWq9nt|tƒrv|j|ƒq9|t|ƒ7}q9Wtjd|||fƒx|D]}    |j|    ƒq«WdS(Ns)    ¸øÖúÕ½»úÆ÷È˼¼ÄÜ: job=%s,npcLV=%s, %s(    tGetSkillManagerROt
isinstanceRRRtlistR#R&tLearnSkillByID(
tcurNPCRŽRŒRt skillManagert skillInfoDictt skillIDListt    skillInfotneedLVtskillID((s~E:\SnxxServerCode\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\GameWorldLogic\FBProcess\FBHelpBattle.pyRkós  
  cCs)tjƒj|ƒ}t|dtƒdS(NtisClientRefresh(R#R$R%t&SendGameServer_RefreshHelpBattlePlayerR (R-R.RR((s~E:\SnxxServerCode\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\GameWorldLogic\FBProcess\FBHelpBattle.pytOnHelpBattleRefresh sicCs |stj|jƒƒ}n|s3tjƒ}ntjd||ƒ}|sRdS|jƒ}tjƒ}g}i}|rÑ|j    |t
j ƒ}    tj ddƒ}
tj ddƒ} |    |
| krÝtj d|    |ƒdS|    |
kr-tj ddƒ} tj|tj| ƒ}|s-tj dƒdSntjj|iƒ} x÷| jƒD]{\}}|jt
j|ƒ}|s}qOn|jt
j|ƒ}|jddƒ}|jd    d
ƒ}|||g||<qOWnk|j|t
j d
ƒ|jt
j|jƒƒ|jt
j|jƒƒtj d |jƒ|jƒfƒtd |||||gƒ}tj ƒj!|j"ƒd
d
d|t#|ƒƒtj$d ||ƒdS(NR"tHelpBattleRefreshiis.³¬¹ýË¢ÐÂÖúÕ½Áбí´ÎÊý£¡ÎÞ·¨Ë¢ÐÂ!refreshCount=%sis»õ±Ò²»×ã!ÎÞ·¨Ë¢ÐÂÖúÕ½£¡R?R9isÉèÖø±±¾Õ½Á¦=%s,±£µ×É˺¦=%sRs)SendGameServer_RefreshHelpBattlePlayer %s(%RERFRGRHRIRJR'R#RDtGetPlayerGameFBDictByKeyRtFBPD_HelpBattleRefreshCountRNR&RRXRYRZRKRLRMRORPRQtDef_FB_HelpBattleGoldCalltSetPlayerGameFBDictRhtFBPD_HelpBattleFBFightPowertGetFightPowerMintFBPD_HelpBattleFBBaseHurttGetRobotBaseHurtR)R$R*R+R,RS(RRtRuR¡RvRrRsR…tcalledPlayerIDDictt refreshCounttfreeRefreshCounttgoldRefreshCounttcostGoldRwR|R}R~t needGoldCallRŒtrelationR0((s~E:\SnxxServerCode\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\GameWorldLogic\FBProcess\FBHelpBattle.pyR¢sR    #.c    Cs<|\}}}}}}}    |jƒ}
tjƒ} i|d6|d6dd6} x0|D](\} }tj|| |tj| ƒqUW| j|
tjƒ}|r¿|d7}| j    |
tj|ƒntj
d|||||||f|
ƒtj
d|    |
ƒ|    t j |
<t jƒ}||_g|_xì|    jƒD]Þ\}}t jƒ}| jtj|ƒ|_||_|jddƒ|_d    |kr|d    |_t|jƒ|_|d
|_|d |_|d |_|jd dƒ|_|jddƒ|_ n|jj!|ƒq4Wt|jƒ|_"t#j$||ƒdS(NR:R;RR=iswFBHelpBattleResult: %s,mapID=%s,funcLineID=%s,isClientRefresh=%s,costMoneyList=%s,calledPlayerIDDict=%s,refreshCount=%ss    helpBattlePlayerDict=%sR?R8RAtRealmLVR@R9iR7(%R'R#RDRR[RR\R¥R¦R¨RSRKRLRttagMCHelpBattleListt RefreshCounttHelpPlayerListROttagMCHelpBattlePlayerRPRQRmRCRMR?R8R,tNameLenRAR´R@R9t
IsNeedGoldRRt    HelpCountRR(RRRR RtRuR¡R…R­RwRrRsR†R‡RˆR®thelpPlayerListPackR|R}t
helpPlayer((s~E:\SnxxServerCode\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\GameWorldLogic\FBProcess\FBHelpBattle.pyRFsD   
                         c    Csl|\}}|jƒ}tjd||f|ƒd}d}g}|jtjƒ}    tjƒ}
g|
_x,|D]$} | \} } }}}}}}tj    |ƒ}tj
|ƒ}tj ƒ}| |_ | |_ t|j ƒ|_||_||_||_||_||_||_|
jj|ƒ|ji| d6|d6|d6|d6|d6|d6|d    6|d
6ƒ||7}|rŒ||7}n|    d 7}    qrWt|
jƒ|
_tj||
ƒi|d 6}tjd |||    f|ƒtj|tj|d|dtƒ|r!tj||ƒntj |tj|    ƒ|    t!j"ddƒkrht#j$|tj%|    ƒndS(Ns)__OnHelpBattleRecord %s,helpRecordList=%sit CallPlayerIDR:t
FuncLineIDtXianyuanCoinAddR9tVIPLVtHelpTimet    IsSameDayitHelpListsJ    addXianyuanCoinTotal=%s,addXianyuanCoinTotalTotay=%s,totalHelpCount=%st addDataDictt    isSysHintR¤i(&R'R#R&RRtDef_PDict_HelpBattleTotalCountRttagMCHelpBattleRecordListt
RecordListtChangeTimeNumToStrtCheckTimeIsSameServerDayExttagMCHelpBattleRecordR¾tCallPlayerNameR,R¹R:R¿RÀR9RÁRÂRRt RecordCountRRRt    GiveMoneyRYtTYPE_Price_XianyuanCoinRtAddTodayXianyuanCoinRRIRNtPlayerBillboardtUpdatePlayerBillboardtDef_BT_FBHelpBattle(RRRR thelpRecordListRrtaddXianyuanCoinTotaltaddXianyuanCoinTotalTotaytdrListttotalHelpCountt
recordPackt
recordInfot callPlayerIDtcallPlayerNameRtRutxianyuanCoinAddR³tvipLVt
recordTimettimeStrt    isSameDaytrecordRÅ((s~E:\SnxxServerCode\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\GameWorldLogic\FBProcess\FBHelpBattle.pyRrsT                                         % 
      "cCsC|jƒ}tjd|ƒ}tjd||ƒ}| sA| rEdSd}|jƒ}tjddƒ}tjddiƒ}    tj|ƒ}
|} |jƒrÔ| t    j
|t j ƒ7} |t    j
|t j ƒ7}n|
| krþtjd|
| f|ƒdSd} tjj|iƒ} xp| jƒD]b}|jd    dƒ}|sJq&n|    jt|ƒgƒ}| t|ƒdkr|dnd7} q&Wt|| |d
ƒ}t| |
dƒ}t||ƒ}tjd |||f|ƒ|r,i|d 6|d 6}tj|tj|d|ƒtj||ƒnt||||ƒdS(NtFBFuncR"i'tHelpBattlePointiisGÍæ¼Ò½ñÈÕÏÉÔµ±ÒÒÑ´ïÉÏÏÞ£¡todayXianyuanCoin=%s,playerXianyuanCoinUpper=%siR9gˆÃ@s>ÌôÕ½µ¥È˸±±¾Ôö¼ÓÏÉÔµ±Ò: coinAdd=%s,canAddMax=%s,coinAddReal=%sR:R¿RÅ(R'RIRJt
GetFBPointRNtGetFuncEvalCfgRtGetTodayXianyuanCointGetVIPLvt    PlayerViptGetPrivilegeValueRt!VIPPrivilege_XianyuanCoinUpperAddtVIPPrivilege_XianyuanCoinAddPerR#R&RKRLRMtvaluesR)R,RtmaxRVRÏRYRÐRÑtSync_AddXianyuanCoinMsg(RRtR;Rrt fbFuncIpyDatat fbHelpIpyDatat addCoinRatet baseFBPointtxianyuanCoinUppertrelationCoinAddDictttodayXianyuanCointplayerXianyuanCoinUppert relationAddRwR}R³trelationAddListtcoinAddt    canAddMaxt coinAddRealRÅ((s~E:\SnxxServerCode\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\GameWorldLogic\FBProcess\FBHelpBattle.pytDoSingleFBAddXianyuanCoin¦sH        *cCsdS(N((RRtR;RÜRÝR³((s~E:\SnxxServerCode\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\GameWorldLogic\FBProcess\FBHelpBattle.pytDoTeamFBAddXianyuanCoinÔstcCs_tjƒ}||_||_||_||_||_t|jƒ|_t    j
||ƒdS(s€ͬ²½×Ô¼ºÖ÷¶¯Õ½¶·»ñµÃÏÉÔµ±ÒÐÅÏ¢
    1. Ö÷¶¯·¢Æðͨ¹Ø¾µÏñÖúÕ½¸±±¾£¬´Ëʱ callPlayerID ¼° name Îª¿Õ
    2. ²ÎÓëͨ¹ØÕæÊµÖúÕ½µÄ¸±±¾£¬´ÎÊýÈç¹û×Ô¼ºÊÇÖúÕ½µÄ£¬Ôò callPlayer ¼° name ÓÐÖµ
    @param addXianyuanCoin: Ôö¼ÓµÄÏÉÔµ±Ò£¬¿ÉÄÜΪ0£¬´ú±íÒÑ´ï±¾ÈÕÉÏÏÞ£¬µ«ÊÇǰ¶ËÈÓÐèҪչʾ¼Ç¼
    @param callPlayerID: ÖúÕ½±ðÈËʱ£¬¶Ô·½Íæ¼ÒµÄplayerID
    @param callPlayerName: ÖúÕ½±ðÈËʱ£¬¶Ô·½Íæ¼ÒµÄÃû×Ö   
    N( RttagMCAddXianyuanCoinMsgR:R¿RÀR¾RÍR,R¹RR(RRtRutaddXianyuanCoinRÜRÝtmsgPack((s~E:\SnxxServerCode\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\GameWorldLogic\FBProcess\FBHelpBattle.pyRðØs                     ( R#RRRÒRRR2RERIRYRKRTRdRfRnRêR R RR!R1RR•RkR£RR¢RRRþRÿRð(((s~E:\SnxxServerCode\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\GameWorldLogic\FBProcess\FBHelpBattle.pyt<module>s<                    
                         u        4    ,    4    .