Ripple Module Version 1.5
Creates ripples based on a parts cframe and then the ripple parts are sorted from its distance from the part.
Based on the Mega Hunts ripple effect in a section of the Mega Token Lobby.
Preview
Color Ripple
Splash
Giant Splash
Code Examples
Example 1 (Basic)
local Parts = script.Parent.Parts:GetDescendants()
local Debounce = false
local Ripple = require(game:GetService("ReplicatedStorage"):WaitForChild("RippleModule"))
for _, Part in ipairs(Parts) do
if Part:IsA("BasePart") then
Part.Touched:Connect(function(otherPart : BasePart)
if Debounce or otherPart == Part then return end
Debounce = true
task.delay(1, function()
Debounce = false
end)
local Velocity = otherPart.Velocity.Y -- The Velocity Y axis
if Velocity < 0 then -- Must be put for it to make a splash styled ripple
Velocity = -Velocity
end
Ripple.Create_Ripple(Parts, otherPart, Velocity, {script.Parent.Base.CFrame.Y}, {Color3.fromRGB(17, 17, 17), Color3.fromRGB(97, 147, 255)}, {200})
end)
end
end
Example 2 (Dance floor thingy)
local Parts = script.Parent.Parts:GetDescendants()
local Debounce = false
local Ripple = require(game:GetService("ReplicatedStorage"):WaitForChild("RippleModule"))
for _, Part in ipairs(Parts) do
if Part:IsA("BasePart") then
Part.Touched:Connect(function(otherPart : BasePart)
if Debounce or otherPart == Part then return end
Debounce = true
task.delay(1, function()
Debounce = false
end)
local Velocity = otherPart.Velocity.Y -- The Velocity Y axis
Ripple.Create_Ripple(Parts, otherPart, 0, {script.Parent.Base.CFrame.Y}, {Color3.fromRGB(17, 17, 17), Color3.fromRGB(97, 147, 255)}, {200})
end)
end
end
Credits
- Real_Alyke : Giving me the idea to make it raise through his community post.
Should I make more modules like this?
Close the poll at 50 votes or in a 2 weeks (6th April 2025).
- Yes
- No
0 voters
Feel free to leave any feedback about anything you think should be change, fixed or reworked.
Make sure any feedback follows the Roblox TOS and the Developer Forum TOS