Search Unity

terrain cracking animation

Discussion in 'Editor & General Support' started by badescuga9, Oct 7, 2013.

  1. badescuga9

    badescuga9

    Joined:
    Dec 11, 2012
    Posts:
    37
    I am trying to find out how can i make terrain effects animations that are possible at any given position. I have though about this and i can't seem to find any (perfect) solution using the following:

    a) Projectors. They are good for simple effects but for a 'terrain crack' animation, i don't think it could be used.

    b) Shaders. Although i think this is the way to go, i don't know if this is the best solution. Can anyone provide an example (visual or in code)?

    c) Procedural Textures (i.e. Substances). Although they are great for animations, they bring certain restrictions, they are less flexible than a shader for example (although i think it would bring less processing to the table).

    If you have an example in mind, feel free to share it!
     
  2. chelnok

    chelnok

    Joined:
    Jul 2, 2012
    Posts:
    680
    I think this one is clever:
    Unity - Add Detail to Terrains Using Cloth

    ..havnt test this technique yet, but probably not good one for terrain crack animation.

    I would first try to modify height map, having crack image, and using it as a stamp ..if that wouldnt work i'd try animated texture.
     
  3. badescuga9

    badescuga9

    Joined:
    Dec 11, 2012
    Posts:
    37
    Interesting technique but i don't think it helps me. I was thinking about possibly using something like smoothMoves to create a 2d animation, and then play it under my character, though i'm not very pleased by the idea.
     
  4. chelnok

    chelnok

    Joined:
    Jul 2, 2012
    Posts:
    680
    i think you should give a try to modify the heightmap. Check this one:
    http://www.youtube.com/watch?v=2W3Vm1_QGf0

    There is also demoscene, and i remember playing around with it ..with different kind of "stamps", and results were nice. I just havnt need anything like that, so i didnt try anything like animated holes or cracks, but i believe those could be done with interpolating stamps data with current heightmap data.. i really dont know how it hits the performance though..


    edit: lol.. i watched the video ..didnt remember ..awsome :)
     
    Last edited: Oct 7, 2013