Custom detailsprites

Discussion in 'Bug Reports' started by Silk, Apr 13, 2014.

  1. Z100000M

    Z100000M Vithered Weteran

    Messages:
    9,120
    Likes Received:
    70
    Trophy Points:
    0
    Makes me want to see a tall grass/ fields with crops style map in empires.
     
  2. Silk

    Silk Mapper

    Messages:
    3,145
    Likes Received:
    34
    Trophy Points:
    0
    The problem with tall grass is that they go right through the buildings. Even this grass is visible for several inches through the barracks floor.

    But maybe in large open maps, some sections could be made unbuildable and on those I suppose you could have tall grass
     
  3. flasche

    flasche Member Staff Member Moderator

    Messages:
    13,299
    Likes Received:
    168
    Trophy Points:
    0
    idk, arbitrary nobuilds just for tall grass? meh
     
  4. D.D.D. Destroyer

    D.D.D. Destroyer Member Staff Member Moderator

    Messages:
    9,506
    Likes Received:
    111
    Trophy Points:
    0
    Code in removing/hiding detail sprites when a building is placed on top? Not sure if possible though.
     
  5. Silk

    Silk Mapper

    Messages:
    3,145
    Likes Received:
    34
    Trophy Points:
    0
    Changed it to my own grass texture. I placed 5 grass textures in a row, and used all 5 as a detail sprite to experiment.

    The downside is those 5 are always on one line and can get repetitive. Another problem is because of the size, on none flat surfaces it'll start floating in the air at one end while being partially underground on the other. This can be improved up to a point but not entirely eradicated.

    The upside is that I now have 5 times as much grass for the same (maximum) amount of detail sprites. Where the grass is dense, the repetitiveness is obscured by other grass. At the edges it's visible though, but you do see similar things in modern engines.

    Grass this dense would only be viable with a detail draw distance of at least 6000, or it would look very weird popping up as an island of detail in a circle around you

    Screenshots:
    https://dl.dropboxusercontent.com/u/234836/mapping/canyon/custom_detail_grass 1.jpg
    https://dl.dropboxusercontent.com/u/234836/mapping/canyon/custom_detail_grass 2.jpg
     
    Last edited: Apr 20, 2014
  6. Z100000M

    Z100000M Vithered Weteran

    Messages:
    9,120
    Likes Received:
    70
    Trophy Points:
    0
    I guess yu could have buidable hills/parking lot/space near a farm and the rest be farmlands.
    I guess it would require to restrict to lvl1 mgs since lvl3s + any vision shenanigans such as forest dont mix at all.
     
  7. Silk

    Silk Mapper

    Messages:
    3,145
    Likes Received:
    34
    Trophy Points:
    0
    https://www.youtube.com/watch?v=V7yqUWN8oTA

    One annoying problem remains: grass sprites in the back being drawn as if they're in the front. I'm gonna test this with $alphatest instead of translucent, as that should solve that, however with a drastic decrease in quality according to the wiki. I'm hoping the quality drop will be reasonable though.

    That video was with detaildraw distance of 7000. Average fps was 220 (it's lower in the video cause I was recording it). Lowest fps I had was 160.

    Trivia: those are plants from my garden which I photographed
     
    Last edited: Apr 21, 2014
  8. Trickster

    Trickster Retired Developer

    Messages:
    16,576
    Likes Received:
    46
    Trophy Points:
    0
    That's fucking awesome.
     

Share This Page