Advertisement
Guest User

Test

a guest
Jul 21st, 2021
111
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 0.61 KB | None | 0 0
  1. local Dialogue = workspace.Map.Model.Blacksmith.Blacksmith.Head.Dialog
  2. local Confirm = Dialogue.DialogueChoice
  3.  
  4. Dialogue.DialogueChoiceSelected:Connect(function(player, dialogueInstance)
  5.     print(player, dialogueInstance) --It has default params that gives you whoever triggered it and the dialogue choice,
  6.     if player.leaderstats.Currency.Value >= 15 or player.leaderstats.Currency.Value == 15 and dialogueInstance == Confirm then
  7.        
  8.         game:GetService("ReplicatedStorage").DeluxeSword:Clone().Parent = player.BackPack
  9.         player.leaderstats.Currency.Value = player.leaderstats.Currency.Value - 15
  10.        
  11.     end
  12. end)
  13.  
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement