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. We have updated the language to the Editor Terms based on feedback from our employees and community. Learn more.
    Dismiss Notice

Jovia environment demo

Discussion in 'Made With Unity' started by mstevenson, Sep 30, 2009.

  1. andrewc

    andrewc

    Joined:
    Aug 20, 2008
    Posts:
    180
    First of all, I've personally given up on trying to combine global illumination and final gather. Too much of a headache. We pretty much just use final gather for everything now. I've attached the settings.


    In terms of light sources, you don't always get the best results using maya lights. I like to create an object with some surface area as a light source and then give it a texture with an incandescence value. YOu can even hide the object and just get the light from it. For the incandescence I like to plug in a mental ray light utility.

    Does this help?
     

    Attached Files:

  2. defmech

    defmech

    Joined:
    Feb 24, 2007
    Posts:
    506
    I'd love to see that, too, actually.
     
  3. mstevenson

    mstevenson

    Joined:
    Sep 24, 2009
    Posts:
    189
    Whoa, I hope not, the doors are only 6 1/2 ft tall! ;)

    We've dropped the camera slightly. Once we get other characters into the scene we'll have a better frame of reference for player height.

    By not capping the framerate the GPU tries to pump out as many frames as it possibly can, so things heat up quickly. The fans on my MacBook Pro kick on full speed, but it renders at 1,800 frames per second. Application.targetFrameRate should fix the problem if set to a sane level - I'll add it to our next demo. Application.targetFrameRate only functions in compiled games and not in the editor, so it's not too useful during development.
     
  4. mstevenson

    mstevenson

    Joined:
    Sep 24, 2009
    Posts:
    189
    The SendMessage documentation has a good example. Our script isn't really any different, but unfortunately it relies on intricate web of secondary scripts - player proximity, interactive item manager, etc. Here's an example of sending messages:


    Scene setup:
    Create two cubes, a button and a door, and attach the appropriate scripts to them (included below). Drag the door game object onto the button's "Button Responder" in the inspector.

    Button.js
    Code (csharp):
    1.  
    2. var buttonResponder : GameObject;
    3.  
    4. function OnMouseOver () {
    5.     if ( Input.GetButton("Fire1") ) {
    6.         buttonResponder.BroadcastMessage( "OnButton", SendMessageOptions.DontRequireReceiver );
    7.     }
    8. }
    9.  
    10.  
    Door.js
    Code (csharp):
    1.  
    2. function OnButton () {
    3.     // Respond to the "OnButton" message here
    4.     Debug.Log( "The door is opening" );
    5. }
    6.  
    7.  
    Edit: I just realized that "OnButton" and "buttonResponder" are a little ambiguous. They refer to the actual button object within the game, and not one of Unity's input buttons. If I'd planned on releasing this, I probably would have used a different naming scheme.
     
  5. championsoftware

    championsoftware

    Joined:
    Jan 8, 2009
    Posts:
    123
    Wow really impressive light mapping. I've never seen furniture look so amazing.
     
  6. Jasper-Hesseling

    Jasper-Hesseling

    Joined:
    Jul 27, 2009
    Posts:
    34
    Thanks so far. I get all the messages in the console. Now another "noob" question; what string should I use to acces the animation I want to play? It's called "dooropen" on the object in my case.

    Code (csharp):
    1. var doorOpened : boolean = false;
    2. var doorAudio : AudioClip;
    3. var doorShut : AudioClip;
    4. var timer : float = 0.0;
    5.  
    6. }
    7.  
    8.  
    9. function Update(){
    10.    
    11.     if(doorOpened){
    12.         timer += Time.deltaTime;
    13.     }
    14.    
    15.     if(timer >= 5){
    16.         shutDoor();
    17.     }
    18. }
    19.  
    20. }
    21.  
    22. function shutDoor(){
    23.  
    24.     var Elevator = gameObject.FindWithTag("Elevator");
    25.     Door.animation.Play("doorshuts");
    26.     doorOpened = false;
    27.     audio.PlayOneShot(doorShut);   
    28.     timer = 0;
    29. }
    30.  
    31.  
    32. function OnButton () {
    33.    
    34.         doorOpened = true;
    35.         var Elevator = gameObject.FindWithTag("Elevator");
    36.         Elevator.animation.Play("dooropen");
    37.         audio.PlayOneShot(doorAudio);  
    38.        
    39. }
    40.  
    Got something like this now...
     
  7. Jasper-Hesseling

    Jasper-Hesseling

    Joined:
    Jul 27, 2009
    Posts:
    34
    Nevermind my question. I got it fixed now. I am amazed that it works but I got an elevator with buttons to the doors and to the next floor and such. The only thing I have is that when the elevator goes down you have a little falling sensation even though the fps controller is being parented with this script.

    Code (csharp):
    1. function OnTriggerEnter () {
    2.    var GO = GameObject.Find("Platform");//whatever the name of your moving platform is
    3.    var GO1 = GameObject.Find("First Person Controller");
    4.  
    5.    GO1.transform.parent = GO.transform;    
    6. }
    7.  
    8. function OnTriggerExit () {
    9.    var GO = GameObject.Find("Platform");
    10.    var GO1 = GameObject.Find("First Person Controller");
    11.  
    12.       GO1.transform.parent = null;
    13. }
    14.  
    I don't mean to clutter this thread but since you are busy with an elevator as well I thought it might be handy.
     
  8. funshark

    funshark

    Joined:
    Mar 24, 2009
    Posts:
    225
    Sure it helps!!
    I didn't know you could put the MR lights like this with final gather :eek:

    THANK YOU
     
  9. ColossalDuck

    ColossalDuck

    Joined:
    Jun 6, 2009
    Posts:
    3,246
    Looks great, nice job.
     
  10. Mani

    Mani

    Joined:
    Jan 12, 2009
    Posts:
    117
    I know I'm late to this party but those are beautiful!!!
     
  11. andrewc

    andrewc

    Joined:
    Aug 20, 2008
    Posts:
    180
    Better late than never :D

    Thanks
     
  12. XFunc_CaRteR

    XFunc_CaRteR

    Joined:
    Jan 3, 2010
    Posts:
    7
    Looks to clean. Too lived in. Doesn't look like real people live there. Looks more like a 3d graphic than a real-world environment.
     
  13. Blacklight

    Blacklight

    Joined:
    Dec 6, 2009
    Posts:
    1,241
    Wow. Just wow.

    This looks extremly good. I can't find any other way to desctibe it.

    (And you made this in indie!?!)
     
  14. Wolf Dreamer

    Wolf Dreamer

    Joined:
    Sep 2, 2009
    Posts:
    142
    Very impressive work.

    I'm surprised the indie version can do graphics this well.

    Was there any external library used? Was this honestly done entirely in Indie?
     
  15. Eric5h5

    Eric5h5

    Volunteer Moderator Moderator

    Joined:
    Jul 19, 2006
    Posts:
    32,401
    I'm not sure why people are so surprised this was done in Indie...the only thing "tricky" is the reflection in the bathroom floor (although it's a very old trick). Basically the only thing Pro has over Indie, graphically speaking, is rendertextures, and good art is a lot more important than having rendertextures. Using Indie doesn't mean you have to use bad art. ;)

    --Eric
     
  16. Nick3d

    Nick3d

    Joined:
    Jan 28, 2010
    Posts:
    100
    Very nice stuff! since I would like to use Unity3D for Arch Viz I would like to ask you a question:

    Lightmapping looks really nice, I saw that with Maya you can achieve very good results ( or with XSI, 3ds, the important are settings and knowledge of mental ray/Vray ).
    I'm using ( to speed up the workflow ) pureLIGHT ( which will be availavle for Unity in a bit ), but I don't understand how you can reduce the quality in Unity3D...I mean, you import a 4096*4096 lightmap ( with perfect quality ) into Unity, then how you "compress" it or reduce its quality?
     
  17. defmech

    defmech

    Joined:
    Feb 24, 2007
    Posts:
    506
    You select your imported texture inside Unity and change its import settings. From there, you can resize and change the compression(among other things). It's all non-destructive and your original remains untouched.
     
  18. Nick3d

    Nick3d

    Joined:
    Jan 28, 2010
    Posts:
    100
    Wow, that is a really interesting feature! well, can have much more control over my lightmaps and diffuse textures, and is exactly what I was looking for :)
     
  19. wizardious

    wizardious

    Joined:
    Dec 31, 2009
    Posts:
    189
    Apparently, I'm an idiot.How do you get out of the apartment? :oops:

    By the way, it looks spectacular. I guess I'm gonna have to learn how to make lightmaps properly. :?
    ("Wizardious bows down, with arms extended") :)
     
  20. arkkitekktura

    arkkitekktura

    Joined:
    Apr 9, 2009
    Posts:
    16
    Great work! I have a few questions regarding the user experience.

    How did you calculate the conversion of the units between Maya and Unity?

    What FOV are you using? 60mm, 70mm? It looks good, but not great, I find hard to achieve a wider view in interior spaces withut exaggerate the perspective.

    The icon in the middel (Target) is that standard? How did you place it there?

    Is the glare on the lights standard? or did you use an script?

    Like I said, great work, wondering how you find the pipeline between Maya and Unity, I think for a game the amont of work is ok but for ArchViz may be a to long of a process.
     
  21. spaceMan-2.5

    spaceMan-2.5

    Joined:
    Oct 21, 2009
    Posts:
    710
    indie can do the same to pro, the michael and his partner´s work is no more than a great lightmap well worked maybe with a great render tool, and some effects like reflections..

    btw, this demo shows that Unity can do anything...

    yet!, in blender game engine, with a good lightmap, or so one bah.. is ok, never mind... your demo looks fantastic..

    PS. What´s the name... err.. oh yeah!, Mirror´s Edge, looks like that game a bit ;D