How to tween or animate a protractable helmet?

I want to make a protractable helmet that comes up from the back of the player’s character then moves over the player’s head but I have no idea where to start. I read on a similar post that I have to rig an invisible part to the character and weld it to the helmet (and none of the rigging tutorials out there deal with stuff like this, only custom characters) but the post isn’t exactly clear on how exactly to do it. If I were to tween it like how I would a regular part, it prolly wouldn’t work.

And according to it, I also have to make use of euleranglesxyz but I’m not exactly sure why and how I should use it.

Here’s a post on someone elses project for tweening the mask, through the C0 of a weld or Motor6D (both are joint Instances) CFrame offset from the initial state to the final state:

But now the question is how do you find the correct C0 to place the helmet using Motor6Ds. CFrame.fromEulerAngles? Nah too confusing, just use an attachment, the CFrame property of an attachment is the equivalent of the C0 of the motor6D if the part0 and the parent of the attachment is the same since they both represent the CFrame offset from the same part, watch the gif and use the free model default Roblox sword like in the below to experiment with Motor6D C0s:

https://devforum.roblox.com/t/need-help-on-c0-cframe-rotation/911900/8?u=dthecoolest

Once you find the correct C0s you can tween them from one C0 to another and voila your cool effect.

Should I be attaching the attachment inside the helmet, part or the head?

Also where should my primary part be set to? I’m so confused with all this attachment, c0,c1 (I only have basic knowledge of this in welding)stuff.

Should I even listen to this post?

I think the easier thing to do would be just to make an animation for the helmet and play it instead of tweening anything.

Uhm how do I animate parts then? Do I do it like how I would with a character’s movements?

Tbh I’m not very well versed in this since I do mostly scripting… perhaps ask on the building category or look up a YouTube video for it. I do believe you have to make some parts with bones and do some welding or something like that. But after the animation is complete you can call it from a script with a couple of lines and that would just skip tween service entirely.

I’ll try the building category but do you know how to do this via scripting? Honestly I’m so confused because everyone’s saying different things, some say to use attachments, some suggests rigging transparent parts, others suggest tween service. Information is all over the place across countless different posts.

It depends which method you want to use. They probably all work. Pick one that is most understandable or comfortable for you. The method I used was TweenService.

Here is a sample file I made which will hopefully be helpful for you to understand.
RotatingMask.rbxm (4.6 KB)

I tried to comment the code to explain what each line was doing. What I do is Tween the C0 value, which is changing the CFrame offset of the weld, therefore rotating the mask.

If you have more questions or need a line clarified send me a message. I’ll be going offline for now :slight_smile:

Uhm this sample is a notepad? This is what I get when I try to open it:

<roblox!‰ÿ

     a           META$   "       ð      ExplicitAutoJoints   trueINST          ð       Decal          INSTe          ð
      Part           
INST          ð      Script       INST          ð
      SpecialMesh       INST          ð      Vector3Value       PROP&   $       ð       AttributesSerialize        PROP    '       ð       Color3 '   P     PROP          ð       Face      PROP          Ð       Name	 Àface   facePROP#   &       ða    
   SourceAssetIde  P   PROP          ð       Tags        PROP8   P       ò    a   Texture   rbxasset://t ¯s/face.png  Pe.pngPROP          ð       Transparency        PROP          ð      Anchored PROP&   $       ð      AttributesSerialize        PROP   e       ð   
   BackParamA~~    PROP   e       ð   
   BackParamB~~      PROP          ð
      BackSurface        PROP#   !       ð      BackSurfaceInput        PROP          ð      BottomParamA~~    PROP          ð      BottomParamB~~      PROP           ð   
   BottomSurface        PROP%   #       ð      BottomSurfaceInput        PROPI   M       ð      CFrame   €¿    .½»³ @  €? @.½»3     }} `  ‚‚@@ €X  PROP          ð   
   CanCollide PROP          ð      CanTouchPROP          ð   
   CastShadowPROP#   !       ð      CollisionGroupId        PROP          ð      Color3uint8££¢¢¥¥PROP%   #       ð      CustomPhysicalProperties  PROP          ð
      FrontParamA~~    PROP          ð
      FrontParamB~~      PROP          ð      FrontSurface        PROP$   "       ð      FrontSurfaceInput        PROP   e       ð   
   LeftParamA~~    PROP   e       ð   
   LeftParamB~~      PROP          ð
      LeftSurface        PROP#   !       ð      LeftSurfaceInput        PROP          ð      Locked  PROP          ð      Massless PROPe          ð
      Material      PROP          Ð      Name	 ÀHead   MaskPROP          ð
      Reflectance        PROP          ð
      RightParamA~~    PROP          ð
      RightParamB~~      PROP          ð      RightSurface        PROP$   "       ð      RightSurfaceInput        PROP          ð      RootPriority        PROP   ,       þ      RotVelocity  P     PROP!   &       ö   
   SourceAssetIde  P   PROP          ð      Tags        PROP          ð   	   TopParamA~~    PROP          ð   	   TopParamB~~      PROP   e       ð   
   TopSurface        PROP"           ð      TopSurfaceInput        PROP          ð      Transparency~       PROP   )       þ      Velocity  P     PROP           ð   
   formFactorRaw      PROP          ða      shape      PROP    %       ñ      size€   p}      PROP"           ð      AttributesSerialize    PROP          ð      Disabled PROPe          ð
      LinkedSource    PROP          ð      Name   ScriptPROP?   =       ð.   
   ScriptGuid&   {C92C7ED6-EC85-433C-A519-784D34901DF9}PROPß  ‚      ó!      Sourceo  local TweenService = game:Get (("  B")

6 óhead = script.Parente amask =" ð.Mask


-- Making the tr ó info customization@ t =™ úInfo.new(
	1,
	Enum.EasingStyle.Linear PDirecQ ð.InOut,
	0,
	false !
)‘ TCreat“ Cweld   ± = Instance} P"Weldý   ².C0 = CFram “0,0,0) -- ñ offset of 0 fromö SPart0A 1A 1A 1A 1ƒ M eT    W  ~ 4ent% Þ 1funeP openžO()
	Ÿbgoal
	í , ±Goal = {}
	1 1 unit in¡ ní  Ü öô and rotated 70 degrees upward, relatively
	[ *T.Hñ
EulerAnglesXYZ(math.rad(-70)„œ Û ‰ Dplayçzu?ä our variablesê ! |:O  e(»,ž,? 1)
	4 ®:Play()
enkTcloselR  @ SqBack to._	@posiß%
	G ? q ¥ Ù S Ú Òwhile true do¾Ù swait(2)• 
 P)
endPROP           ð   
   SourceAssetIde       PROP          ð      Tags    PROP"           ð      AttributesSerialize    PROP          ð      LODX   PROP          ð      LODY   PROP          ð      MeshId    PROP          ð      MeshType    PROP          ð      Name   MeshPROP   e       ð      Offset            PROP          ð      Scale@  @  @  PROP           ð   
   SourceAssetIde       PROP          ð      Tags    PROP          ða   	   TextureId    PROP"           ð      VertexColor         PROP"           ð      AttributesSerialize    PROP          @    ðName   OriginalSizePROP           ð   
   SourceAssetIde       PROP          @    Tags    PROP          ð      Value@  @  @  PRNT   =       ? a   P  END     	       </roblox>