• Bone aligning and rendering
    2 replies, posted
Two things i can't figure out no mather how hard i try. 1. I have an entity which i want to place at the same pos as a ragdolls limb, and with the same angles as well. This works fine, but how would i add an offset to the angle? I've already tried adding the offset angle to the angle of the limb with no success. [highlight]SOLVED[/highlight] 2. How can I make my effect run the Render hook only when the game renders an other entity? Thanks in advance!
To offset an angle, you need to use the RotateAroundAxis method. I imagine it would look like this.. [lua] angle:RotateAroundAxis( angle:Right( ), offset.p ); angle:RotateAroundAxis( angle:Up( ), offset.y ); angle:RotateAroundAxis( angle:Forward( ), offset.r ); [/lua]
[QUOTE=Nevec;16793173]To offset an angle, you need to use the RotateAroundAxis method. I imagine it would look like this.. [lua] angle:RotateAroundAxis( angle:Right( ), offset.p ); angle:RotateAroundAxis( angle:Up( ), offset.y ); angle:RotateAroundAxis( angle:Forward( ), offset.r ); [/lua][/QUOTE] Thanks, that worked.
Sorry, you need to Log In to post a reply to this thread.