- What do you want to achieve? Keep it simple and clear!
Hello, I want to achieve something like this in Jailbreak the piston crusher that makes their Character tiny when the crusher landed on them.
- What is the issue? Include screenshots / videos if possible!
the problem is when I touch the side of the part it makes my Character smaller. But I only want the bottom part of Y axis to have the ability to do that.
https://photos.app.goo.gl/rqSoypQkiTG8QtE68
- What solutions have you tried so far? Did you look for solutions on the Developer Hub?
I did my research on google as well as on the devforum but couldn’t find a solution or similar topics to this.
- here is my script, Its a serverscript in serverscriptservice
local tweenservice = game:GetService("TweenService")
local W = game.Workspace:WaitForChild("W")
local debounce = false
local player = game.Players.PlayerAdded:Connect(function(player)
local Character = player.Character or player.CharacterAdded:Wait()
local Humanoid = Character:WaitForChild("Humanoid")
local TypeScale = .2
local S = TweenInfo.new(.5, Enum.EasingStyle.Sine, Enum.EasingDirection.In, -1, true, 3.5)
local P = {Position = Vector3.new(558.5, 9, -155)}
local A = tweenservice:Create(W, S, P)
A:Play()
W.Touched:Connect(function()
if Humanoid then
if debounce == false then
debounce = true
print(debounce)
Humanoid.HeadScale.Value = TypeScale
Humanoid.BodyTypeScale.Value = TypeScale
Humanoid.BodyHeightScale.Value = TypeScale
Humanoid.BodyDepthScale.Value = TypeScale
print("Roti Prata")
wait(10)
Humanoid.HeadScale.Value = 0.95
Humanoid.BodyTypeScale.Value = 0
Humanoid.BodyHeightScale.Value = 0.9
Humanoid.BodyDepthScale.Value = 0.85
print("Normal!")
wait(3)
debounce = false
print(debounce)
end
else
print("Error!")
end
end)
end)



"