Skip to content

Commit

Permalink
release: 0.8.3 (#89)
Browse files Browse the repository at this point in the history
  • Loading branch information
devxb authored Dec 7, 2024
2 parents 7ffe85e + bec4d09 commit d646686
Show file tree
Hide file tree
Showing 4 changed files with 25 additions and 12 deletions.
7 changes: 7 additions & 0 deletions src/main/kotlin/org/gitanimals/auction/domain/PersonaType.kt
Original file line number Diff line number Diff line change
Expand Up @@ -79,4 +79,11 @@ enum class PersonaType {
HAMSTER_JAVA,
HAMSTER_KOTLIN,
HAMSTER_JS,
SNOWMAN_MELT,
SNOWMAN,
DESSERT_FOX_RUDOLPH,
RABBIT_BROWN_RUDOLPH,
LITTLE_CHICK_SANTA,
HAMSTER_SANTA,
;
}
20 changes: 10 additions & 10 deletions src/main/kotlin/org/gitanimals/coupon/app/CouponFacade.kt
Original file line number Diff line number Diff line change
Expand Up @@ -24,9 +24,9 @@ class CouponFacade(

return when (CouponCodes.getByCode(code)) {
CouponCodes.NEW_USER_BONUS_PET -> useBonusCoupon(token, code, dynamic)
CouponCodes.HALLOWEEN_2024,
CouponCodes.HALLOWEEN_2024_STAR_BONUS -> {
val picked = halloweenCandidates.random()
CouponCodes.CHRISTMAS_2024_STAR_BONUS,
CouponCodes.CHRISTMAS_2024 -> {
val picked = christmasCandidates.random()
useBonusCoupon(token, code, picked)
return CouponUsedResponse(picked)
}
Expand All @@ -47,24 +47,24 @@ class CouponFacade(
}

private companion object {
private val halloweenCandidates = mutableListOf<String>().also { candidates ->
private val christmasCandidates = mutableListOf<String>().also { candidates ->
repeat(500) {
candidates.add("SLIME_PUMPKIN_1")
candidates.add("SNOWMAN")
}
repeat(302) {
candidates.add("SLIME_PUMPKIN_2")
candidates.add("HAMSTER_SANTA")
}
repeat(150) {
candidates.add("GHOST")
candidates.add("LITTLE_CHICK_SANTA")
}
repeat(30) {
candidates.add("GHOST_KING")
candidates.add("RABBIT_BROWN_RUDOLPH")
}
repeat(15) {
candidates.add("SCREAM")
candidates.add("DESSERT_FOX_RUDOLPH")
}
repeat(3) {
candidates.add("SCREAM_GHOST")
candidates.add("SNOWMAN_MELT")
}
}
}
Expand Down
4 changes: 2 additions & 2 deletions src/main/kotlin/org/gitanimals/coupon/domain/CouponCodes.kt
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,8 @@ package org.gitanimals.coupon.domain
enum class CouponCodes {

NEW_USER_BONUS_PET,
HALLOWEEN_2024,
HALLOWEEN_2024_STAR_BONUS,
CHRISTMAS_2024,
CHRISTMAS_2024_STAR_BONUS,
;

companion object {
Expand Down
6 changes: 6 additions & 0 deletions src/main/kotlin/org/gitanimals/gotcha/domain/GotchaType.kt
Original file line number Diff line number Diff line change
Expand Up @@ -101,6 +101,12 @@ enum class GotchaType(
Capsule.of("HAMSTER_JAVA", 0.01),
Capsule.of("HAMSTER_KOTLIN", 0.01),
Capsule.of("HAMSTER_JS", 0.01),
Capsule.of("SNOWMAN_MELT", 0.001),
Capsule.of("SNOWMAN", 0.005),
Capsule.of("DESSERT_FOX_RUDOLPH", 0.005),
Capsule.of("RABBIT_BROWN_RUDOLPH", 0.007),
Capsule.of("LITTLE_CHICK_SANTA", 0.01),
Capsule.of("HAMSTER_SANTA", 0.01),
)
}
}

0 comments on commit d646686

Please sign in to comment.