Search Unity

  1. Welcome to the Unity Forums! Please take the time to read our Code of Conduct to familiarize yourself with the forum rules and how to post constructively.
  2. Dismiss Notice

Question retro dirt effects

Discussion in '2D' started by Krellumdaed, Jul 12, 2020.

  1. Krellumdaed

    Krellumdaed

    Joined:
    Jun 24, 2015
    Posts:
    22
    If you look at the "mother of all games" Scorched Earth, it is a 1991 C++ and assembler video game. If you watch this video of it you will see that around time index 2:18 the weapons can take out the mountain dirt and the dirt will fall. (It also has a suspended dirt mode where the dirt just stays as pixels in the air.) I really want an effect like this but other than making more or less single-pixel dirt objects I am not thinking of any way to do it. Does anyone have some suggestions on how to get this sort of fine-grained behavior? It is like a particle effect but it has more behavioral properties.

    If you have never played the game it is an interesting journey into the history of video games. You can play it on the web, original source code I think. Click here.
     
  2. aElSi2

    aElSi2

    Joined:
    Feb 20, 2019
    Posts:
    12
    Hello. I have a suggestion.
    You can do it not per pixel, but per tile like terraria's sand. When you create an explosion you scan through all the tiles above it, then turn them into objects (i suggest joining multiple falling tiles in vertical lines) and start displacing them down. When an object meets the tilemap, it places a tile or multiple on the tilemap and deletes itself.
    Hope I helped.
    Edit: If you want that fine grained look, you need to either make the tiles really small or make it per pixel.
     
  3. Martin_H

    Martin_H

    Joined:
    Jul 11, 2015
    Posts:
    4,433
  4. Krellumdaed

    Krellumdaed

    Joined:
    Jun 24, 2015
    Posts:
    22
    Martin_H likes this.