- Home /
Spawned Particle System in game looks different from prefab
When I spawn a particle system (prefab) in the game it looks totally different in comparison to dragging the prefab in the scene view and playing it manually. At first I thought it's the "limit-velocity over time" (bound to fps) thing, but I am using Unity 5.2 and the Issue Tracker says that this issue is resolved: [link text][1] [1]: http://issuetracker.unity3d.com/issues/shuriken-particle-system-module-limit-velocity-over-lifetime-is-fps-dependent
Has somebody got a different Idea ? Maybe its a problem that the particle system was created in Unity 5.1 and was imported to 5.2 ? If so what can I do about this ?
Thank you !
does your spawn code do ANYTHING besides instantiating? screenshot would be nice
Is the prefab stored with a non-standard rotation?
If say your prefab is stored rotated 90 degrees on the x-axis, it'll get that rotation when dragged into the scene. Instantiating the prefab will usually give it a rotation of 0, and it'll look different.
@Baste We already thought this was the problem, but the explosion looks exactly the same from every side, so even rotating it via code, changed nothing. The explosion when its instatiated looks way bigger and less dense than the prefab counterpart, it looks like the velocitys over lifetime are off. @hexagonius we only instantiate the prefab -1 line of code
@hexagonius Here is the exact code:
GameObject Explosion;
Explosion = ((GameObject)GameObject.Instantiate
(Resources.Load("Explosion"), new Vector3(CallerPos.x, 0.85f,
CallerPos.z), Quaternion.Euler(new Vector3(270, 0, 0))));
CallerPos is a Vector3 which has the coordinates of the bomb. Its rotated by 270 degrees cause the prefab was rotated by the same amount.
Answer by outasync · Oct 02, 2015 at 07:03 AM
Could it be that the prefab particle has the simulation space set to world and should be local or the other way round? Also check under 'Renderer' of the particle that it is on the correct sorting layer
@outasync We already did change the simulation space and it did nothing.( which is quite logical) I'll check the sorting layer later. Thanks !
@outasync Im afraid but the problem doesn't seem to be caused by incorrect sorting layers. The whole particle animation is different....
$$anonymous$$ay I suggest that you revert back to 5.1 as 5.2 is anything but stable right now, unless you are using a feature specific to 5.2 you have no benefit over 5.1. Regards
Thanks @outasync I'll try it on 5.1 and look if it changes anything.
@outasync turns out my programmer did a mistake in his long script -- with a short instantiate script it worked without any problems -- Im sorry -- Im the art guy (I understand a bit of coding), but my programmer is sometimes a bit lazy when it comes to visuals ("It's an explosion -- I don't care how it looks" ;)), that's why I have to do a lot of visual bugfixing and then I don't have a lot of insight in his other coding. I think we have to restructure our distribution of work, but thank you very very much for your Unity 5.1 advice -- otherwise we would have never found that mistake !
Your answer
Follow this Question
Related Questions
Two Particle Systems 1 Answer
Explosion Using Particle System 0 Answers
Smoke Particle Not Playing Continuously 2 Answers
How do i have explosion effect after my object destroyed? 3 Answers
Fill a Cube with Smoke Particle System 0 Answers