| | |
| | | # @change: "2013-09-18 17:00" Alee 退出锁定退出交易
|
| | | # @change: "2013-09-23 19:30" Alee 红名提示修改
|
| | | # @change: "2013-11-15 20:20" hxp 关闭07 3A购买背包封包功能,增加背包成功系统提示
|
| | | # @change: "2013-11-27 20:30" hxp 修改结束摆摊状态事件单独处理,不在结束事件中处理
|
| | | # @change: "2013-12-10 14:00" hxp 修改查看摆摊状态事件单独处理,不在结束事件中处理
|
| | | # @change: "2013-12-12 14:30" hxp 增加钻石购买背包计费点事件同步
|
| | | # @change: "2013-12-13 12:20" hxp 修改首登物品绑定设置
|
| | | # @change: "2013-12-27 16:00" Alee 删除多余代码
|
| | |
| | | import PlayerControl
|
| | | import FunctionNPCCommon
|
| | | import FBLogic
|
| | | import PlayerShopItem
|
| | | import ItemControler
|
| | | import ItemCommon
|
| | | import QuestCommon
|
| | |
| | | return
|
| | |
|
| | | curPlayer.SetActionObj(curNPC)
|
| | | PlayerControl.ChangePlayerAction(curPlayer, IPY_GameWorld.paNull)
|
| | |
|
| | | if NPCCommon.OnCollectNPCBegin(curPlayer, curNPC, tick):
|
| | | return
|
| | |
| | | RunQuestEvent(curPlayer, 'on_deactive', missionID, Def_RunQuestType_RunAll)
|
| | | return
|
| | |
|
| | | #---------------------------------------------------------------------
|
| | | ##任务触发器_OnCoin 换取金钱事件
|
| | | #@param curPlayer 玩家实例
|
| | | #@return 返回值无意义
|
| | | #@remarks 任务触发器_OnCoin 换取金钱事件
|
| | | def EventResponse_OnCoin(curPlayer):
|
| | | RunQuestEvent(curPlayer, 'on_coin', 'on_coin', Def_RunQuestType_RunAll)
|
| | | curPlayer.DataServer_CheckPrizeItem()
|
| | | return
|
| | |
|
| | | #---------------------------------------------------------------------
|
| | | ##任务触发器_OnDig 挖宝进度条结束后触发
|
| | |
| | | RunQuestEvent(curPlayer, "on_trialtowercnt", cnt, Def_RunQuestType_Normal)
|
| | | return
|
| | |
|
| | | ## 通关天星塔第X层
|
| | | # @param curPlayer 玩家实例
|
| | | # @param eventName |
| | | # @return None
|
| | | def EventRespons_SkyTowerCnt(curPlayer, cnt):
|
| | | RunQuestEvent(curPlayer, "skytowerpass", cnt, Def_RunQuestType_Normal)
|
| | | return
|
| | |
|
| | | ##护送X次美女
|
| | | # @param curPlayer 玩家实例
|
| | | # @param eventName 事件名
|
| | |
| | | RunQuestEvent(curPlayer, "passiveset", "passiveset", Def_RunQuestType_Normal)
|
| | | return
|
| | |
|
| | | def EventRespons_PlusGodWeapon(curPlayer):
|
| | | def EventRespons_PlusGodWeapon(curPlayer, weaponType):
|
| | | #神兵锤炼
|
| | | RunQuestEvent(curPlayer, "plusgodweapon", "plusgodweapon", Def_RunQuestType_Normal)
|
| | | RunQuestEvent(curPlayer, "plusgodweapon", weaponType, Def_RunQuestType_Normal)
|
| | | return
|
| | | def EventRespons_GodWeaponUp(curPlayer, weaponType, attrLV):
|
| | | # 神兵升级
|
| | | RunQuestEvent(curPlayer, "godweaponup", "%s_%s"%(weaponType, attrLV), Def_RunQuestType_Normal)
|
| | | return
|
| | |
|
| | | def EventRespons_RefineItem(curPlayer, alchemyLV):
|
| | | def EventRespons_RefineItem(curPlayer, alchemyLV, alchemyItemID):
|
| | | #八卦炉炼丹
|
| | | RunQuestEvent(curPlayer, "refineitem", alchemyLV, Def_RunQuestType_Normal)
|
| | | RunQuestEvent(curPlayer, "refineitem", "refineitem", Def_RunQuestType_Normal)
|
| | | #这两个接口策划暂时不用,先注释,使用新的连某个丹药接口
|
| | | #RunQuestEvent(curPlayer, "refineitem", alchemyLV, Def_RunQuestType_Normal)
|
| | | #RunQuestEvent(curPlayer, "refineitem", "refineitem", Def_RunQuestType_Normal)
|
| | | RunQuestEvent(curPlayer, "refineitem", alchemyItemID, Def_RunQuestType_Normal)
|
| | | return
|
| | |
|
| | | def EventRespons_RefineStoveUp(curPlayer, alchemyLV):
|
| | |
| | | RunQuestEvent(curPlayer, "equipplus", '%s_%s'%(classLV, partPlusLV), Def_RunQuestType_Normal)
|
| | | return
|
| | |
|
| | | def EventRespons_EquipStar(curPlayer):
|
| | | #装备总星级变化
|
| | | RunQuestEvent(curPlayer, "equipstar", "equipstar", Def_RunQuestType_Normal)
|
| | | def EventRespons_EquipPlusEvolve(curPlayer, nextEvolveLV):
|
| | | #强化进化
|
| | | RunQuestEvent(curPlayer, "equipplusevolve", "equipplusevolve", Def_RunQuestType_Normal)
|
| | | return
|
| | |
|
| | | def EventRespons_Talk(curPlayer, eventName):
|
| | | #频道发言
|
| | | RunQuestEvent(curPlayer, "talk", eventName, Def_RunQuestType_Normal)
|
| | | return
|
| | |
|
| | | def EventRespons_FairyDomain(curPlayer, eventType):
|
| | | #完成缥缈仙域事件
|
| | | RunQuestEvent(curPlayer, "fairydomain", 'fairydomain', Def_RunQuestType_Normal)
|
| | | RunQuestEvent(curPlayer, "fairydomain", eventType, Def_RunQuestType_Normal)
|
| | | return
|
| | |
|
| | | def EventRespons_AroundMission(curPlayer, missionType):
|
| | | #完成跑环任务
|
| | | RunQuestEvent(curPlayer, "aroundfinish", missionType, Def_RunQuestType_Normal)
|
| | | return
|
| | |
|
| | | def EventRespons_Pray(curPlayer, prayType):
|
| | | #完成祈愿
|
| | | RunQuestEvent(curPlayer, "pray", prayType, Def_RunQuestType_Normal)
|
| | | return
|
| | |
|
| | | def EventRespons_ThinkMagicWeapon(curPlayer):
|
| | | #感应法宝
|
| | | RunQuestEvent(curPlayer, "thinkfabao", 'thinkfabao', Def_RunQuestType_Normal)
|
| | | return
|
| | |
|
| | | def EventRespons_ElementSkill(curPlayer, mainSkillID, skillElementType, updSelectSkillLV):
|
| | | #激活五行专精 主技能ID_专精类型_激活等级.xml
|
| | | RunQuestEvent(curPlayer, "elementskill", '%s_%s_%s'%(mainSkillID, skillElementType, updSelectSkillLV), Def_RunQuestType_Normal)
|
| | | return
|
| | |
|
| | | def EventRespons_EquipStarUp(curPlayer):
|
| | | #装备升星
|
| | | RunQuestEvent(curPlayer, "equipstarup", 'equipstarup', Def_RunQuestType_Normal)
|
| | | return
|
| | |
|
| | | def EventRespons_InlayStone(curPlayer):
|
| | | #宝石镶嵌
|
| | | RunQuestEvent(curPlayer, "inlaystone", 'inlaystone', Def_RunQuestType_Normal)
|
| | | return
|
| | |
|
| | | def EventRespons_StoneChange(curPlayer):
|
| | | # 宝石变更
|
| | | RunQuestEvent(curPlayer, "stonechange", 'stonechange', Def_RunQuestType_Normal)
|
| | | return
|
| | |
|
| | | def EventRespons_EquipItem(curPlayer):
|
| | | #穿脱装备
|
| | | RunQuestEvent(curPlayer, "equipitem", 'equipitem', Def_RunQuestType_Normal)
|
| | | return
|
| | |
|
| | | def EventRespons_SkillUp(curPlayer, FuncType, skillLV):
|
| | | #升级技能
|
| | | RunQuestEvent(curPlayer, "skillup", FuncType, Def_RunQuestType_Normal)
|
| | | RunQuestEvent(curPlayer, "skillup", '%s_%s' % (FuncType, skillLV), Def_RunQuestType_Normal)
|
| | | return
|
| | |
|
| | | def EventRespons_LingGenQualityUP(curPlayer, attrID, qualityLV):
|
| | | #灵根升品
|
| | | RunQuestEvent(curPlayer, "linggenqualityup", '%s_%s' % (attrID, qualityLV), Def_RunQuestType_Normal)
|
| | | return
|
| | |
|
| | | def EventRespons_AddPoint(curPlayer):
|
| | | #灵根加点
|
| | | RunQuestEvent(curPlayer, "addpoint", '0', Def_RunQuestType_Normal)
|
| | | return
|
| | |
|
| | | def EventRespons_ActivityAward(curPlayer, awardIndex):
|
| | | #活跃领奖
|
| | | RunQuestEvent(curPlayer, "activityaward", awardIndex, Def_RunQuestType_Normal)
|
| | | return
|
| | |
|
| | | def EventRespons_AddActivityValue(curPlayer):
|
| | | # 增加活跃度
|
| | | RunQuestEvent(curPlayer, "addactivity", "addactivity", Def_RunQuestType_Normal)
|
| | | return
|
| | |
|
| | | def EventRespons_HorsePetBoss(curPlayer):
|
| | | #参加骑宠BOSS
|
| | | RunQuestEvent(curPlayer, "horsepetboss", 'horsepetboss', Def_RunQuestType_Normal)
|
| | | return
|
| | |
|
| | | def EventRespons_LingGenReset(curPlayer):
|
| | | #灵根重置
|
| | | RunQuestEvent(curPlayer, "linggenreset", 'linggenreset', Def_RunQuestType_Normal)
|
| | | return
|
| | |
|
| | | def EventRespons_UseMissionItem(curPlayer, missionID):
|
| | | # 使用物品触发任务
|
| | | RunQuestEvent(curPlayer, "usemissionitem", missionID, Def_RunQuestType_RunAll)
|
| | | return
|
| | |
|
| | | def EventRespons_XBXZ(curPlayer, MWID):
|
| | | # 仙宝寻主领奖
|
| | | RunQuestEvent(curPlayer, "xbxz", MWID, Def_RunQuestType_Normal)
|
| | | return
|
| | |
|
| | | #---------------------------------------------------------------------
|
| | |
|
| | | #================================================================================
|
| | |
| | | ExitCreateFamily(curPlayer)
|
| | | ExitBillboard(curPlayer)
|
| | | #ExitEventLock(curPlayer)
|
| | | #ExitShopItem(curPlayer) # 奇迹只在切地图及下线时关闭摆摊
|
| | | #ExitWatchShopItem(curPlayer)
|
| | | #npc商店退出
|
| | | ExitNPCShop(curPlayer)
|
| | |
|
| | |
| | | PlayerControl.NomalDictSetProperty(curPlayer, ChConfig.Def_Player_Dict_PyPlayerAction, 0)
|
| | | return
|
| | |
|
| | |
|
| | | ##结束摆摊事件
|
| | | #@param curPlayer 玩家实例
|
| | | #@return 返回值无意义
|
| | | #@remarks 自定义函数:结束摆摊事件
|
| | | def ExitShopItem(curPlayer):
|
| | | GameWorld.DebugLog("ExitShopItem", curPlayer.GetPlayerID())
|
| | | playerShop = curPlayer.GetPlayerShop()
|
| | | #在摆摊状态
|
| | | if playerShop.GetIsStartShop():
|
| | | PlayerShopItem.DoExitShop(curPlayer , curPlayer.GetPlayerShop())
|
| | | |
| | | return
|
| | | #---------------------------------------------------------------------
|
| | | ##结束查看摆摊事件
|
| | | #@param curPlayer 玩家实例
|
| | | #@return 返回值无意义
|
| | | #@remarks 自定义函数:结束查看摆摊事件
|
| | | def ExitWatchShopItem(curPlayer):
|
| | | curPlayerShop = curPlayer.GetPlayerShop()
|
| | | |
| | | if not curPlayerShop.GetIsWatchingShop():
|
| | | return
|
| | |
|
| | | openShopPlayer = curPlayer.GetActionPlayer()
|
| | | __DoExitWatchShopItem(curPlayer , openShopPlayer)
|
| | | |
| | | curPlayerShop.SetIsWatchingShop(0) |
| | | return
|
| | | #---------------------------------------------------------------------
|
| | | ##结束查看摆摊事件
|
| | | #@param curPlayer 玩家实例
|
| | | #@return 返回值无意义
|
| | | #@remarks 自定义函数:结束查看摆摊事件
|
| | | def __DoExitWatchShopItem(curPlayer , openShopPlayer):
|
| | | |
| | | if openShopPlayer == None:
|
| | | return
|
| | | |
| | | shop = openShopPlayer.GetPlayerShop()
|
| | | #没有开店
|
| | | if not shop.GetIsStartShop():
|
| | | return
|
| | | |
| | | #商店删除这个玩家
|
| | | shop.DeleteWatchPlayer(curPlayer.GetPlayerID())
|
| | | return
|
| | |
|
| | | #---------------------------------------------------------------------
|
| | | ##结束事件锁
|
| | | #@param curPlayer 玩家实例
|
| | | #@return 返回值无意义
|
| | | #@remarks 自定义函数:结束事件锁
|
| | | #===============================================================================
|
| | | # def ExitEventLock(curPlayer):
|
| | | # if not curPlayer.GetHaveSetEventLock() :
|
| | | # return
|
| | | # |
| | | # #在摆摊状态不解锁,奇迹摆摊物品解锁只在切地图/下线/玩家主动结束摆摊情况下解锁
|
| | | # playerShop = curPlayer.GetPlayerShop()
|
| | | # if playerShop.GetIsStartShop():
|
| | | # return
|
| | | # |
| | | # #获得玩家物品管理器
|
| | | # ItemManager = curPlayer.GetItemManager()
|
| | | # #获得背包
|
| | | # curPack = ItemManager.GetPack(IPY_GameWorld.rptItem)
|
| | | # for i in range(curPack.GetCount()):
|
| | | # item = curPack.GetAt(i)
|
| | | # if item == None or item.IsEmpty():
|
| | | # continue
|
| | | # |
| | | # if not item.GetIsEventLocked():
|
| | | # continue
|
| | | # |
| | | # #离开事件锁
|
| | | # item.SetIsEventLocked(False)
|
| | | #===============================================================================
|
| | | |
| | | #---------------------------------------------------------------------
|
| | | ##结束查看排行榜
|
| | | #@param curPlayer 玩家实例
|