Halfgeek's Forum Posts

    C2 is already great, really all we need is native export options for mobiles that bypass the wrapper limitations, such as frame rate control and efficiency gains of native vs wrappers.

    I feel that for PC, our current options are good enough lately. It's just lacking for mobiles. Yes it's getting better, but those limitations still puts C2 as always the non-optimal solution.

    tumira

    I read up on Spark, it sounds too much like hype and PR without substance. Will keep an eye on it, but as far as believing their claims, don't put too much faith on it.

  • Alright, test done. Big fleet battle scenario.

    On NW 0.13 alpha and RC, I get ~50% to 60% CPU usage on the main logic thread, as reported by cpuutilization.

    On NW 0.14 RC1, I get ~36% to 45% CPU usage.

    This is a significant improvement under peak load conditions.

    Under idling conditions, it's still around 10-15%, no change.

    Looking forward to GreenWorks shipping with C2 and moving from experimental status!

  • I recently asked the same thing.

    It turns out it's an engine limitation due to requiring browser rendering engines which implement vsync, so the game runs at whatever speed the display refresh is at.

    So for the meantime, cannot be done.

    Basically just know the limits, when you make bigger games, the CPU becomes the bottleneck as its processing all your JS code 60 times per second. Optimize, and more optimizations!

    How I approached my game is to limit cpuutilization to ~50% max (it measures CPU usage for the main game logic thread, single threaded bound). On my Intel i5-3570K, that means I am reaching 50% of the main thread. I can push it higher, going to 99% and the game starts to slow down. But 50% is a good target, because it means other CPUs that are much weaker, will be capable of sustaining 60 fps. I ended up with players on C2D PCs from 2006 with crap Intel graphics able to run the game fluid.

  • Danwood, I'll give it a test in Star Nomad 2. It's also very CPU intensive.

  • It seems pretty obvious, but 64-bit NW is intended for developing on a 64-bit system, while 32-bit NW is intended for developing on a 32-bit system.

    My system is 64 bit, OS and CPU.

    64 bit NW always runs worse. By a lot.

    It's not like this in other games.

  • OK, on my embryonic platform game, at the same re-spawn position with only some background bullet effects taking place...

    nw.js 32 bit preview: 48% cpu

    nw.js 32 bit export: 39% cpu

    nw.js 64 bit export 61% cpu

    It's illogical....

    I've always had much worse performance with 64 bit export so I've stuck with 32 bit.

    I delete the 64 bit NW folder, so the preview is using 32 bit as well, and I get the same performance preview or export.

  • Try Construct 3

    Develop games in your browser. Powerful, performant & highly capable.

    Try Now Construct 3 users don't see these ads
  • Yes, there are lots of features to control what is stored on your device, such as private browsing - that would wipe storage when you close the tab. Some browsers refer to all local storage as "cookies" for historical reasons, so if you've done something like disable cookies then that can disable local storage as well.

    Thanks, I did not know that.

    Would those settings disable LocalStorage for wrapped C2 games that use WKWebView?

  • Can't reproduce on an iPad Air 2 with iOS 9.3 on r224. Given that iOS devices are usually pretty consistent and there are no other reports of this, it sounds like it's specific to your device. Are you sure you haven't set some privacy settings or content blockers that will block storage access?

    You mean there's a privacy setting that can block LocalStorage? I did not know that. I'll check it out.

    This problem doesn't occur on my iPad Mini 2 or Air. Only on iPhone 6 Plus. I don't have a normal iPhone 6 to test.

  • Canvas+ is their own engine so it does not have issues like Safari based ones that WebView has.

    But WebView+ is heaps faster and more power efficient than Canvas+.

  • Preload does not work for iOS for awhile now, ever since iOS9, Apple broke that feature.

    I don't know if Ashley is aware of it or not, but there's been lots of audio related bugs with iOS9+.

    Sometimes my audio tracks don't play at all, it's messed up actually!

  • xmnboy

    Thanks, I'm fine with iOS9+, due to how buggy iOS8 was with WKWebView.

    Any ETA on the next XDK release?

  • Sounds like sandboxing.

    Yep, it used to be a problem with iOS8 and WKWebView, it would reset the LocalStorage. Was fixed in iOS9... now bugged again for iPhone... freaken Apple.

  • Many of these bugs isn't the fault of C2 , I've said as much many times.

    It is often the fault of Apple, they break things when they do iOS updates.

    It was the fault of Google, who broke Chromium v-sync. It was also their fault for introducing memory leaks into Chromium.

    The problem is because C2 is a HTML5/JS engine, it relies on these tech and so, despite not being the fault of C2, we ultimately suffer due to these issues.

    I would kill for a C3 that exports to native, bypassing these browsers.

    Just 3 export options most widely used: DirectX for PC, Java for Android, Objective C for iOS. No need to go nuts with all the platforms. Go where the audience are, where the money is at.

    So I guess until someone makes such an engine with the intuitive event system that exports native, C2/C3 is still the best we got for 2D.

  • I cannot remove the WKWebView plugin, because performance without it is utter crap, as it defaults back to the old UIWebView that is x5 or even x10 slower.

    I tested it in preview on UIWebView, my game gets 10-20 fps, with 99.9% CPU usage (cpuutilization).

    In Safari itself (WKWebView), it's 50-60 fps, with 50-70% CPU usage.

    Basically you do not want to publish without WKWebView on iOS, because the high CPU usage for sub-par performance means your game will destroy the battery life of these devices and make them run really hot. This is a very important concern for mobile gamers. You want to be as efficient as possible, getting high FPS with the least CPU usage.

  • yea localstorage seems to be working ok for me so far. I'm not doing anything too complex with that though my current project is using about 8 different local storage objects..

    Good to know.

    I'll use whichever one works.

    The confusing thing about CocoonIO is their pricing, basically if you pay a single month and compile your game, what if the subscription is not renewed, your game is already on the market, it works, right?