Scripting Helpers is winding down operations and is now read-only. More info→
Ad
Log in to vote
0

RemoteEvents won't fire at all, they did yesterday, can someone help me?

Asked by 7 years ago

I have actually done quite a few things, the scripts are all good, I put the RemoteEvents in ReplicatedStorage and I have also put a WaitForChild in every script that is needed to fire those events. If there's a solution to this, then I'd be happy. Also, it doesn't work in online mode either.

1 answer

Log in to vote
0
Answered by 7 years ago

If you think it's a Roblox bug, the correct thing to do would be to start a new place and try to recreate the bug with the simplest scripts and fewest objects possible.

However, you say "I have actually done quite a few things", suggesting you probably introduced an error. You should use print statements to diagnose the problem. Put a print statement before and maybe after a RemoteEvent is supposed to be called and see if anything prints out. (Make sure each print statement you use prints out something unique.) If nothing prints out, then your problem is earlier on. Every time you add a print statement, you can figure out if some piece of code is working or not. Find the place where you script begins to not work and you'll have found a bug. Don't forget that you can print out the values of variables, like so:

--Before:
if a < 5 then
    CallRemoteEvent()
end

--After:
print("Before call", a)
if a < 5 then
    print("About to call remote event")
    CallRemoteEvent()
end

--Imagine the output is "Before call 7", then you know why the remote event isn't working and can figure out what's wrong from there
Ad

Answer this question