Hi Roblox Community!
I have just released a new module called Speaker Module! Speaker Module lets you easily create NPCs that can talk to players on-screen and in their chat! Here is a quick video of it being used to say an example:
As you can see in the example, the speaker Bob says 2 messages to me (LoveTheBears101), and both appear in the chat. Here is the code I used to make that:
-- Import the module local speak = require(script.Parent.SpeakerModule) -- Create a new speaker speaker = speak.defineSpeaker("Bob", Color3.fromRGB(32, 255, 144), "Gotham", "scale", true, true) --Wait 4 seconds wait(4) -- Speak some text speaker:speak("Something important... blah blah blah! More Text. Why? Goodbye!", "LoveTheBears101") -- Wait speaker:waitUntilFinishedSpeaking() -- Speak some more text speaker:speak("This comes second!", "LoveTheBears101")
These are all the functions:
Don’t forget to
require the module first!
module.defineSpeaker(Name, ChatColor, ChatFont, ChatTextsize, InChat, NPCLabel)
Name - The name of the speaker (String)
ChatColor - The color the person chats in (Color3)
ChatFont - The font the person speaks in (String)
ChatTextSize - The size of the text. Can also be “scale”, which will scale the text according to the screen size (Int or String)
InChat - Whether or not everything the player says goes into the chat (bool)
NPCLabel - Whether or not the person has a
(NPC) next to them in the chat (bool)
Speaker Object - The speaker that you just defined.
message - The message that the speaker says (String)
player - Either the player or player’s name that you want it to speak to (String or Player Instance)
Note: This function will not wait until the speaker has finished speaking to return.
Waits until the speaker is done talking. It takes no parameters and returns nothing. You can also check if the speaker is speaking using
Those are all the functions to create a speaker and make them talk to a player!
If you want to make your speaker talk to everyone, you can do something like this:
for _, player in pairs(game.Players:GetChildren()) do speaker:speak("Your message", player) end
Any questions? Comments? Concerns? Requests? Put them in the replies!!
Get the module here: https://www.roblox.com/library/5805526978
Please help me make it better by answering these questions
How useful do you think this module will be to you?
What best describes your feelings about it?
- I like it, and I think I’ll use it for development
- I like it, but I don’t think I’ll use it for development
- I don’t like it (Please explain)
Hope you enjoy!
- Head develop of Bear Development Team