-
Notifications
You must be signed in to change notification settings - Fork 1
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat: 야구게임 베팅가능 금액 변경 #446
The head ref may contain hidden characters: "Feature/#430-\uC57C\uAD6C\uAC8C\uC784-\uAE08\uC561-\uBCC0\uACBD"
Conversation
val earnablePoint = baseballResultEntity.earnablePoint | ||
|
||
if (baseballResultEntity.isEnd()) { | ||
requestMember.addPoint(earnablePoint, EARN_POINT_MESSAGE) | ||
gameEntity.baseball.baseballDayPoint = earnablePoint | ||
requestMember.addPoint(earnablePoint*2, EARN_POINT_MESSAGE) | ||
gameEntity.baseball.baseballDayPoint = earnablePoint*2 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
val earnablePoint = baseballResultEntity.earnablePoint
if (baseballResultEntity.isEnd()) {
requestMember.addPoint(earnablePoint, EARN_POINT_MESSAGE)
gameEntity.baseball.baseballDayPoint = earnablePoint
}
return BaseballResponse(
convertBaseballResult(baseballResultEntity.results),
baseballResultEntity.bettingPoint,
earnablePoint,
0
)
최종적으로 earnablePoint
변수를 BaseballResponse
에 넣어서 반환하고 있는데,
if (baseballResultEntity.isEnd())
안에서 계산된 earnablePoint*2
, BaseballResponse
에 담아서 반환하는 값이랑 달라서 그런 것 같아요.
코드를 완벽히 파악한건 아니지만.. if문 안에서 earnablePoint *= 2
를 하면 해결되지 않을까 싶네요 ㅎ..
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
오 맞네요!! 해결됐습니다 감사합니다!ㅎ
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
수고하셨습니다~~ 지금 야구게임이 한 판만 가능할텐데 하루에 여러판 가능하게 수정해보는 것도 좋을 것 같아요~!
src/main/java/com/keeper/homepage/domain/game/application/BaseballService.kt
Outdated
Show resolved
Hide resolved
Co-authored-by: 정핸모 <[email protected]>
Co-authored-by: 정핸모 <[email protected]>
🔥 Related Issue
📝 Description
⭐️ Review Request