1 |
local function onTouch(otherPart)
local character = otherPart.Parent
if character then
local tweenService = game:GetService("TweenService")
local tweenInfo = TweenInfo.new(3, Enum.EasingStyle.Bounce, Enum.EasingDirection.InOut, 2, true , 0.5) local man = {CFrame = CFrame.new(20, 20 , 20)}
tweenInfo:Play()
end end
01 | local function onTouch(otherPart) |
02 |
03 | local character = otherPart.Parent |
04 |
05 | if character then |
06 |
07 | local tweenService = game:GetService( "TweenService" ) |
08 |
09 | local tweenInfo = TweenInfo.new( 3 , Enum.EasingStyle.Bounce, Enum.EasingDirection.InOut, 2 , true , 0.5 ) |
10 |
11 | local tween = game:GetService( "TweenService" ):Create(character,tweenInfo, { |
12 | CFrame = CFrame.new( 20 , 20 , 20 ) --Currently i'm assuming the thing you want to enlarge is the character, so i put character as the first parameters. ELSE, change character to the part you want to enlarge. |
13 | } ) |
14 |
15 | tween:Play() |
16 |
17 | end |
18 |
19 | end ) |