Include a standalone, bare-bones rbxl file with only the code you want reviewed.
- Code Review is for reviewing specific parts of your code, and not your whole game.
- Code Review is intended for improving already-working code. If you need help debugging your code, please use Scripting Support.
Provide an overview of:
- What does the code do and what are you not satisfied with?
- What potential improvements have you considered?
- How (specifically) do you want to improve the code?
-- game. Players. PlayerAdded: connect (function (p)
p-CharacterÄdded: connect (function (c)
c:WaitForChild ("Sound") : Destroy ()
local x
script:WaitForChild ("Sounds") : GetChildren ()
for
, =X do
xlil:clone() .Parent
=
C.HumanoidRootPart
end
local
c:WaitForChild ("Humanoid")
while h.Health >
local mag
= (c.HumanoidRootPart.Velocity-Vector3. new (0, c.HumanoidRootPart.Veloc
local rate
(16/3) / mag
-h.WalkSpeed
local isWalking = mag › 2 and h.FloorMaterial
= Enum.Material.Air
if iswalking
then
local name
if c.HumanoidRootPart:FindFirstChild(n.FloorMaterial.Name)
NE nil then
= h.FloorMaterial.Name
else
"Plastic"
end
spawn (function ()
local 3
. HumanoidRootPart:FindFirstChild(name) :Clone ()
s.Parent
c-HumanoidRootPart
3. Name
3.Name
" (Playing)
s.PlaybackSpeed
S.PlaybackSpeed + math. random (-20, 20) /100
3: Play ()
game: GetService (3, 3. TimeLength + 0.1)
end)
end
if isNalking then
wait (rate)
else
wait0)
end
end
end)
endi