Skip to content

AssetBundle

AssetBundle is a special Object type that has access to custom AssetBundle related functions like looping and trigger effects.

Example Usage: self.AssetBundle.getLoopingEffects()

Function Summary

Object Functions

Function Name Description Return  
getLoopingEffectIndex() Index of the currently looping effect. Indexs starts at 0.
getLoopingEffects() Returns a Table with the keys "index" and "name" for each looping effect.
getTriggerEffects() Returns a Table with the keys "index" and "name" for each trigger effect.
playLoopingEffect( index) Starts playing a looping effect. Indexs starts at 0.
playTriggerEffect( index) Starts playing a trigger effect. Indexs starts at 0.

Function Details

getLoopingEffects()

 Returns a Table with the keys "index" and "name" for each looping effect.

    -- Example usage
    effectTable = self.AssetBundle.getLoopingEffects()
    -- Example returned table
    {
        {index=0, name="Effect Name 1"},
        {index=1, name="Effect Name 2"},
    }


getTriggerEffects()

 Returns a Table with the keys "index" and "name" for each trigger effect.

    -- Example usage
    effectTable = self.AssetBundle.getTriggerEffects()
    -- Example returned table
    {
        {index=0, name="Effect Name 1"},
        {index=1, name="Effect Name 2"},
    }