edited April 2017 in ORK Support
i've been through all the equipment viewer events i could find and i'm fairly sure this isn't possible within the current framework, but i thought i'd ask anyway, just in case there's a more elegant solution to the one i'm using. so, here goes:

the current equipment viewer mechanism works ok for eggmen and the like, where all the actors are the same basic type, but i've got a range of different models in my current game, of different shapes and sizes, and using a range of different animations, so what works for one actor to display a particular weapon in combat, may not work for a different actor

i've got around the problem for the time being by having different inventory copies of each weapon, with different equipment viewer settings for each one, and restricting their usage by class, but it's a pretty clunky solution

as an example i've currently got "Machete (Male)" and "Machete (Female)" for basically the same weapon, but even then it relies on certain assumptions about each type of actor that may not always hold true as the game develops and i add more characters and different attack animations. my ideal solution would be to have a single weapon in the inventory, and tweak its equipment viewer settings on the fly

Post edited by HarryOminous on
  • edited April 2017
    It sounds like the problem you're having is that the position and rotation settings need to be customized for each character model; correct me if I'm wrong.

    Are you putting the Equipment Viewer component directly on the "right hand" transform? (I think that's how the "egg" characters are set up.)

    Instead of doing that, create a new child transform directly under the hand; call it "Right Hand Viewer" or something like that. Put the Equipment Viewer on that transform. Now you just need to adjust the viewer's transform in each model and you can leave the weapon's settings alone.

    This also works if you have duplicate viewers for displaying a weapon sheathed when out of combat. As long as the viewer is on a child transform, you're good.

    Choose one character model to be your reference for setting up the base viewer position/rotation settings. A good choice would be the model your weapon animations are built on (even if it's just an untextured "dummy").

    I also created a simple cylinder about 2m long and 0.1m in diameter as a reference prop and placed it in the Right Hand Viewer transform. Weapon models are often built at different orientations, so this one should only require minimal adjustments to the Viewer transform to get it oriented correctly.

    Once you have a good initial orientation set up (check how it looks in different battle idle animations), get all of your initial weapon positioning values from the same model. And when setting up other characters, use your reference prop to get the Viewer transform positioned and aligned correctly.

    It should be a breeze after that.
    Post edited by Keldryn on
  • thanks for the reply

    i was already using a child transform for the equipment viewer, but i had it initialised to zero for each character, and was then trying to position each weapon by using its equipment viewer position and rotation

    i think what you're suggesting instead is to make sure the equipment viewer is initially positioned and rotated so that it correctly displays a reference piece of equipment (the simple cylinder in your example) for each distinct character type?

    after that, any adjustments to that weapon's equipment viewer position and rotation should automatically work on all the characters that can use that weapon

    yeah, that makes more sense than my method, i'll give it a shot

    (plus, i've just noticed that you can preview all the weapons on each actor's equipment viewer, which should speed up the whole process)

    thanks
  • i think what you're suggesting instead is to make sure the equipment viewer is initially positioned and rotated so that it correctly displays a reference piece of equipment (the simple cylinder in your example) for each distinct character type?
    Yes, exactly. Once you have a good "neutral" reference set up, the rest is easy. It works for holstered or sheathed viewers as well.
Sign In or Register to comment.