Search Unity

How to best animate when dealing with hundreds of individual GameObjects?

Discussion in 'Animation' started by mrCharli3, Feb 16, 2018.

  1. mrCharli3

    mrCharli3

    Joined:
    Mar 22, 2017
    Posts:
    976
    I am making a 2D top-down game. I allow the player to do their own landscaping, one of the things they can place is water. This is done using bitmasking. However, I want the water to be animated (each piece of water has 4 frames). Not sure what the best option is when dealing with animation on a lot of individual GameObjects. A common scenario will probably be around 200 individual water-tiles.

    Should I use Tiled2Unity?
    Should I just use Unity's own Animator and have each GameObject play it's own animation on a loop?
    Should I do something else?

    EDIT: Decided to do animations in a script to minimize repetetive work.
     
    Last edited: Feb 17, 2018
  2. FiveFingerStudios

    FiveFingerStudios

    Joined:
    Apr 22, 2016
    Posts:
    510
    I’m no expert on this, but maybe use a shader for the water tiles instead of animation?