Messaging Service Bug

Hello !

Right now i try to make a Global Nuke for my Game
(I use Messaging Service)
But when i start this script

game:GetService("MessagingService"):PublishAsync("Nukes", "test")

I don’t know why, it make several time the request…

The script :


local ms = game:GetService("MessagingService")

ms:SubscribeAsync("Nukes", function(plr)
	local Clone = script.Parent.Assets.Script.Rig:Clone()
	Clone.Parent = workspace
	local Humanoid = Clone.Humanoid
	script.Parent.Parent = workspace
	Humanoid:LoadAnimation(Clone.Animation):Play()
	Clone.Nuke:Play()
end)

And make bug in every way for Unknown Reason
Like is impossible to Use “ServerScriptService” and return an error

" Server_Main is not a valid member of ServerScriptService “ServerScriptService” "

The error is telling you that “Server_Main” does not exist in ServerScriptService. Not sure where you are referring to that tho.

image

Are you sure the error is coming from your MessagingService script? From what I see you are not mentioning ServerScriptService anywhere in your script.

When I started the script just at that time there was this bug…

If you press on the error it should open the script and line where it errored.

It’s return a random script using ServerScriptService


I have this error too

The error you are showing is not caused directly by the script you posted. Click the error in the output while the game is running to see what script and line is causing the issue. Please send relavent code to the error, and the image of the error, not just text.

2 Likes

Did you use LocalScript? In my current knowledge, it’s impossible to access ServerScriptService using LocalScript unless you’re also using RemoteEvent.

1 Like

I fix it ! Thank You ALL for all replys !!!

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.