robotmega
|
  |
| Joined: 16 May 2009 |
| Total Posts: 14084 |
|
|
| 19 Jun 2013 12:07 AM |
So i made a local script that shoots bullets, but for some reason people can't hear, except me. knife is a sound i added somewhere in script. i already tried removing the "local" in local kj=knife:clone()
coroutine.resume(coroutine.create(function() local kj=knife:clone() kj.Looped=false kj.Parent=shur kj:play() wait(.4) kj:stop() wait() kj:Destroy() end))
|
|
|
| Report Abuse |
|
|
robotmega
|
  |
| Joined: 16 May 2009 |
| Total Posts: 14084 |
|
| |
|
robotmega
|
  |
| Joined: 16 May 2009 |
| Total Posts: 14084 |
|
|
| 19 Jun 2013 12:10 AM |
| and btw if i remove local in the bullet(cuz its local Instance.new("Part"), it will break the trail script and lag) |
|
|
| Report Abuse |
|
|
|
| 19 Jun 2013 12:10 AM |
| Did you use a localscript? If you did, use a normal script. |
|
|
| Report Abuse |
|
|
|
| 19 Jun 2013 12:13 AM |
| Use a bindablefunction or bindableevent and play the sound in a normal script. Look them up on the wiki. |
|
|
| Report Abuse |
|
|
robotmega
|
  |
| Joined: 16 May 2009 |
| Total Posts: 14084 |
|
|
| 19 Jun 2013 12:14 AM |
| lolno just no, script needs to be local yes or yes, |
|
|
| Report Abuse |
|
|
|
| 19 Jun 2013 12:17 AM |
LOOK UP "BINDABLEFUNCTION"/"BINDABLEEVENT" you can still use a localscript. |
|
|
| Report Abuse |
|
|
robotmega
|
  |
| Joined: 16 May 2009 |
| Total Posts: 14084 |
|
|
| 19 Jun 2013 12:22 AM |
| i dont understand what wiki says about bindable thing |
|
|
| Report Abuse |
|
|
|
| 19 Jun 2013 12:24 AM |
Script 1:
local Soundy = Instance.new("BindableEvent",script.Parent) script.Parent:FindFirstChild("Sound Script").Parent = Soundy
Spawn(function() Soundy:Fire(knife:Clone(),shur) end)
script 2: --Make this a normal script put is in the same place where the other script is. Name it "Sound script"
if not script.Parent:IsA("BindableEvent") then script.Disabled = true end script.Parent.Event:connect(function(Sound,Bullet) Sound.Parent = Bullet Sound:Play() wait(.4) Sound:Stop() wait() Bullet:Destroy() end)
|
|
|
| Report Abuse |
|
|
|
| 19 Jun 2013 12:25 AM |
Make sure to put this part at the top(ish) of your script. ""local Soundy = Instance.new("BindableEvent",script.Parent) script.Parent:FindFirstChild("Sound Script").Parent = Soundy |
|
|
| Report Abuse |
|
|
robotmega
|
  |
| Joined: 16 May 2009 |
| Total Posts: 14084 |
|
|
| 19 Jun 2013 12:29 AM |
| but this is a script builder script. |
|
|
| Report Abuse |
|
|
robotmega
|
  |
| Joined: 16 May 2009 |
| Total Posts: 14084 |
|
|
| 19 Jun 2013 12:30 AM |
| so it must be everything in 1 local script |
|
|
| Report Abuse |
|
|
|
| 19 Jun 2013 12:34 AM |
Problem solved: Don't make script builder scripts. |
|
|
| Report Abuse |
|
|