diff --git a/lua_probject/base_project/Game/Controller/GameController.lua b/lua_probject/base_project/Game/Controller/GameController.lua index 634d1b7f..4710f130 100644 --- a/lua_probject/base_project/Game/Controller/GameController.lua +++ b/lua_probject/base_project/Game/Controller/GameController.lua @@ -29,6 +29,9 @@ GameEvent = { --麻将修改牌大小 MJModifySzie = 'MJModifySzie', + + --翻字 + FangziAnimation = "FangziAnimation", } --- Base GameController @@ -650,3 +653,7 @@ end function M:OnEvtExieWitness(msg) DispatchEvent(self._dispatcher, GameEvent.WitnessPlayerLeave, msg.playyer) end + +function M:OnEventFzAction(msg) + DispatchEvent(self._dispatcher, GameEvent.FangziAnimation, msg) +end diff --git a/lua_probject/base_project/Game/Controller/GroupMgrController.lua b/lua_probject/base_project/Game/Controller/GroupMgrController.lua index 30a47765..db357690 100644 --- a/lua_probject/base_project/Game/Controller/GroupMgrController.lua +++ b/lua_probject/base_project/Game/Controller/GroupMgrController.lua @@ -17,6 +17,7 @@ GroupMgrEvent = { ChatRoomData = "ChatRoomData", OnNewApply = "OnNewApply", OnNewRecord = "OnNewRecord", + OnMemberState = "OnMemberState", } GroupMgrController = { @@ -55,6 +56,7 @@ function GroupMgrController.new() self._eventmap[Protocol.FGMGR_EVT_ISOPEN_CHATROOM] = self.FG_Isopen_ChatRoom self._eventmap[Protocol.FGMGR_EVT_DATA_CHATROOM] = self.FG_Data_ChatRoom self._eventmap[Protocol.FGMGR_EVT_NEWCHAT] = self.FG_Data_NewChat + self._eventmap[Protocol.FGMGR_EVT_Member_State] = self.FG_Data_Member_State -- self:connect(callback) return self end @@ -401,6 +403,12 @@ function M:FG_Data_NewChat(evt_data) DispatchEvent(self._dispatcher, GroupMgrEvent.OnNewRecord, evt_data) end +function M:FG_Data_Member_State(evt_data) + print("收到成员状态推送") + pt(evt_data) + DispatchEvent(self._dispatcher, GroupMgrEvent.OnMemberState, evt_data) +end + function M:PopEvent() local _cacheEvent = self._cacheEvent if (_cacheEvent:Count() > 0) then diff --git a/lua_probject/base_project/Game/View/MainView.lua b/lua_probject/base_project/Game/View/MainView.lua index e59a1740..ae22f671 100644 --- a/lua_probject/base_project/Game/View/MainView.lua +++ b/lua_probject/base_project/Game/View/MainView.lua @@ -6,6 +6,14 @@ local SettingView = import('.SettingView') local PlayerDistanceView = import('.PlayerDistanceView') local FGAssistView = import('.FGAssistView') +local function GetSeat(data, uId) + for _,player in pairs(data.player_list) do + if player.self_user.account_id == uId then + return player.seat + end + end +end + --lingmeng新全局标记 lingmengxin = false @@ -702,6 +710,8 @@ function M:EventInit() _gamectr:AddEventListener(GameEvent.PlayerReady, handler(self, self.OnPlayerReady)) + _gamectr:AddEventListener(GameEvent.FangziAnimation, handler(self, self.OnFangziAnimation)) + _gamectr:AddEventListener( GameEvent.DeskBreak, function(...) @@ -986,6 +996,19 @@ function M:OnPlayerReady(...) printlog("基类准备++++++++++++++++++++++++++") end +-- 飘字 +function M:OnFangziAnimation(...) + print("OnFangziAnimation") + local arg = {...} + pt(arg) + local fz = arg[1] + local playerid = arg[1].playerid + local fromPlayer = arg[1].from_seat + local type = arg[1].type + + local player = self._player_info[self:GetPos(playerid)] +end + function M:OnUpdateInfo(...) local arg = { ... } local p = arg[1] diff --git a/lua_probject/extend_project/extend/majiang/100zhang/EXGameController.lua b/lua_probject/extend_project/extend/majiang/100zhang/EXGameController.lua index d2ae2467..21bffa3f 100644 --- a/lua_probject/extend_project/extend/majiang/100zhang/EXGameController.lua +++ b/lua_probject/extend_project/extend/majiang/100zhang/EXGameController.lua @@ -211,6 +211,7 @@ function M:OnEventFzTips(evt_data) end function M:OnEventFzAction(evt_data) + GameController.OnEventFzAction(self, evt_data) printlog("吃杠碰行为事件===========>>>") pt(evt_data) local _room = self._room diff --git a/lua_probject/extend_project/extend/majiang/changsha/EXGameController.lua b/lua_probject/extend_project/extend/majiang/changsha/EXGameController.lua index acd03944..9fc3f809 100644 --- a/lua_probject/extend_project/extend/majiang/changsha/EXGameController.lua +++ b/lua_probject/extend_project/extend/majiang/changsha/EXGameController.lua @@ -221,6 +221,7 @@ function M:OnEventFzTips(evt_data) end function M:OnEventFzAction(evt_data) + GameController.OnEventFzAction(self, evt_data) local _room = self._room local playerid = evt_data["playerid"] local card = evt_data["card"] diff --git a/lua_probject/extend_project/extend/majiang/chaoshan/EXGameController.lua b/lua_probject/extend_project/extend/majiang/chaoshan/EXGameController.lua index d75c1cb2..c9813b6a 100644 --- a/lua_probject/extend_project/extend/majiang/chaoshan/EXGameController.lua +++ b/lua_probject/extend_project/extend/majiang/chaoshan/EXGameController.lua @@ -211,6 +211,7 @@ function M:OnEventFzTips(evt_data) end function M:OnEventFzAction(evt_data) + GameController.OnEventFzAction(self, evt_data) printlog("吃杠碰行为事件===========>>>") pt(evt_data) local _room = self._room diff --git a/lua_probject/extend_project/extend/majiang/chaozhou/EXGameController.lua b/lua_probject/extend_project/extend/majiang/chaozhou/EXGameController.lua index 420e67c0..59c45e36 100644 --- a/lua_probject/extend_project/extend/majiang/chaozhou/EXGameController.lua +++ b/lua_probject/extend_project/extend/majiang/chaozhou/EXGameController.lua @@ -213,6 +213,7 @@ function M:OnEventFzTips(evt_data) end function M:OnEventFzAction(evt_data) + GameController.OnEventFzAction(self, evt_data) printlog("吃杠碰行为事件===========>>>") pt(evt_data) local _room = self._room diff --git a/lua_probject/extend_project/extend/majiang/chaozhougui/EXGameController.lua b/lua_probject/extend_project/extend/majiang/chaozhougui/EXGameController.lua index 420e67c0..59c45e36 100644 --- a/lua_probject/extend_project/extend/majiang/chaozhougui/EXGameController.lua +++ b/lua_probject/extend_project/extend/majiang/chaozhougui/EXGameController.lua @@ -213,6 +213,7 @@ function M:OnEventFzTips(evt_data) end function M:OnEventFzAction(evt_data) + GameController.OnEventFzAction(self, evt_data) printlog("吃杠碰行为事件===========>>>") pt(evt_data) local _room = self._room diff --git a/lua_probject/extend_project/extend/majiang/fuzhou/EXGameController.lua b/lua_probject/extend_project/extend/majiang/fuzhou/EXGameController.lua index a500e8b7..551791a5 100644 --- a/lua_probject/extend_project/extend/majiang/fuzhou/EXGameController.lua +++ b/lua_probject/extend_project/extend/majiang/fuzhou/EXGameController.lua @@ -250,6 +250,7 @@ function M:OnEventFzTips(evt_data) end function M:OnEventFzAction(evt_data) + GameController.OnEventFzAction(self, evt_data) local _room = self._room local playerid = evt_data["playerid"] local card = evt_data["card"] diff --git a/lua_probject/extend_project/extend/majiang/gejiu/EXGameController.lua b/lua_probject/extend_project/extend/majiang/gejiu/EXGameController.lua index cd808d0b..a94c7765 100644 --- a/lua_probject/extend_project/extend/majiang/gejiu/EXGameController.lua +++ b/lua_probject/extend_project/extend/majiang/gejiu/EXGameController.lua @@ -214,6 +214,7 @@ function M:OnEventFzTips(evt_data) end function M:OnEventFzAction(evt_data) + GameController.OnEventFzAction(self, evt_data) local _room = self._room local playerid = evt_data["playerid"] local card = evt_data["card"] diff --git a/lua_probject/extend_project/extend/majiang/hongzhong/EXGameController.lua b/lua_probject/extend_project/extend/majiang/hongzhong/EXGameController.lua index b89f9cd7..2d68c53e 100644 --- a/lua_probject/extend_project/extend/majiang/hongzhong/EXGameController.lua +++ b/lua_probject/extend_project/extend/majiang/hongzhong/EXGameController.lua @@ -230,6 +230,7 @@ function M:OnEventFzTips(evt_data) end function M:OnEventFzAction(evt_data) + GameController.OnEventFzAction(self, evt_data) local _room = self._room local playerid = evt_data["playerid"] local card = evt_data["card"] diff --git a/lua_probject/extend_project/extend/majiang/jinxi/EXGameController.lua b/lua_probject/extend_project/extend/majiang/jinxi/EXGameController.lua index b312ab64..1fd228f1 100644 --- a/lua_probject/extend_project/extend/majiang/jinxi/EXGameController.lua +++ b/lua_probject/extend_project/extend/majiang/jinxi/EXGameController.lua @@ -250,6 +250,7 @@ function M:OnEventFzTips(evt_data) end function M:OnEventFzAction(evt_data) + GameController.OnEventFzAction(self, evt_data) local _room = self._room local playerid = evt_data["playerid"] local card = evt_data["card"] diff --git a/lua_probject/extend_project/extend/majiang/lichuan/EXGameController.lua b/lua_probject/extend_project/extend/majiang/lichuan/EXGameController.lua index 13ac9c94..985c8c40 100644 --- a/lua_probject/extend_project/extend/majiang/lichuan/EXGameController.lua +++ b/lua_probject/extend_project/extend/majiang/lichuan/EXGameController.lua @@ -251,6 +251,7 @@ function M:OnEventFzTips(evt_data) end function M:OnEventFzAction(evt_data) + GameController.OnEventFzAction(self, evt_data) local _room = self._room local playerid = evt_data["playerid"] local card = evt_data["card"] diff --git a/lua_probject/extend_project/extend/majiang/nancheng/EXGameController.lua b/lua_probject/extend_project/extend/majiang/nancheng/EXGameController.lua index c14c31bb..d885a18a 100644 --- a/lua_probject/extend_project/extend/majiang/nancheng/EXGameController.lua +++ b/lua_probject/extend_project/extend/majiang/nancheng/EXGameController.lua @@ -250,6 +250,7 @@ function M:OnEventFzTips(evt_data) end function M:OnEventFzAction(evt_data) + GameController.OnEventFzAction(self, evt_data) local _room = self._room local playerid = evt_data["playerid"] local card = evt_data["card"] diff --git a/lua_probject/extend_project/extend/majiang/qizhiba/EXGameController.lua b/lua_probject/extend_project/extend/majiang/qizhiba/EXGameController.lua index 1a879c74..a00cdc65 100644 --- a/lua_probject/extend_project/extend/majiang/qizhiba/EXGameController.lua +++ b/lua_probject/extend_project/extend/majiang/qizhiba/EXGameController.lua @@ -246,6 +246,7 @@ function M:OnEventFzTips(evt_data) end function M:OnEventFzAction(evt_data) + GameController.OnEventFzAction(self, evt_data) printlog("吃杠碰行为事件===========>>>") pt(evt_data) diff --git a/lua_probject/extend_project/extend/majiang/tuidaohu/EXGameController.lua b/lua_probject/extend_project/extend/majiang/tuidaohu/EXGameController.lua index 07126dc3..7ae817d2 100644 --- a/lua_probject/extend_project/extend/majiang/tuidaohu/EXGameController.lua +++ b/lua_probject/extend_project/extend/majiang/tuidaohu/EXGameController.lua @@ -201,6 +201,7 @@ function M:OnEventFzTips(evt_data) end function M:OnEventFzAction(evt_data) + GameController.OnEventFzAction(self, evt_data) local _room = self._room local playerid = evt_data["playerid"] local card = evt_data["card"] diff --git a/lua_probject/extend_project/extend/majiang/zhuanzhuan/EXGameController.lua b/lua_probject/extend_project/extend/majiang/zhuanzhuan/EXGameController.lua index a2de4c84..4ce33330 100644 --- a/lua_probject/extend_project/extend/majiang/zhuanzhuan/EXGameController.lua +++ b/lua_probject/extend_project/extend/majiang/zhuanzhuan/EXGameController.lua @@ -227,6 +227,7 @@ function M:OnEventFzTips(evt_data) end function M:OnEventFzAction(evt_data) + GameController.OnEventFzAction(self, evt_data) local _room = self._room local playerid = evt_data["playerid"] local card = evt_data["card"] diff --git a/lua_probject/extend_project/extend/zipai/changdepaohuzi/EXGameController.lua b/lua_probject/extend_project/extend/zipai/changdepaohuzi/EXGameController.lua index 217d4b02..f91e05bd 100644 --- a/lua_probject/extend_project/extend/zipai/changdepaohuzi/EXGameController.lua +++ b/lua_probject/extend_project/extend/zipai/changdepaohuzi/EXGameController.lua @@ -266,6 +266,7 @@ function M:OnEventFzTips(evt_data) end function M:OnEventFzAction(evt_data) + GameController.OnEventFzAction(self, evt_data) local _room = self._room local playerid = evt_data["playerid"] local card = evt_data["card"] diff --git a/lua_probject/extend_project/extend/zipai/fulushou/EXGameController.lua b/lua_probject/extend_project/extend/zipai/fulushou/EXGameController.lua index 1049f524..53b93d29 100644 --- a/lua_probject/extend_project/extend/zipai/fulushou/EXGameController.lua +++ b/lua_probject/extend_project/extend/zipai/fulushou/EXGameController.lua @@ -380,6 +380,7 @@ function M:OnEventFzTips(evt_data) end function M:OnEventFzAction(evt_data) + GameController.OnEventFzAction(self, evt_data) printlog("放子行为事件===》》》") pt(evt_data) diff --git a/lua_probject/extend_project/extend/zipai/hsrunbeard/EXGameController.lua b/lua_probject/extend_project/extend/zipai/hsrunbeard/EXGameController.lua index cb129fe5..004415c0 100644 --- a/lua_probject/extend_project/extend/zipai/hsrunbeard/EXGameController.lua +++ b/lua_probject/extend_project/extend/zipai/hsrunbeard/EXGameController.lua @@ -268,6 +268,7 @@ function M:OnEventFzTips(evt_data) end function M:OnEventFzAction(evt_data) + GameController.OnEventFzAction(self, evt_data) local _room = self._room local playerid = evt_data["playerid"] local card = evt_data["card"] diff --git a/lua_probject/extend_project/extend/zipai/runbeard/EXGameController.lua b/lua_probject/extend_project/extend/zipai/runbeard/EXGameController.lua index 0a7c0ecb..382f14e2 100644 --- a/lua_probject/extend_project/extend/zipai/runbeard/EXGameController.lua +++ b/lua_probject/extend_project/extend/zipai/runbeard/EXGameController.lua @@ -299,6 +299,7 @@ function M:OnEventFangWei(evt_data) end function M:OnEventFzAction(evt_data) + GameController.OnEventFzAction(self, evt_data) printlog("jefe EventFz 操作提示===>>>>") local _room = self._room local playerid = evt_data["playerid"] diff --git a/lua_probject/extend_project/extend/zipai/yueyangwaihuzi/EXGameController.lua b/lua_probject/extend_project/extend/zipai/yueyangwaihuzi/EXGameController.lua index 4924c315..2d184c0d 100644 --- a/lua_probject/extend_project/extend/zipai/yueyangwaihuzi/EXGameController.lua +++ b/lua_probject/extend_project/extend/zipai/yueyangwaihuzi/EXGameController.lua @@ -319,6 +319,7 @@ function M:OnEventFzTips(evt_data) end function M:OnEventFzAction(evt_data) + GameController.OnEventFzAction(self, evt_data) printlog("放子行为提示事件===》》》") pt(evt_data) local _room = self._room diff --git a/lua_probject/extend_project/extend/zipai/yueyangwaihuzi_bak/EXGameController.lua b/lua_probject/extend_project/extend/zipai/yueyangwaihuzi_bak/EXGameController.lua index 81e93874..57e1ab85 100644 --- a/lua_probject/extend_project/extend/zipai/yueyangwaihuzi_bak/EXGameController.lua +++ b/lua_probject/extend_project/extend/zipai/yueyangwaihuzi_bak/EXGameController.lua @@ -320,6 +320,7 @@ function M:OnEventFzTips(evt_data) end function M:OnEventFzAction(evt_data) + GameController.OnEventFzAction(self, evt_data) printlog("放子行为提示事件===》》》") pt(evt_data) local _room = self._room diff --git a/wb_new_ui/assets/Common/package.xml b/wb_new_ui/assets/Common/package.xml index 39a5e960..92ad09be 100644 --- a/wb_new_ui/assets/Common/package.xml +++ b/wb_new_ui/assets/Common/package.xml @@ -2097,6 +2097,7 @@ + diff --git a/wb_new_ui/assets/Main_Majiang/Main_new/Main/PlayerHead_1.xml b/wb_new_ui/assets/Main_Majiang/Main_new/Main/PlayerHead_1.xml index 228ec16a..8d252c7e 100644 --- a/wb_new_ui/assets/Main_Majiang/Main_new/Main/PlayerHead_1.xml +++ b/wb_new_ui/assets/Main_Majiang/Main_new/Main/PlayerHead_1.xml @@ -2,7 +2,7 @@ - + @@ -10,6 +10,7 @@ + @@ -68,5 +69,11 @@ + + + + + + \ No newline at end of file diff --git a/wb_new_ui/assets/Main_Majiang/package.xml b/wb_new_ui/assets/Main_Majiang/package.xml index 52989531..d2af391d 100644 --- a/wb_new_ui/assets/Main_Majiang/package.xml +++ b/wb_new_ui/assets/Main_Majiang/package.xml @@ -1423,6 +1423,18 @@ + + + + + + + + + + + + \ No newline at end of file diff --git a/wb_new_ui/assets/NewGroup/mgr/View_GroupGameSetting.xml b/wb_new_ui/assets/NewGroup/mgr/View_GroupGameSetting.xml index 18dc08a9..9a8a6687 100644 --- a/wb_new_ui/assets/NewGroup/mgr/View_GroupGameSetting.xml +++ b/wb_new_ui/assets/NewGroup/mgr/View_GroupGameSetting.xml @@ -4,6 +4,7 @@ +