Scripting HelpersARCHIVE
A little piece of Roblox history. Preserved for everyone, one question at a time.Read about the archive →
COMMUNITY QUESTION

How would I animate textures?

I'm animating a conveyor texture and couldn't find out how so used the code which Roblox provided. It works normally but starts to expand somewhat after a little while. How would I stop this? Here is the code I used:

local TweenService = game:GetService("TweenService")
 
local texture1 = script.Parent.Texture1
local texture2 = script.Parent.Texture2
 
local tweenInfo1 = TweenInfo.new(8, Enum.EasingStyle.Sine, Enum.EasingDirection.InOut, -1)
local tween1 = TweenService:Create(texture1, tweenInfo1, {OffsetStudsV=50})
local tweenInfo2 = TweenInfo.new(7, Enum.EasingStyle.Sine, Enum.EasingDirection.InOut, -1, true)
local tween2 = TweenService:Create(texture2, tweenInfo2, {OffsetStudsU=50, StudsPerTileU=55, StudsPerTileV=45})
 
tween1:Play()
tween2:Play()

2 comments

0

How are your Texture1 & 2 defined in Explorer ?

0

Texture1 and Texture2

1 answer

maybe just use a Beam, and an attachment or switch from texture to texture with each one different in a while loop.

This discussion is preserved as it was. New answers, comments, and votes are closed.