-
_checkEvent
(event)Boolean
private
-
Checks the event
Returns:
-
-
Checks the events
-
_checkEventsContainer
(container)Array
private
-
Checks a container with the events and removes the completed events
Name |
Type |
Description |
container |
Array
|
Container for the events |
Returns:
Type |
Description |
Array
|
Filtered array |
-
-
Adds the animation
- Version:
Returns:
-
-
Adds the event
Name |
Type |
Description |
object |
DKTools.Event
|
DKTools.Animation
|
Object
|
Event or object with parameters for the event
Name |
Type |
Description |
id |
Number
|
String
|
*
|
optional
ID of the event |
type |
String
|
optional
Type of the event |
repeatTime |
Number
|
optional
Time of one repeat |
repeats |
Number
|
optional
Amount of repeats |
remainingPauseTime |
Number
|
optional
Remaining time of pause |
onStart |
function
|
optional
Handler of the event start |
onUpdate |
function
|
optional
Handler of the event update |
onPause |
function
|
optional
Handler of the event pause |
onReset |
function
|
optional
Handler of the event reset |
onRepeat |
function
|
optional
Handler of the event repeat |
onSuccess |
function
|
optional
Handler of the event success |
onFail |
function
|
optional
Handler of the event fail |
|
- Version:
Returns:
-
-
Adds the event to container
- Version:
Returns:
-
-
Adds the one time event
Name |
Type |
Description |
object |
DKTools.Event
|
Object
|
Event or object with parameters for the event
Name |
Type |
Description |
id |
Number
|
String
|
*
|
optional
ID of the event |
type |
String
|
optional
Type of the event |
remainingPauseTime |
Number
|
optional
Remaining time of pause |
onStart |
function
|
optional
Handler of the event start |
onUpdate |
function
|
optional
Handler of the event update |
onPause |
function
|
optional
Handler of the event pause |
onReset |
function
|
optional
Handler of the event reset |
onRepeat |
function
|
optional
Handler of the event repeat |
onSuccess |
function
|
optional
Handler of the event success |
onFail |
function
|
optional
Handler of the event fail |
|
- Version:
Returns:
-
-
Clears the events
Name |
Type |
Description |
object |
Array.<String>
|
String
|
optional
Array with event types or event type |
-
createEventsContainer
(type)Array
-
Creates a container for the events
Name |
Type |
Description |
type |
String
|
Type of the events |
- Version:
Returns:
Type |
Description |
Array
|
Container for the events |
-
-
Fails the events
Name |
Type |
Description |
type |
String
|
Type of the events |
data |
*
|
optional
Data |
- Version:
-
-
Returns the found animation
Name |
Type |
Description |
id |
Number
|
String
|
*
|
ID of the animation |
type |
String
|
optional
Type of the animation |
- Since:
Returns:
-
-
Returns the found event
Name |
Type |
Description |
id |
Number
|
String
|
*
|
ID of the event |
type |
String
|
optional
Type of the event |
- Since:
Returns:
-
finishEvents
(type, forcedSuccess, data)
-
Finishes the events
Name |
Type |
Default |
Description |
type |
String
|
|
Type of the events |
forcedSuccess |
Boolean
|
false
|
optional
Forced success for the finish of the events |
data |
*
|
|
optional
Data |
- Version:
-
getAnimations
(type)Array
-
Returns an array with the all animations or animations of a certain type
Name |
Type |
Description |
type |
String
|
optional
Type of animation |
Returns:
Type |
Description |
Array
|
Array with the animations |
-
getEventIndex
(event)Number
-
Returns an index of the event in its container
Returns:
Type |
Description |
Number
|
Index of the event in its container |
-
-
Returns an array with the all events or events of a certain type
Name |
Type |
Description |
type |
String
|
optional
Type of the events |
Returns:
Type |
Description |
Array
|
Array with the events |
-
getEventsContainerByType
(type)Array
-
Returns a container for the events by event type
Name |
Type |
Description |
type |
String
|
Type of the events |
Returns:
Type |
Description |
Array
|
Container for the events |
-
hasAnimation
(animation)Boolean
-
Checks for existence of the animation in the object
Returns true if the animation exists
Returns:
Type |
Description |
Boolean
|
Animation exists |
-
hasAnimations
(type)Boolean
-
Checks for existence of the animations of a certain type
Returns true if the animations exists
Name |
Type |
Description |
type |
String
|
optional
Type of the animations |
Returns:
Type |
Description |
Boolean
|
Animations exists |
-
-
Checks for existence of the event in the object
Returns true if the event exists
Returns:
Type |
Description |
Boolean
|
Event exists |
-
-
Checks for existence of the events of a certain type
Returns true if the events exists
Name |
Type |
Description |
type |
String
|
optional
Type of the events |
Returns:
Type |
Description |
Boolean
|
Events exists |
-
-
Initializes the event manager
-
isEventsPaused
(type)Boolean
-
Checks the events for pause
Returns the conjunction of pauses of the events
Name |
Type |
Description |
type |
String
|
Type of the events |
Returns:
Type |
Description |
Boolean
|
Conjunction of pauses of the events |
-
iterateEventsContainer
(type, callback)
-
Performs a callback function for the events
Name |
Type |
Description |
type |
String
|
Type of the events |
callback |
function
|
Event processing function |
-
pauseEvents
(type, duration)
-
Pauses the events
Name |
Type |
Default |
Description |
type |
String
|
|
Type of the events |
duration |
Number
|
-1
|
optional
Duration of the pause |
-
removeEvent
(event)Boolean
-
Removes the event from a container
Returns true if the event was removed
Returns:
Type |
Description |
Boolean
|
Event was removed |
-
-
Resumes the events
Name |
Type |
Description |
type |
String
|
Type of the events |
-
stopEvents
(type, forcedSuccess)
-
Stops the events
Name |
Type |
Default |
Description |
type |
String
|
|
Type of the events |
forcedSuccess |
Boolean
|
false
|
optional
Forced success for the finish of the events |
-
-
Updates the manager
-
updateEventsContainer
(type, data)
-
Updates the events from container
Name |
Type |
Description |
type |
String
|
Type of the events |
data |
*
|
optional
Data |