Search Issue Tracker

By Design

Votes

0

Found in

2018.4

2018.4.11f1

2019.2

2019.3

2020.1

Issue ID

1191443

Regression

No

Custom Event do not fire on builds

Scripting

-

Steps to reproduce:
1. Open supplied project ("GoblinSlaver.zip")
2. Run the Scene "MovementTest"
3. Notice the game working.
4. Build it on any platform

Expected: game works
Actual: game either does not work or the build crashes entirely (see Notes)

Reproduced in: 2018.4.11f1, 2019.2.10f1, 2019.3.0b8, 2020.1.0a9
Not Reproduced in: 2017.4.33f1 (the whole project breaks upon import)

Notes:
Reproduced platforms:
Windows Standalone, macOS 10.14, iOS, Android

Tested on mono and IL2CPP
Tested on .NET 2.0 and .NET 4.x

On 2020.x the build sometimes crashes or turns black upon launching.

Added a log.txt of the errors from Android

Android devices tested on:
VLNQA00257, Sony Xperia XZ Premium (G8141), Android 9, CPU: Snapdragon 835 MSM8998, GPU: Adreno (TM) 540 Repro
VLNQA00124, Google Pixel 2 XL (Pixel 2 XL), Android 9, CPU: Snapdragon 835 MSM8998, GPU: Adreno (TM) 540 Repro
VLNQA00264, Samsung Galaxy S10+ (SM-G975F), Android 9, CPU: Exynos 9 9820, GPU: Mali-G76 Repro
VLNQA00173, Xiaomi Redmi 6 Pro (Redmi 6 Pro), Android 9, CPU: Snapdragon 625 MSM8953, GPU: Adreno (TM) 506 Repro
VLNQA00139, Vivo Xplay6 (vivo Xplay6), Android 7.1.1, CPU: Snapdragon 820 MSM8996, GPU: Adreno (TM) 530 Repro
VLNQA00146, Htc 10 (HTC 10), Android 7.0, CPU: Snapdragon 820 MSM8996, GPU: Adreno (TM) 530 Repro
VLNQA00147, Razer Razer Phone (Phone), Android 8.1.0, CPU: Snapdragon 835 MSM8998, GPU: Adreno (TM) 540 Repro
VLNQA00011, Xiaomi Mi 5s (MI 5s), Android 6.0.1, CPU: Snapdragon 820 MSM8996, GPU: Adreno (TM) 530 Repro
VLNQA00060, Motorola Moto X (1st Gen) (XT1053), Android 4.4.4, CPU: Snapdragon S4 Plus MSM8960, GPU: Adreno (TM) 320 (CRASH, check attached document "Android4Crash.txt" for log).
VLNQA00023, Xiaomi Mi 4i (Mi 4i), Android 5.0.2, CPU: Snapdragon 410 MSM8916, GPU: Adreno (TM) 405 Repro

iOS devices tested on:
iPad Pro 12.9" iOS 12.2.1 Repro

  1. Resolution Note:

    After debugging this case, its more about initialization and not about CustomEvents not firing or Serializing.
    The project uses OnValidate to initialize the fields, that are only invoked in the editor (https://docs.unity3d.com/ScriptReference/MonoBehaviour.OnValidate.html), and since one field does not have SerializeFieldAttribute on it, it will be null and the events will never be triggered.

Add comment

Log in to post comment

All about bugs

View bugs we have successfully reproduced, and vote for the bugs you want to see fixed most urgently.