From 7d72d72f2cace1a8f01d85ab28d6ac300d382562 Mon Sep 17 00:00:00 2001 From: InsanusMokrassar Date: Fri, 30 Oct 2020 20:38:04 +0600 Subject: [PATCH] Revert "Revert "Revert "Revert "add slot machine, but currently it is not working"""" This reverts commit b457d11067296a8c7ed5b12c2fbe62170158ea13. --- CHANGELOG.md | 3 +++ .../kotlin/dev/inmo/tgbotapi/types/dice/DiceAnimationType.kt | 5 +++++ 2 files changed, 8 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index 34491c6985..9f83e783d5 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -2,6 +2,9 @@ ## 0.29.3 +* `Core`: + * New dice type `SlotMachineDiceAnimationType` + ## 0.29.2 * `Common`: diff --git a/tgbotapi.core/src/commonMain/kotlin/dev/inmo/tgbotapi/types/dice/DiceAnimationType.kt b/tgbotapi.core/src/commonMain/kotlin/dev/inmo/tgbotapi/types/dice/DiceAnimationType.kt index 806e43d16f..89ea0878cf 100644 --- a/tgbotapi.core/src/commonMain/kotlin/dev/inmo/tgbotapi/types/dice/DiceAnimationType.kt +++ b/tgbotapi.core/src/commonMain/kotlin/dev/inmo/tgbotapi/types/dice/DiceAnimationType.kt @@ -22,6 +22,10 @@ object BasketballDiceAnimationType : DiceAnimationType() { override val emoji: String = "\uD83C\uDFC0" } @Serializable(DiceAnimationTypeSerializer::class) +object SlotMachineDiceAnimationType : DiceAnimationType() { + override val emoji: String = "\uD83C\uDFB0" +} +@Serializable(DiceAnimationTypeSerializer::class) data class CustomDiceAnimationType( override val emoji: String ) : DiceAnimationType() @@ -34,6 +38,7 @@ internal object DiceAnimationTypeSerializer : KSerializer { CubeDiceAnimationType.emoji -> CubeDiceAnimationType DartsDiceAnimationType.emoji -> DartsDiceAnimationType BasketballDiceAnimationType.emoji -> BasketballDiceAnimationType + SlotMachineDiceAnimationType.emoji -> BasketballDiceAnimationType else -> CustomDiceAnimationType(type) } }