RunAction

Execute another Streamer.bot action

Run an action, by name

Returns a boolean indicating whether the operation was successful.

Signature

public bool RunAction(string actionName, bool runImmediately = true)

Parameters

actionName
string required

No description provided.

runImmediately
bool

Whether to run the action immediately, inline with the current action, or in it's own queue

ValueDescription
true

Will run the action as part of the current action, like a sub-action

false

Will run the action in it's own set queue. Code will continue without waiting

Return Type

bool

Example

using System;
public class CPHInline
{
    public bool Execute()
    {
        // Specify name of action you want to run
        string actionName = "Streamer.bot Docs Action";

        // Run Action (in current queue)
        CPH.RunAction(actionName);         CPH.RunAction(actionName, true); 
        // Run Action in it's own queue
        CPH.RunAction(actionName, false); 
        return true;
    }
}