Search Unity

New Indie user basic shadows???

Discussion in 'Editor & General Support' started by captnemo, Mar 21, 2008.

  1. captnemo

    captnemo

    Joined:
    Mar 21, 2008
    Posts:
    9
    Hi
    just bought unity indie license,

    sorry if i missed something obivous but I've been looking around for almost an hr and I can't figure out how to do a basic blob shadow under a character/vehicle just to connect them to the ground.

    Cheers,
    Tim
     
  2. TJB

    TJB

    Joined:
    Mar 20, 2007
    Posts:
    146
    Their is a Blob-Shadow folder in the Standard Assets folder. All the stuff needed is in their. For something like a car you'll have to change the shape of the blob in photoshop.

    If you don't have the Standard Assets folder go Assets - Import Package and browse to /Applications/Unity/Standard Packages/ and select the Standard Assets package.
     
  3. meshpig

    meshpig

    Joined:
    Aug 17, 2006
    Posts:
    178
    ... also if your shadow fails to appear after adjustments in PS, use the settings button above the project window to reimport it.

    The texture also needs to be clamped.

    m
     
  4. GusM

    GusM

    Joined:
    Aug 27, 2005
    Posts:
    585
    Note also that blob shadows projectors doesn´t currently work with terrains, only does with meshes.
     
  5. captnemo

    captnemo

    Joined:
    Mar 21, 2008
    Posts:
    9
    thanks for the replies just getting into it!

    hmm I was planning a terrain based vehicle game
    what would you guys do for a terrain vehicle shadow?

    (nb I'm only a student first venture into 3d games, pro is not best option just yet...)
     
  6. meshpig

    meshpig

    Joined:
    Aug 17, 2006
    Posts:
    178
    T

    You just parent the projector to the object and make it a prefab. Use the clip distances to determine the vertical depth of the shadow. Make whatever shape you need in PS.

    Cheers!

    m
     

    Attached Files:

  7. meshpig

    meshpig

    Joined:
    Aug 17, 2006
    Posts:
    178

    Yeah, you have to stick a plane underneath.

    I did some experiments with an alpha shaded lightmap on a plane attached to the moving object. OK for flat surfaces.


    m
     
  8. Aras

    Aras

    Unity Technologies

    Joined:
    Nov 7, 2005
    Posts:
    4,770
    Right now, place a plane underneath the vehicle (if you want to go fancy, you can deform plane's vertices to match terrain heightmap).

    Projectors on terrain is something we're working on and should be there in next release of Unity.
     
  9. meshpig

    meshpig

    Joined:
    Aug 17, 2006
    Posts:
    178
    Cool!!

    -But how do you do deform the plane? Does that include a brushed terrain or is it specifically from a RAW file?

    Thanks!
    m
     
  10. GusM

    GusM

    Joined:
    Aug 27, 2005
    Posts:
    585
    Cool!
    Thank you in advance.
     
  11. Aras

    Aras

    Unity Technologies

    Joined:
    Nov 7, 2005
    Posts:
    4,770
    Terrain class has SampleHeight, or alternatively TerrainData can return 2D region of heightmap via GetHeights
     
  12. meshpig

    meshpig

    Joined:
    Aug 17, 2006
    Posts:
    178
    Thanks