Don't Miss Out

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


Lightning Draw

UberLou

28.627 seconds

shinkan

37.084 seconds

Yann

1m 15s

For the first 3 people to download this release!

Quick Draw

Kastas

1m 19s

Lowren

2m 8s

Guest

2m 11s

Guest

2m 28s

bjadams

3m 39s

Hillstrom

3m 40s

xoros

3m 45s

Guest

3m 46s

wakerz

3m 53s

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

Construct 2 Release r117

There is a more up to date Stable Release! Download the latest Stable release instead here.
Download

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

Wednesday, January 30, 2013

New this release: a new Pathfinding behavior! Here's a quick demo of pathfinding, showing how it can help objects navigate around obstacles.

The Pathfinding behavior divides the whole layout in to a grid, and marks cells as obstacles if they are touching any solids. Then it uses A* to find paths through the grid. You can access the sequence of nodes through the behavior's expressions, or alternatively tell the behavior to move the object along the path for you automatically.

One of the coolest things about this new behavior is it uses Web Workers to run the CPU intensive pathfinding calculations on a separate thread. Pathfinding a lot of objects can take a second or more to calculate, especially on mobile devices, and normally this would make the game hang while the paths are worked out. However with Web Workers the game keeps running smoothly while paths are calculated in the background. On dual-core systems (including phones!) this means a separate CPU core can be used for pathfinding, preventing the intensive calculations having any effect on the game framerate! Web Workers are also supported almost everywhere, except IE9 (IE10 has support) and the Android stock browser (but Chrome and Firefox for Android both have support).

The Pathfinding behavior is similar to Classic's RTS movement, but renamed to indicate it's more general purpose than just for RTS games. C2 improves on the RTS movement on two counts: Classic did not use threads, and performance tests indicate C2's Pathfinding behavior is also 2-3x faster (even in Javascript!) due to algorithmic improvements. However note that because C2's pathfinding is asynchronous, you need to use it a little differently: the Find path action only starts looking for a path, and the result is not immediately available in actions after. You need to wait for the On path found trigger to run before you can access the path or move along it, and it may take a moment to calculate. You should also still avoid unnecessary pathfinding calculations (such as calculating every tick) since this may waste battery and make other paths take longer to calculate since the Web Worker will be constantly busy.

Anyway, it should be a very handy behavior for certain games like turret defences or making smarter enemies which can find you more intelligently. Check out the new Pathfinding example in the Start dialog for a visual demo of how it works, including mapping out the nodes.

Changelog

Feature

New Pathfinding behavior

Add

One-time prompt to view release notes after updating Construct 2 (will only appear from next release)

Add

(Steam only) One-time prompt to download media bundle after purchase

Add

Link to release notes in About dialog

Add

Link to download media bundle when licensed in About dialog

Add

Text Box, Button: new 'Set unfocused' action

Add

Button: new 'Checked' property for initial check state

Change

Updated node-webkit to latest version (0.4.0) based on Chromium 26. Note this now appears to only support OS X 10.7 and above. It also now ignores the GPU blacklist and enables WebGL to ensure best performance.

Change

CocoonJS: no longer exports .ttf font files to a Fonts subfolder, since it caused problems with zip compatibility. A future CocoonJS update will also look for .ttf files in the root folder, which should help get fonts working on CocoonJS.

Bug Fix

'On created' did not trigger for objects in containers

Bug Fix

Deleting objects in containers in the editor could prevent other types being added to other containers

Bug Fix

9-patch: possible javascript error with zero size margins

Bug Fix

9-patch: possible incorrect display in editor with tile fill

Bug Fix

XML: javascript error using loopindex in 'For each node'

Bug Fix

Array, Dictionary: possible truncated or altered result when using 'Download' action

Bug Fix

Physics: possible javascript error creating a joint to the same object

Bug Fix

Button: 'set text' for checkboxes did not work


Comments

3
SointulArt 7,037 rep

Thanks for the great work. Can't wait to try out the new pathfinding behaviour!

Wednesday, January 30, 2013 at 5:01:02 PM
2
Temoana 4,979 rep

Good job !

Wednesday, January 30, 2013 at 5:02:57 PM
2
Index 7,577 rep

The pathfinding is great but I hope people also see the other things listed there.
Amazing release.

Wednesday, January 30, 2013 at 5:05:24 PM
2
ethan0004 12.8k rep

NICE WORK GUYS!

Wednesday, January 30, 2013 at 5:06:44 PM
1
delgado 32.4k rep

In my opinion pathfinding behavior should have a limiter distance. otherwise, sprite can be find path in the most difficult maze

Wednesday, January 30, 2013 at 5:07:30 PM
2
PixelAmp 4,487 rep

One of the most impressive releases. Can't wait to start playing with this!

Wednesday, January 30, 2013 at 5:08:43 PM
1
devMidgard 3,950 rep

This is not a huge update but.. hey! It's an update! :D

Wednesday, January 30, 2013 at 5:10:12 PM
3
NotionGames 12.8k rep

A New relse of construct means its Going to be a great day : D

Wednesday, January 30, 2013 at 5:12:40 PM
2
rexrainbow 130.9k rep

Path finding is very interesting!

Wednesday, January 30, 2013 at 5:13:46 PM
2
dodo021 5,314 rep

Thanks for all ! The pathfinding behaviour is really usefull.

Wednesday, January 30, 2013 at 5:16:17 PM
2
andresteves 1,294 rep

Another awesome release. Thanks Scirra :)

Wednesday, January 30, 2013 at 5:16:46 PM
2
ranma 13.6k rep

Text Box, Button: new 'Set unfocused' action
this

Wednesday, January 30, 2013 at 5:23:11 PM
2
procrastinator 5,650 rep

Looking forward to checking out the Pathfinding!

Wednesday, January 30, 2013 at 5:23:35 PM
1
rodmontgt 4,711 rep

O_o !!! It remembers me to Age of Empires, Starcraft xD Thanks Scirra

Wednesday, January 30, 2013 at 5:25:00 PM
2
mltreadway 6,144 rep

Another Awesome release!... The path-finding is a Great addition, Thanks :)

Wednesday, January 30, 2013 at 5:31:46 PM

Leave a comment

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