Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Getting massive errors on editor #67

Closed
rozx opened this issue Jan 24, 2020 · 5 comments
Closed

Getting massive errors on editor #67

rozx opened this issue Jan 24, 2020 · 5 comments
Assignees
Labels
bug Something isn't working released on @preview

Comments

@rozx
Copy link

rozx commented Jan 24, 2020

TargetParameterCountException: Number of parameters specified does not match the expected number.

GUI Error: You are pushing more GUIClips than you are popping. Make sure they are balanced. TargetParameterCountException: Number of parameters specified does not match the expected number.

The targets array should not be used inside OnSceneGUI or OnPreviewGUI. Use the single target property instead.

UnityEditor.EditorApplication:Internal_CallHierarchyHasChanged() (at /Users/builduser/buildslave/unity/build/Editor/Mono/EditorApplication.cs:334) The serializedObject should not be used inside OnSceneGUI or OnPreviewGUI. Use the target property directly instead.

The targets array should not be used inside OnSceneGUI or OnPreviewGUI. Use the single target property instead.

The serializedObject should not be used inside OnSceneGUI or OnPreviewGUI. Use the target property directly instead. UnityEditor.Editor:get_serializedObject()

The serializedObject should not be used inside OnSceneGUI or OnPreviewGUI. Use the target property directly instead. UnityEditor.Editor:get_serializedObject()

The environment is Unity 2019.2.19f1 with UIParticle version 2.3.0

I've also attached a sample project that can recreate the error, just open the prefab under FX/EpicLootBoxEffects/Prefabs/Effects/4_Legendary/P_Stardust_02_Legendary.prefab

Test Project.zip

Much appreciated.

@mob-sakai
Copy link
Owner

Hi @rozx ,

Thank you for your reporting!

@mob-sakai mob-sakai self-assigned this Jan 25, 2020
@mob-sakai mob-sakai added the bug Something isn't working label Jan 25, 2020
@migus88
Copy link

migus88 commented Feb 9, 2020

We had the same issue when upgraded our project to Unity 2019 (from 2018). The fix is pretty simple. The Invoke method requires all parameters to be passed, even if there is an optional parameter in the method, you need to pass it on.
The 'Handles.DoSimpleEdgeHandle' method requires an additional bool parameter (optional with default value set to 'true') that is not passed from the UIParticleEditor.cs:602

In order to fix this issue, you need to change line 602 from this:

float radius = Call<float> (typeof (Handles), "DoSimpleEdgeHandle", Quaternion.identity, Vector3.zero, shapeModule.radius);

Into this:
float radius = Call<float> (typeof (Handles), "DoSimpleEdgeHandle", Quaternion.identity, Vector3.zero, shapeModule.radius, true);

@mob-sakai
Copy link
Owner

@migus88
Thank you!

@mob-sakai
Copy link
Owner

Hmm, I think "use of reflection has some potential bugs".
I will use OpenSesameCompiler (portable) package to access to internals/privates, without reflection.

@mob-sakai mob-sakai changed the title Getting massive errors when applying the compoent to a prefab. Getting massive errors on editor Feb 12, 2020
mob-sakai pushed a commit that referenced this issue Feb 12, 2020
github-actions bot pushed a commit that referenced this issue Feb 12, 2020
# [3.0.0-preview.1](v2.3.0...v3.0.0-preview.1) (2020-02-12)

### Bug Fixes

