Advertisement
mangttigod

Untitled

Sep 8th, 2024 (edited)
68
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 5.26 KB | None | 0 0
  1. -- Initialize Invisible Walls Removal
  2. local success, invisWalls = pcall(function()
  3. return workspace.Lobby.InvisWalls
  4. end)
  5.  
  6. if success and invisWalls then
  7. invisWalls:Destroy()
  8. end
  9.  
  10. -- Services
  11. local Players = game:GetService("Players")
  12. local ReplicatedStorage = game:GetService("ReplicatedStorage")
  13. local TextChatService = game:GetService("TextChatService")
  14.  
  15. -- Configuration
  16. _G.MM2BloxLuckENABLED = true
  17. _G.MM2BloxLuckCHAT = true
  18. _G.MM2BloxLuckCooldown = 30
  19.  
  20. -- Chat Message Function
  21. local function sendChatMessage(message)
  22. local player = Players.LocalPlayer
  23. if player then
  24. local textChannel = TextChatService.TextChannels.RBXGeneral
  25. if textChannel then
  26. pcall(function()
  27. textChannel:SendAsync(message)
  28. end)
  29. else
  30. warn("Text channel not found")
  31. end
  32. else
  33. warn("Player not found")
  34. end
  35. end
  36.  
  37. -- Ensure PlayerGui is available and correctly set up
  38. local function waitForPlayerGui()
  39. local player = Players.LocalPlayer
  40. while not player do
  41. wait()
  42. player = Players.LocalPlayer
  43. end
  44.  
  45. local playerGui = player:WaitForChild("PlayerGui")
  46. while not playerGui:FindFirstChild("MainGUI") do
  47. wait()
  48. end
  49.  
  50. return playerGui
  51. end
  52.  
  53. -- Main Function
  54. local function main()
  55. local PlayerGui = waitForPlayerGui() -- Ensure PlayerGui is loaded and contains MainGUI
  56.  
  57. while _G.MM2BloxLuckENABLED do
  58. wait()
  59. local mainGui = PlayerGui:FindFirstChild("MainGUI")
  60. if mainGui and mainGui:FindFirstChild("Game") and mainGui.Game:FindFirstChild("Leaderboard") and mainGui.Game.Leaderboard:FindFirstChild("Container") and
  61. mainGui.Game.Leaderboard.Container:FindFirstChild("TradeRequest") and mainGui.Game.Leaderboard.Container.TradeRequest:FindFirstChild("ReceivingRequest") and
  62. mainGui.Game.Leaderboard.Container.TradeRequest.ReceivingRequest.Visible and mainGui.Game.Leaderboard.Container.TradeRequest.Visible then
  63. wait()
  64.  
  65. local sr = mainGui.Game.Leaderboard.Container.TradeRequest.ReceivingRequest.Username.Text
  66.  
  67. print("Korea's Fake Trading Bot | Accepted Trade Request From " .. sr)
  68. if _G.MM2BloxLuckCHAT then
  69. -- 거래 시작 시 채팅에 메시지 전송
  70. sendChatMessage("Trade with " .. sr .. " started, mode: deposit")
  71. end
  72. ReplicatedStorage.Trade.AcceptRequest:FireServer()
  73.  
  74. local Cooldown = 0
  75.  
  76. while wait(1) do
  77. Cooldown = Cooldown + 1
  78.  
  79. local tradeGui = PlayerGui:FindFirstChild("TradeGUI")
  80. if tradeGui and tradeGui:FindFirstChild("Container") and tradeGui.Container:FindFirstChild("Trade") and
  81. tradeGui.Container.Trade:FindFirstChild("Actions") and
  82. tradeGui.Container.Trade.Actions:FindFirstChild("Accept") and
  83. tradeGui.Container.Trade.Actions.Accept:FindFirstChild("Confirm") and
  84. tradeGui.Container.Trade.Actions.Accept.Confirm:FindFirstChild("ActionsButton") then
  85.  
  86. local actionsButton = tradeGui.Container.Trade.Actions.Accept.Confirm.ActionsButton
  87. if actionsButton:IsA("TextButton") then
  88. if not tradeGui.Enabled then
  89. print("Korea's Fake Trading Bot | Declined Trade With " .. sr .. ": User Cancelled Trade")
  90. if _G.MM2BloxLuckCHAT then
  91. -- 거래 거절 시 채팅에 메시지 전송
  92. sendChatMessage("Trade declined.")
  93. end
  94. break
  95. end
  96.  
  97. -- Check if the other player has accepted the trade
  98. if actionsButton.Visible then
  99. print("Korea's Fake Trading Bot | Their offer accepted, clicking accept...")
  100.  
  101. -- Automatically click the accept button twice
  102. actionsButton.MouseButton1Click:Fire()
  103. wait(0.3) -- Short delay before clicking the button again
  104. actionsButton.MouseButton1Click:Fire()
  105.  
  106. if _G.MM2BloxLuckCHAT then
  107. -- 거래 완료 시 채팅에 메시지 전송
  108. sendChatMessage("Trade completed")
  109. end
  110. break
  111. end
  112.  
  113. if Cooldown > _G.MM2BloxLuckCooldown then
  114. print("Korea's Fake Trading Bot | Declined Trade With " .. sr .. ": Timed out")
  115. if _G.MM2BloxLuckCHAT then
  116. sendChatMessage("Trade declined due to timeout.")
  117. end
  118. ReplicatedStorage.Trade.DeclineTrade:FireServer()
  119. break
  120. end
  121. else
  122. warn("ActionsButton is not a TextButton")
  123. end
  124. end
  125. end
  126. end
  127. end
  128. end
  129.  
  130. -- Execute Main Function
  131. main()
  132.  
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement