U52
|
  |
| Joined: 07 May 2013 |
| Total Posts: 49 |
|
|
| 19 Jan 2014 12:47 PM |
Words = {script.Parent:GetChildren()}
function Chatted(Msg, Speaker) for i= 1, #Words do for AllWords, Word in pairs(Words[i]) do if string.find(Msg, string.lower(Word)) then Chatbox = Instance.new("Dialog") Chatbox.Parent = script.Parent.Parent.Head Mesg = script.Parent:FindFirstChild(Word) Chatbox.InitialPrompt = Mesg.Value Chatbox.InUse = true end end end end
game.Players.ChildAdded:connect(function(Child) if Child.className == "Player" then Child.Chatted:connect(function(Msg)Chatted(Msg, Child)end) end end)
Messed with dat anti-oder script and I'm trying to instead of using a table to just use values in the script's parent.
The name of the Value is what the person must say, and the Value of that is what the Dialog is suppose to say.
The Dialog is then suppose to appear to be in use although the Dialog doesn't change at all when tested. |
|
|
| Report Abuse |
|
|
U52
|
  |
| Joined: 07 May 2013 |
| Total Posts: 49 |
|
| |
|
U52
|
  |
| Joined: 07 May 2013 |
| Total Posts: 49 |
|
|
| 19 Jan 2014 03:44 PM |
bump2
Twenty Seven views, and yet, not a single reply, as I notice there is replies from REAL SCRIPTERS on other threads. |
|
|
| Report Abuse |
|
|
U52
|
  |
| Joined: 07 May 2013 |
| Total Posts: 49 |
|
|
| 19 Jan 2014 03:59 PM |
bump3
Thirty One views, still not a single reply, except bumps. |
|
|
| Report Abuse |
|
|
|
| 19 Jan 2014 04:10 PM |
I seenone error is that your script is doing wordsnfrom scripts parent which also includes this script
|
|
|
| Report Abuse |
|
|
U52
|
  |
| Joined: 07 May 2013 |
| Total Posts: 49 |
|
|
| 19 Jan 2014 04:20 PM |
| Could somebody fix it for me? bump |
|
|
| Report Abuse |
|
|
vlekje513
|
  |
| Joined: 28 Dec 2010 |
| Total Posts: 9057 |
|
|
| 19 Jan 2014 04:21 PM |
| Child.className > ClassName ? (Player function) |
|
|
| Report Abuse |
|
|
|
| 19 Jan 2014 04:23 PM |
| Vlek that is so wrong in so many ways |
|
|
| Report Abuse |
|
|
U52
|
  |
| Joined: 07 May 2013 |
| Total Posts: 49 |
|
|
| 19 Jan 2014 04:27 PM |
| @Andrew: If its 'wrong', fix it then. |
|
|
| Report Abuse |
|
|
|
| 19 Jan 2014 04:29 PM |
| Sorry on mobile I can't fix it atm, alsomi already said the error no need to fix your script |
|
|
| Report Abuse |
|
|
vlekje513
|
  |
| Joined: 28 Dec 2010 |
| Total Posts: 9057 |
|
|
| 19 Jan 2014 04:30 PM |
1: i mean isnt className should be like ClassName? 2: script.Parent:getchildren will also return the script, would that be a problem? |
|
|
| Report Abuse |
|
|
|
| 19 Jan 2014 04:32 PM |
| Vlek 1. Is className and 2. Is correct I said that and yes it is a problem |
|
|
| Report Abuse |
|
|
U52
|
  |
| Joined: 07 May 2013 |
| Total Posts: 49 |
|
| |
|
vlekje513
|
  |
| Joined: 28 Dec 2010 |
| Total Posts: 9057 |
|
|
| 19 Jan 2014 05:07 PM |
U52, error is given, you can fix it. Im on iPad so im not gonna do that. |
|
|
| Report Abuse |
|
|
U52
|
  |
| Joined: 07 May 2013 |
| Total Posts: 49 |
|
| |
|
vlekje513
|
  |
| Joined: 28 Dec 2010 |
| Total Posts: 9057 |
|
| |
|
U52
|
  |
| Joined: 07 May 2013 |
| Total Posts: 49 |
|
| |
|
U52
|
  |
| Joined: 07 May 2013 |
| Total Posts: 49 |
|
| |
|
U52
|
  |
| Joined: 07 May 2013 |
| Total Posts: 49 |
|
| |
|
|
| 19 Jan 2014 06:40 PM |
Words = script.Parent:GetChildren()
|
|
|
| Report Abuse |
|
|