generic image
Processing...
  • Games
  • Catalog
  • Develop
  • Robux
  • Search in Players
  • Search in Games
  • Search in Catalog
  • Search in Groups
  • Search in Library
  • Log In
  • Sign Up
  • Games
  • Catalog
  • Develop
  • Robux
   
ROBLOX Forum » Game Creation and Development » Scripting Helpers
Home Search
 

Re: WHAT DOES THIS MEAN PLS

Previous Thread :: Next Thread 
Swoof is not online. Swoof
Joined: 13 Mar 2010
Total Posts: 16146
22 Nov 2013 04:29 PM
Instance.new("Part").Shape = 0



Shape = 0
?
Report Abuse
Rukain is not online. Rukain
Joined: 30 Jul 2013
Total Posts: 1944
22 Nov 2013 04:29 PM
It makes the part a Sphere.
Report Abuse
Bebee2 is not online. Bebee2
Joined: 17 May 2009
Total Posts: 3985
22 Nov 2013 04:30 PM
Shape = 0

is the same as

Shape = 'Ball'

is the same as

Shape = Enum.PartType.Ball
Report Abuse
Jetta765214 is not online. Jetta765214
Joined: 22 Oct 2008
Total Posts: 1855
22 Nov 2013 04:31 PM
For more info, goto:
http://wiki.roblox.com/index.php/PartType_(Enum)
Report Abuse
Swoof is not online. Swoof
Joined: 13 Mar 2010
Total Posts: 16146
22 Nov 2013 04:31 PM
is there any wiki with the shape values

what if i want like a square
Report Abuse
Rukain is not online. Rukain
Joined: 30 Jul 2013
Total Posts: 1944
22 Nov 2013 04:32 PM
Pretty sure a Cube is 1.
Report Abuse
Swoof is not online. Swoof
Joined: 13 Mar 2010
Total Posts: 16146
22 Nov 2013 04:35 PM
so i got this so far
is there anyway to make the block flat
sort of like a coin?



function onDied()
for i =1,script.XPCount.Value do
local xp = Instance.new("Part")
xp.Parent = game.Workspace
xp.Position = script.Parent.Parent.Torso.Position + Vector3.new(math.random(-3,3),math.random(-3,3),math.random(-3,3))
xp.Shape = 0
xp.formFactor = "Symmetric"
xp.Name = "Crowns"
xp.BrickColor = BrickColor.new(24)
xp.Reflectance = 0.5
xp.Size = Vector3.new(1,1,1)
local clone = script.IncreaseXP:Clone()
clone.Disabled = false
clone.Parent = xp
end
end

script.Parent.Died:connect(onDied)
Report Abuse
Swoof is not online. Swoof
Joined: 13 Mar 2010
Total Posts: 16146
22 Nov 2013 04:36 PM
xp.Size = Vector3.new(1,0.4,1)



would this work?
Report Abuse
Jetta765214 is not online. Jetta765214
Joined: 22 Oct 2008
Total Posts: 1855
22 Nov 2013 04:36 PM
You may have to set the FormFactor to "Custom" to get it to work right
Report Abuse
Swoof is not online. Swoof
Joined: 13 Mar 2010
Total Posts: 16146
22 Nov 2013 04:40 PM
works as formfactor symmetric fine


hey, by anychance do you know how to make this only apply to PLAYERS, not humanoid monsters

amnt = 5
function onTouched(part)
local h = part.Parent:findFirstChild("Humanoid")
if (h~=nil) then
local thisplr = game.Players:findFirstChild(h.Parent.Name)
if (thisplr~=nil) then
local stats = thisplr:findFirstChild("leaderstats")
if (stats~=nil) then
local score = stats:findFirstChild("Crowns")
if (score~=nil) then
score.Value = score.Value + amnt
end
end
end
script.Parent:remove()
end
end

