---
title: "ClearActorAnimations | open.mp"
description: "Clear any animations applied to an actor."
canonical: https://omp.itsneufox.com/th/docs/scripting/functions/ClearActorAnimations
language: th
---

# ClearActorAnimations

warning

ฟังก์ชั่นนี้ถูกเพิ่มใน SA-MP 0.3.7 และจะไม่ทำงานในเวอร์ชั่นก่อนหน้านี้!

## คำอธิบาย

Clear any animations applied to an actor.

| Name | Description |
| --- | --- |
| actorid | The ID of the actor (returned by CreateActor) to clear the animations for. |

## ส่งคืน

1: The function executed successfully.

0: The function failed to execute. The actor specified does not exist.

## ตัวอย่าง

```c
new MyActor;

public OnGameModeInit()
{
    MyActor = CreateActor(...);
}

// Somewhere else
ApplyActorAnimation(MyActor, ...);

// Somewhere else
ClearActorAnimations(MyActor);
```

## ฟังก์ชั่นที่เกี่ยวข้องกัน

-   [ApplyActorAnimation](https://omp.itsneufox.com/th/docs/scripting/functions/ApplyActorAnimation): Apply an animation to an actor.
