# API

## Methods

## TickSchedule

<mark style="color:green;">`POST`</mark> `TickSchedule(ScheduleTimes scheduledTime, float timeToUpdate, UnityAction toSchedule, UnityAction elapsed)`

Invoking this method will allow you to schedule a function to be invoked on a specific update time, for a small amount of time, and get events for the ending of that time.

#### Path Parameters

| Name          | Type   | Description                                             |
| ------------- | ------ | ------------------------------------------------------- |
| ScheduledTime | number | Unity function in which the scheduling will take place. |
| TimeToUpdate  | number | Amount of time the scheduling will last for.            |
| ToSchedule    | object | Method to schedule.                                     |
| Elapsed       | object | Method to invoke once the timer has elapsed.            |

{% tabs %}
{% tab title="200 We can use this function to update things for a short while, or wait for a while." %}

```csharp
private void Log(){ 
    Debug.Log("Hey");
}

//Log every frame for fifteen seconds.
Scheduler.TickSchedule(ScheduleTimes.Update, 15f, Log);
```

{% endtab %}
{% endtabs %}
