OpenFL 7.0 Release

We have been hard at work preparing our seventh major release, but in addition to the ordinary improvements and refinements, this release opens up an entirely new way to use OpenFL.


This is a companion discussion topic for the original entry at http://www.openfl.org/blog/2018/01/16/openfl-7-release/
16 Likes

This is an awesome news !

2 Likes

I read something about being able to use the DOM without making all the game run in the DOM. Is there any example of how to do this? (Did I misunderstand?)

First, the changes make it possible to select a DOM renderer without rebuilding OpenFL. This is important, because the NPM version of OpenFL does not have defines. However, you can use the DOM target, and blend in the canvas renderer by using cacheAsBitmap = true on an object, or bitmapData.draw :slight_smile:

3 Likes

Wow, this is a huge release! A lot of respect to you guys!

1 Like

Wow big release! But where is output compile with C#? :confused: Respect to you!

There’s some support for C#, using openfl test cs, but it’s not stable, and would require more work

1 Like

Hooray. I’ve updated. Thank you very much.
I tried to compile my project under AIR and caught the error.

Error: You must define AIR_SDK with the path to your AIR SDK

This SDK is installed, what should I do?

Use openfl config AIR_SDK path/to/air/sdk :slight_smile:

2 Likes

Its working. Thank you.

1 Like

My application for Android began to weigh less with the transition to version 7.0. Almost a megabyte. This is a pleasant surprise.

1 Like

UWP should mean console support could be coming soon? At least for Xbone?

1 Like

@singmajesty how can I test this fix https://github.com/openfl/openfl/issues/1710 ?
How can I merge manually to OpenFL 7.0?

Copy the changes made here:

Into your “src/openfl/display/MovieClip.hx” file in your local install. It may likely be located at “C:\HaxeToolkit\haxe\lib\openfl\7,0,0\src\openfl\display” or similar

Is the .pak file available through some setup in the project.xml ?

Yes, you can do something such like:

<library name="level1" type="zip" />
<assets path="Assets/level1" library="level1" />

The types are “zip”, “gzip”, “deflate” or “pack” / “pak”. You can use library="default" to apply it to the default (unnamed) library if you wish.

The “pack” type blobs assets together, but does not compress. “zip” is the same as “gzip” I believe, for gzip compression, and “deflate” uses deflate compression

2 Likes

I can confirm my issue has been fixed

1 Like

@singmajesty
How do you get the content of a .pak file ?
If I pak my sounds for example :

<library name="sound" type="pak" />
<assets path="assets/sounds" library="sound"/>

Do I need to unpak it ?
If I use Assets.getSound(), It always tell me that the sound doesn’t exist in assets.

For your example, try:

Assets.loadLibrary ("sound").onComplete (function (library) {
    var sound = library.getSound ("mysound.wav");
    // or
    var sound = Assets.getSound ("sound:mysound.wav");
});

You may also be able to set the “default” asset library to type “pak”, or set your custom asset library to preload

Awesome thanks, I will try this