x


Why is my object disappearing at runtime?

I have an interative scene that allows you to click various objects and move them around however for the latest object I have added, I have followed the asme procedure as I have for the other objects yet this one seems to disappear when running the scene and cant seem to see a reason why, can anyone provide any clues please?

Many thanks

more ▼

asked Mar 25 '10 at 10:56 PM

ALex gravatar image

ALex
2 2 2 3

Have you assined your objects to a corresponding prefab? Is this last object same as the others and using the same scripts?

Mar 25 '10 at 11:22 PM Tuti
(comments are locked)
10|3000 characters needed characters left

2 answers: sort voted first

It might be worth a shot, but have you checked in your modelling application of choice whether the surface normals are reversed? That could be a reason why the object doesn't show up while the others do (given the same script and same scene used). Does it only happen at runtime? Have you checked up close in your scene view?

There are many related questions available to surface normals. Try this Answer

I know you said that all procedures are the same, but did you change anything with layers? Is it truly rendered by the correct camera? Is the object so close/far away to the camera, that it's outside of the the clipping range? That's all I can think of for now.

more ▼

answered Mar 26 '10 at 02:16 AM

Sebas gravatar image

Sebas
4k 12 18 45

(comments are locked)
10|3000 characters needed characters left

Hi, too few infos to be sure this is your case but since I had similar issues..

  1. Find the Animation component in your object. There you should see the Culling Type option. This is set by default to Based on Renderers which basically means that if your object goes out the rendering context it will no longer be animated. If your object is out of the scene when the game start, you'll not see it. So, if you want your object to be animated bypassing any logics that Unity does to optimize animations, set Culling Type to Always Animated. Have a look to the other conditions too as they could meet your needs.
  2. Make sure you don't have any script that changes your object's layer to another one that might be "culled out" and thus not rendered.
more ▼

answered Jul 13 '12 at 10:49 AM

rstecca gravatar image

rstecca
30 2 2 4

I had to comment a thank you as well as an up-vote on this one, we were stumped, with a deadline fast approaching, and our characters were set up under a gameobject whos culling time was Always Animated, but the imported characters below it were set to something different. This modification seems to have fixed our issues.

Thank you.

Dec 11 '12 at 06:14 PM Emericanized

Very glad it helped you.

Jan 15 at 01:46 PM Rs
(comments are locked)
10|3000 characters needed characters left
Your answer
toggle preview:

Up to 2 attachments (including images) can be used with a maximum of 524.3 kB each and 1.0 MB total.

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here

By RSS:

Answers

Answers and Comments

Topics:

x1095
x375
x108

asked: Mar 25 '10 at 10:56 PM

Seen: 2275 times

Last Updated: Jan 15 at 01:46 PM