private void ReloadAndPlay(AEScriptRunner obj)
        {
            obj.UseLiveScript();
            obj.Kill();
            obj.Load();

            // Add delay to compensate script loading time
            var action = AE.Sequence(
                AE.Delay(0.5f),
                AE.Script(() => obj.Play())
                );

            if (obj.Unscaled)
            {
                action.PlayUnscaled();
            }
            else
            {
                action.Play();
            }
        }
 public AEScriptRunner GetAEScript(string key, AEScriptRunner defValue = null)
 {
     return(FindData(key, (x) => x.@aescript, defValue));
 }
 public AEScriptContext(AEScriptRunner runner, Dictionary <string, object> overrideData = null)
 {
     runner_       = runner;
     overrideData_ = overrideData;
 }
 public static ActionBase CreateActionFromScript(AEScriptRunner script, Dictionary <string, object> overrideData)
 {
     return(createActionFunc_(script, overrideData));
 }
Esempio n. 5
0
 private static ActionBase CreateActionFromScript(AEScriptRunner script, Dictionary <string, object> overrideData)
 {
     return(CreateActionFromScript(script.ScriptSource, script.GetContext(overrideData)));
 }
 private void Kill(AEScriptRunner obj)
 {
     obj.Kill();
 }
 private void Reload(AEScriptRunner obj)
 {
     obj.UseLiveScript();
 }
 public void SetAEScript(AEScriptRunner value)
 {
     @aescript = value;
     type      = AEScriptDataType.AEScript;
 }