Scripting HelpersARCHIVE
A little piece of Roblox history. Preserved for everyone, one question at a time.Read about the archive →
COMMUNITY QUESTION

How do I enable a disabled script in Workspace via Dialog choices?

Pls help I'm new to scripting. This is the script i put in the Dialog and it doesnt work

local dialog = script.Parent
local activateScript = game.Workspace.["MyDisabledScript"] --Name of your script


dialog.DialogChoiceSelected:connect(function(player, choice) --This is for getting the service when the choice is selected
    if choice == script.Parent.DialogChoice.ChoiceA then --Choice A is what you named the option in studio
        --Do what you want to do
        activateScript.Disabled = false --Activated Script


    elseif choice = script.Parent.DialogChoice.ChoiceB then
       --Do what you want
    end
    --Repeat for all choices
end)

1 comment

0

dialog choices must be local; also, use a remote event/function

1 answer

Is it in a local script? DialogChoiceSelected needs to be in a localscript.

This discussion is preserved as it was. New answers, comments, and votes are closed.