mirror of
https://github.com/2006-Scape/apollo.git
synced 2026-07-03 08:39:11 +00:00
15 lines
466 B
Kotlin
15 lines
466 B
Kotlin
import org.apollo.game.model.Animation
|
|
import org.apollo.game.model.entity.setting.PrivilegeLevel
|
|
|
|
on_command("animate", PrivilegeLevel.MODERATOR)
|
|
.then { player ->
|
|
arguments.firstOrNull()
|
|
?.let(String::toIntOrNull)
|
|
?.let(::Animation)
|
|
?.let {
|
|
player.playAnimation(it)
|
|
return@then
|
|
}
|
|
|
|
player.sendMessage("Invalid syntax - ::animate [animation-id]")
|
|
} |