Error on IOS Device

Help, support and information for our Pro Pooling Unity Asset
Post Reply
Fabb
Posts: 30
Joined: Mon May 16, 2016 10:04 am

Error on IOS Device

Post by Fabb » Mon May 16, 2016 10:16 am

Hi Mark,

I try to use Pro Pooling in my code because i have often issues on my IOS Devices (it's a known problem).

I have a Canvas Panel UI which use my own class, inside this class the below elements :

In the Start method :
_pool = new Pool<PoolItem>(wordTile, 20);

In other initialization method :
var poolItem = _pool.GetFromPool (new Vector3 ((_x*80)-280, _y, -80), Quaternion.identity, this.transform);
poolItem.GetComponent<LetterWord> ().setLetterIndex (_index); ==> used to change texture on my object

It works great on Unity Editor, i can see objects move from the root to my Canvas Panel but not on IOS Device (and i don't know on Android for the moment).

I have this log on execution :

Code: Select all

NullReferenceException: A null value was found where an object instance was required.
  at FlipWebApps.ProPooling.Scripts.Pool`1[T].ClearPool () [0x00000] in <filename unknown>:0 
  at MapGenerator.Start () [0x00000] in <filename unknown>:0 
 
(Filename: currently not available on il2cpp Line: -1)

NullReferenceException: A null value was found where an object instance was required.
  at FlipWebApps.ProPooling.Scripts.Pool`1[T].ClearPool () [0x00000] in <filename unknown>:0 
  at Word.Start () [0x00000] in <filename unknown>:0 
 
(Filename: currently not available on il2cpp Line: -1)

Unloading 3 Unused Serialized files (Serialized files now loaded: 0)
UnloadTime: 9.001791 ms
Do you have a idea ?

Thanks :)

Fabb
Posts: 30
Joined: Mon May 16, 2016 10:04 am

Re: Error on IOS Device

Post by Fabb » Mon May 16, 2016 10:29 am

I have another message on my debugging screen when i run the Mac OS X version, but not in the Unity Editor.

Code: Select all

Prefab must not be null
Assertion failed. Value was null
I don't understand because my class has a prefab connected ...

Fabb
Posts: 30
Joined: Mon May 16, 2016 10:04 am

[SOLVED]Error on IOS Device

Post by Fabb » Mon May 16, 2016 10:48 am

I found the issue ...

Prefab must be drag from the Prefab folder and not from the Hierarchy scene even if the Prefab used on the hierarchy scene is the same.
It's strange, i don't understand why.

Fabb

mahewitt
Site Admin
Posts: 252
Joined: Thu May 05, 2016 8:06 pm

Re: Error on IOS Device

Post by mahewitt » Wed May 18, 2016 2:08 pm

Hi Fabb,

Sorry that I missed this post, but glad that you found a solution.

As I understand, you used a standard gameobject for the prefab when creating the pool and that failed, while a prefab from the prefab folder doesn't (and also only on iOS)?

If so then I will check this out further as it would be good to at least give a clearer warning

Regards,
Mark

Fabb
Posts: 30
Joined: Mon May 16, 2016 10:04 am

Re: Error on IOS Device

Post by Fabb » Wed May 18, 2016 6:11 pm

Hi,

I'm not sure that these issue is only Mac or IOS because i haven't check on PC, but it's the same issue on Mac (app) or IOS devices.
However, when you drag & drop an object from hierarchy, it doesn't work.
You must drag & drop the object from the prefab directory.

In my case, it was the solution. Perhaps it's another problem or a specific problem inside my application.

Fabb

Post Reply