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
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
SÃ6\c@s'ddlZddlZddlZddlZddlZddlZddlZddlZddlZddl    Z    ddl
Z
ddl Z ddl Z ddl Z ddlZddlZddlZddlZddlZddlZddlZddlZddlZddlZddlZddlZddlZddlZddlZddlZddlZddlZddl Z ddl!Z!ddl"Z"d„Z#d„Z$d„Z%d„Z&d„Z'd„Z(d„Z)d    „Z*d
„Z+d „Z,d „Z-e.d „Z/d„Z0d„Z1d„Z2d„Z3d„Z4d„Z5d„Z6d„Z7d„Z8d„Z9d„Z:d„Z;d„Z<d„Z=ej>d„Z?dd„Z@d„ZAd „ZBd!dd"„ZCd#„ZDd$„ZEd%„ZFd&„ZGd'„ZHd(„ZId)„ZJd*„ZKd+„ZLd,„ZMd-„ZNd.„ZOd/„ZPd0„ZQd1„ZRd2„ZSd3„ZTd4„ZUd5„ZVd6„ZWd7„ZXd8„ZYd9„ZZd:„Z[d;„Z\d<„Z]d=„Z^d>„Z_d?„Z`d@„ZadA„ZbdB„ZcdC„ZddD„ZedE„ZfdF„ZgdG„ZhdH„ZidS(IiÿÿÿÿNcCsOtjdƒtj|ƒtjƒj|ƒt|ƒtjƒt    j
ƒdS(NsGameServer -> OnHour!( t    GameWorldtLogtPlayerEventCountertDoLogic_GameServer_OnHourt GetGameWorldtOnHourt__SetWorldKey_SavePlayert GameLogInfotSet_Server_Hourt PlayerFamilyt FamilyOnHour(t
curTimeStrttick((sT.\\ServerPython\CoreServerGroup\GameServer\Script\GameWorldLogic\GameWorldProcess.pyRvs  
 
 
cCstjdƒtjƒtj|ƒtjtjƒ}tj    t
j |ƒtjtj ƒ}tjtj ƒ}tj    t
j|ƒtj    t
j|ƒtjƒj|ƒtjƒtjƒtjƒtjƒtjƒtjƒddl}|jƒtjƒdS(NsGameServer -> OnDay!iÿÿÿÿ( RRtPlayerBillboardtCopyBillboardOnDayRtDoLogic_GameServer_OnDaytPlayerDBGSEventtGetDBGSTrig_ByKeyt Def_ServerDaytSendMapServerMsgExt ShareDefinetDef_Notify_WorldKey_ServerDaytDef_IsMixServertDef_MixServerDaytDef_Notify_WorldKey_IsMixServert Def_Notify_WorldKey_MixServerDayRtOnDayRtSet_Server_DaytNoteOssBillboardInfoByDaytPlayerFamilyRedPackettDoOnDaytChPlayertUpdataPlayerLVInfotPlayerCompensationtClearUpTimeOutCompensationt PlayerGeTuitClearFMTGeTuiLimitt PlayerBoursetOverTimeItemsDealtGameWorldFamilyWar(R R t openServerDayt isMixServert mixServerDayR%((sT.\\ServerPython\CoreServerGroup\GameServer\Script\GameWorldLogic\GameWorldProcess.pyR‹s( 
 
 
 
 
 
 
 
 
cCs/tjdƒtj|ƒtƒtjƒdS(NsGameServer -> OnDayEx!(RRRtDoLogic_GameServer_OnDayExt__Set_Server_DayExt
PlayerXMZZt XMZZOndayEx(R ((sT.\\ServerPython\CoreServerGroup\GameServer\Script\GameWorldLogic\GameWorldProcess.pytOnDayEx³s
 
cCs;tjdƒtjƒtj|ƒtjƒj|ƒdS(NsGameServer -> OnWeek!(RRRtSet_Server_WeekRtDoLogic_GameServer_OnWeekRtOnWeek(R R ((sT.\\ServerPython\CoreServerGroup\GameServer\Script\GameWorldLogic\GameWorldProcess.pyR2Âs
 
 cCs%tjdƒtj|ƒtƒdS(NsGameServer -> OnWeekEx!(RRRtDoLogic_GameServer_OnWeekExt__Set_Server_WeekEx(R ((sT.\\ServerPython\CoreServerGroup\GameServer\Script\GameWorldLogic\GameWorldProcess.pytOnWeekExËs  cCs;tjdƒtj|ƒtjƒj|ƒtjƒdS(NsGameServer -> OnMonth!(RRRtDoLogic_GameServer_OnMonthRtOnMonthRtSet_Server_Month(R R ((sT.\\ServerPython\CoreServerGroup\GameServer\Script\GameWorldLogic\GameWorldProcess.pyR7×s
 
cCs%tjdƒtj|ƒtƒdS(NsGameServer -> OnMonthEx!(RRRtDoLogic_GameServer_OnMonthExt__Set_Server_MonthEx(R ((sT.\\ServerPython\CoreServerGroup\GameServer\Script\GameWorldLogic\GameWorldProcess.pyt    OnMonthExßs  cCs;tjdƒtj|ƒtjƒj|ƒtjƒdS(NsGameServer -> OnYear!(RRRtDoLogic_GameServer_OnYearRtOnYearRtSet_Server_Year(R R ((sT.\\ServerPython\CoreServerGroup\GameServer\Script\GameWorldLogic\GameWorldProcess.pyR=ës
 
cCsÄy't|jƒdjdƒdƒ}Wn+tk
rT}tjd||fƒdSXtjƒ}|dkr˜|jtjƒsÀ|j    tjdƒqÀn(|jtjƒrÀ|j    tjdƒndS(Nis:is!###»ñÈ¡Íæ¼Ò´¢´æ×ÖµäÒì³£ = %s , %si(
tinttsplitt BaseExceptionRRRt GetDictByKeytChConfigtDef_WorldKey_SavePlayertSetDict(R ttimeStrtet    gameWorld((sT.\\ServerPython\CoreServerGroup\GameServer\Script\GameWorldLogic\GameWorldProcess.pyRûs'  cCstjtƒ|ƒdS(N(Rt GetPsycoFunct__Func_HighPrecisionProcess(R ((sT.\\ServerPython\CoreServerGroup\GameServer\Script\GameWorldLogic\GameWorldProcess.pytHighPrecisionProcessscCstjƒjtjƒsdStj|ƒtj|ƒt    j
|ƒt j |ƒt j |ƒtj|ƒtj|ƒtj|ƒtjjƒ}|j}|j}|d}tjƒjtjƒ}||krütjƒjtj|ƒt||ƒn|ddkrtƒndS(Nii
i(RRRBRCtDef_WorldKey_IsGameWorldInittPlayerFamilyPartytFamilyParty_ProcessR    tOnLeaderImpeachTickt CrossRealmPKtOnPKMatchProcesst GameWorldBosstDoCheckWorldBossReborntProcessBossGeTuiR#tProcessNewGuyCallBackGeTuit
PlayerTeamt DoTeamProcesst PlayerDBOpert PyDBProccesstdatetimettodaytminutetsecondtDef_WorldKey_ProcessMinuteREtGameWorldProcessOnMinutetSendMapCommMapLinePlayerCount(R t curDateTimet    curMinutet    curSecondt processMinutetlastProcessMinute((sT.\\ServerPython\CoreServerGroup\GameServer\Script\GameWorldLogic\GameWorldProcess.pyRJs*                
 
cCsR| rtj rdStjd|tjfƒtjtjtjƒtt_dS(NsO֪ͨ³£¹æµØÍ¼Íæ¼ÒÈËÊýÐÅÏ¢: isForce=%s,PyGameData.g_commMapLinePlayerCountDict=%s(    t
PyGameDatat g_needSyncCommMapLinePlayerCountRtDebugLogtg_commMapLinePlayerCountDicttSendCommMapServerMsgRt*Def_Notify_WorldKey_CommMapLinePlayerCounttFalse(tisForce((sT.\\ServerPython\CoreServerGroup\GameServer\Script\GameWorldLogic\GameWorldProcess.pyR`Es        cCs~t|ƒt|ƒtjƒtjƒtjƒtjƒtj    ƒt
j |ƒt jƒ|ddkrzt jƒndS(Nii(tDoCheckNewServerOpentDisposeGameWorldEvenByTimetGameWorldActionControltDispose_OperationActionStatetDispose_DailyActionStatetDispose_FBStateTimeRPtOnMinuteProcesstGameWorldAverageLvtOpenWorldAverageLvRVtDoCountdownLeaveTeamLogictPlayerFBHelpBattleR    tUpdFamilyTotalFightPower(RbR ((sT.\\ServerPython\CoreServerGroup\GameServer\Script\GameWorldLogic\GameWorldProcess.pyR_Rs
 
 
 
 
 
 
 
 cCstjtƒ|ƒdS(N(RRIt__Func_OnGameWorldProcess(R ((sT.\\ServerPython\CoreServerGroup\GameServer\Script\GameWorldLogic\GameWorldProcess.pytOnGameWorldProcesspscCsut|ƒt|ƒt|ƒt|ƒt|ƒt|ƒt|ƒt|ƒt|ƒt    j
ƒt j |ƒdS(N( tDisposeGameWorldEvenByTrucktDisposeGameWorldBroadcasttDisposeGameWorldGametDisposeGameActivePlayertDispose_MapServer_TimetDispose_MapServer_PlayerSavetDisposeMapServerRunningStatetDispose_DataBase_GMShelltDispose_SendMsg_RouteServert EventReporttOnTimeCloseScribeTxtRRtCalcGameWorldBossOnlineCnt(R ((sT.\\ServerPython\CoreServerGroup\GameServer\Script\GameWorldLogic\GameWorldProcess.pyRzxs
 
 
 
 
 
 
 
 
 
 cCsstjƒ}|jtjƒ}|dkr.dS||tjtjkrLdS|jtj|ƒtjƒjƒdS(Niÿÿÿÿ(RRt GetTickByTypeRCtTYPE_SendMsg_RouteServertTYPE_Tick_Timet SetTickByTypet SendHeartBeat(R RHtlastTick((sT.\\ServerPython\CoreServerGroup\GameServer\Script\GameWorldLogic\GameWorldProcess.pyR„žs  cCs¹tjƒ}||jtjƒtjtjkr6dS|jtj|ƒ|jƒ}|jƒ|j    ƒ}|sudSx3t
d|ƒD]"}|j |ƒ}t j |ƒq…W|jƒdS(Ni(RRRˆRCtTYPE_ReadDateBaseGMRŠR‹tGetDBGMCommandListManagertDataServer_GMCommandReqtGetCounttrangetGetAttGMShelltDoLogic_DBGMCommontClear(R RHtdBGMCommandListManagertdBGMCommandListCounttitgmCommon((sT.\\ServerPython\CoreServerGroup\GameServer\Script\GameWorldLogic\GameWorldProcess.pyRƒ¶s & 
 
cCs`tjƒ}||jtjƒtjtjkr6dS|jtj|ƒ|jtjƒƒdS(N(    RRRˆRCtTYPE_SendTimeToMapServerRŠR‹t
OnTimeSynctGetCurrentDataTimeStr(R RH((sT.\\ServerPython\CoreServerGroup\GameServer\Script\GameWorldLogic\GameWorldProcess.pyR€Õs  &cCsWtjƒ}||jtjƒtjtjkr6dS|jtj|ƒ|jƒdS(N(RRRˆRCtTYPE_SendServerStateRŠR‹tDataServer_ServerStateReport(R RH((sT.\\ServerPython\CoreServerGroup\GameServer\Script\GameWorldLogic\GameWorldProcess.pytDisposeServerStateæs  &
cCsútjƒjtjƒdkr"dStjjƒjdkr>dStjƒ}g}x6t    |j
ƒƒD]"}|j |ƒ}|j |ƒqcW|j dtƒxAt    dt|ƒƒD]*}|dkrÅPn||}|jƒq¯WtjƒjtjdƒdS(Nii2tkeyii(RRRBRCRDRZR[R\tGetPlayerManagerR’tGetActivePlayerCounttGetActivePlayerAttappendtsorttGetKeytlentMapServer_PlayerSaveRE(R t playerManagert curPlayerListR™t    curPlayer((sT.\\ServerPython\CoreServerGroup\GameServer\Script\GameWorldLogic\GameWorldProcess.pyR÷s"  
cCs
|jƒS(N(tGetLV(R¬((sT.\\ServerPython\CoreServerGroup\GameServer\Script\GameWorldLogic\GameWorldProcess.pyR§sc Csltjƒ}tjjƒj}|ddkr2dS|jdƒ}||krQdS|jd|ƒi}d}tjƒ}|jƒ}xŠt    |ƒD]|}|j
|ƒ}    |    dks’|    j ƒ rÆq’nt j|    ƒrå|d7}q’ntj|    ƒ}
|j|
dƒd||
<q’Wx@|jƒD]2\}
} tj| |
|ƒtj| d|
ƒqWtj|i|ƒdS(Niit
OnlineCntMi(RRRZR[R\RBRER¢R£txrangeR¤tNonet    GetInitOKt PlayerControltGetIsTJGtGetPlayerPlatformtgettitemstDataRecordPacktDR_OnLinePlayerCountR…tWriteEvent_concurrency( R RHRbtnoteDatatplatformOLDictt tjgOnlineCntRªtactivePlayerCounttindextplayertplatformt    playerCnt((sT.\\ServerPython\CoreServerGroup\GameServer\Script\GameWorldLogic\GameWorldProcess.pyR"s4    
c Csµtjƒ}g}tjjƒ}x7t|jƒƒD]#}|j|ƒ}|jƒ}tj|j    ƒƒ}tj|j
ƒƒ}| s| rº|j |ƒtj d|||fƒq4n|j ƒs;||kr;||kr;|jtƒ|jƒ}    t|||    ƒtj|ƒ}
|
dkr8tjd|
ƒq8q;n||kr4|j |ƒq4q4WxS|D]K} t| ƒ|j| ƒtj| ƒ}
|
dkrbtjd|
ƒqbqbWdS(Ns%###---»î¶¯ÉèÖÃʱ¼äÒì³£ , %s , %s , %sti(RtGetGameWorldEventManagerRZR[R’tGetActiveEventCounttGetActiveEventByIndext
GetEventIDtGetDateTimeByStrt
GetEndTimet GetStartTimeR¥RtGetIsProcessingtSetIsProcessingtTruetGetPart__NotifyMapServerProcesstGMCommontGetGameServer_GM_GameOpen_MsgR²t WorldNotifytDoLogic_ProcessEvent_ClosetDelActiveEventtGetGameServer_GM_GameClose_Msg( R t eventManagertdelListt todayDateTimeR¾teventteventIDt eventEndTimeteventStartTimeteventPartsysMsgt
delEventID((sT.\\ServerPython\CoreServerGroup\GameServer\Script\GameWorldLogic\GameWorldProcess.pyR~xs:         
  cCsŒ|tjkr%ttt|ƒƒnc|tjkrJttt|ƒƒn>|tjkr~t|ƒ\}}t    t||ƒn
|j
ƒdS(N( RCtDef_GY_GM_Game_DoubleExpt__DisposeWorldExpEventRÌR?tDef_GY_GM_Game_DropRatet__DisposeWorldDropRateEventtDef_GY_GM_Game_Broadcastt__GetBroseCastStrt__DisposeBroadcastEventtNotify_AllMapServerProcess(RØRÙRÜtintervaltmsg((sT.\\ServerPython\CoreServerGroup\GameServer\Script\GameWorldLogic\GameWorldProcess.pyRήs
cCsX|tjkrttƒn8|tjkr8ttƒn|tjkrTttƒndS(N(RCRßRàRlRáRâRãRå(RÙ((sT.\\ServerPython\CoreServerGroup\GameServer\Script\GameWorldLogic\GameWorldProcess.pyRÒÄs   cCs7|jdƒ}t|| ƒ}||d}||fS(Ns:i(tfindR?(RÜR¾RçRè((sT.\\ServerPython\CoreServerGroup\GameServer\Script\GameWorldLogic\GameWorldProcess.pyRäÖscCs3tjƒ}|r"|j|ƒn |j|ƒdS(N(RRt
SetExpRate(tisOpentexpRateRH((sT.\\ServerPython\CoreServerGroup\GameServer\Script\GameWorldLogic\GameWorldProcess.pyRàás
  icCs3|rtd|tjƒ}nd}t|ƒdS(Ni(tmaxRCtDef_MaxRateValuetSetWorldDropRateAdd(RëRìtworldDropRateAdd((sT.\\ServerPython\CoreServerGroup\GameServer\Script\GameWorldLogic\GameWorldProcess.pyRâïs
 
cCsdS(N((Rð((sT.\\ServerPython\CoreServerGroup\GameServer\Script\GameWorldLogic\GameWorldProcess.pyRïúscCsat|ƒ}|s |jƒdStjƒ}x!|D]}|jt|ƒƒq3W|j|ƒdS(N(tevalRætIPY_GameServert    IntVectort    push_backR?tNotify_SelectMapServerProcess(RØt    mapIDListtvectortmapID((sT.\\ServerPython\CoreServerGroup\GameServer\Script\GameWorldLogic\GameWorldProcess.pyt__DisposeMapGiveExp s 
   RÂcCsZtjƒ}|r/|j|ƒ|j|ƒn'|j|ƒ|jdƒ|jdƒdS(Ni(RRtSetBroadcastMsgtSetBroadcastIntervaltSetBroadcastTick(Rët broadcastMsgt broadcastTickRH((sT.\\ServerPython\CoreServerGroup\GameServer\Script\GameWorldLogic\GameWorldProcess.pyRå"s     cCs¬tjƒ}|jtjƒ}|s(dS|jƒs8dStjƒ}|jƒ}|dkr`dS||jƒ|j    ƒddkrˆdStj
ƒj |ƒ|j |ƒdS(NRÂi<iè( RRÃtFindActiveEventRCRãRÊRtGetBroadcastMsgtGetBroadcastTicktGetBroadcastIntervalR¢t BroadcastInfoRü(R RÕt
broadEventRHRý((sT.\\ServerPython\CoreServerGroup\GameServer\Script\GameWorldLogic\GameWorldProcess.pyR}:s     $ c    Csòg}tjƒ}x6t|jƒƒD]"}|j|ƒ}|j|ƒq%W|sUdStjdƒd}tt    j    ƒƒ}|t
j d}x`|D]X}||j ƒ|kr´q’ntj d|jƒ|j ƒ||fƒtj|ƒq’WdS(Nt    TruckTimei<iès@ÔËïÚʱ¼ä³¬Ê±: %d disappear! startTime=%d,curTime=%s,truckTime=%s(RtGetTruckManangerR’t GetTruckCounttGetTruckByIndexR¥t ReadChConfigtGetEvalChConfigR?ttimeRCtDef_PlayerTruckLogoffTickt GetLogoffTickRt
GetOwnerIDt PlayerTrucktDelTruck(    R tworldTruck_Listt truckManangerR¾ttruckt    truckTimetcurTimet disappearTimetcurTruck((sT.\\ServerPython\CoreServerGroup\GameServer\Script\GameWorldLogic\GameWorldProcess.pyR|ls"       cCst|ƒdS(N(tDoLogic_GameWorldEvenByTime(R ((sT.\\ServerPython\CoreServerGroup\GameServer\Script\GameWorldLogic\GameWorldProcess.pyRo¥s
c    Cs²tjƒjtjƒ}|dkr(dStjƒ}tjjƒ}|j}|j    }tjj
|ƒd}|j }|j }t jƒ\}    }
} } } |    |ksÈ|
|ksÈ| |ksÈ| |krØt||ƒn|
|ksü| |ksü| |kr t||ƒntƒr"t|ƒn| |kr>t||ƒntƒrTt|ƒn| |ksl| |kr|t||ƒntƒr’t|ƒn| |kr®t||ƒndS(Niÿÿÿÿi(RRRˆRCtTYPE_EvenByTimeRRZR[thourtdayt isocalendartmonthtyearRtInitServerTimeRRt__Get_Can_OnDayExR/R2t__Get_Can_OnWeekExR5R7t__Get_Can_OnMonthExR;R=(R RR Rt curTimeHourt
curTimeDayt curTimeWeekt curTimeMontht curTimeYeart
serverHourt    serverDayt
serverWeekt serverMontht
serverYear((sT.\\ServerPython\CoreServerGroup\GameServer\Script\GameWorldLogic\GameWorldProcess.pyR¯s8                  0$                 c    Csºtjƒ}tjtjƒ}|r¶|d}|dd}|d}tj|||dddƒ}||}|j}|j}|dkrdS|dkr¶|tj    dkr¶dSndS(s5ÅжϿɷñÁ賿Xµã¹ýÌì
    @return: 0-²»¿É£» 1-¿ÉÒÔ
    i'idiii(
Rt GetServerTimeRRtDef_Server_DayExRZtdaystsecondsRtDef_OnEventHour(    Rat lastOndayExtlastOndayEx_YeartlastOndayEx_MonthtlastOndayEx_Dayt lastDatetimetpassTimetpassDayst passSeconds((sT.\\ServerPython\CoreServerGroup\GameServer\Script\GameWorldLogic\GameWorldProcess.pyR ès 
 
 
         cCs‘tjƒ}|jtjkr7|tjddƒ}n|jd|jd|j    }t
j t
j |ƒtj tj|ƒtjd|ƒdS(NR/ii'ids!Set_Server_DayEx, OnDayExValue=%s(RR-RRR1RZt    timedeltaRRRRtSetDBGSTrig_ByKeyR.RtDef_Notify_WorldKey_OnDayExR(t onDayDateTimet ondayExValue((sT.\\ServerPython\CoreServerGroup\GameServer\Script\GameWorldLogic\GameWorldProcess.pyR,s c Csítjƒ}tjj|ƒ}|\}}}tjtjƒ}|ré|d}|d}||kru||krudS|dkré|tjddƒ}tjj|ƒ\}    }
} |    |kræ|
|kræ|jt    j
krãdSqæqéndS(s5ÅжϿɷñÁ賿Xµã¹ýÖÜ
    @return: 0-²»¿É£» 1-¿ÉÒÔ
    idiiR/i( RR-RZRRRtDef_Server_WeekExR:RRR1( RaRt dateTime_yeart dateTime_weekt dateTime_dayt lastOnWeekExtlastOnWeekEx_YeartlastOnWeekEx_WeektpreWeekDateTimet preWeek_yeart preWeek_weekt preWeek_day((sT.\\ServerPython\CoreServerGroup\GameServer\Script\GameWorldLogic\GameWorldProcess.pyR!s$ 
 
 cCsÈtjƒ}tjj|ƒ}|\}}}|dkr|jtjkr|tjddƒ}tjj|ƒ\}}}n|d|}tj    tj
|ƒtj tj |ƒtj d|ƒdS(NiR/iids#Set_Server_WeekEx, OnWeekExValue=%s(RR-RZRRRR1R:RR;R?RtDef_Notify_WorldKey_OnWeekExR(tonWeekDateTimeRR@RARBt onWeekExValue((sT.\\ServerPython\CoreServerGroup\GameServer\Script\GameWorldLogic\GameWorldProcess.pyR4Hs c    Csîtjƒ}|j}|j}|j}tjtjƒ}|rê|d}|d}||kro||krodS|dkrê|dkrdn|d}|dkr©|n|d}||krç||krç|jt    j
krädSqçqêndS(s5ÅжϿɷñÁ賿Xµã¹ýÔÂ
    @return: 0-²»¿É£» 1-¿ÉÒÔ
    idiii ( RR-RRRRRtDef_Server_MonthExRRR1(    RaRBtdateTime_monthR@t lastOnMonthExtlastOnMonthEx_YeartlastOnMonthEx_MonthtpreMonth_montht preMonth_year((sT.\\ServerPython\CoreServerGroup\GameServer\Script\GameWorldLogic\GameWorldProcess.pyR"Xs&             
 
 cCsÖtjƒ}|j}|j}|j}|dkr|jtjkr|dkrWdn|d}|dkrs|n|d}tjdƒn|d|}t    j
t    j |ƒtj tj |ƒtjd|ƒdS(Nii sWSetMonthEx ÔÂ1ºÅÌØÊâXµã֮ǰ¹ýÌìµÄ£¬´ú±íÔ²î´óÓÚ1µÄÔÂ1ºÅ¹ýÔ£¬ÕâʱºòµÄ¹ýÔÂÖµÐèÉèÖÃΪÉÏÔÂids%Set_Server_MonthEx, onMonthExValue=%s(RR-RRRRRR1RRR;RMRtDef_Notify_WorldKey_OnMonthEx(tonMonthDateTimeRBRNR@tonMonthExValue((sT.\\ServerPython\CoreServerGroup\GameServer\Script\GameWorldLogic\GameWorldProcess.pyR:†s             cCs7tjƒtjƒjtjƒtjƒjt    ƒdS(N(
R tInitServerBillboardRtGetTeamManagertSetMaxTeamMemberCountRCtDef_Team_MaxPlayerCountRt SetPreInitOKRÌ(R ((sT.\\ServerPython\CoreServerGroup\GameServer\Script\GameWorldLogic\GameWorldProcess.pytPreInitGameWorldœs
cCsÄtjƒjtjttjƒƒƒtjƒjtjƒt    j
t    j ƒ}t    j
t    j ƒ}|dksw|dkrŸt    j |r‰|nttjƒƒƒntjƒtjƒjtjƒtjƒjƒjƒtjƒtjƒtjƒtjƒtjƒtjƒtƒt jƒt!j"ƒt#j$ƒt%jƒtj&ƒ}|r£t    j
t    j'ƒ}|rpdnd}tjƒjt(j)|ƒtj*d|ƒntj+ƒ}tj*d|ƒdS(Niis#¿ç·þ·þÎñÆ÷Æô¶¯³É¹¦: isServerOpen=%ss ·þÎñÆ÷Æô¶¯³É¹¦: ServerGroupID=%s(,RRRERCRLR?R tSetTickTypeCounttTYPE_Tick_CountRRtDef_InitOpenServerTimetDef_OpenServerWeekdaytSetInitOpenServerTimet CrossRealmMsgtOnGameServerInitOKtGetFamilyManagertSetFamilyUpperLimitCounttDef_Family_MaxCnttGetDBGoldOrderFormMgrtSortR tClearBillboardOnServerInittSortServerBillboardR    t DoFamilySortRpRsR'R…t InitDllAppIDt__DoMixServerInitR-RtLoadPlayerLVDataRxt OnServerStartRPt IsCrossServertDef_CrossServerCloseRt#Def_Notify_WorldKey_CrossServerOpenRtGetServerGroupID(R tinitOpenServerTimetopenServerWeekdayt isCrossServert isServerCloset isServerOpent serverGroupID((sT.\\ServerPython\CoreServerGroup\GameServer\Script\GameWorldLogic\GameWorldProcess.pyt InitGameWorld®s:%(
 
 
 
 
 
 
 
 
 
 
  cCsntjtjƒ}|sdStjtjƒ}||kr>dSttjƒƒ}||kr`dSt|ƒdS(N(RRtDef_SetOpenServerTimeR_R?R tOnNewServerOpen(R tsetOpenServerTimetcurOpenServerTimeR((sT.\\ServerPython\CoreServerGroup\GameServer\Script\GameWorldLogic\GameWorldProcess.pyRnås  
cCstjdƒtjtjƒ}|s)dSi}tjƒjƒ}xpt|jƒƒD]\}|j    |ƒ}|j
ƒ}|j ƒ}| sT|tj tjgkr¦qTn|||<qTWx>|j ƒD]0\}}|j|ƒtjd||fƒqÁWxktjD]`}tjƒj|ƒ}    |    s&dn    |    jƒ}
|
rÿtj|ƒtjd||
fƒqÿqÿWtjƒ} xetjD]Z} | j| ƒ} | sšdn    | jƒ}| j| ƒ|rytjd| |fƒqyqyWg}tjƒ}x0t|jƒƒD]}|j|j    |ƒƒqüWx8|D]0}tjd|jƒƒtjd||ƒq#Wt j!ƒgt"_#tj$|ƒt%j&ƒt'|ƒdS(sзþ¿ªÆôÐèÒª´¦ÀíµÄÂß¼­sÖ´ÐÐÕýʽ¿ª·þÖØÖÃÂß¼­...NsDeleteGameServerEventTrig %s=%sisClearBillboard %s, count=%ss"DeleteRecData recType=%s, count=%ssDeleteFamily familyID=%s((RRRRR{RtGetDBGameServerEventTrigManagerR¯R‘R“RÆt
GetIsEventR_R¶t DeleteByKeyRtBillboardTypeListt GetBillboardt FindBillboardR tClearBillboardByIndextGetUniversalRecMgrtDef_UniversalGameRecTypeListt GetTypeListtCounttDeleteRdR¥tGetIDR    tDoLogic_DeleteFamilyR°R'tDoFamilyWarResetRftg_sortBOSSRefreshListRaR    t ReloadConfigtAllMapServerInitOK(R R}tdbgsTrigKeyDicttgsEventTrigManagerR™tgsEventR¡tvaluetbillboardIndext    billBoardtcounttuniversalRecMgrtrecTypet
recordListt recordCountt
familyListt    familyMgrtfamily((sT.\\ServerPython\CoreServerGroup\GameServer\Script\GameWorldLogic\GameWorldProcess.pyR|õsT         
     
 
cCstjtjƒS(N(RRR`(((sT.\\ServerPython\CoreServerGroup\GameServer\Script\GameWorldLogic\GameWorldProcess.pytGetOpenServerWeekday2sc Cstjƒjtjƒƒtƒtƒtƒtjƒtj    ƒtj
ƒt ƒt j tjƒ}tjtj|ƒt j t jƒ}tjtj|ƒt j t jƒ}tjtj|ƒt j t jƒ}tjtj|ƒt j t jƒ}tjtj|ƒt j t jƒ}tjtj|ƒt j tjƒ}tjtj|ƒt j tjƒ}tjtj|ƒtjƒjtjƒ}    tjtj |    ƒt!j"ƒt#j"ƒtjƒjtj$ƒ}
tjtj$|
ƒt%j"ƒt&ƒt't(ƒt)j*ƒdS(N(+RRtNotify_AllMapServerInitOKRt__SetWorldExpRatet__SetWorldDropRateAddt__NotifyMapServerEventRpt!SendMapServerOperationActionStatetSendMapServerDailyActionStatetSendMapServerFBFuncStatet__NotifyMissionPubEventRRRt"Def_Notify_WorldKey_WorldAverageLvRRRR`t%Def_Notify_WorldKey_OpenServerWeekdayRRRRtDef_LastMixServerDayt$Def_Notify_WorldKey_LastMixServerDayt&Def_Notify_WorldKey_ClearBillboardSignt*Def_Notify_WorldKey_FamilyActivityDayStateRBRCRLt%Def_Notify_WorldKey_InitGameWorldTimeRRtOnMapServerInitOKR'RrRPtSendAllMapGlobalDropInfoR`RÌR    tRandomFakeFamily( R tworldLvR(RuR)R*tlastMixServerDaytlastSigntfadStatetinitGameWorldTimetisCrossServerOpen((sT.\\ServerPython\CoreServerGroup\GameServer\Script\GameWorldLogic\GameWorldProcess.pyR8sF
 
 
 
 
 
 
 
cCs    tjtjƒ}|s)tjdƒdStjtjƒ}|rRtjdƒdStjdƒtjƒ}tjg}tjdt    |ƒƒx|D]}|j
|ƒq•Wt |ƒt j ƒtjtjdƒtjtjƒ}tjtj|ƒtjdƒdS(Ns$·ÇºÏ·þ£¬²»´¦ÀíºÏ·þÊ×´ÎÆô¶¯Êý¾Ý¼ÓÔØ£¡sºÏ·þÊ×´ÎÆô¶¯¼ÓÔØÒѾ­´¦Àí¹ý£¡sºÏ·þÊ×´ÎÆô¶¯¼ÓÔØ´¦Àí...s&    Çå³ýÖ¸¶¨Í¨ÓÃÊý¾Ý delRecTypeList=%sis    ºÏ·þÊ×´ÎÆô¶¯¼ÓÔØ³É¹¦...(RRRRRhtDef_IsMixServerInitOKR†Rt%Def_UniversalGameRecType_ManorWarInfotstrRŠt__DelOutofdayRecDataR'RR;RRª(R)tisMixServerInitOKR˜tdelRecTypeListt
delRecTypeR)((sT.\\ServerPython\CoreServerGroup\GameServer\Script\GameWorldLogic\GameWorldProcess.pyRm“s*      
 
 c Csñttjƒƒ}tjd|ƒi}xÁ|jƒD]³\}}|j|ƒ}|s]q6nd}|jƒ}x]t|ƒD]O}||}    |j|    ƒ}
||
j    ƒ|kr||j
|    ƒ|d7}q|q|Wtjd|||fƒq6WdS(Ns"Ö´ÐÐɾ³ý¹ýÆÚµÄͨÓÃÊý¾Ý, curTime=%siis2    É¾³ý¹ýÆÚÌõÊý: recType=%s,totalCnt=%s,delCnt=%s( R?R RRR¶RˆR‰R¯tAttGetTimeRŠ( R˜RtdelOutofdayRecDataDictt otDayRecTypetotTimet otRecDataListtdelCntttotalCntR¾tdelIndext    otRecData((sT.\\ServerPython\CoreServerGroup\GameServer\Script\GameWorldLogic\GameWorldProcess.pyR»·s" 
 cCsqtjƒ}|jtjƒ}|s0tj}n*|jƒsHtj}nt|jƒƒ}tj    ƒj
|ƒdS(N( RRÃRÿRCRßRîRÊR?RÍRRê(RÕt expRateEventRì((sT.\\ServerPython\CoreServerGroup\GameServer\Script\GameWorldLogic\GameWorldProcess.pyR¡Ðs    cCsgtjƒ}|jtjƒ}|s1ttƒn2|jƒsJttƒnttt    |j
ƒƒƒdS(N( RRÃRÿRCRáRâRlRÊRÌR?RÍ(RÕRØ((sT.\\ServerPython\CoreServerGroup\GameServer\Script\GameWorldLogic\GameWorldProcess.pyR¢ås    cCsjtjƒ}xWt|jƒƒD]C}|j|ƒ}|jƒsFqnt||jƒ|jƒƒqWdS(N(    RRÃR’RÄRÅRÊRÎRÆRÍ(RÕR¾RØ((sT.\\ServerPython\CoreServerGroup\GameServer\Script\GameWorldLogic\GameWorldProcess.pyR£÷s   c    CsØtjƒ}|jƒ}|jƒ}|jƒ}|jƒ}|jƒ}tjƒj    ƒj
|||||ƒ|t j ||f<t j j|iƒ}||ks±|||krÔ|||<|t j |<tt _ndS(N(RòtIPY_GMapServerStatetGetRouteServerIndextGetMapIDt    GetLineIDtGetCurPlayerCounttGetMaxPlayerCountRRtGetMapServerStateManagertSetZoneServerStateRftg_commMapLineRouteDictRiRµRÌRg(    R¾R tpacktrouteServerIndexRøtlineIDtcurPlayerCounttmaxPlayerCounttlinePlayerCountDict((sT.\\ServerPython\CoreServerGroup\GameServer\Script\GameWorldLogic\GameWorldProcess.pytMapServer_RefreshState s      %
  cCsgtjƒ}tjƒjƒ}|j|jƒƒ}|j|jƒƒ|j    |j
ƒƒ|j ƒdS(N( RòtIPY_GMissionPubRRtGetDBMissionPubManagertAddDBMissionPubt GetMissionIDtSetMissinoPubTypetGetMissinoPubTypetSetPubIDtGetPubIDRæ(R¾R RÓtmissionPubManagert curMissionPub((sT.\\ServerPython\CoreServerGroup\GameServer\Script\GameWorldLogic\GameWorldProcess.pytMapServer_MissionPub6s 
cCs tjƒjƒ}|jƒdS(N(RRRÛt#NotifyAllMapServerMissionPubProcess(Râ((sT.\\ServerPython\CoreServerGroup\GameServer\Script\GameWorldLogic\GameWorldProcess.pyR§Cs
cCsitjƒ}|jƒ}|jƒ}|jƒ}t|||ƒ|tjkrettj||ƒndS(N(RòtIPY_GTreasureDropt    GetItemIDt GetItemCounttGetDropFunctionTypet__ProcessFunctionTypeDroptdfdAll(R¾R RÓtitemIDt    itemCounttdropFunctionType((sT.\\ServerPython\CoreServerGroup\GameServer\Script\GameWorldLogic\GameWorldProcess.pytMapServer_TreasureDrop[s    cCswtjƒjƒ}|j||ƒ}|dkr4dS|jƒ|}|j|ƒ||jƒkrs|jdƒndS(Ni(    RRtGetDBGameWorldDropManagertFindGameWorldDropR°tGetCurrentCounttSetCurrentCountt GetDropCounttNotify_AllMapServerDropState(RîRìRít dropManagertcurDropt
finalCount((sT.\\ServerPython\CoreServerGroup\GameServer\Script\GameWorldLogic\GameWorldProcess.pyRêns  cCsYtjƒjƒ}x6t|jƒƒD]"}|j|ƒ}|jdƒq%W|jƒdS(Ni(RRRðR’R‘R“Rót%Notify_AllMapServerClearForbiddenDrop(RöR™R÷((sT.\\ServerPython\CoreServerGroup\GameServer\Script\GameWorldLogic\GameWorldProcess.pyt__ClearTreasureDropCounts 
cCstjddƒ}tjddƒ}tjdƒ}x@|jƒD]2}tj|}tj|ƒ}tj||ƒq@Wx@|jƒD]2}tj    |}tj|ƒ}tj||ƒqƒWx@|jƒD]2}tj
|}tj|ƒ}tj||ƒqÆWdS(Nt GlobalDropCDiitNPCGlobalDropRate( t IpyGameDataPYtGetFuncEvalCfgtkeysRt Def_Notify_WorldKey_LastDropTimeRRRRt$Def_Notify_WorldKey_DropNPCKilledCntt"Def_Notify_WorldKey_NPCKilledCount(tglobalDropCDDicttglobalKilledCountDropDicttglobalDropRateDictRìR¡tdropTimet    killedCnttnpcID((sT.\\ServerPython\CoreServerGroup\GameServer\Script\GameWorldLogic\GameWorldProcess.pyR°‹s    cCs=|\}}tj|}tj||ƒtj||ƒdS(N(RRRR;RR(tmsgListRìRR¡((sT.\\ServerPython\CoreServerGroup\GameServer\Script\GameWorldLogic\GameWorldProcess.pytUpdGlobalDropCD¡s
  cCs=|\}}tj|}tj||ƒtj||ƒdS(N(RRRR;RR(R    Rìt updKilledCntR¡((sT.\\ServerPython\CoreServerGroup\GameServer\Script\GameWorldLogic\GameWorldProcess.pytUpdGlobalDropRate©s
  cCs=|\}}tj|}tj||ƒtj||ƒdS(N(RRRR;RR(R    RR R¡((sT.\\ServerPython\CoreServerGroup\GameServer\Script\GameWorldLogic\GameWorldProcess.pytUpdGlobalKillCount±s
  cCsŽtjƒjƒ}tjƒ}|j|jƒ|jƒƒ}|j|j    ƒƒ}|j
|j    ƒƒ|j |j ƒƒ|j |jƒƒdS(N(RRtGetGameFbEventListRòtIPY_GRegisterFBInfotGetGameFbEventRÍt GetDataMapIDtGetGameFbDetailtGetClientLineIDtSetClientLineIDtSetMaxPlayerCountRÏt    SetFbInfot    GetFbInfo(R¾R t
fbEventMgrtmPackt gameFBEventtfbDetail((sT.\\ServerPython\CoreServerGroup\GameServer\Script\GameWorldLogic\GameWorldProcess.pytMapServer_RegisterFBInfoÓs cCsxtjƒ}tjƒjƒ}|j|jƒ|jƒƒ}|dkrLdS|j    |j
ƒƒ}|j |j ƒƒdS(N( RòtIPY_GFbInfoRefreshRRRtFindGameFbEventRÍRR°RRtSetPlayerCounttGetPlayerCount(R¾R RÓtfbEventRR((sT.\\ServerPython\CoreServerGroup\GameServer\Script\GameWorldLogic\GameWorldProcess.pytMapServer_FbInfoRefreshós  cCsptjƒ}tjƒjƒ}|j|jƒ|jƒƒ}|dkrLdS|j    |j
ƒƒ|j |ƒdS(N( RòtIPY_GMapServerRunningStateRRtGetGameMapManagertFindRËRÌR°tSetStatetGetStatetSetRefreshTick(R¾R t mapServerPacktgameMapManagertcurMap((sT.\\ServerPython\CoreServerGroup\GameServer\Script\GameWorldLogic\GameWorldProcess.pytMapServer_RunningStateRefreshs   cCs¨tjtj|ƒsdStjƒjƒ}xvtd|jƒƒD]_}|j|ƒ}|j    ƒt
j krqqAn||j ƒtj krqAn|jt
j ƒqAWdS(Ni(RtSetWorldDictKeyRCtTYPE_MapServerRunningStateRR$R’R‘R“R'RòtmssNonetGetRefreshTicktDef_Tick_MapServer_MssNoneR&(R R*R™R+((sT.\\ServerPython\CoreServerGroup\GameServer\Script\GameWorldLogic\GameWorldProcess.pyR‚)scCs&tjƒ}|jƒ}t|ƒdS(N(RòtIPY_GMapServerMsgtGetMsgt RunEventFunc(R¾R RÓRè((sT.\\ServerPython\CoreServerGroup\GameServer\Script\GameWorldLogic\GameWorldProcess.pytMapServer_MapServerMsgNs  
cCs?d|}tƒj|ƒr*tƒ|ƒStjd|ƒdS(Nt RunEventFunc_s"Error : RunEventFunc funcName = %s(tglobalsthas_keyRR(tfuncName((sT.\\ServerPython\CoreServerGroup\GameServer\Script\GameWorldLogic\GameWorldProcess.pyR4Zs
 
cCsBtj|ƒtjƒtjƒtjdƒtjƒjƒdS(Ns ֪ͨC++¹Ø·þ£¡(RVt OnServerCloseRtSavePlayerLVDataRxRRR(R ((sT.\\ServerPython\CoreServerGroup\GameServer\Script\GameWorldLogic\GameWorldProcess.pyt BeforeClosehs
 
 
 (jRRZRCRRR²R”RR    RRpR RòRÏR R·RRuRXR#RRR!R    R…RPRbRxRRýRMR'R-RVRfRRRR/R2R5R7R;R=RRKRJRlR`R_R{RzR„RƒR€R RR§RR~RÎRÒRäRîRàRâRïRùRåR}R|RoRR R,R!R4R"R:R\RzRnR|RŸRRmR»R¡R¢R£RÙRäR§RïRêRúR°R
R R RR"R,R‚R5R4R<(((sT.\\ServerPython\CoreServerGroup\GameServer\Script\GameWorldLogic\GameWorldProcess.pyt<module>AsÎ                                           (                                              &             &                    #        V    6                          2    9    
    9    '         ,        .            7        =        [    $                    +                     
                "         %        %