* change the text in the inspector to make it more understandable. ([7ca0b6f](7ca0b6f)), closes [#66](#66)
* editor crashes when mesh is set to null when ParticleSystem.RenderMode=Mesh ([e5ebadd](e5ebadd)), closes [#69](#69)
* getting massive errors on editor ([ef82fa8](ef82fa8)), closes [#67](#67)
* heavy editor UI ([d3b470a](d3b470a))
* remove a menu to add overlay camera ([f5d3b6e](f5d3b6e))
* rotating the particle rect may cause out of bounds ([3439842](3439842)), closes [#55](#55)
* scale will be decrease on editor ([0c59846](0c59846))
* UI darker than normal when change to linear color space ([db4d8a7](db4d8a7)), closes [#57](#57)

### Build System

* update develop environment ([9fcf169](9fcf169))

### Features

* add menu to import sample ([b8b1827](b8b1827))
* add samples test ([287b5cc](287b5cc))
* **editor:** add osc package (portable mode) ([6c7f880](6c7f880))

### BREAKING CHANGES

* update develop environment to Unity 2018.3.
Unity 2018.2 will continue to be supported.
github-actions bot pushed a commit that referenced this issue Feb 12, 2020
# [3.0.0-preview.1](v2.3.0...v3.0.0-preview.1) (2020-02-12)

### Bug Fixes

* change the text in the inspector to make it more understandable. ([7ca0b6f](7ca0b6f)), closes [#66](#66)
* editor crashes when mesh is set to null when ParticleSystem.RenderMode=Mesh ([e5ebadd](e5ebadd)), closes [#69](#69)
* getting massive errors on editor ([ef82fa8](ef82fa8)), closes [#67](#67)
* heavy editor UI ([d3b470a](d3b470a))
* remove a menu to add overlay camera ([f5d3b6e](f5d3b6e))
* rotating the particle rect may cause out of bounds ([3439842](3439842)), closes [#55](#55)
* scale will be decrease on editor ([0c59846](0c59846))
* UI darker than normal when change to linear color space ([db4d8a7](db4d8a7)), closes [#57](#57)

### Build System

* update develop environment ([9fcf169](9fcf169))

### Features

* add menu to import sample ([b8b1827](b8b1827))
* add samples test ([287b5cc](287b5cc))
* **editor:** add osc package (portable mode) ([6c7f880](6c7f880))

### BREAKING CHANGES

* update develop environment to Unity 2018.3.
Unity 2018.2 will continue to be supported.
@mob-sakai
Copy link
Owner

🎉 This issue has been resolved in version 3.0.0-preview.1 🎉

The release is available on:

Your semantic-release bot 📦🚀

LionelPerrault added a commit to LionelPerrault/Unity-Particle that referenced this issue Jul 25, 2023
# [3.0.0-preview.1](mob-sakai/ParticleEffectForUGUI@v2.3.0...v3.0.0-preview.1) (2020-02-12)

### Bug Fixes

* change the text in the inspector to make it more understandable. ([7ca0b6f](mob-sakai/ParticleEffectForUGUI@7ca0b6f)), closes [#66](mob-sakai/ParticleEffectForUGUI#66)
* editor crashes when mesh is set to null when ParticleSystem.RenderMode=Mesh ([e5ebadd](mob-sakai/ParticleEffectForUGUI@e5ebadd)), closes [#69](mob-sakai/ParticleEffectForUGUI#69)
* getting massive errors on editor ([ef82fa8](mob-sakai/ParticleEffectForUGUI@ef82fa8)), closes [#67](mob-sakai/ParticleEffectForUGUI#67)
* heavy editor UI ([d3b470a](mob-sakai/ParticleEffectForUGUI@d3b470a))
* remove a menu to add overlay camera ([f5d3b6e](mob-sakai/ParticleEffectForUGUI@f5d3b6e))
* rotating the particle rect may cause out of bounds ([3439842](mob-sakai/ParticleEffectForUGUI@3439842)), closes [#55](mob-sakai/ParticleEffectForUGUI#55)
* scale will be decrease on editor ([0c59846](mob-sakai/ParticleEffectForUGUI@0c59846))
* UI darker than normal when change to linear color space ([db4d8a7](mob-sakai/ParticleEffectForUGUI@db4d8a7)), closes [#57](mob-sakai/ParticleEffectForUGUI#57)

### Build System

* update develop environment ([9fcf169](mob-sakai/ParticleEffectForUGUI@9fcf169))

### Features

* add menu to import sample ([b8b1827](mob-sakai/ParticleEffectForUGUI@b8b1827))
* add samples test ([287b5cc](mob-sakai/ParticleEffectForUGUI@287b5cc))
* **editor:** add osc package (portable mode) ([6c7f880](mob-sakai/ParticleEffectForUGUI@6c7f880))

### BREAKING CHANGES

* update develop environment to Unity 2018.3.
Unity 2018.2 will continue to be supported.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working released on @preview
Projects
None yet
Development

No branches or pull requests

3 participants