Advanced Roblox Scripting Tutorial #9 - Welding (Beginner to Pro 2019)

preview_player
Показать описание
Advanced Roblox Scripting Tutorial #9 - Welding (Beginner to Pro 2019)

Hey guys! welcome to a brand new roblox scripting tutorial and in todays video I am going to be teaching you about welding in roblox studio. Basically welding is how you make two parts touch and stay in the same relative position without anchoring them. It's a suepr cool feature and I hope you're excited to learn it. Please leave any questions you may have in the comments or in my discord server. Anyways enjoy! :D

--Join my Discord Server to learn and meet other developers!--



Link to Beginner's Tutorial Series:

--What is this series about and who is it for?

So this series is meant for people who really want to learn exactly how to script, if that is you then I promise by the time you watch this whole series you will know exactly how to script on roblox. Anyways be sure to subscribe to see whenever I release a new tutorial and I will see you guys in the next one. Peace!
Рекомендации по теме
Комментарии
Автор

damn dude i was needing some lua tutorials, and i found your channel it helped alot

sononcio
Автор

Unlike Weld, WeldConstraint does not use C0 and C1 properties to determine the relative positioning of the parts. Instead, WeldConstraint automatically maintains the relative position and orientation of the two parts it connects, without the need for manual setting of C0 and C1. This makes it a more modern and convenient alternative to Weld for many use cases. Weld is outdated so use WeldConstraint in the same way but without c1 and c0

jimhalpert
Автор

I think i have the perfect explanation, which also explains why the part is below u.

part0 will be welded to part1, and that order matters.
if you weld your head to the part like you did, your head will be offset from the part.
this means you set your head ten above the part, making the part below u.
so u should weld the part to ur head instead, and it will work.

C0 is kinda where the offset starts, so ur head
C1 is how much it is offset from C0, ur head, so thats a CFrame.New()

so the way u need to do it is:
part0 = the part
part1 = ur head
C0 = part1.CFrame
C1 = C0 * CFrame.New(the offset)

vikovitch
Автор

C0 and C1 means the Weld offset. Just think of it as "If I want to put a distance between two parts that has been welded together I need C0 and C1". Also This would be easier for some of us to understand:

if then
local newWeld = Instance.new("Weld")
script.Parent.CFrame = hit.Parent.Head.CFrame * CFrame.new(0, 2, 0)
newWeld.Parent = script.Parent
newWeld.C0 =
newWeld.C1 =
newWeld.Part0 = hit.Parent.Head
newWeld.Part1 = script.Parent
end
end) pin this if you'd like

davidkinzel
Автор

ok this scripting channel is great, helped me improve alot. i turned from doing = 1 to remote events tysm

olikjam
Автор

Just be sure to not collide into other objects with a Humanoid, because it finds two humanoids, it finds another one if it touches it. Therefore merging both humanoids via a weld.

wheredabanana
Автор

This just gave me a good idea for a game lol

NewsOnQueue
Автор

Can you make a video on Velocities and Force?

Lavender
Автор

there is a MUCH SIMPLER way to do this. Instead of using CFrames, Just use Vector3 Positioning

local bluePart = script.Parent


local humanoid =
if humanoid then
local head =

local weld = Instance.new("Weld")
weld.Parent = bluePart
weld.Part0 = bluePart
weld.Part1 = head


bluePart.Position = head.Position + Vector3.new(0, 5, 0)
end
end)

GamingwithProsperYT
Автор

For anyone who has trouble with the part sticking to your head and not moving, simply put bluePart.Anchored = true after your variables and put bluePart.Anchored = false at the end of your code In the function thing.

alextran
Автор

For the people who didn't watch the whole video I'll summarise it, welding allows two parts to move whenever one of the parts move. It has the same CFrame and cframe is position and rotation.

Random-
Автор

for the people who didnt get it i believe that c0 is part 1 and c1 is part 2 and if u think why dont use c0 instead of part 1 then,
"C0" and "C1" represent the relative position and orientation of these parts when they are connected by a constraint, typically a WeldConstraint

"C0" is used to specify the desired position and orientation for "Part 1."
"C1" is used to specify the desired position and orientation for "Part 2."
So, if you're using a WeldConstraint to connect "Part 1" and "Part 2, " "C0" controls how "Part 1" should be positioned and oriented relative to its current position, and "C1" controls the same for "Part 2." These properties allow you to control how these parts are aligned and rotated when they are connected using the constraint. The names "Part 1" and "Part 2" are just placeholders for the parts you are working with and do not directly correspond to "C0" or "C1."

and if i wrong pls make it right

royemen
Автор

Why are you so underrated I hate this world

yashdhivar
Автор

Can you make a tutorial on how to put an animation into a keybind so it can be played when pressed in game?

kemonogane
Автор

When i started to learn building stuff on roblox and blender 2 years and half i used the welding thing so that the builds are connected

zchaudhry
Автор

thx for tutorial on weld, now i can add welding :)

MwSama
Автор

within 5 minutes, I knew exactly what to do. Great job, thanks!

lexiconlover
Автор

This is so awesome I was making a tower defense game and one of my enemies had to have extra parts but they didn't stick and just didn't follow the enemy so now i can continue this game

goofymemer_
Автор

Bruh this is gonna help so much thanks! I didn’t even know the create tool was there!

Gore-Labs
Автор

best youtuber ever im learning how to script because of you, no offense to alvin but I switched from him cause in MY opinion you explain better.

ryze