Why Nostr? What is Njump?
2023-02-13 19:36:12

TZH on Nostr: local Players = game:GetService("Players") local Character = script.Parent local ...

local Players = game:GetService("Players")
local Character = script.Parent
local Humanoid = Character:WaitForChild("Humanoid")
local Mount = Character:WaitForChild("Mount")
local mounting = false

function mountCharacter(player)
if mounting then
return
end
mounting = true
local character = player.Character or player.CharacterAdded:Wait()
local humanoid = character:WaitForChild("Humanoid")
local torso = character:WaitForChild("HumanoidRootPart")
local humanoidMount = humanoid:LoadAnimation(Mount)
humanoidMount:Play()
humanoid.AutoRotate = false
torso.CFrame = Mount.CFrame * CFrame.new(0, 0, -1.5) * CFrame.Angles(math.rad(90), 0, 0)
humanoid.Sit = true
end

Humanoid.Died:Connect(function()
mounting = false
end)

Players.PlayerAdded:Connect(function(player)
player.Chatted:Connect(function(message)
if message:lower() == "mount" then
mountCharacter(player)
end
end)
end)
Author Public Key
npub1e3axwaz52trqqftmxg2v0r24n400vudfkf6gylztm84aw5ut3agsydvk4e