Please or Register to create posts and topics.

attachments in 1st and 3rd person

I need to attach a thing to the portalgun but when in firstperson I see it moving, since it's parented to the model visible in thirdperson (which has a idle animation).

Is this coop or singleplayer? Cause in coop the camera will move if you parent the other partners view to the portalgun.
I assume Valve has some type of viewing script (or attatchment) otherwise you won't be able to see your partners view when you press tab. In HL2 I think they used the 'muzzle' attachment for the player's view around the world.

Singleplayer -> All you need to do is create an output: "ent_fire nameOfThingYouWantToParent setparent weapon_portalgun", "ent_fire nameOfThingYouWantToParent setparentattachment(maintainoffset) muzzle"

?????????????????????????????TWP Releases | My Workshop

The model visible in firstperson isn't the same in thirdperson, as usual in games. Since the player model in thirdperson has an animation, objects don't appear stable in firstperson.
I suspect there's no workaround.

Depends what you want to attach. If you parent a dynamic prop to the player it will only follow the player's current z axis (no x or y sorry).

What do you think Valve uses to attach the players' camera to when you are third person?

?????????????????????????????TWP Releases | My Workshop

No, you can attach a prop and have it follow all the axes (x, y, z), no problem with that, both in firstperson and thirdperson.
The problem is in parenting the object to something that is not the model seen in thirdperson.