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

Dialogue Shop not giving tool in FE?

Asked by 5 years ago
Edited 5 years ago

I made a dialogue shop but in FE the tools dont give to the players backpack when they 30 ROBUX FOR WHOEVER SOLVES! This works in studio but not server the game is FE

I think when they buy the item from the dialogue it should fire a RE in rep storage and then a server script service script should respond to it and get the player as a parameter and then give the player the tool?

Image1

Image2

Code ((code also provided below) but recommended to check img)

script.Parent.DialogChoiceSelected:connect(function(player, choice)
    if choice == script.Parent.DialogChoice.Sword.Yes then
            game.ReplicatedStorage.RemoteEvent:FireServer()

    end
end)

Code that recieves the remoteveentfireserver ((also below))

game.ReplicatedStorage.RemoteEvent.OnServerEvent:connect(function(player)
                game.Lighting.Sword:Clone().Parent = player.Backpack
            game.Lighting.Sword:Clone().Parent = player.StarterGear
            local gui = game.Lighting.Success:Clone()
            gui.Parent = player.PlayerGui
            gui.Script.Disabled = false
end)

Image of Sword and 'Success' Gui location

0
Can you give more information, like the scripts, and maybe a pic of the explorer where everything is located... benben3963 6 — 5y
0
I agree with Ben... How are we supposed to help you if you didn't give us any scripts or maybe a screenshot of the explorer? duje225_awesome 10 — 5y
0
I did it Ind1v1duals 43 — 5y
0
connect should have a capital C since connect is depricated. I would put the tools in Server storage since this is coming from the server Sergiomontani10 236 — 5y

2 answers

Log in to vote
0
Answered by 5 years ago

send the script so i can get more info, but what might be the problem is if your LocalScript is trying to Instance.new or change the property of a part (or something in the Workspace).

1
Talk in comments, so it doesn't count as an ANSWER * Wink Wink * ;) AIphanium 124 — 5y
Ad
Log in to vote
0
Answered by
AIphanium 124
5 years ago
Edited 5 years ago

I don't believe if it has something to do with the scripts, so, DO NOT GIVE YOUR SCRIPTS TO THESE SCRIPT-THIRST newbies, they just want your script.

Here is a method that i learned from this site.


RemoteEvent


local event = Instance.new("RemoteEvent", game:GetService("ReplicatedStorage"))
event.Name = "Ready"

These lines, make a RemoteEvent inside ReplicatedStorage, and names it to "Ready".

Now, all you have to do is creating a function, and telling the function what you want it to do.

After that... FIRE THE SERVER !

("Note : Put those inside your script, but do not really paste your script, i'm sure a RemoteEvent can do the job. ") ("For more help, click HERE ")

0
I have updated the form Ind1v1duals 43 — 5y

Answer this question