script.Parent.Touched:connect(onTouched)
Report Abuse
Jetta765214 is not online. Jetta765214
Joined: 22 Oct 2008
Total Posts: 1855
22 Nov 2013 04:44 PM
if game.Players:GetPlayerFromCharacter(part.Parent) then
Report Abuse
Swoof is not online. Swoof
Joined: 13 Mar 2010
Total Posts: 16146
22 Nov 2013 04:51 PM
TY A TON!

one last thing if you can <3

this doesn't seem to be working, when i have the humanoid ragdoll death
is it because the ragdoll script modifies the torso and this puts the xp at the torso?



function onDied()
for i =1,script.XPCount.Value do
local xp = Instance.new("Part")
xp.Parent = game.Workspace
xp.Position = script.Parent.Parent.Torso.Position + Vector3.new(math.random(-5,5),math.random(-5,5),math.random(-5,5))
xp.Shape = 1
xp.formFactor = "Plate"
xp.Name = "Crowns"
xp.BrickColor = BrickColor.new(24)
xp.Reflectance = 0.5
xp.Size = Vector3.new(1,0.4,1)
xp.BackSurface = "Smooth"
xp.TopSurface = "Smooth"
local clone = script.IncreaseXP:Clone()
clone.Disabled = false
clone.Parent = xp
end
end

script.Parent.Died:connect(onDied)




ragdoll death:

Character = script.Parent
Humanoid = Character.Humanoid
Torso = Character.Torso

function OnDeath()
print("Death")
Humanoid.Parent = nil
if Torso then
local Head = Character:FindFirstChild("Head")
if Head then
local Neck = Instance.new("Weld")
Neck.Name = "Neck"
Neck.Part0 = Torso
Neck.Part1 = Head
Neck.C0 = CFrame.new(0, 1.5, 0)
Neck.C1 = CFrame.new()
Neck.Parent = Torso
end
local Limb = Character:FindFirstChild("Right Arm")
if Limb then

Limb.CFrame = Torso.CFrame * CFrame.new(1.5, 0, 0)
local Joint = Instance.new("Glue")
Joint.Name = "RightShoulder"
Joint.Part0 = Torso
Joint.Part1 = Limb
Joint.C0 = CFrame.new(1.5, 0.5, 0, 0, 0, 1, 0, 1, 0, -1, -0, -0)
Joint.C1 = CFrame.new(-0, 0.5, 0, 0, 0, 1, 0, 1, 0, -1, -0, -0)
Joint.Parent = Torso

local B = Instance.new("Part")
B.TopSurface = 0
B.BottomSurface = 0
B.formFactor = "Symmetric"
B.Size = Vector3.new(1, 1, 1)
B.Transparency = 1
B.CFrame = Limb.CFrame * CFrame.new(0, -0.5, 0)
B.Parent = Character
local W = Instance.new("Weld")
W.Part0 = Limb
W.Part1 = B
W.C0 = CFrame.new(0, -0.5, 0)
W.Parent = Limb

end
local Limb = Character:FindFirstChild("Left Arm")
if Limb then

Limb.CFrame = Torso.CFrame * CFrame.new(-1.5, 0, 0)
local Joint = Instance.new("Glue")
Joint.Name = "LeftShoulder"
Joint.Part0 = Torso
Joint.Part1 = Limb
Joint.C0 = CFrame.new(-1.5, 0.5, 0, -0, -0, -1, 0, 1, 0, 1, 0, 0)
Joint.C1 = CFrame.new(0, 0.5, 0, -0, -0, -1, 0, 1, 0, 1, 0, 0)
Joint.Parent = Torso

local B = Instance.new("Part")
B.TopSurface = 0
B.BottomSurface = 0
B.formFactor = "Symmetric"
B.Size = Vector3.new(1, 1, 1)
B.Transparency = 1
B.CFrame = Limb.CFrame * CFrame.new(0, -0.5, 0)
B.Parent = Character
local W = Instance.new("Weld")
W.Part0 = Limb
W.Part1 = B
W.C0 = CFrame.new(0, -0.5, 0)
W.Parent = Limb

