So this script works in studio, but it doesn't work in-game. It doesn't even print. The point of this script is to tell another server script to give a tool when a dialog choice is selected.
--This is a script, not a local script
--The game is FilteringEnabled
local RepService = game:GetService("ReplicatedStorage")
local GiveCrateEvent = RepService:WaitForChild("Events"):WaitForChild("GiveCrate")
script.Parent.DialogChoiceSelected:connect(function(player, choice)
if (choice == script.Parent.Stock.ASand.AYes) then
print(player.Name.." asked for a Sand Crate")
GiveCrateEvent:Fire(player,"ASandCrate")
end
end)
The other script:
--Also a script
--Located in SSS
local RepStorage = game:GetService("ReplicatedStorage")
local GiveCrateEvent = RepStorage:WaitForChild("Events"):WaitForChild("GiveCrate")
local ServerStorage = game:GetService("ServerStorage")
local CrateStorage = ServerStorage.Crates
GiveCrateEvent.Event:connect(function(player, crate)
local ChosenCrate = CrateStorage:FindFirstChild(crate)
local CrateClone = ChosenCrate:clone()
CrateClone.Parent = player.Backpack
print("Gave "..player.Name .." a ".. crate)
end)
I have absolutely no idea why this won't even print in-game. Any help would be appreciated. Thanks.
I'm going to make my own set of gui dialogs instead. Thanks for those who tryed to help me solve this problem. :)

4 comments
Is it a local script or a script. Also where is it placed in the game? Under workspace, lighting, replicatedstorage?
This script is in the workspace under the NPC's head. This is a server script.
Is Experimental Mode off for you (Is Filtering Enabled On? ), or is it Experimental Mode on for you(Is Filtering Enabled Off?)?
Filtering Enabled is on/Experimental mode is off.