Layer.beginTransition

機能/意味
Start transition
タイプ
Layerクラスのメソッド
構文
beginTransition(name, withchildren=true, transsrc=null, options=%[ ])
引数
name  Specify the transition name.
 By default, 'crossfade' (crossfade), 'universal' (universal transition) and 'scroll' (scroll transition) are defined.
withchildren  Whether the child layers will transition together. If true is specified, transition will be performed for each child layer. If false, only the layer that executes the method will transition.
transsrc  Specify the layer to switch to. Some transitions do not need to be specified (such as transitions by themselves).
options  Specify the transition options in a dictionary array.
 The options you need depend on the type of transition.
 Regardless of the type of transition, the options that can be specified in common are the 'selfupdate' and 'callback' members.

 If the 'selfupdate' member is true, Kirikiri will not update the screen automatically. In this case, the screen must be updated appropriately by the program using the Layer.update method. This feature is useful when you want to completely synchronize transition drawing and program drawing.

 If you specify a TJS2 method in the 'callback' member, that method will be called every time the drawing is actually performed. In this method (the method that is called back), return the 'tick' value as a value greater than or equal to 0. Many transitions make transitions based on the 'tick' value, which is the actual time in milliseconds. You can rewind the effect at any point or fast-forward in the middle, allowing you to control the transition regardless of the actual time. Many transitions consider the value specified in the optional 'time' member to be the end of the transition. Therefore, for example, specify an appropriate value such as 1000 for the option 'time', and display a transition at any stage by returning a value less than 1000 with this callback method. Will be able to Also, for many transitions, the transition will stop when the 'tick' value reaches the value specified in the optional 'time', so if you do not want to stop the transition, the value specified in 'time' Always specify a value less than.
戻り値
なし (void)
説明
 Start the transition.
 When the transition when children = true ends, the tree structure of the parent-child relationship is completely replaced with the transition source specified by transsrc.
 If children = false, only the transition source layer and the layer that executed the method (transition destination layer) are replaced.
 Note that in both cases, the tree structure is replaced.
 This method just initiates the transition and returns immediately.