Playmaker Forum

PlayMaker Help & Tips => Android Help => Topic started by: Yagolov on November 10, 2020, 06:18:49 AM

Title: Array Transfer Value not working on Android Build
Post by: Yagolov on November 10, 2020, 06:18:49 AM
Hello!

I created a word game and works fine in Editor and Unity Remote but when I Build the game for testing it on my phone some parts of the game was not working.

After reading different posts about similar problems, I tried Wizard linker (doing all the steps from the FSM) and a couple of other solutions that didnt work out.

I decided to recreate that FSM in a brand new project with only PlayMaker and the ecosystem installed on it... and the problem persist!! I dont know what else to do.

In the new project and FSM I did the next:
Created 2 Arrays of String:
1- H,O,L,A
2- A,B,C,D

and then I used the Array Transfer Value (0 first, 1 after, 2 after etc) to replace H for A, O for B L for C and A for D.
Each state has a wait 1 second and go to the next, replacing the letters using the appropiate index and then going to the next.

I tried to reduce as max the complexity of the FSM and at the end I am only using
- Array Transfer Value
- String Join
- UISet Text
- Wait

The FSM works well on PC and unity remote but still not in Build.
I am using Unity 2019.4.14f1
and PlayMaker 1.9.0.p21

In the Console I have 1 Warning:
Game scripts or other custom code contains OnMouse_ event handlers. Presence of such handlers might impact performance on handheld devices.

Which I am surprised because the project doesnt have any action OnMouse, only the mentioned above.. I have read on different posts on Unity forum that this Warning could be ignored and that shouldnt be affecting the project...

I would be immensely grateful if someone could help me with this...

Thank you in advance!
Title: Re: Array Transfer Value not working on Android Build
Post by: djaydino on November 10, 2020, 11:18:09 AM
Hi.

If you use a scene with no special objects, you can send the scene here.
Or place some images of your setup (Fsm's / States / actions).
Or maybe a video.

Also maybe try to do the same thing using Array Maker (https://hutonggames.fogbugz.com/?W715)
Title: Re: Array Transfer Value not working on Android Build
Post by: Yagolov on November 11, 2020, 09:41:05 AM
Hello djaydino,

I have replicated what I achieved with the Arrays with the Array List actions from ArrayMaker and now the Fsm runs on build.

Instead of using Transfer Value for replacing 2 strings at X index, I use Get and Set from Arraymaker ( Transfer Value was perfect though, I couldnt find the same action for Arraymaker).

I dont know if I was doing something wrong and the Array Transfer Value works perfectly on built but the process of finding what was failing on build (since Editor and Unity remote works smooth) it has been painful!

Thanks!

Title: Re: Array Transfer Value not working on Android Build
Post by: djaydino on November 12, 2020, 04:43:29 AM
Hi.
I think its best to do a bug report on this.
Title: Re: Array Transfer Value not working on Android Build
Post by: Broken Stylus on November 13, 2020, 04:37:59 AM
I decided to recreate that FSM in a brand new project with only PlayMaker and the ecosystem installed on it... and the problem persist!! I dont know what else to do.

That's the good news.

Quote
In the new project and FSM I did the next:
Created 2 Arrays of String:
1- H,O,L,A
2- A,B,C,D

and then I used the Array Transfer Value (0 first, 1 after, 2 after etc) to replace H for A, O for B L for C and A for D.
Each state has a wait 1 second and go to the next, replacing the letters using the appropiate index and then going to the next.

I tried to reduce as max the complexity of the FSM and at the end I am only using
- Array Transfer Value
- String Join
- UISet Text
- Wait

The FSM works well on PC and unity remote but still not in Build.
I am using Unity 2019.4.14f1
and PlayMaker 1.9.0.p21

In the Console I have 1 Warning:
Game scripts or other custom code contains OnMouse_ event handlers. Presence of such handlers might impact performance on handheld devices.

Might be totally unrelated although it's an issue to keep an eye since your script just runs on its own, from what I understand.

Build a test FSM that does the same operation but with other actions, through more steps (get value from array 1, store value, set value in array 2) and see if at least this works.
Title: Re: Array Transfer Value not working on Android Build
Post by: Yagolov on November 13, 2020, 07:31:38 PM
Hello!

Thank you for your answers!

Yep, I isolated the FSM that was creating problems and created a brand new project with only that FSM and making a build in every step that I was adding.

The game failed on build at the moment that I added the action Array Transfer Value.
I changed to make the same actions only with ArrayMaker and now it works in the Editor, Unity remote and in build. I changed Array Transfer Value for ArrayList Get and ArrayList Set.

I just reported the probable bug using the PlayMaker Bug report system so hopefully they can fix this Issue with ArrayTransferValue action and help others who may have the same Issue.