end
local Limb = Character:FindFirstChild("Right Leg")
if Limb then

Limb.CFrame = Torso.CFrame * CFrame.new(0.5, -2, 0)
local Joint = Instance.new("Glue")
Joint.Name = "RightHip"
Joint.Part0 = Torso
Joint.Part1 = Limb
Joint.C0 = CFrame.new(0.5, -1, 0, 0, 0, 1, 0, 1, 0, -1, -0, -0)
Joint.C1 = CFrame.new(0, 1, 0, 0, 0, 1, 0, 1, 0, -1, -0, -0)
Joint.Parent = Torso

local B = Instance.new("Part")
B.TopSurface = 0
B.BottomSurface = 0
B.formFactor = "Symmetric"
B.Size = Vector3.new(1, 1, 1)
B.Transparency = 1
B.CFrame = Limb.CFrame * CFrame.new(0, -0.5, 0)
B.Parent = Character
local W = Instance.new("Weld")
W.Part0 = Limb
W.Part1 = B
W.C0 = CFrame.new(0, -0.5, 0)
W.Parent = Limb

end
local Limb = Character:FindFirstChild("Left Leg")
if Limb then

Limb.CFrame = Torso.CFrame * CFrame.new(-0.5, -2, 0)
local Joint = Instance.new("Glue")
Joint.Name = "LeftHip"
Joint.Part0 = Torso
Joint.Part1 = Limb
Joint.C0 = CFrame.new(-0.5, -1, 0, -0, -0, -1, 0, 1, 0, 1, 0, 0)
Joint.C1 = CFrame.new(-0, 1, 0, -0, -0, -1, 0, 1, 0, 1, 0, 0)
Joint.Parent = Torso

local B = Instance.new("Part")
B.TopSurface = 0
B.BottomSurface = 0
B.formFactor = "Symmetric"
B.Size = Vector3.new(1, 1, 1)
B.Transparency = 1
B.CFrame = Limb.CFrame * CFrame.new(0, -0.5, 0)
B.Parent = Character
local W = Instance.new("Weld")
W.Part0 = Limb
W.Part1 = B
W.C0 = CFrame.new(0, -0.5, 0)
W.Parent = Limb

end
--[
local Bar = Instance.new("Part")
Bar.TopSurface = 0
Bar.BottomSurface = 0
Bar.formFactor = "Symmetric"
Bar.Size = Vector3.new(1, 1, 1)
Bar.Transparency = 1
Bar.CFrame = Torso.CFrame * CFrame.new(0, 0.5, 0)
Bar.Parent = Character
local Weld = Instance.new("Weld")
Weld.Part0 = Torso
Weld.Part1 = Bar
Weld.C0 = CFrame.new(0, 0.5, 0)
Weld.Parent = Torso
--]]
end
end

Humanoid.Died:connect(OnDeath)
Report Abuse
Swoof is not online. Swoof
Joined: 13 Mar 2010
Total Posts: 16146
22 Nov 2013 04:59 PM
the ragdoll script removes "Humanoid" from the model once it dies

Report Abuse
Previous Thread :: Next Thread 
Page 1 of 1
 
 
ROBLOX Forum » Game Creation and Development » Scripting Helpers
   
 
   
  • About Us
  • Jobs
  • Blog
  • Parents
  • Help
  • Terms
  • Privacy

©2017 Roblox Corporation. Roblox, the Roblox logo, Robux, Bloxy, and Powering Imagination are among our registered and unregistered trademarks in the U.S. and other countries.



Progress
Starting Roblox...
Connecting to Players...
R R

Roblox is now loading. Get ready to play!

R R

You're moments away from getting into the game!

Click here for help

Check Remember my choice and click Launch Application in the dialog box above to join games faster in the future!

Gameplay sponsored by:
Loading 0% - Starting game...
Get more with Builders Club! Join Builders Club
Choose Your Avatar
I have an account
generic image