LocalStorage not working on iOS.

Get help using Construct 2

Post » Fri Mar 03, 2017 11:04 am

Hi,
I built a game for iOS. I tested it on iPhone 6s and iPad Air. The game has few videos that are to be played only one time. In order to make this work I used localstorage to identify whether a video is played for the first time. The first video is playing only one time but the rest are playing every time I launch the app. Not only videos but also all the scores are being whipped out.

Is there a way to solve this? I updated the iOS to 10.2 on both the devices.

It works fine on android.

Please help.
B
24
S
7
Posts: 335
Reputation: 2,220

Post » Fri Mar 03, 2017 1:44 pm

I just tested Local Storage on iOS 10.2.1 and it worked fine.

Are you sure it isn't just a mistake in your events? This is why in bug reports we ask for a minimal .capx demonstrating the issue.
Scirra Founder
B
387
S
230
G
87
Posts: 24,248
Reputation: 192,238

Post » Fri Mar 03, 2017 2:03 pm

Ashley wrote:I just tested Local Storage on iOS 10.2.1 and it worked fine.

Are you sure it isn't just a mistake in your events? This is why in bug reports we ask for a minimal .capx demonstrating the issue.


Thanks Ashley for responding. I tested it on android as well. It is working fine on android. I'm not sure why it isn't working on iOS. Is there anything that I need to do?
B
24
S
7
Posts: 335
Reputation: 2,220

Post » Fri Mar 03, 2017 2:12 pm

No. It should work. That's all I can say unless you provide a minimal .capx.
Scirra Founder
B
387
S
230
G
87
Posts: 24,248
Reputation: 192,238

Post » Fri Mar 03, 2017 2:27 pm

Ashley wrote:No. It should work. That's all I can say unless you provide a minimal .capx.


Okay then I will once again check the events thoroughly. If the problem still exists I will share you the .capx. Thanks alot.
B
24
S
7
Posts: 335
Reputation: 2,220

Post » Sun Mar 05, 2017 8:34 pm

sudeep98 wrote:
Ashley wrote:No. It should work. That's all I can say unless you provide a minimal .capx.


Okay then I will once again check the events thoroughly. If the problem still exists I will share you the .capx. Thanks alot.


Hi @Ashley,
I checked the events once again, built the app and tested it on iPad but unfortunately the problem still exits. I used the same events for android, there it is working fine. I'm not sure where it went wrong for iOS. When I tested the game on safari browser this is what I get.

Image

I don't have any issues on any other browser, where the game running is smoothly. The game doesn't contain any third party plugins even. At first I built the game for android after resolving all the bugs I built it for iOS. Everything is fine and smooth on android but I'm facing problems with iOS.

Here is the .capx. I reduced the game size inorder to make you download it easily.
https://drive.google.com/file/d/0B9wfZG ... sp=sharing

Please let me know if I miss anything.

Thanks,
Sudeep
B
24
S
7
Posts: 335
Reputation: 2,220

Post » Mon Mar 06, 2017 10:42 am

What version of Safari is that? Are the iOS devices old? What version are they running?
Scirra Founder
B
387
S
230
G
87
Posts: 24,248
Reputation: 192,238

Post » Mon Mar 06, 2017 10:52 am

Ashley wrote:What version of Safari is that? Are the iOS devices old? What version are they running?


Safari version - 5.1.7

My iPad is an old device but I also tested the game on iPhone 6s and iPhone 7 as well. It gives me the same result. All the devices are running on 10.2.1 version.
B
24
S
7
Posts: 335
Reputation: 2,220

Post » Mon Mar 06, 2017 11:40 am

Ha, are you kidding? Safari 5.1.7? That is the last version before Apple retired Safari on Windows five years ago, right? Nobody uses that any more and it's not useful for testing - I'd avoid using it at all!

I did test on iOS 10.2.1 and it worked fine. I think you'd best follow the guidelines for a bug report to investigate this further, i.e. create a minimal .capx that reproduces.
Scirra Founder
B
387
S
230
G
87
Posts: 24,248
Reputation: 192,238

Post » Mon Mar 06, 2017 12:28 pm

Ashley wrote:Ha, are you kidding? Safari 5.1.7? That is the last version before Apple retired Safari on Windows five years ago, right? Nobody uses that any more and it's not useful for testing - I'd avoid using it at all!

I did test on iOS 10.2.1 and it worked fine. I think you'd best follow the guidelines for a bug report to investigate this further, i.e. create a minimal .capx that reproduces.



"Ha, are you kidding? Safari 5.1.7?" I didn't know this. Okay fine I will not use this browser for testing.

I shared the .capx already in the previous post. If you test that and found no bugs then it is really strange for me. I'm not sure what is causing me the issue. Looks like I'm on my own on this.

Anyways, thanks alot for your time.
B
24
S
7
Posts: 335
Reputation: 2,220

Next

Return to How do I....?

Who is online

Users browsing this forum: No registered users and 9 guests