Advertisement
ERROR_CODE

Close?

Jul 6th, 2023 (edited)
36
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 3.66 KB | None | 0 0
  1. local ScreenGui = Instance.new("ScreenGui")
  2. local QuestionFrame = Instance.new("Frame")
  3. local Question = Instance.new("TextLabel")
  4. local Yes = Instance.new("TextButton")
  5. local Text = Instance.new("TextLabel")
  6. local No = Instance.new("TextButton")
  7.  
  8.  
  9. ScreenGui.Parent = game.CoreGui
  10.  
  11. QuestionFrame.Parent = ScreenGui
  12. QuestionFrame.BackgroundColor3 = Color3.fromRGB(0, 0, 0)
  13. QuestionFrame.Position = UDim2.new(0.3, 0, 0.2, 0)
  14. QuestionFrame.Size = UDim2.new(0, 378, 0, 250)
  15.  
  16. Question.Name = "Question"
  17. Question.Parent = QuestionFrame
  18. Question.BackgroundColor3 = Color3.fromRGB(255, 255, 255)
  19. Question.Size = UDim2.new(0, 378, 0, 25)
  20. Question.Font = Enum.Font.GothamBold
  21. Question.Text = "Close Executor?"
  22. Question.TextColor3 = Color3.fromRGB(0, 0, 0)
  23. Question.TextScaled = true
  24. Question.TextSize = 14.000
  25. Question.TextWrapped = true
  26.  
  27.  
  28.  
  29.  
  30. Yes.Name = "Yes"
  31. Yes.Parent = QuestionFrame
  32. Yes.BackgroundColor3 = Color3.fromRGB(255, 255, 255)
  33. Yes.Position = UDim2.new(0, 0, 0.648000002, 0)
  34. Yes.Size = UDim2.new(0, 155, 0, 55)
  35. Yes.Font = Enum.Font.GothamBold
  36. Yes.Text = "Yes"
  37. Yes.TextColor3 = Color3.fromRGB(0, 0, 0)
  38. Yes.TextScaled = true
  39. Yes.TextSize = 14.000
  40. Yes.TextWrapped = true
  41. Yes.MouseButton1Down:connect(function()
  42.  
  43. end)
  44. Text.Name = "Text"
  45. Text.Parent = QuestionFrame
  46. Text.Position = UDim2.new(0, 0, 0.2, 0)
  47. Text.BackgroundColor3 = Color3.fromRGB(0, 0, 0)
  48. Text.Size = UDim2.new(0, 377, 0, 100)
  49. Text.Font = Enum.Font.GothamBold
  50. Text.Text = "Are you sure?"
  51. Text.TextColor3 = Color3.fromRGB(255, 255, 255)
  52. Text.TextScaled = true
  53. Text.TextSize = 14.000
  54. Text.TextWrapped = true
  55.  
  56.  
  57. No.Name = "No"
  58. No.Parent = QuestionFrame
  59. No.BackgroundColor3 = Color3.fromRGB(255, 255, 255)
  60. No.Position = UDim2.new(0.59, 0, 0.648000002, 0)
  61. No.Size = UDim2.new(0, 155, 0, 55)
  62. No.Font = Enum.Font.GothamBold
  63. No.Text = "No"
  64. No.TextColor3 = Color3.fromRGB(0, 0, 0)
  65. No.TextScaled = true
  66. No.TextSize = 14.000
  67. No.TextWrapped = true
  68. No.MouseButton1Down:connect(function()
  69. QuestionFrame:Destroy()
  70. end)
  71. local function QFCS_fake_script()
  72. local script = Instance.new('LocalScript', QuestionFrame)
  73.  
  74. local UIS = game:GetService("UserInputService")
  75. function dragify(QuestionFrame)
  76. dragToggle = nil
  77. local dragSpeed = 0
  78. dragInput = nil
  79. dragStart = nil
  80. local dragPos = nil
  81. function updateInput(input)
  82. local Delta = input.Position - dragStart
  83. local Position = UDim2.new(startPos.X.Scale, startPos.X.Offset + Delta.X, startPos.Y.Scale, startPos.Y.Offset + Delta.Y)
  84. game:GetService("TweenService"):Create(QuestionFrame, TweenInfo.new(0.25), {Position = Position}):Play()
  85. end
  86. QuestionFrame.InputBegan:Connect(function(input)
  87. if (input.UserInputType == Enum.UserInputType.MouseButton1 or input.UserInputType == Enum.UserInputType.Touch) and UIS:GetFocusedTextBox() == nil then
  88. dragToggle = true
  89. dragStart = input.Position
  90. startPos = QuestionFrame.Position
  91. input.Changed:Connect(function()
  92. if input.UserInputState == Enum.UserInputState.End then
  93. dragToggle = false
  94. end
  95. end)
  96. end
  97. end)
  98. QuestionFrame.InputChanged:Connect(function(input)
  99. if input.UserInputType == Enum.UserInputType.MouseMovement or input.UserInputType == Enum.UserInputType.Touch then
  100. dragInput = input
  101. end
  102. end)
  103. game:GetService("UserInputService").InputChanged:Connect(function(input)
  104. if input == dragInput and dragToggle then
  105. updateInput(input)
  106. end
  107. end)
  108. end
  109.  
  110. dragify(script.Parent)
  111. end
  112. coroutine.wrap(QFCS_fake_script)()
  113.  
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement