Search Unity

  1. Good news ✨ We have more Unite Now videos available for you to watch on-demand! Come check them out and ask our experts any questions!
    Dismiss Notice

UMA - Unity Multipurpose Avatar on the Asset Store!

Discussion in 'Assets and Asset Store' started by FernandoRibeiro, Dec 24, 2013.

  1. DeadSeraph

    DeadSeraph

    Joined:
    Sep 8, 2017
    Posts:
    95
    This makes more sense. So there might be something in the project that's enforcing texture clamping. Any idea where I'd look off the top of your head?

    *Edit to add: I never changed anything on the texture import settings for anything related to this asset or for UMA, so I'm wondering if it might be something set globally or within the code of this particular project? I literally just installed it, ran the demo scene, and the eyebrows and facial hair didn't work.
     
    Last edited: Jul 26, 2019
  2. DeadSeraph

    DeadSeraph

    Joined:
    Sep 8, 2017
    Posts:
    95
    The only one missing is the roughness. I don't think that's the problem. I have a feeling it's due to the texture import settings as Jaimi mentioned.
     
  3. egherbaz

    egherbaz

    Joined:
    Sep 21, 2012
    Posts:
    34
    Thanks Jaimi, I will add my request after i figure out how to add it.

    I don't know if what I do when I have issues with the overlays position will help you, but what I do is this:
    i run the scene in the editor, then select the DCA and on the UMA menu Runtime/Save selected..to PNG, then I open it with Photoshop where I check if the sizes of the textures are correct and which are the correct positions for the overlapping textures.
    Recently I faced a similar case like you, and when I did the above, I found that my textures were the half of the size on the atlas and i was setting the overlaping textures with wrong rects.
     
    Last edited: Jul 27, 2019
  4. DeadSeraph

    DeadSeraph

    Joined:
    Sep 8, 2017
    Posts:
    95
    I heard from the author of the asset this afternoon and it seems like this might be related to build settings. Apparently iOS build settings globally square all the textures, which is what is probably causing the issue.

    Drom the dev:

    "The texture size comment is half correct. It happens when texture sizes change or some build setting enforces square textures. The head texture is a rectangle. When some builds (I know one is mac) change it to be square, the adjusted texture has different eyebrow locations.

    And the eyebrows are smaller textures with location x/y settings in the first place. (If they were the same size as the head texture they wouldn’t be affected at all). I started not using the locations feature and just create the same sized overlay textures because of this.

    The only way to fix it is doing some trial error on the location xy / height width values of the textures on the eyebrow recipes. usually, you’ll have to double some of them.

    Best regards."


    If anyone knows of a good work around here, I'm all ears. I can change the positioning of each overlay manually (which I'd obviously rather not do), I suppose. But then my concern is that it won't work properly with other builds (such as android). I'm a little out of my element in this regard, so if anyone can offer some big brain solutions I'd love to hear them.
     
    Last edited: Jul 27, 2019
  5. egherbaz

    egherbaz

    Joined:
    Sep 21, 2012
    Posts:
    34
    :confused: where can I read how to use the starting bone position?
     
  6. Jaimi

    Jaimi

    Joined:
    Jan 10, 2009
    Posts:
    5,382
    Probably best to use the Develop branch for bone poses, I made some changes to the editor to make it easier to use. But basically, you just edit the bones in the pose (usually scaling).
    I added a Wardrobe Slot for "Physique" also, and a menu item to generate all the pieces to make the bone pose and DNA.
     
  7. Jaimi

    Jaimi

    Joined:
    Jan 10, 2009
    Posts:
    5,382
    You're probably best off to go in and manually make the items square, and then just adjust the rect positions. Then it won't matter if one resizes it, and another doesn't.
     
  8. ellenblomw

    ellenblomw

    Joined:
    Mar 4, 2018
    Posts:
    153
    Hello, I am following a tutorial to get my 3d character up and running with UMA but I am stuck at trying to drag my meshes into the slot in the slot builder. I cant drag n drop any mesh into the slot mesh, just gives me a ring with a line in it: https://drive.google.com/open?id=19sYUQACMqY6ZWcYt0i0FTawD1ttKrEGq
    What am I doing wrong?

    Tutorial:
     
  9. Jaimi

    Jaimi

    Joined:
    Jan 10, 2009
    Posts:
    5,382
    It has to be a skinned mesh. Make sure you exported it with the armature and it has been correctly rigged.

     
  10. ellenblomw

    ellenblomw

    Joined:
    Mar 4, 2018
    Posts:
    153
  11. ellenblomw

    ellenblomw

    Joined:
    Mar 4, 2018
    Posts:
    153
    It seem to be skinned mesh renderer, at least it says so if I press the different part of it and look in the inspector
     
  12. hopeful

    hopeful

    Joined:
    Nov 20, 2013
    Posts:
    5,189
    Blender is a good 3D modeling program, and it's free. UMA was originally designed to work with Blender, so if you need it, Blender is a logical choice.
     
    ellenblomw likes this.
  13. Jaimi

    Jaimi

    Joined:
    Jan 10, 2009
    Posts:
    5,382
    You cant drop the fbx itself into the slot field. Expand it in the project and find the skinned mesh under it.
     
  14. Firlefanz73

    Firlefanz73

    Joined:
    Apr 2, 2015
    Posts:
    1,197
    Hello,

    I want to install the Salsa Lip Sync Update soon and the latest UMA Version for Unity 2019.1.12.

    Should I use the Uma GitHub Develop?
    Should I wait for an update coming very soon or use the current?

    Thanks a lot and have a nice Sunday :)
     
  15. ellenblomw

    ellenblomw

    Joined:
    Mar 4, 2018
    Posts:
    153
    Hmm but I cant expand it anymore than I already am? There is no expand button on it? https://drive.google.com/file/d/19sYUQACMqY6ZWcYt0i0FTawD1ttKrEGq/view

    I got in contact with the person who made it and he doesnt understand the armature part, and asks if that is a feature just in one single software (I think he uses Maya) or if its some sort of own software
     
    Last edited: Jul 28, 2019
  16. chrisk

    chrisk

    Joined:
    Jan 23, 2009
    Posts:
    691
    Hi, guys, I have one problem I'm trying to solve but I can't seem to figure out how.

    Ok, here is what I like to do.
    I have many Overlays and the same Overlays can be applied to many different Slots (several different body parts). The combinatorial combination will run out of handle pretty quickly.
    Therefore, what I would like is to add Overlays to Recipes at runtime without creating Recipes first.

    Looking at the source code, I thought I can add overlay during BuildCharcter(), in this particular case, right before Mege is called in AddAdditionalSerializedRecipes.

    My code is just for a quick test to add an Overlay to a shirt recipe.
    The code will add the Overlay and it is added without error and umaRecipe.Merge() will show that overlay is in there as expected. But the overlay will not show up in the game.
    Could someone please help what I'm missing?
    I believe adding Overlays at runtime is a useful feature in general anyway.
    Thanks a lot!

    Code (CSharp):
    1.  
    2.  
    3. public OverlayDataAsset overlayDataAsset;  //  "MaleShirt01Color.asset"
    4.  
    5. public void AddAdditionalSerializedRecipes(UMARecipeBase[] umaAdditionalSerializedRecipes)
    6. {
    7.       if (umaAdditionalSerializedRecipes != null) {
    8.           foreach (var umaAdditionalRecipe in umaAdditionalSerializedRecipes) {
    9.               UMAData.UMARecipe cachedRecipe = umaAdditionalRecipe.GetCachedRecipe(context);
    10.  
    11. // my code begins here
    12.               UMAWardrobeRecipe wardrobeRecipe = umaAdditionalRecipe as UMAWardrobeRecipe;
    13.               if (wardrobeRecipe != null && wardrobeRecipe.wardrobeSlot.Equals("Chest")) {
    14.                   cachedRecipe.slotDataList[0].AddOverlay(new OverlayData(Instantiate(overlayDataAsset)));
    15.               }
    16. // my code ends here.
    17.  
    18.               umaData.umaRecipe.Merge(cachedRecipe, false);
    19.           }
    20.       }
    21.  }
    22.  
     
    Last edited: Jul 29, 2019
  17. kenamis

    kenamis

    Joined:
    Feb 5, 2015
    Posts:
    356
    It looks like you are trying to drag the mesh asset into that field, not the skinned mesh renderer.

    Armature is blender terminology for a skeleton (I think).

    It looks like your mesh has skinning data so Unity probably imported a skinned mesh renderer for you, you just need to find the correct object.
    For example,
    upload_2019-7-28_13-14-55.png
     
    Jaimi likes this.
  18. ellenblomw

    ellenblomw

    Joined:
    Mar 4, 2018
    Posts:
    153
    Thank you Kenamis, I have tried all of the children to the model and none of them work :/
     
  19. egherbaz

    egherbaz

    Joined:
    Sep 21, 2012
    Posts:
    34
    sorry for my ignorance but what you mean by "Develop branch" and "Physique"?
    my problem for starting bone position was that I was not setting the weight to 1 on the BonePoseDNAConverter, I thought that by just adding it will control the morf, because it have a modifying DNA, so I thought that by using that will be enought, and that is why i was asking where to read the use of that (because the tooltip is not too much explicit). At the end what i did was to add the bonepose converter for the starting point and a skelentondnaconverter for after changes, because when starting weight is set to 1 then the modifying DNA dont take effect (on the BonePoseDNAConverter)
     
    Last edited: Jul 29, 2019
  20. egherbaz

    egherbaz

    Joined:
    Sep 21, 2012
    Posts:
    34
    on your video what you are dragging to the slot builder is the MESH, not the SKINNED MESH, what you need to drag on the slot builder is the SKINNED not the MESH, as @kenamis told you in his post.
    you can identify the skinned mesh on the project window by its icon see on the @kenamis image that the skinned mesh have a different icon than the MESH. I recommend you to move the project window slider all to the left, so you will be able to see the icons, instead of the way you have it(showed in your video that it is almost at the middle)
     
    Last edited: Jul 29, 2019
  21. hopeful

    hopeful

    Joined:
    Nov 20, 2013
    Posts:
    5,189
    I think you may have previously seen the "master" branch of UMA on Github. There is also a "develop" branch, which is the version that is being worked on for the next release.
     
  22. egherbaz

    egherbaz

    Joined:
    Sep 21, 2012
    Posts:
    34
    I tested the blank recipe (no slots) on the race base recipe, you can use it you don't add a default animation controller on the DNA on the start, and the reason is because with an empty slots on the base recipe and no default wardrobes, the skeleton chain is not generated (just generates Root and Global if no default wardrobes) and with an animator controller that plays an animation on the start (like an idle animation that use almost all bones) the animation will not find the bones it needs and you will get errors like this:
    AvatarBuilder 'emptyRace': Transform 'Hips' for human bone 'Hips' not found
    (unless you add default wardrobes which slots are weighted to the bones the animation use)

    I even tested with a prebuild skeleton (by using bone builder) but when run, that prebuild skeleton is replaced again for just root and global (why is that? I supouse that prebuilding a skeleton will keep it and not rebuild)

    So what I did, to avoid those errors from the AvatarBuilder, because I don't want to add the default animator controller with code and I want to start with no default wardrobes, was to create a mesh that is based on planes



    and put an edge in the center of every joint that my animations reference


    and that is the mesh that im setting as base on the base race recipe, with an overlay with transparent textures 4x4 px, that way I never need to hide base slots when adding wardrobes (in my case my wardrobes are the full parts every time, I mean my legs for example allways will full replace the legs wardrobe, I don't overlap meshes), avoid the animation errors and probably never need to use the basemeshhider, so im just using #1 of what you told me on your post https://forum.unity.com/threads/uma...-the-asset-store.219175/page-176#post-4704032
     
    Last edited: Jul 29, 2019
  23. egherbaz

    egherbaz

    Joined:
    Sep 21, 2012
    Posts:
    34
    OMG, thank you, to be honest I never went to UMA on Github untill Jaimi told me to add a request jajaja and still didn't added because still dont know how too (i'm not familiar with code repositories :oops:)
     
    Last edited: Jul 29, 2019
  24. chrisk

    chrisk

    Joined:
    Jan 23, 2009
    Posts:
    691
    ok, to make the test easier, here is the set up to dynamically add an Overlay to existing Recipe.
    Replace AddAdditionalSerializedRecipes() with the following test code and click on Chest->Shirt 2 using "UMA DCS Demo - Simple Setup" Scene

    "Shirt 3" use to two overlays but "Shirt 2" uses only one overlay. I'm trying to add an overlay to "Shirt 2" to make it look like "Shirt 3".

    I tried to trace into the BuildCharacter and everything looks nomal but the overlay won't show up. I think there is something very simple missing.

    I'll appreciate for your help.
    Cheers!

    Code (CSharp):
    1.         public void AddAdditionalSerializedRecipes(UMARecipeBase[] umaAdditionalSerializedRecipes)
    2.         {
    3.             if (umaAdditionalSerializedRecipes != null)
    4.             {
    5.                 foreach (var umaAdditionalRecipe in umaAdditionalSerializedRecipes)
    6.                 {
    7.                     UMAData.UMARecipe cachedRecipe = umaAdditionalRecipe.GetCachedRecipe(context);
    8.                  
    9.                     UMAWardrobeRecipe wardrobeRecipe = umaAdditionalRecipe as UMAWardrobeRecipe;
    10.                     if (wardrobeRecipe.DisplayValue.Equals("Shirt 2")) {
    11.                         var slotData = cachedRecipe.slotDataList.FirstOrDefault(i => i==null ? false : i.slotName.Equals("MaleTorso"));
    12.                         if (slotData) {
    13.                             var overlayData = context.InstantiateOverlay("MaleShirt01Color");
    14.                             slotData.AddOverlay(overlayData);
    15.                             Debug.Log("Adding Overlay: " + overlayData.overlayName + " to slot " + slotData.slotName);
    16.                         }
    17.                     }
    18.                  
    19.                  
    20.                     umaData.umaRecipe.Merge(cachedRecipe, false);
    21.                 }
    22.             }
    23.         }
    upload_2019-7-29_17-13-58.png
     
  25. Jaimi

    Jaimi

    Joined:
    Jan 10, 2009
    Posts:
    5,382
    The latest develop has some nice new features - like the new rendermanagement and bone pose helpers - but if you don't use that, you can continue to use the current version until it's released.
     
    hopeful and Firlefanz73 like this.
  26. rasto61

    rasto61

    Joined:
    Nov 1, 2015
    Posts:
    334
    Hi @Jaimi,
    new to UMA here.
    When I run a bone builder with any configuration the resulting avatar animator has a scene instance of an avatar definition, not the one from the base UMA fbx avatar definition. This can't be prefabed. How do you create prefabs when following the '3rd party integration' setup?
     
    Last edited: Jul 29, 2019
  27. Firlefanz73

    Firlefanz73

    Joined:
    Apr 2, 2015
    Posts:
    1,197
    Thanks Jaimi!
     
  28. Jaimi

    Jaimi

    Joined:
    Jan 10, 2009
    Posts:
    5,382
    The problem is probably due to you modifying the recipe, and adding the same slots/overlays. I'm really not sure if that is the cause, and I don't have time to track it down right now.

    But in the RecipeUpdated event, you should be able to go into the UMAData.UMARecipe , and look for the slots and add the overlay to it at the end of the chain, without modifying the wardrobe at all.

    Something like:
    foreach (SlotData sd in UMAData.UMARecipe.slotDataList)
    {
    if (!sd) continue;

    if (this is the slot I want to update)
    {
    sd.AddOverlay(umaContext.InstantiateOverlay("BloodyBits")););
    }
    }

     
  29. Jaimi

    Jaimi

    Joined:
    Jan 10, 2009
    Posts:
    5,382
    Use the avatar from the Unified model:

    Assets\UMA\Content\UMA_Core\HumanMale\FBX\Male_Unified.fbx
    Assets\UMA\Content\UMA_Core\HumanFemale\FBX\Female_Unified.fbx
     
  30. rasto61

    rasto61

    Joined:
    Nov 1, 2015
    Posts:
    334
    Thats the one I am using. However it replaces it with 'UMADynamicCharacterAvatar' avatar (or the name of the gameobject) when I Generate Bones though. When I replace the one that was changed during Generate Bones with the Male_UnifiedAvatar then when Im doing GetBoneTransform(HumanBodyBones.Head) its not returning anything. (Male_UnifiedAvatar is a humanoid rig with the head assigned) When I dont replace the avatar instance with the asset ref and just keep the one that was generated during the Generate Bones then GetBoneTransform(HumanBodyBones.Head) returns the head properly.
     
  31. DeadSeraph

    DeadSeraph

    Joined:
    Sep 8, 2017
    Posts:
    95
    I have tried this but I can't seem to figure out what the rect positions should be since there is no way to see the changes as I make them. Very difficult to nail down which values I should be changing and to what? How are the rect values determined in the first place?
     
  32. Jaimi

    Jaimi

    Joined:
    Jan 10, 2009
    Posts:
    5,382
    Usually someone just figures them out by using Photoshop or something. The content creation PDF that ships in the UMA folder, has a page on how to calculate the offset, and an example. The trick is that it is measured from the bottom and the left.
     
  33. Jaimi

    Jaimi

    Joined:
    Jan 10, 2009
    Posts:
    5,382
    I'll try to take a look at this. It's a busy week for me, so it might be a few days.
     
  34. chrisk

    chrisk

    Joined:
    Jan 23, 2009
    Posts:
    691
    @Jaimi Hi, thanks for the pointer.

    As you suggested, I added the event handler.

    Code (CSharp):
    1. public void AddOverlay_RecipeUpdatedEvent(UMAData umaData)
    2.         {
    3.            var slotData = umaData.umaRecipe.slotDataList.FirstOrDefault(i => i == null ? false : i.slotName.Equals("MaleTorso"));
    4.            if (slotData) {
    5.                var overlayData = context.InstantiateOverlay("MaleShirt01Color");
    6.                slotData.AddOverlay(overlayData);
    7.                Debug.Log("Adding Overlay: " + overlayData.overlayName + " to slot " + slotData.slotName);
    8.            }
    9.         }
    The attached image is what the debugger shows after clicking on "Shirt 2".
    As you can see, "MaleShirt01Color" overlay is added correctly to the overlayList, however, the overlay still won't show up.

    It's really strange why it won't build with seemingly correct overlayList.

    I'm using camo Overlays (like patterns, emblems, tattoos) and it will be very useful if we can add/remove to any slots easily without a Recipe.
    The reason is that the Recipe will limit the overlay to attachable to a single slot and I need to have Recipes for each slot and for all camos.
    I hope I made it clear why it's useful and I'll appreciate if you can help.
    Cheers!
     

    Attached Files:

  35. Jaimi

    Jaimi

    Joined:
    Jan 10, 2009
    Posts:
    5,382
    Is the alpha set in the texture? Only thing I can imagine is that it's adding the texture, but it's invisible? It might be helpful to save the resulting texture set at runtime, to see if it has somehow shrunk the texture, etc.

    The wardrobe recipes are setup so that each one is a separate "item" - so a camo shirt would have a separate recipe than a plaid shirt. It's so that there is a 1-1 relationship between items and wardrobe recipes.
    If you want to double-duty a wardrobe recipe - make it both a camo shirt and a plaid shirt, for example, you can include both overlays on the recipe and vary the alpha on the colors to make one appear/disappear. Adding the overlay should have worked - I've done something similar in the past. I'll try to find some time this week to look into it, but I'm swamped with college starting up (my kids, not me, I'm old)

    There is also the option of using the low-level access to UMA - ie, just building the slots and overlays however you want them on the UMAData. In that case, you don't use a DynamicCharacterAvatar. However, you lose all the wardrobe functionality, and you also lose things like Mesh Hide Assets, shared color management, base races, etc.


     
  36. chrisk

    chrisk

    Joined:
    Jan 23, 2009
    Posts:
    691
    Hi, @Jaimi, oh, you look like a college student in the picture yourself. Good luck rearing your kid and it sounds like the end is near. ^^

    And thanks for the hint. I'm making progress. Here is the resulting texture. The Overlay went to the leg instead to the chest. I totally missed it because the viewer showed just the upper body and it was barely visible.
    I'm going to make some more investigation why but if you have a quick answer, please let me know.
    Cheers!

    upload_2019-7-31_6-11-5.png
     
  37. Jaimi

    Jaimi

    Joined:
    Jan 10, 2009
    Posts:
    5,382
    You need to fill out the "rect" value, that specifies where the overlay sits relative to the base texture. It wants the coordinates from the bottom left. I think the recipes that use it double the values (look at "maleshirt1") so it fits correctly x:0,y:1024,w:2048,h:1024.

    also - that picture has been following me around the internet since like 1995 - it always shows up as me by default.
     
  38. chrisk

    chrisk

    Joined:
    Jan 23, 2009
    Posts:
    691
    Oh, I just figured the culprit is the "rect" and now playing with rect values.
    So is the rect manually configured depends on each slot differently?
    Some just use {0,0,0,0} some use offset values like the shirt.
    I guess the differences are that shirt is part of the base texture and it needs be offsetted and some doesn't need be offsetted. I need to play bit more to figure out how rect works exactly.
    Many thanks! The problem, dynamically adding overlays is solved and I'm very happy!
     
  39. egherbaz

    egherbaz

    Joined:
    Sep 21, 2012
    Posts:
    34
    The rect is used when you will cover a part of a texture with another texture that dont have the same size as the base one.
    Is explained on the UMAContentCreation documentation as Jaimi said as well as on the Secret Anorak video
     
    hopeful and chrisk like this.
  40. mattis89

    mattis89

    Joined:
    Jan 10, 2017
    Posts:
    1,100
    Thank you ! =)
     
  41. erw29

    erw29

    Joined:
    Sep 27, 2018
    Posts:
    11
    Hi,

    i’m using your UMA Avatars for a research project in which I have to render the avatars partly see-trough (transparent). Is there a ways to achive this?

    Best,

    Erik
     
  42. mfitzpatrick-1

    mfitzpatrick-1

    Joined:
    Oct 8, 2013
    Posts:
    31
    Hello! Is there a way to have two materials work on one object/slot with UMA?

    Im having zdepth problems with LWRP so I want to have everything transparent be a different material.

    Thank you.
     
  43. Jaimi

    Jaimi

    Joined:
    Jan 10, 2009
    Posts:
    5,382
    Yes, you use a transparent shader. For best results, you may need to use a "ghost" type shader. See my shaders for an example.
     
  44. Jaimi

    Jaimi

    Joined:
    Jan 10, 2009
    Posts:
    5,382
    You have to break it up into separate slots. Then assign different materials to those slots/overlays. You can combine multiple slots in a single wardrobe recipe so you can still treat them like one unit.
     
  45. mfitzpatrick-1

    mfitzpatrick-1

    Joined:
    Oct 8, 2013
    Posts:
    31
    Ok, so it needs to be two separate objects when bringing into Unity correct?

    Thank you.
     
  46. Jaimi

    Jaimi

    Joined:
    Jan 10, 2009
    Posts:
    5,382
    Yes, separate them in the modeller. You can still save it as one fbx.
     
  47. DeadSeraph

    DeadSeraph

    Joined:
    Sep 8, 2017
    Posts:
    95
    Hi guys, back again. Looking for advice on how to approach something within UMA.

    The project I'm working on requires multiple logos (sports based). So I'm wondering how best to approach this within UMA. I've watched the Secret Anorak videos on overlays, but they seem to be based on creating overlays for the characters body.

    Basically, I would like to be able to create overlays for clothing. So you could have 30 different team logos that can be swapped out for one piece of clothing (while still being able to change the base color of the clothing without affecting the logos).

    Currently, I have 30 different logos all set up to line up properly with the UV's of a tanktop for the UMA male. I've exported one as a texture, and just switched out the albedo in the existing overlay / recipe to make sure it lines up, and it does. After that, I simply created all the other 29 variants and lined them up to do so as well in GIMP.

    So, some general questions:

    1) Would overlays be the best way to approach this?

    2) Is it possible to have one overlay or recipe with multiple images that can be swapped in and out, or is it necessary to create a unique overlay and recipe for each logo?

    3) Either way, if I wanted to change the base color of the shirt via code, but just have the logos sit over top of the shirt, how would I go about setting this up given that they are already lined up with the UV's properly? Would I use a secondary overlay, and have the logos exported with a transparent background, and then just keep the rect values at zero, since the textures are the same size?

    As always, any feedback / suggestions are greatly appreciated.
     
  48. Jaimi

    Jaimi

    Joined:
    Jan 10, 2009
    Posts:
    5,382
    1. You could do this several ways, but the most efficient would be to have a different overlay for each logo, and a different recipe for each shirt (with the base shirt, and the team logo). For example, a "Cowboys" shirt would have the base tank top, and the cowboys logo overlay/

    2. Yes. But that's a lot of management. It's simpler to just have a 1-1 relationship between shirts. So you have a "patriots" shirt, and a "cowboys" shirt for example. Then to wear it, you simply equip the correct shirt recipe - no need to fiddle with anything.

    3. In the examples look at "MaleShirt1" - it does exactly what you want. It has the base tanktop, and a "stars" overlay. The base shirt gets it's color from the shared color "Shirt1", and the stars overlay gets it's colors from the "Shirt2" shared color. If you didn't want to change the colors on the fly, you could hardcode the colors in the recipe.

    The rect values for the tanktop are set in the recipe. You'll notice that the stars overlay has the same (since they share the same texture size). You could save some memory by lowering the size of your logos, but it may not be worth it.

     
    DeadSeraph likes this.
  49. Ne0mega

    Ne0mega

    Joined:
    Feb 18, 2018
    Posts:
    341
    1) no. wardrobe recipes is the way to do it.
    2) no. you must create a unique overlay and recipe for each logo (jaimi beat me to the answer... ...there are other ways, but you would be insane to try, imho, and the optimization recieved for all the extra work would be about nil)
    3) the logo wardrobe recipe, when done properly, does not care about whatever you do with the shirt underneath.
    4) you will probaly also want to create 20 or 100 wardrobe recipes for the jersey numbers, and the jersey names would be a challenge. You could either do a recipe per jersey name/number pair, or set up a system of wardrobe recipes with 26 recipes for each letter position slot, if you want custom names/randomized names. If you want unique fonts, but customizable names and jersey numbers... ...You are gonna have to do some serious coding, or your workload multiplies by each font.

    Its a ton of work, but once you get into the groove and understanding, Id say you could get it all done in a few days.
     
    Last edited: Aug 2, 2019
  50. bran76765

    bran76765

    Joined:
    Jul 14, 2018
    Posts:
    19
    Anyone know how to change the color of a UMA avatar? because I'm trying:

    Code (CSharp):
    1. DynamicCharacterAvatar human = instanobj.GetComponent<DynamicCharacterAvatar>();
    2.  
    3. human.SetColor("Skin", new Color(78, 50, 8, 1));
    4. human.UpdateColors(true);
    5. human.BuildCharacter();
    and all it's doing is getting the color permanently stuck on white (default color). Anyone know what I'm doing wrong?
     
unityunity