icreator Posted January 7, 2012 Share Posted January 7, 2012 AONotifications.zip ссылка на програмку - внизу страницы вот как я слала сообщения в WhisperWindow Code: function LogToChatWWVT(valuedText, name) local sender = name or ADDONname --- object.GetName(avatar.GetId()) if not common.IsWString(sender) then sender = userMods.ToWString(sender) end local senderId = avatar.IsExist() and avatar.GetId() local chatType = CHAT_TYPE_NOTICE --- -1 ---CHAT_TYPE_NOTICE ---CHAT_TYPE_WHISPER --- = -1 --- от аддонов local recipient = sender userMods.SendEvent("EVENT_CHAT_MESSAGE_WITH_OBJECTS", { msg = valuedText, chatType = chatType, sender = sender, isEcho=true, isAlive=true, recipient = recipient, senderId = senderId}) end Quote Link to comment Share on other sites More sharing options...
icreator Posted January 7, 2012 Author Share Posted January 7, 2012 если надо отследить системное сообщение то Code: function OnEventMatchMakingTeleportRequest( eventParams ) LogInfo("0|Вас пригласили присоедениться к сражению") end function OnEventChatMessage( params ) if params.chatType == CHAT_TYPE_NOTICE then LogInfo("1|Кто-то шепчет вам") end end common.RegisterEventHandler( OnEventMatchMakingTeleportRequest, "EVENT_MATCH_MAKING_EVENT_TELEPORT_REQUEST" ) common.RegisterEventHandler( OnEventChatMessage, "EVENT_CHAT_MESSAGE" ) Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.