smiley599
|
  |
| Joined: 23 Jan 2010 |
| Total Posts: 21869 |
|
|
| 18 Nov 2013 11:23 AM |
i have made my own chat gui, but people can use profanity
how do i avoid this? |
|
|
| Report Abuse |
|
|
robotmega
|
  |
| Joined: 16 May 2009 |
| Total Posts: 14084 |
|
| |
|
smiley599
|
  |
| Joined: 23 Jan 2010 |
| Total Posts: 21869 |
|
| |
|
|
| 18 Nov 2013 11:30 AM |
ROBLOX has an automatic blacklist. However, if you want to make your own, you could try this (untested, sorry, I can't open ROBLOX at the moment):
local blacklist = {"badword"} -- A list of bad words
function check(msg) for i, word in pairs(blacklist) do local word = word:lower() local index = 0 while (msg:lower():find(word, index)) do local start, end = msg:find(word, index) msg = msg:sub(1, start - 1)..("#"):rep(#word)..msg:sub(end + 1) -- You may need to adjust the "- 1" and "+ 1" if parts of the words are being cut off. (Again, I can't test this. Sorry) index = end end end return msg end
Wiki Profile: http://wiki.roblox.com/index.php/User:Nelson |
|
|
| Report Abuse |
|
|
|
| 18 Nov 2013 01:26 PM |
| Were you able to forcefocus on the gui when / is pressed :O |
|
|
| Report Abuse |
|
|
crouton04
|
  |
| Joined: 07 Jul 2010 |
| Total Posts: 4459 |
|
|
| 18 Nov 2013 01:35 PM |
lol
if message:find(badword[i]) do |
|
|
| Report Abuse |
|
|
smiley599
|
  |
| Joined: 23 Jan 2010 |
| Total Posts: 21869 |
|
| |
|
|
| 18 Nov 2013 01:40 PM |
what is forefocus? --- Nothing. |
|
|
| Report Abuse |
|
|
|
| 18 Nov 2013 01:51 PM |
I might have said the name wrong but its not nothing It like makes it so you are typing inside that box |
|
|
| Report Abuse |
|
|
|
| 18 Nov 2013 07:52 PM |
To force the user to focus on a TextBox, you can use the CaptureFocus method. Here's an example that focuses on a TextBox whenever you hit the "T" key:
game.Players.LocalPlayer:GetMouse().KeyDown:connect(function(key) if (key:upper() == "T") then script.Parent.TextBox:CaptureFocus() end end)
Wiki Profile: http://wiki.roblox.com/index.php/User:Nelson |
|
|
| Report Abuse |
|
|
|
| 18 Nov 2013 07:57 PM |
assuming msg is a variable for the chatted message
blacklist = {list}
for i, v inpairs(blacklist) do if msg == v then msg:remove() end end |
|
|
| Report Abuse |
|
|
|
| 19 Nov 2013 12:41 AM |
@MrDanelson Wait so its not locked?! |
|
|
| Report Abuse |
|
|
|
| 19 Nov 2013 12:51 AM |
@Scriptural Apparently not... On that note, I'm going to go update the Wiki page :3
Wiki Profile: http://wiki.roblox.com/index.php/User:Nelson |
|
|
| Report Abuse |
|
|
|
| 19 Nov 2013 12:54 AM |
Yah I checked the wiki and checked the last updated xP I was like What that was recently today Did you test it? Is it really not locked anymore? :D |
|
|
| Report Abuse |
|
|
cntkillme
|
  |
| Joined: 07 Apr 2008 |
| Total Posts: 44956 |
|
|
| 19 Nov 2013 12:55 AM |
OMG NOT LOCKED XDD making my own chat gui soon |
|
|
| Report Abuse |
|
|
|
| 19 Nov 2013 01:03 AM |
@Scriptural Yeah, I tested it :D
@cntkillme Along with that, we now deal with a whole new era of script builder abusers.
Wiki Profile: http://wiki.roblox.com/index.php/User:Nelson |
|
|
| Report Abuse |
|
|
|
| 19 Nov 2013 01:06 AM |
Omg Ong Ifnw Iwiauq So gonna make my own chat gui and then create a Chatted event for it |
|
|
| Report Abuse |
|
|
|
| 19 Nov 2013 01:10 AM |
dem metatabulz?
Wiki Profile: http://wiki.roblox.com/index.php/User:Nelson |
|
|
| Report Abuse |
|
|
|
| 19 Nov 2013 01:16 AM |
| Use tables. That would somewhat help. |
|
|
| Report Abuse |
|
|
smiley599
|
  |
| Joined: 23 Jan 2010 |
| Total Posts: 21869 |
|
|
| 19 Nov 2013 01:18 AM |
| I'm confused. What was locked before that did not allow you to make your own chat GUI? I made my own one last week? |
|
|
| Report Abuse |
|
|
|
| 19 Nov 2013 01:19 AM |
@Smile ForceFocus() The wiki and people said it was locked |
|
|
| Report Abuse |
|
|
|
| 19 Nov 2013 01:20 AM |
@Scriptural It was locked, I tried to use it a while back... Wait did ROBLOX just do a good update.....? Yus
Wiki Profile: http://wiki.roblox.com/index.php/User:Nelson |
|
|
| Report Abuse |
|
|
|
| 19 Nov 2013 01:31 AM |
| I know but then it got unlocked who knows when and no one noticed xD |
|
|
| Report Abuse |
|
|
cntkillme
|
  |
| Joined: 07 Apr 2008 |
| Total Posts: 44956 |
|
|
| 19 Nov 2013 01:40 AM |
| lol sb abuse -- here comes focus ban |
|
|
| Report Abuse |
|
|
smiley599
|
  |
| Joined: 23 Jan 2010 |
| Total Posts: 21869 |
|
|
| 19 Nov 2013 01:50 AM |
| The problem is that I realised is that you cannot use profanity in scripting. So most words that are not allowed will not even allowed to be implented in scripting. I could use tags but ain't nobody got time fo dat. |
|
|
| Report Abuse |
|
|