# MotionDebugger

実行中のTweenの追跡と作成時スタックの記録を切り替えます。Itemsから追跡データを参照できます。

Namespace: MeatMotion

Assembly: MeatMotion

```csharp
public static class MotionDebugger
```

[Runtime/Diagnostics/MotionDebugger.cs · L12](../../source/Runtime/Diagnostics/MotionDebugger.cs.html#L12)

## Enabled

新しく登録するTweenを追跡するか指定します。

```csharp
public static bool Enabled;
```

[Runtime/Diagnostics/MotionDebugger.cs · L14](../../source/Runtime/Diagnostics/MotionDebugger.cs.html#L14)

## EnableStackTrace

追跡時に作成スタックを記録するか指定します。

```csharp
public static bool EnableStackTrace;
```

[Runtime/Diagnostics/MotionDebugger.cs · L15](../../source/Runtime/Diagnostics/MotionDebugger.cs.html#L15)

## Items

現在追跡している項目を読み取り専用リストで取得します。

```csharp
public static IReadOnlyList<TrackingState> Items { get; }
```

[Runtime/Diagnostics/MotionDebugger.cs · L17](../../source/Runtime/Diagnostics/MotionDebugger.cs.html#L17)

## AddTracking

有効なハンドルを指定して追跡に追加します。追跡済みなら二重に追加しません。

```csharp
public static void AddTracking(MotionHandle motionHandle, IMotionScheduler scheduler, int skipFrames = 3)
```

引数

- `motionHandle` (`MotionHandle`) 操作・関連付けの対象となるハンドル。
- `scheduler` (`IMotionScheduler`) 更新の時刻・登録先を決めるスケジューラ。
- `skipFrames = 3` (`int`) スタック記録時に読み飛ばす先頭のフレーム数。

[Runtime/Diagnostics/MotionDebugger.cs · L26](../../source/Runtime/Diagnostics/MotionDebugger.cs.html#L26)

## Clear

追跡記録を消去します。Tweenの停止操作はハンドルから行います。

```csharp
public static void Clear()
```

[Runtime/Diagnostics/MotionDebugger.cs · L34](../../source/Runtime/Diagnostics/MotionDebugger.cs.html#L34)

## 関連する型

- [MotionDebugger.TrackingState](../../api/motiondebugger-trackingstate/index.md)
