Don't Miss Out

Follow us now so you don't miss new releases!


Lightning Draw

Przemek32767

11.624 seconds

newt

13.977 seconds

Marxally

31.827 seconds

For the first 3 people to download this release!

Quick Draw

RamPackWobble

52.31 seconds

delgado

2m 39s

delgado

2m 45s

Guest

2m 53s

aruche

2m 1s

Guest

3m 33s

Guest

5m 57s

Guest

5m 12s

Guest

6m 56s

Guest

8m 30s

facecjf

9m 39s

Eisenhans

9m 15s

Be one of the first 15 people to download this release!

Construct 2 Release r225

This is an old Beta release! Download the latest Beta release instead here.
Download

58.8 mb, Windows 8/Windows 7/Vista/XP

Wednesday, March 23, 2016

New this build: audio scheduling, more WKWebView improvements, a new multiple colored shadow-casting lights example based on this tutorial, rewritten and updated support for IAP for Cordova on iOS, and some bug fixes. Also note since r224 there were three releases of NW.js for v0.13.0-rc2, rc3 and rc4 - get them at scirra.com/nwjs as usual. NW.js v0.13.0 just recently made its stable release at last, so NW.js support should be pretty robust now, and is being updated regularly with every Chrome update too now, so things are looking good for NW.js.

Audio scheduling

Events normally run 60 times a second, or roughly every 16ms. It's previously been difficult to schedule sounds with better accuracy than 16ms because of this. For example a sound played every 25ms would come either 16ms or 32ms apart, with an irregular pattern that would average out to one every 25ms. Now there's a new "Schedule next play" action which allows you to schedule the next "Play" action to happen a short time in the future. This playback is sample-accurate so can even happen between ticks. This makes it possible to get perfectly aligned playback regardless of how often events run.

There's a new 'Audio scheduling' example that demonstrates how to do this with a couple of events. It schedules playback at 25ms intervals up to 50ms ahead, and lets you listen to the difference. This type of technique is important for music-based games or sequencer type apps, where it's important to have exact playback timing which does not depend on the framerate.

Note audio scheduling requires Web Audio API support, which you can test for using the "Advanced audio supported" condition. Pretty much all platforms support it now, except IE11 and older (but Edge does support it).

WKWebView improvements

Since introducing WKWebView support, we've made a few improvements to mitigate the shortcomings it had previously. There's new memory management to avoid music tracks (which have to be kept fully decompressed in memory in WKWebView) clogging up and wasting memory: only one music track is kept in memory at a time now. Also with a heroic hack, we've managed to get video playback working too! Now WKWebView mode includes a local HTTP server solely to serve video files, which means it can dynamically assign a free port without affecting storage access, and still provide a working URL for the video element to play from.

Given these improvements, all features should now be working in WKWebView mode now. Given the great performance improvements in WKWebView, we want to make this a new default if possible. So if you haven't done so already, we encourage you to try exporting your iOS apps with WKWebView mode enabled, and let us know if you have any problems.

Changelog

Add

Audio: 'Schedule next play' action for sample-accurate playback timing

Add

New example: Audio scheduling

Add

New example: Multiple colored shadow-casting lights

Add

Video: now supported in WKWebView. This is achieved by using a local HTTP server (cordova-plugin-httpd) solely to serve video files.

Change

IAP: rewritten support for Cordova on iOS using the updated cc.fovea.cordova.purchase plugin

Change

Cordova export: replace references to org.apache.cordova.media and org.crosswalk.engine with the newer IDs cordova-plugin-media and cordova-plugin-crosswalk-webview, allowing both to use the latest versions. Note however for Crosswalk builds to work on PhoneGap Build you will need to specify the version by adding to config.xml, until they make CLI 6+ the default.

Change

Audio: in Cordova on iOS in WKWebView mode, no longer waits for a touch before starting music.

Change

Audio: rudimentary memory management for music in WKWebView mode. Should now only keep one decompressed music track in memory at a time, preventing high memory usage in large projects.

Change

Cordova export: updates to the new Intel XDK project format

Change

NW.js: work around a bug that could leave ghost processes behind in apps that were upgraded from NW.js 0.12

Change

Events: adding an effect can now bring back actions that disappeared after "replace object" because an effect was missing

Bug Fix

Tilemap plugin: did not properly clear remaining tiles after loading a tilemap from JSON

Bug Fix

Tilemap editor: should no longer change editing tilemap when pressing undo

Bug Fix

Pathfinding behavior: did not always correctly update the obstacle map when changing layouts


Do you like this release?

We'd love it if you could show your appreciation of it by retweeting and sharing it on Facebook and Twitter!

Posted by Scirra Ltd on 3/23/2016

Comments

5
rozpustelnik 5,096 rep

Wow! Plenty of new features! Audio scheduling - GREAT!

Wednesday, March 23, 2016 at 2:48:57 PM
3
C-7 15.9k rep

I'm really excited about audio scheduling! Thanks a ton for that!

Wednesday, March 23, 2016 at 3:01:03 PM
2
Mike Mead 2,362 rep

Audio scheduling! I was literally talking about wanting this within the last week. You guys are incredible and psychic.

Wednesday, March 23, 2016 at 3:02:54 PM
2
condolent 2,898 rep

neat-o!
When will we see a implementation of greenworks??

Wednesday, March 23, 2016 at 3:04:07 PM
4
mercy 5,790 rep

Excellent news for NW.js! Thank You for the support.

Wednesday, March 23, 2016 at 3:13:34 PM
2
AlexFrancois 1,309 rep

Brilliant work dude! This addresses a lot of issues that were effecting my projects :D

Wednesday, March 23, 2016 at 3:15:21 PM
2
chadorireborn 58.4k rep

Nice Update. I really like how the improvements are being made.

Wednesday, March 23, 2016 at 3:24:20 PM
2
Rotabell 1,297 rep

Thanks a lot Scirra Team :D

Wednesday, March 23, 2016 at 3:39:00 PM
2
Squid 5,560 rep

Some squishy and some changes - all good.
Keep it up

Wednesday, March 23, 2016 at 3:40:35 PM
2
glerikud 19.8k rep

It's so nice to see new features in C2. Thank you for taking the time for these while developing C3. :)

Wednesday, March 23, 2016 at 3:47:05 PM
3
jobel 11.9k rep

not sure I understand the need for Audio Scheduling for sfx (sounds that are in memory). being off up around 11ms is not even detectable by a human.. maybe if you were playing a virtual instrument you'd "feel" the latency... but for games and triggering sfx.. I don't see the need (meaning a max of 16ms delay is no big deal).

What we do need is seamless looping/syncing with multiple streaming audio tracks. But I know that's on the Chromium side of things..

Wednesday, March 23, 2016 at 4:00:00 PM
2
Animate 10.7k rep

Audio scheduler looks to fix audio issues when playback needs to be perfectly in sync with other objects as it does not rely on frame rate. Great work Ashley!

Wednesday, March 23, 2016 at 4:01:06 PM
2
Lordshiva1948 38.3k rep

Thank you boys

Wednesday, March 23, 2016 at 4:34:12 PM
2
Xam 692 rep

Thank you so much for implementing the scheduled audio feature!

Wednesday, March 23, 2016 at 4:50:22 PM
2
saour 3,406 rep

Nice update!

Wednesday, March 23, 2016 at 4:53:01 PM

Leave a comment

Everyone is welcome to leave their thoughts! Register a new account or login.