LTween Module for moving goal on tweenservice

Hello everybody! I’m BloxuService,I’ve been creating a module called LTween is a very basic module but i wanted to share is to you.

What is LTween ?

L = Lerps
Tween = TweenService

and yes this a module for tween lerps

i use this Module when i have a moving goal like the player character or something else

How to use LTween ?

Is work a little bit the same thing as the twenservice

(note : is a local script for something good and don’t lag but you can use server too)

local LTween = require(script.LTween)

local SpawnCoin = function(Player)

	local Coin = game.ReplicatedStorage:WaitForChild("Part"..math.random(1,2)):Clone()
	Coin.Parent = workspace
	Coin.Anchored = true
	Coin.CanCollide = false
	local StartPosition = workspace.Part.Position + Vector3.new(math.random(-workspace.Part.Size.X/2,workspace.Part.Size.X/2),0,math.random(-workspace.Part.Size.Z/2,workspace.Part.Size.Z/2))
	
	Coin.CFrame = CFrame.new(StartPosition)
	
	-->> Here i start use LTween <<--

	local CoinTween = LTween.create(Coin,Coin,Player.Character.HumanoidRootPart,1,Enum.EasingStyle.Quart,Enum.EasingDirection.In,0,false,0)
	CoinTween:Play()	
	CoinTween:CompletedWait()
	CoinTween:destroy()

	-->> Here i stop use LTween <<--

	Coin:Destroy()

end

while wait(math.random(0.1,0.2)) do
	
	spawn(function()
	
		SpawnCoin(game.Players.LocalPlayer)
		
	end)
	
end

Get Module here : https://www.roblox.com/library/10087609310/LTween-Module
Open source place that you can edit : https://www.roblox.com/games/9891869899/LTween-Open-Place

Thank you for take time to read and is my first ressource and module so i hope is good and useful i was scared to publish this ressource.
You can rewrite the code if you want make something better and share on this post for other user

4 Likes