correct bugs
continuous-integration/drone/push Build is passing Details

master
Lucas Delanier 2 years ago
parent 1dab25c89e
commit af20aa2832

@ -17,23 +17,23 @@ class MainViewModel : ViewModel() {
fun craft(recipe : Recipe, count : Int = 1){
currentPlayer.value?.craft(recipe, count)
currentPlayer.value = currentPlayer.value
this.currentPlayer.value = currentPlayer.value
}
fun addItem(item: Item) {
currentPlayer.value?.addItem(item)
currentPlayer.value = currentPlayer.value
this.currentPlayer.value = currentPlayer.value
}
fun gainXp(xpReward: Int) {
currentPlayer.value?.gainXp(xpReward)
currentPlayer.value = currentPlayer.value
this.currentPlayer.value = currentPlayer.value
}
fun equipeItem(item: Item): Boolean {
currentPlayer.value?.equipeItem(item)
currentPlayer.value = currentPlayer.value
this.currentPlayer.value = currentPlayer.value
return true
}
}
Loading…
Cancel
Save