Help with subscribe async

  1. **What do you want to achieve?I want a bindable event to be fired when subscribeasync takes place.

  2. What is the issue? when I send the publishasync I send the 2 players’ name and a number but when the bindable is sent it isnt sending and there is no errors

  3. What solutions have you tried so far? I know im doing something wrong with sending the name but I dont know how and no devforum has explained it properly to me

local MPS = game:GetService("MarketplaceService")
local MessagingService = game:GetService("MessagingService")
MessagingService:SubscribeAsync("NukeServers", function(reciever, donater, cost)

	local nuke = game.ServerStorage:WaitForChild("Nuke"):clone()
	nuke.Parent = workspace
	local tweenService = game:GetService("TweenService")
	workspace.NukePosition1["Nuke siren"]:Play()
	local tween = tweenService:Create(nuke, TweenInfo.new(3, Enum.EasingStyle.Linear, Enum.EasingDirection.Out, 0, false, 0), {Position = workspace.NukePosition1.Position})
	tween:Play()
	wait(2)

	local tween2 = tweenService:Create(nuke, TweenInfo.new(2, Enum.EasingStyle.Linear, Enum.EasingDirection.Out, 0, false, 0), {Position = workspace.NukePosition3.Position})
	local tween3 = tweenService:Create(nuke, TweenInfo.new(5, Enum.EasingStyle.Linear, Enum.EasingDirection.Out, 0, false, 0), {Position = workspace.NukePosition2.Position})
	tween3:Play()
	for i = 0,0.25,0.01 do
		wait(0.1)
		nuke.CFrame = nuke.CFrame:Lerp(workspace.NukePosition2.CFrame, i)
	end
	wait(0.25)
	tween2:Play()
	workspace.NukePosition1["Nuke siren"]:Pause()
	nuke.woosh:Play()
	wait(1)
	nuke["Nuke Explosion"]:Play()
	game.ReplicatedStorage.NukeClient:FireAllClients(true)
	wait(1.35)
	local clonebomb = game.ServerStorage.NukeBomb:Clone()
	clonebomb.Parent = game.Workspace
	game.ReplicatedStorage.CoolEffect:Fire(reciever.Data, donater.Data, cost)
	game.ReplicatedStorage.Nuke:Fire()
	
	wait(10)
	game.ReplicatedStorage.NukeClient:FireAllClients(false)

	nuke:Destroy()


end)


game.ReplicatedStorage.Donate.Event:Connect(function(recieved, donater, amount)

	print(recieved)
	print(donater)
	print(amount)
	MessagingService:PublishAsync("NukeServers", recieved.Name, donater.Name, amount)
	
end)

The bindable event is cool effect btw. Thanks!

I fixed it. Thanks. CHARACTER

1 Like

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