Different Web Broswer

Discussion and feedback on Construct 2

Post » Sun Mar 31, 2013 11:35 am

Part of this is ignorance on my part, but I have my game well underway, and noticed something strange when I exported to the node-webkit. I looked a bit online and found to test the game on multiple browsers, so I did.

Can someone explain to me why my game works perfectly in the browser I've been testing in, but the second I switch to a different browser, half of my events just flat out don't work? I've been using palemoon, but trying internet explorer, simple things such as changing a variable isn't working. I'm now getting the game to crash at certain points. Is it not possible to run large games using Construct 2 because of this issue?
B
22
S
3
Posts: 451
Reputation: 2,135

Post » Sun Mar 31, 2013 11:50 am

It's most likely all your events are working properly. Perhaps you depend on some specific browser feature that isn't supported everywhere. You must test across browsers from the very start, because it's now very difficult to track down the cause of the issue or offer any help to you. If you were testing properly from the start, you'd probably know roughly which change caused the issues.Ashley2013-03-31 11:51:12
Scirra Founder
B
359
S
214
G
72
Posts: 22,949
Reputation: 178,544

Post » Mon Apr 01, 2013 3:41 am

So I was able to fix everything in every browser, however some things are now broken when I export to Node-Webkit.
B
22
S
3
Posts: 451
Reputation: 2,135

Post » Mon Apr 01, 2013 9:31 am

Sorry to be pesky about this, but I've checked my code quite a few times, and I'm still having an issue. Basically I'm trying to save a few arrays with both numbers and text.

I have 2 separate arrays, one giving me an issue and not saving the text, and the other works perfectly. The codes are the EXACT SAME aside from being a different array and I've now tested them and they work on Chrome, IE, Firefox, and Palemoon, but when I export to Node-Webkit, only one of the arrays saves the data appropriately.

Have there been issues like this using node-webkit?

Thanks!
B
22
S
3
Posts: 451
Reputation: 2,135

Post » Mon Apr 01, 2013 3:32 pm

It's hard to help unless you can share a minimal .capx showing the issue in isolation.
Scirra Founder
B
359
S
214
G
72
Posts: 22,949
Reputation: 178,544

Post » Mon Apr 01, 2013 4:10 pm

@ome6a1717 Have you tried declaring your text as strings? i.e.

str(data)

Clearly declaring the data type often fixes a few idiosyncrasies across browsers.

Also check you're not setting your variables incorrectly as text or number, which can be an easy mistake to make.
B
29
S
8
G
4
Posts: 61
Reputation: 6,205

Post » Mon Apr 01, 2013 6:58 pm

Nathan you are a savior! Just adding str for the text array numbers seem to have fixed it. It's just strange that it worked in every browser until I exported it to a node-webkit.

Just curious, Ashley; what browser does the node-webkit use? Or is it based on which one you currently have set in your project?

Thanks guys!
B
22
S
3
Posts: 451
Reputation: 2,135

Post » Mon Apr 01, 2013 7:19 pm

Node-webkit is chromium based.

I do not know why your strings were not being recognized, usually having ""s around a data entry signifies it as a string and you don't need to announce it.
B
15
S
4
G
4
Posts: 294
Reputation: 3,225

Post » Mon Apr 01, 2013 7:21 pm

My strings weren't exactly Set Array to "text", it was set Array to Sprite.AnimationName. That could have been causing the issue.

B
22
S
3
Posts: 451
Reputation: 2,135

Post » Mon Apr 01, 2013 7:23 pm

Node-webkit is based on Chromium, effectively the same browser as Chrome. So it is usually very strange to have differences between Chrome and node-webkit.
Scirra Founder
B
359
S
214
G
72
Posts: 22,949
Reputation: 178,544

Next

Return to Construct 2 General

Who is online

Users browsing this forum: TRMG and 14 guests