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
8hc@sxddlZddlZddlZddlZddlZddlZddlZddlZddlZddl    Z    ddl
Z
ddl Z ddl Z ddl Z ddlZddlZddlZddlZddlZdZdZdZdZd„Zd„Zd„Zd    „Zd
„Zd „Zd „Zd „Zd„Zd„Z d„Z!dd„Z"d„Z#dS(iÿÿÿÿNiiiicCs'tj|tjƒsdSt|ƒdS(N(t GameFuncCommt GetFuncCanUset ShareDefinetGameFuncID_GodWeapontSync_GodWeaponLVInfo(t    curPlayer((snD:\SG_ServerCode\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Player\PlayerGodWeapon.pytOnLogin2s
cCs\tj|tj||ƒt|ƒ}tj|tj|ƒt    j
|tj |t t ƒdS(N(t PlayerControltNomalDictSetPropertytChConfigtDef_PDict_GodWeaponLVtGetGodWeaponTotalLVtOpenServerCampaigntUpdOpenServerCampaignRecordDataRtDef_Campaign_Type_GodWeaponLVtPlayerWeekPartytAddWeekPartyActionCnttDef_WPAct_GodWeapontFalsetTrue(Rt
weaponTypetlvttotalLV((snD:\SG_ServerCode\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Player\PlayerGodWeapon.pytSetGodWeaponLV9s
 cCsmd}tjƒ}|j|jƒdƒjƒ}x5td|dƒD] }||jtj|ƒ7}qEW|S(Nii(    t IpyGameDataPYtIPY_DatatGetGodWeaponByIndextGetGodWeaponCounttGetTypetxrangetNomalDictGetPropertyR    R
(RRt
ipyDataMgrtmaxTypetgwType((snD:\SG_ServerCode\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Player\PlayerGodWeapon.pyR Cs  cCsTxCtjdƒD]2}t||dƒtj|tjd|gƒqWt|ƒtS(NtGodWeaponActivei(    RtGetFuncEvalCfgRt PlayerSuccesstUptateSuccessProgressRtSuccType_GodWeaponRR(Rti((snD:\SG_ServerCode\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Player\PlayerGodWeapon.pytDoGodWeaponOpenNs
 
cCs!t|ƒtj|ƒjƒdS(N(tCalcGodWeaponAttrRtRefreshPlayerAttrState(R((snD:\SG_ServerCode\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Player\PlayerGodWeapon.pytRefreshGodWeaponAttrXs
c Csltj|tjƒsdStjƒ}|j|jƒdƒjƒ}d}gt    dƒD] }i^qW}xÐt
d|dƒD]»}|j t j |ƒ}|s¥q}ntjd||ƒ}|sÆq}n|jƒ|jƒ}    }
x1t|    ƒD]#\}} tj| |
||ƒqìW|tjdƒjt|ƒdƒ7}q}Wtj|tj|ƒtj|t j|ƒdS(Niiit    GodWeapont MagicExterior(RRRRRRRRRtrangeRRR    R
tGetIpyGameDatat GetAttrTypet
GetAttrNumt    enumerateRtCalcAttrDict_TypeR#tgettstrtSetMFPExFightPowertDef_MFPType_GodWeapontSetCalcAttrListValuetDef_CalcAttrFunc_GodWeapon( RRR t fightPowerExR't allAttrListR!tattrLVt godWeaponDatat attrTypeListt attrValueListtattrID((snD:\SG_ServerCode\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Player\PlayerGodWeapon.pyR)bs( )cCs¦tjƒj|ƒ}|j}|jtj|ƒrItjd|ƒdSt||ƒsgt    ||ƒr¢t
||dƒt |ƒtjd|ƒt ||ƒndS(NsÒѾ­½âËøµÄÉñ±ø!weaponType=%sis½âËøÉñ±ø: weaponType=%s( t    GameWorldtGetPlayerManagertGetPlayerByIndext
WeaponTypeRR    R
tDebugLogt__GWCheckPlayerLVt__GWCheckOtherGWLVRR+R(tindext
clientDatattickRR((snD:\SG_ServerCode\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Player\PlayerGodWeapon.pytOnGodWeaponActivateŠs    
cCsVtjddiƒ}t|ƒ|kr<tjd|ƒtS|jƒ|t|ƒkS(NR"is¸ÃÉñ±ø²»ÄܽâËø!weaponType=%s(RR#R5RARERtGetLV(RRtgodWeaponUnlockDict((snD:\SG_ServerCode\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Player\PlayerGodWeapon.pyRFœs
cCsªtjddiƒ}t|ƒ|kr<tjd|ƒtS|t|ƒ}xW|D]O\}}|jtj|ƒ}||krStjd||||fƒtSqSWt    S(NR"is¸ÃÉñ±ø²»ÄܽâËø!weaponType=%ssTËùÐèǰÖÃÉñ±øµÈ¼¶²»×㣬ÎÞ·¨½âËø£¡weaponType=%s,needType=%s,needLV=%s > needTypeLV(%s)(
RR#R5RARERRR    R
R(RRRMt conditionListtneedTypetneedLVt
needTypeLV((snD:\SG_ServerCode\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Player\PlayerGodWeapon.pyRG¤s     c 
Cs¦tjƒj|ƒ}|j}|j}td|jƒ}|j}tj    |t
j ƒs[dS|j t j|ƒ}|}    tjd||ƒ}
|
s­tjd||fƒdS|
jƒ} | dkrÉdS|tjd|ƒkrædStjƒj|ƒ} | sdStj| t jƒ} | s5tjd|ƒdS| jdƒ}|s_tjd|ƒdSd}tj|||ƒ\}}}td|||ƒ}|dkrw|sÐtjd|||||fƒdStjddiƒ}t|ƒ|krûdS|t|ƒ\}}||}||}|dkr5dSi|t j6|d    6}tj|tj |t j!||ƒswdSn||}|r©tj"|||||t j#ƒn|||}|j t j$|ƒ}||}tjd
||    ||||||fƒt%}xÁt&d ƒD]³}|| kr)Pntjd||dƒ}
|
sctjd||fƒPntjd || fƒ|| }|d7}t'}t(||
|ƒ|
jƒ} | dkrd}PqqWtj)|t j$||ƒ|r•t*|||ƒtjd ||fƒt+|ƒt,j-|t
j.||gƒ|    dkr†tjddiƒj/|dƒ}tj0d||j1ƒ|gƒn|
jƒ} nt2||ƒdS(NiR,sÉñ±øÉý¼¶ÕÒ²»µ½Êý¾Ý %s-%sis GodWeapon%ss ###Éñ±ø¼Ù°ü£¬ÎïÆ·ID=%sûÓо­ÑéÖµsRÉñ±øÉý¼¶ÏûºÄ²»×ã!useItemID=%s,useItemCount=%s,bindCnt=%s,unBindCnt=%s,lackCount=%st GodMagicExpt    lackCountsXÖ´ÐÐÉñ±øÉý¼¶: weaponType=%s,beforeAttrLV=%s,befExp=%s,addTotalExp=%s(%s*%s+%s),curExp=%sids"    Éñ±øÉý¼¶: attrLV=%s,needExp=%ss!Éñ±øÉý¼¶½á¹û: attrLV=%s,curExp=%st GodWeaponSyst GetGodWeapon(3RARBRCRDtItemIDtmaxt    ItemCountt    IsAutoBuyRRRRRR    R
RR/REtGetExpR#t GetGameDatatGetItemByTypeIDt
ItemCommontGetItemEffectByEffectIDtDef_Item_Eff_GodWeaponExptGetEffectValuetGetPackItemBindStateIndexInfoR5tDef_Cost_Reason_SonKeyRtPayMoneyt IPY_GameWorldtTYPE_Price_Gold_MoneytDef_Cost_GodWeapontDelCostItemByBindtItemDel_GodWeapontDef_PDict_GodWeaponExpRRRt GodWeaponLVUPRRR+R$R%R&R4t WorldNotifytGetNameR( RHRIRJRRt    useItemIDt useItemCountt    isAutoBuyR<t beforeAttrLVR=ttotalExptitemDatateffecttitemExpt goldExpTotaltcostItemIndexListtbindCntt    unBindCntRStgodMagicExpDicttcostGoldtgoldExptlackCosttinfoDicttdelUseItemCountt addTotalExptbefExptcurExptisLVUPt_tsysMark((snD:\SG_ServerCode\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Player\PlayerGodWeapon.pytOnPlusGodWeaponÀs¬                   
 
 
"
      
 
 
 !"  cCsc|jƒ}|r_t||ƒr_|jƒ}|rXtjd||jƒ||gƒn|SndS(Ni(t
GetSkillIDt__GiveGodWeaponSkillt
GetSysMarkRRkRl(RR=R<tskillIDR„((snD:\SG_ServerCode\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Player\PlayerGodWeapon.pyRjBs  %icCs_tjƒ}|jƒg|_|dkrØtjƒ}|j|jƒdƒjƒ}xàt    d|dƒD]g}tj
ƒ}|jƒ||_ |j t j|ƒ|_|j t j|ƒ|_|jj|ƒqjWnatj
ƒ}|jƒ||_ |j t j|ƒ|_|j t j|ƒ|_|jj|ƒt|jƒ|_tj||ƒdS(Nii(tChPyNetSendPackttagMCGodWeaponLVListtCleartWeaponInfoListRRRRRRttagMCGodWeaponLVInfoRDRR    R
tWeaponLVRit    WeaponExptappendtlent    WeaponNumt NetPackCommont SendFakePack(Rt godWeaponIDtsendPackRR R't
weaponInfo((snD:\SG_ServerCode\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Player\PlayerGodWeapon.pyRTs, 
       
     
    c
Cs‡|jƒ}|j|ƒr0tjd|ƒdStjƒj|ƒ}|dkrftjd|ƒdStj||ƒstjd|ƒdS|j    ƒ}|j
ƒ}d\}}|j |ƒ}|r|j    ƒ}    |j ƒ}|j ƒ}||    krtjd|||    |fƒdSn|j|ƒtjd|||fƒtj||dƒtjƒj||ƒtj|ƒj||ƒtS(Ns!godSkill() have learned skill(%s)s godSkill() hasn't find skill(%s)s1godSkill() learn skill(%s) condition isn't enoughisUgodSkill() learn skill(%s) skillLV(%s) <= befSkillLV(%s),befSkillID=%s no need learn.s?godSkill() skill(%s) success! befSkillID=%s,beforeFightPower=%s(ii(tGetSkillManagertFindSkillBySkillIDRARER[tGetSkillBySkillIDtNonet
SkillShelltCheckLearnSkillConditiont
GetSkillLVtGetSkillTypeIDtFindSkillBySkillTypeIDR†t GetFightPowertLearnSkillByIDtDataRecordPacktDR_LearnORUPSkilltPassiveBuffEffMngtGetPassiveEffManagertRegistPassiveEffRtRefreshSkillFightPowerExR(
RR‰t skillManagert    skillDatatskillLVt skillTypeIDt
befSkillIDtbeforeFightPowertbefSkillt
befSkillLV((snD:\SG_ServerCode\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Player\PlayerGodWeapon.pyR‡ws:              ($RAR    RR]RdRŠR”R$RRR¤Rt SkillCommont    BuffSkillRRR¦R trandomtDef_GodWeaponType_HPtDef_GodWeaponType_AtktDef_GodWeaponType_SuperHittDef_GodWeaponType_DefRRR R(R+R)RKRFRGR…RjRR‡(((snD:\SG_ServerCode\ServerPython\ZoneServerGroup\map1_8G\MapServer\MapServerData\Script\Player\PlayerGodWeapon.pyt<module>sF                           
         
    
    (                ‚     #