#how would i weld a handle to right arm?

1 messages · Page 1 of 1 (latest)

past mountain
past mountain
#

wrong video ;-;

pine relic
#

fair

past mountain
#

the idle animation requires no handle movement so we kidna postponed it for later

pine relic
#

i dont know how to animate sorry ;-;

past mountain
#

i just needa know how to uh

#

yknow

pine relic
#

you got any code thats not working properly? I can help with that

past mountain
#

motor handle to right arm and stuff

#

sure

#

this is the code i made (and i know its absolute and utter brofreeze )

past mountain
pine relic
#

no error messages right?

past mountain
pine relic
#

what is marked as "Handle.Part1"?

past mountain
#

the handle of the tool

pine relic
#

okay, uhm i have no idea, i don't know much about tools and stuff

#

sorry

past mountain
#

but a note

#

handle is just a part essentially

pine relic
#

yes i know

#

i just never tried animating a tool before

storm dock
#

maybe smth with AnimationPriority?

past mountain
#

should i set it to action?

storm dock
#

idle to Idle

#

and swing to Action

past mountain
past mountain
storm dock
#

wait so

pine relic
#

wait hold on

storm dock
pine relic
#

why did you weld the "Handle" part of the tool

storm dock
#

you need to play animation on handle too

pine relic
#

it already does that by default no?

past mountain
pine relic
#

oh

past mountain
pine relic
#

right

storm dock
#

ig

past mountain
#

lemme try that

past mountain
#

unless im mistaken

storm dock
#

AnimationController

pine relic
#

You need an animation controller

pine relic
#

not with the anim controller

past mountain
pine relic
#

like i had never said to play animation on handle too

storm dock
#

im not sure if it works 😭

past mountain
#

xd

#

idek what an animationcontroller is xd

#

but ill try it

storm dock
#

ima test it rn

past mountain
#

ok so apparently its for parts only

#

as in a part only rig

#

with no humanoid ;-;

storm dock
#

oh nvm

#

you don't need to play animation on sword

past mountain
#

:p

storm dock
#

in moon animator

past mountain
#

a

#

i forgot to send the animation script

storm dock
#

like ts

past mountain
#

yea
-# p.s. ts doesnt mean "this" :P

storm dock
#

this shit 😄

past mountain
#

oh alr

#

anyways heres the scripting code thing

#
local Player = PlayerService.LocalPlayer

local WeaponFolder = script.Parent
local Tool = WeaponFolder.Parent
local Handle = Tool:WaitForChild("Handle")
local AnimationsFolder = Handle:WaitForChild("Animations")

Tool.Equipped:Connect(function()
    local IdleAnimation = AnimationsFolder:WaitForChild("Idle")
    local Character = Player.Character or Player.CharacterAdded:Wait()
    local Humanoid = Character:FindFirstChildOfClass("Humanoid")

    if Humanoid then
        local Animator = Humanoid:FindFirstChildOfClass("Animator")

        if Animator then
            IdleTrack = Animator:LoadAnimation(IdleAnimation)
            IdleTrack.Priority = Enum.AnimationPriority.Idle
            IdleTrack:Play()
        end
    end
end)

Tool.Unequipped:Connect(function()    
    if IdleTrack then
        if IdleTrack.IsPlaying then
            IdleTrack:Stop()
        end
    end
end)

Tool.Activated:Connect(function()    
    local AttackAnimation = AnimationsFolder:WaitForChild("Slash")
    local Character = Player.Character or Player.CharacterAdded:Wait()
    local Humanoid = Character:FindFirstChildOfClass("Humanoid")
    
    if Humanoid then
        local Animator = Humanoid:FindFirstChildOfClass("Animator")

        if Animator then
            local AttackTrack = Animator:LoadAnimation(AttackAnimation)
            AttackTrack.Priority = Enum.AnimationPriority.Action4
            AttackTrack:Play()
            
            Tool.Unequipped:Connect(function() 
                if AttackTrack.IsPlaying then
                    AttackTrack:Stop()
                end
            end)
        end
    end
end)```
#
    local AttackAnimation = AnimationsFolder:WaitForChild("Slash")
    local Character = Player.Character or Player.CharacterAdded:Wait()
    local Humanoid = Character:FindFirstChildOfClass("Humanoid")
    
    if Humanoid then
        local Animator = Humanoid:FindFirstChildOfClass("Animator")

        if Animator then
            local AttackTrack = Animator:LoadAnimation(AttackAnimation)
            AttackTrack.Priority = Enum.AnimationPriority.Action4
            AttackTrack:Play()
            
            Tool.Unequipped:Connect(function() 
                if AttackTrack.IsPlaying then
                    AttackTrack:Stop()
                end
            end)
        end
    end
end)
``` this is the attack part
gusty lodgeBOT
#

studio** You are now Level 6! **studio

storm dock
#

i dont think conneting connection in connetion is great idea 😄

#

i mean Tool.Unequipped in Tool.Activated

past mountain
storm dock
#

mrjamp knows better

past mountain
#

fixed

storm dock
#

hm

#

idkkkk

#

maybe you messed up with animation

past mountain
#

rip

past mountain
storm dock
#

in moon animator

past mountain
#

i animated as others would with a tool in mind

#

welded it to the right arm [rather than torso since its only 1 part]

storm dock
#

wait

#

you animated without a tool

#

not like this!! ??!??!?!

past mountain
past mountain
#

i took the handle

past mountain
#

added a motor to it and the right arm and yeah

storm dock
#

can you give me your sword model

past mountain
#

sure thing

#

its just one part with a mesh and nothing more

storm dock
#

im 200% sure the fix is ez and we're just overcomplicating everything

storm dock
#

erm

past mountain
#

what is it ;-;

storm dock
#

it should be a model isn't it

#

ehhh

#

sec

past mountain
storm dock
#

yea

#

sec

storm dock
past mountain
#

models arent supported for motors

storm dock
past mountain
#

whattaboutit

storm dock
#

idk bruh

#

it works with your part

past mountain
#

i just used

#

a default rig

#

with no modifications :p

storm dock
#

uh

#

k sec

#

now i cant create Rig animation 😭

past mountain
#

howd you weld it?>

#

is the right arm Part0 or Part1?

storm dock
#

the animation is still works

#

oh k

#

ik the issue

past mountain
#

hit me

past mountain
storm dock
#

where is motor

#

in sword

past mountain
#

in right arm

#

before you asked

#

i welded it exactly the same as the rig i used it with

storm dock
#

so its in Right Arm and Part0 is always Right Arm and Part1 is Handle

past mountain
#

yeppers

storm dock
#

could you show me what happens rn

past mountain
#

sure

storm dock
storm dock
past mountain
storm dock
#

it should be like this ig

past mountain
storm dock
past mountain
storm dock
past mountain
#

lemme try scripting it so it goes into the right arm

past mountain
#

it likely woulda done nothing anyways

past mountain