Hello, I am making a game cald Children Brawl, where Kirby-Like characters who are children brawl.
I was wondering, I am using a custom character for this, since the character’s arms are different sizes, shapes, and orientations, how can I fix the tool grip?
The character picks up tools, but they look really bad on the character…
Tool Grip Editor allows you to edit the position and orientation of the tool grip. (For some reason you have to anchor the Handle while editing the grip with the plugin, make sure to unanchor it after.)
usually, when i work with tools i dont put the actual tool model inside the tool itself.
I usually just weld the weapon model to the character when the player equips the corresponding tool, and destroy the weapon model (and weld) when the tool is equipped. It saves time on having to figure out the tool grip, but you have to have a good understanding of weld/motor6D C0’s and C1’s and such.
Using C0 and C1 helps positioning the weld/joint and the actual weapon part.
C0 will position the actual joint (where the weld joint is)
C1 positions where the actual part is (so instead of moving the joint, it moves the part that the weld is welded to)
if youd like a more in-depth explanation please let me know.
Well, Im sure you know what both of these instances do. Welds allow parts to “stick” together. They can be quite useful when making specific things like cars and other objects.
Motor6Ds have a similar function, except You use Motor6Ds to animate. I personally prefer Motor6Ds when welding things to the character. As an animator it just makes things easier when i animate because i have full control of how everything on the character moves.
C0 and C1 is a little complicated to explain because its CFrame, but there are so many reasources out there to help you get a better understanding of how they work.
But in a nutshell, C0 controls the JointInstance, where the joint is located in 3D space.
C1 controls the Weld (or Motor6D)s Part1 position (or rotation because its CFrame). When editing the C1 the joint will not move but the welded object will be moved.
Also, heres a template for what i was initially talking about
local tool = script.parent
local weaponmodel = game.replicatedstorage.weaponmodel:clone()
tool.Equipped:Connect(Function()
---Blah blah editing weapon model welds and stuff
--- more code
end)
tool.Unequipped:Connect(function()
weaponmodel:Destroy() --Make sure the weld/Motor6D is parented to the weapon model, so you destroy it along with the model to prevent duplication
end)
19:34:36.831 Unable to assign property C0. CoordinateFrame expected, got Instance - Client - LocalScript:5
19:34:36.832 Stack Begin - Studio
19:34:36.832 Script 'Workspace.NubblyFry.Ban Hammer.LocalScript', Line 5 - Studio - LocalScript:5
19:34:36.832 Stack End - Studio
local Motor
script.Parent.Equipped:Connect(function()
local RightArm = script.Parent.Parent:FindFirstChild("Right Arm")
local Motor6D = Instance.new("Motor6D", RightArm)
Motor6D.C0 = RightArm
Motor6D.C1 = script.Parent:FindFirstChild("Handle")
Motor = Motor6D
end)
script.Parent.Unequipped:Connect(function()
Motor:Destroy()
end)
C0 requires a CFrame, not an instance. Heres an example of code
local tool = script.parent
tool.equipped:Connect(function()
local weapon = replicatedstorage.weapon:clone()
local m6d = instance.new("Motor6D", weapon) --Parents the Motor6d to the parent
weapon.Parent = char
m6d.Part0 = RightArm --Set the part0 like any other weld
m6d.Part1 = weapon --Set part1 like any other weld
----------------------------
--C0/C1 config
m6d.C0 = CFrame.New(m6d.C0.Position + Vector3.new(0,3,0) --Keeps the C0's CFrame, but moves it 3 spaces up. Its better to just add/remove position values to the already existing C0 because it makes things easier when finding the perfect position.)
m6d.C1 = CFrame.new(m6d.C1.Position + Vector3.new(0,0,2) --Moves the object 2 places back.
end)
tool.unequipped:connect(function()
char:FindFirstChild("weapon"):Destroy() --Destroys the weapon model AND the motor6D because the Motor6D is parented to the weapon. By destroying the parent, you destroy any children that are under it
end)
Parent it to the object you want to weld it to, so you dont have to physically destroy the motor. This isnt a mandetory option but its better than writing
weapon:Destroy()
motor:Destroy()
C0 and C1 are CFrame Values. You cannot set them to instances
With this, you have to experiment and find the perfect set of numbers to position whatever you want to weld just right. May i suggest getting a plugin called RigEdit