2009
10.23

Unity3D : Skydome

Well, after some time of programming, testing finally a first version of my skydome Script.

i tried implementing a scattering algorithm, hope you like it.

Here is an example :

for usage instuctions press read more.

Download : Skydome version 1.0 (2082)

A Note: Please try to improve the script and let me know if you use it! for questions just mail me.

To use this do the following:

- Import the package in you project
- Drag the skydomeMesh into the scene. i saw a little error here. but for now you have to make the scale x,y,z to 100.
drag the aScattering material on the skydomeObject.
Set textures (cloud/stars)
Set wind direction (try to see what it does)

- Create a directionalLight and name is “Sun”
now drag the Sun.cs to the directional light, set the property “maincontroller” to the skydome controller object

Create and emptyGameobject and name it “Skydome controller”
Drag the skydome2.cs to the skydomeController object (NOT THE SPHERE)

Set the properties of the skydomescript:
sunLight > the directionallight object.
Skydome > the sphere object.
cam > your camera.

You can try some settings if you press “TAB”.

27 comments so far

Add Your Comment
  1. This is fantastic! Thank you very much for sharing this! :)

  2. Wow! Thanks for sharing this. I’m headed to mess with it right now!!

  3. This is amazing, it would be good if we could adjust cloud density and speed too.

  4. somehow you need to connect the skydome to the camera so it moves a long the xy (not z) axes. This way you cannot bump into the sphere ;-)

  5. I am throughly impressed. I’d like to make use of this. If I come up with any innovations I’ll share them with you.

  6. [...] site Pixelstudio a sortit il y a quelques temps un projet Unity nommé Skydome. Il s’agit en fait, d’un [...]

  7. i downloaded it and now i like to find time to prove it. Thanks for sharing it.

  8. Awsome stuff. Thank you soooooo much for sharing!
    If you got problems hitting the sphere, make it bigger and adjust the sun to match the sphere in the sun script.

  9. Found your skydome on youtube, it looks awesome. Thank you very much for uploading it. Would you be against us using it for a game in unity?

  10. Really great stuff :D and we use the same wordpress theme lol :P Will mess around with it :)

  11. great script ! beautifull sky.
    the sun is inverted in my scene. did you know what happen ?
    i dont know how to change his position ?

  12. Fantastic! thanks for sharing.

  13. This script is just amazing.
    For best results, the equator of the sphere must be a bit under the height of the landscape.

  14. In my case this “SkyDome version 1.0.unitypackage” – “Error while importing package: Couldn’t decompress package”
    You may uploading unpackge version of this Skydome package?

  15. OK so far I can’t get this to work properly. Is this supposed to cover the map or what? I’ve got it covering over the map but it looks funcky. or is it supposed to stay 100 x 100x 100 and use some wierd camera thing

  16. I also can’t see the sun.

  17. When I extract the .gz file the SkyDome version 1.0.unitypackage becomes a folder.
    Any help here?

  18. Looks really cool, but when I implemented it (in Unity 2.6.1 Free) the sun flare is on the wrong side of the sphere (it’s in the grey area, instead of the sky area).

    Any idea why that may happen?

  19. So is sunrise and sunset automatic, or do you have to add additional scripting?

  20. you need to double-click the unitypackage. unity will import it automaticly

  21. hmm i have no idea. it should work cause i’m using it in 2.6

    perhaps you need to look at some variables that need to be set in the scripts.. ? or something is inverted.. /

  22. you can set the time, but it’s does not change automatically. it really simple to write a script that would do that.
    for example you can link the time to the pc time or whatever you want

  23. I found a fix on the forums, thanks.

  24. What is this packages license by the way?

  25. can this be done on a Mac?

  26. @Wahooney
    Can you please give me the link of the forum’s topic? because i’m having the same problem.. thanks..:)

  27. Ok i solved it..:) line 48 of skydomescript2 is not -Vector3.Forward… but only Vector3.Forward.. without “-”..:) Anyway this is such a great tool!! :)