local HttpService = game:GetService("HttpService")
-- Webhook URL (Replace with your Discord webhook URL)
local webhookUrl = "https://[Log in to view URL]"
-- Function to log to Discord webhook
local function sendLogToDiscord(username, action, timestamp)
local payload = {
username = "Script Log", -- You can customize the bot's name
embeds = {{
title = "Action Logged",
description = string.format("**Username:** %s\n**Action:** %s\n**Timestamp:** %s", username, action, timestamp),
color = 0x00FF00, -- Green color for the embed
}}
}
local jsonData = HttpService:JSONEncode(payload)
-- Send the log to the webhook
local success, errorMessage = pcall(function()
HttpService:PostAsync(webhookUrl, jsonData, Enum.HttpContentType.ApplicationJson)
end)
if not success then
warn("Failed to send log to Discord: " .. errorMessage)
end
end
local Rayfield = loadstring(game:HttpGet('https://[Log in to view URL]'))()
local Window = Rayfield:CreateWindow({
Name = "Steal Time & Flex On Others",
Icon = 0, -- Icon in Topbar. Can use Lucide Icons (string) or Roblox Image (number). 0 to use no icon (default).
LoadingTitle = "Steal Time & Flex On Others",
LoadingSubtitle = "by 3e_x1",
Theme = "Default", -- Check
DisableRayfieldPrompts = false,
DisableBuildWarnings = false, -- Prevents Rayfield from warning when the script has a version mismatch with the interface
ConfigurationSaving = {
Enabled = true,
FolderName = nil, -- Create a custom folder for your hub/game
FileName = "Steal Time & Flex On Others"
},
Discord = {
Enabled = true, -- Prompt the user to join your Discord server if their executor supports it
Invite = "[]", -- The Discord invite code, do not include discord.gg/. E.g. discord.gg/ ABCD would be ABCD
RememberJoins = true -- Set this to false to make them join the discord every time they load it up
},
KeySystem = true, -- Set this to true to use our key system
KeySettings = {
Title = "STFO",
Subtitle = "Get The key from our Discord Server",
Note = "You can get the key from our discord server", -- Use this to tell the user how to get a key
FileName = "STFO Hub Key", -- It is recommended to use something unique as other scripts using Rayfield may overwrite your key file
SaveKey = true, -- The user's key will be saved, but if you change the key, they will be unable to use your script
GrabKeyFromSite = false, -- If this is true, set Key below to the RAW site you would like Rayfield to get the key from
Key = {"Like", "Fav"} -- List of keys that will be accepted by the system, can be RAW file links (pastebin, github etc) or simple strings ("hello","key22")
}
})
local MainTab = Window:CreateTab("Main Reach", 4483362458) -- Title, Image
local MainSection = MainTab:CreateSection("Reach")
Rayfield:Notify({
Title = "You have executed the script",
Content = "You executed the script :D",
Duration = 5,
Image = nil,
})
local Button = MainTab:CreateButton({
Name = "Reach",
Callback = function()
-- Log button click to Discord
local username = game.Players.LocalPlayer.Name
local action = "Clicked Reach Button"
local timestamp = os.date("%Y-%m-%d %H:%M:%S")
sendLogToDiscord(username, action, timestamp)
print("Reach button clicked.") -- Logging button click event.
--// Setting \--
local range = 500e000000000000000000000000000000000000000000000000000000000000
print("Range set to: " .. tostring(range)) -- Logging range value.
--// Variable \--
local player = game:GetService("Players").LocalPlayer
print("Player set to: " .. player.Name) -- Logging player info.
--// Script \--
game:GetService("RunService").RenderStepped:Connect(function()
print("RenderStepped triggered.") -- Logging each RenderStepped event.
local p = game.Players:GetPlayers()
for i = 2, #p do
local v = p[i].Character
if v and v:FindFirstChild("Humanoid") and v.Humanoid.Health > 0 and v:FindFirstChild("HumanoidRootPart") then
local distance = player:DistanceFromCharacter(v.HumanoidRootPart.Position)
print("Checking distance for player " .. p[i].Name .. ": " .. tostring(distance))
if distance <= range then
local tool = player.Character and player.Character:FindFirstChildOfClass("Tool")
if tool and tool:FindFirstChild("Handle") then
print("Tool activated for player " .. p[i].Name) -- Logging tool activation.
tool:Activate()
for _, part in next, v:GetChildren() do
if part:IsA("BasePart") then
firetouchinterest(tool.Handle, part, 0)
firetouchinterest(tool.Handle, part, 1)
print("Touch interaction with part: " .. part.Name) -- Logging touch interactions.
end
end
end
else
print("Player " .. p[i].Name .. " is out of range.") -- Logging when a player is out of range.
end
end
end
end)
end,
})
print("Script Loaded Successfully!") -- Logging successful script load.
To embed this project on your website, copy the following code and paste it into your website's HTML: