Hiho!
Here some things how i would do it:
$includemodel "m_anm.mdl" ( you need only this one for a gmod playermodel )
$hboxset "default" ( you can generate a complete new hitbox-set with SDK MDL Viewer if you wish )
$attachment anim_attachment_RH "ValveBiped.Anim_Attachment_RH" 0 0 0 rotate -90 0 -90
$attachment anim_attachment_LH "ValveBiped.Anim_Attachment_LH" 0 0 0 rotate -90 0 -90
$attachment anim_attachment_head "ValveBiped.Bip01_Head1" 0 0 0 rotate -90 0 -90
( standard attachments. anim_attachment_RH and anim_attachment_LH for weapons )
i hope i could help you. ^^
Hiho!
Ok. For this exist only one reason: The skeleton of the model don't have the "ValveBiped.Anim_Attachment_RH" or "ValveBiped.Anim_Attachment_LH" bone.
So try this:
$attachment anim_attachment_RH "ValveBiped.Bip01_R_Hand" 0 0 0 rotate -90 0 -90
$attachment anim_attachment_LH "ValveBiped.Bip01_L_Hand" 0 0 0 rotate -90 0 -90
But I do not know, if after that, the position and rotation is still correct.
I test it for myself fast. ^^
Edit: I tried it and it works fine for me.
This reminds me of something.
Can you please give me a list from all bones that your model use?
(open the smd with the model and copy all bones and paste it here)
I had this error before at a model from a friend that i fixed, but i need to be sure and for that i need a list of the bones that your model use.
Edit:
I know it now again. But i need the list to explain it. ^^
-snip- Way too much for one post, lagged the entire thread
No problem ^^
Thanks! That is exactly what i need and here comes the "how to fix it fast":
The problem are these bones:
48 "ValveBiped.weapon_bone" 1
49 "ValveBiped.weapon_bone_RHand" 48
50 "ValveBiped.weapon_bone_LHand" 49
51 "ValveBiped.weapon_bone_Clip" 50
The weapon_bone is ( was ) important for old css models but make a conflict with the weapons in GMod. ( That what your picture was shown )
If you start the SDK MDL Viewer you will see that this weapon bone is under the feet in ragdoll pose and thats why it is this way in game too.
Fix:
I bet you won't to re-rig the guy right? ^^ So please follow this steps:
1. Be sure that you make not one mistake ( better make a BACKUP from smd and phy )
2. Open the smd and phy with your favorite editing program ( i use N++ )
3. The important part
Change this:
48 "ValveBiped.weapon_bone" 1
49 "ValveBiped.weapon_bone_RHand" 48
50 "ValveBiped.weapon_bone_LHand" 49
51 "ValveBiped.weapon_bone_Clip" 50
To this:
48 "ValveBiped.123456_1234" 1
49 "ValveBiped.123456_1234_12345" 48
50 "ValveBiped.123456_1234_12345" 49
51 "ValveBiped.123456_1234_1234" 50
In BOTH files! Save the files.
4. Re-compile your model with your new files and should work now.
And if you think: "Why should i do it this way?"
Here the answer:
If you rename the bone's with the same lenght of character's , then you have not to rebuild the model.
You only "disable" the "wrong" bone's for GMod at this way. ^_^
This variant of a "fast fix" work for all old css models. But remember: The bones that you manipulate at this way, should not be used for a hitbox or constraint or attachment!
[quote]The bones that you manipulate at this way, should not be used for a hitbox or constraint or attachment![/quote]
So should I remove the attachment once I change it or how should I modify the .qc according to this bone change?
You dont need to change the .qc for this again. ^^
Because you do not use one of the "wrong" bones in your qc.
[t]http://puu.sh/4MgcV.jpg[/t]
Thank you so much, it worked!
[QUOTE=code_gs;42474127][t]http://puu.sh/4MgcV.jpg[/t]
Thank you so much, it worked![/QUOTE]
Whoohoo! :D
Sorry, you need to Log In to post a reply to this thread.