Variables, Layers/Group Names etc

Migrating From Kwik3

Variables

Layers and group names

In Kwik4, your layer (or group) named “abc” is referenced by its own name with the prefix “layer.” in external code. For example, if you want to change its transparency, you would write:

layer.abc.alpha = 1

As you can see, all layers and groups are now prefixed with “layer.” – if you forget to add this prefix, your code will not work.

Audio names

Similar to the layer’s case above, audios in Kwik4 are named with UI.allAudio. For example, an audio file called abc.mp3 will be named in Kwik as below.

Kwik3

allAudios.abc

Kwik4

UI.allAudios.abc

Assets folder

Animations, transitions and timers

Lastly, transitions, timers and animations are prefixed

Actions

If you like to call the action of yours in external codes, you need to dispatch it as an event

Enjoy!