Search the Community
Showing results for tags 'chat'.
Found 10 results
-
Как реализовывать кастомный чат? У меня есть такое представление по его реализации: Скрыть дефолтный чат, запретить открывать его, с помощью cef вывести свою модель чата и в нее помещать сообщения. Если у меня правильное представление, то подскажите, как текст сообщения, присланный с сервера через SendChatMessage и т.п. функции, вставить в свою модель чата? Если же у меня не верное представление, то как тогда его реализовывать?
-
Version 1.1.0
303 downloads
This resource introduces the known chat scaleform from GTA:O. This chat supports (TEAM, LOCAL, GLOBAL) chats. CONTROLS: T (GLOBAL chat) Y (TEAM chat) U (LOCAL chat) PAGE_UP (Scroll history up) works only when input is opened PAGE_DOWN (Scroll history down) works only when input is opened Known Issues: Message colors aren't supported due to scaleform Other languages than ENGLISH isn't supported (Might be supported in future) API: Client-side API // Client side // Property getter/setter Boolean (Disables/Enables chat input) mp.gui.chat.disabledInput = true; mp.gui.chat.disabledInput // Property getter Boolean (Check if chat is open) mp.gui.chat.enabled; // Function to clear localPlayer's chat feed mp.gui.chat.clear(); // Trigger chat's visibility (visible: Boolean); mp.gui.chat.visible(visible); /* * msg: string * scope: string (message's scope (Author [scope] msg)) * author: string (Default: [SERVER]) * authorColor: int hudColorID (https://wiki.rage.mp/index.php?title=Fonts_and_Colors) (Default: white) */ mp.gui.chat.sendMessage(msg, scope, author, authorColor); /* * Registers command locally for client. * name: string (command name) * arg1: command's arguement */ mp.gui.chat.addCommand(name, function (arg1, arg2) { // do whatever... }); /* * Removes command locally for client. * name: string (command name) */ mp.gui.chat.removeCommand(name); Server-side API /* * Sends message to all players in server * msg: string * scope: string (message's scope (Author [scope] msg)) * author: string (Default: [SERVER]) * authorColor: int hudColorID (https://wiki.rage.mp/index.php?title=Fonts_and_Colors) (Default: white) */ mp.players.announce(msg, scope, author, authorColor); /* * Sends messaage to all players in specified dimension * dimension: int * msg: string * scope: string (message's scope (Author [scope] msg)) * author: string (Default: [SERVER]) * authorColor: int hudColorID (https://wiki.rage.mp/index.php?title=Fonts_and_Colors) (Default: white) */ mp.players.announceInDimension(dimension, msg, scope, author, authorColor); /* * Sends messaage to all players in specified dimension * position: Vector3 * range: int * msg: string * scope: string (message's scope (Author [scope] msg)) * author: string (Default: [SERVER]) * authorColor: int hudColorID (https://wiki.rage.mp/index.php?title=Fonts_and_Colors) (Default: white) */ mp.players.announceInRange(position, range, msg, scope, author, authorColor); /* * Registers commands in chat * name: string (command name) * player: command executer * arg1: Arguement after command */ mp.events.addChatCommand(name, function (player, arg1, arg2) { // Do what you want... }); /* * Removes command from server * name: string (command name) */ mp.events.removeChatCommand(name); /* * Sends message to all players in server * msg: string * scope: string (message's scope (Author [scope] msg)) * author: string (Default: [SERVER]) * authorColor: int hudColorID (https://wiki.rage.mp/index.php?title=Fonts_and_Colors) (Default: white) */ player.sendChatMessage(msg, scope, author, authorColor); // Clears player's chat player.clearChat(); Teams resource is supported. If you have any issues don't hesitate to contact me on Discord/Forums DM. You're not allowed to redistribute this resource without my permission. -
Hello to all! I have a question about chat messaging. I read the OnChatMessage documentation. There was an example for filtering bad words. The [DisableDefaultChat] attribute was used to disable the default chat behavior, but it was written that this attribute was not yet implemented. What can I use instead of this attribute for the same behavior? Thank you in advance
- 9 replies
-
- solved
- server-side
-
(and 1 more)
Tagged with:
-
So I have been trying to get my voice chat to work for the past like 2 hours, It works just fine in normal GTA 5 but when I launch Eclipse-RP no one can hear me, and it doesn't even show the game picking up my mic, I restored settings to default in both the main game and the Eclipse server so all key binds and everything are the same. Cant for the life of me figure out why its not working.
-
Can be deleted.
- 4 replies
-
- Perhaps Dupe
- Perhaps Dupe
-
(and 2 more)
Tagged with:
-
-
Hey! I just want to know, how can i cancel the chat message sending (event), because my code isn't working. Here is my code: mp.events.add("playerChat", (player, text) => { return true; });
