Advertisement
Previized

Balloon Physics Script [ROBLOX]

Jul 10th, 2017
4,543
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 1.56 KB | None | 0 0
  1. --@author FiredDusk (aka Previized)
  2.  
  3. --[[ NOTES:
  4.     (If you use this code, please be sure to give me credit)
  5.     (PLEASE WATCH THE REST OF THE VIDEO SO YOU KNOW WHAT TO DO WITH ALL THE SCRIPTS)
  6.    
  7.     1. Insert a script into ServerScriptService
  8.     2. Put all this code into it. (Telling you this b/c maybe you are reading this on pastebin.
  9.     3. MAKE SURE you configure your game and check off "Morph to R15". This will not work with R6 unless I script it differently.
  10.    
  11. --]]
  12.  
  13. --// Services
  14. local Players = game:GetService('Players')
  15. local ReplicatedStorage = game:GetService('ReplicatedStorage')
  16.  
  17. --// Main
  18. Players.PlayerAdded:Connect(function(Player)
  19.     local Balloon = ReplicatedStorage:WaitForChild('Balloon')
  20.    
  21.     Player.CharacterAdded:Connect(function(Character)
  22.         --// Create New Balloon
  23.         local NewBalloon = Balloon:Clone()
  24.         NewBalloon.Parent = Character
  25.        
  26.         --// Constraint
  27.         local LeftHand = Character:WaitForChild('LeftHand')
  28.        
  29.         local Att1 = Instance.new('Attachment',LeftHand)
  30.         local Att2 = Instance.new('Attachment',NewBalloon.PrimaryPart)
  31.  
  32.         local Rope = Instance.new('RopeConstraint',LeftHand)
  33.         Rope.Thickness = 0.04
  34.         Rope.Color = BrickColor.new('Institutional white')
  35.         Rope.Visible = true
  36.         Rope.Attachment0 = Att1
  37.         Rope.Attachment1 = Att2
  38.        
  39.         --// Force
  40.         local BodyForce = Instance.new('BodyForce',NewBalloon.PrimaryPart)
  41.         BodyForce.Force = Vector3.new(0,1000,0)
  42.        
  43.         --// Anim
  44.         Character:WaitForChild('LeftUpperArm'):WaitForChild('LeftShoulder').C1 = Character.LeftUpperArm.LeftShoulder.C1 * CFrame.Angles(math.rad(-80),0,0)
  45.     end)
  46. end)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement