[P3][UI] Fix tooltip bugs in Starter Select screen (#4641)
* [UI] Fix candy friendship tooltip bug in Starter Select * [UI] remove tooltip when exiting starter select screen
This commit is contained in:
parent
70b9a43c8b
commit
89d7e7ea65
|
@ -2963,8 +2963,12 @@ export default class StarterSelectUiHandler extends MessageUiHandler {
|
||||||
this.natureCursor = -1;
|
this.natureCursor = -1;
|
||||||
|
|
||||||
if (this.activeTooltip === "CANDY") {
|
if (this.activeTooltip === "CANDY") {
|
||||||
const { currentFriendship, friendshipCap } = this.getFriendship(this.lastSpecies.speciesId);
|
if (this.lastSpecies) {
|
||||||
this.scene.ui.editTooltip("", `${currentFriendship}/${friendshipCap}`);
|
const { currentFriendship, friendshipCap } = this.getFriendship(this.lastSpecies.speciesId);
|
||||||
|
this.scene.ui.editTooltip("", `${currentFriendship}/${friendshipCap}`);
|
||||||
|
} else {
|
||||||
|
this.scene.ui.hideTooltip();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if (species?.forms?.find(f => f.formKey === "female")) {
|
if (species?.forms?.find(f => f.formKey === "female")) {
|
||||||
|
@ -3655,6 +3659,9 @@ export default class StarterSelectUiHandler extends MessageUiHandler {
|
||||||
StarterPrefs.save(this.starterPreferences);
|
StarterPrefs.save(this.starterPreferences);
|
||||||
this.cursor = -1;
|
this.cursor = -1;
|
||||||
this.hideInstructions();
|
this.hideInstructions();
|
||||||
|
this.activeTooltip = undefined;
|
||||||
|
this.scene.ui.hideTooltip();
|
||||||
|
|
||||||
this.starterSelectContainer.setVisible(false);
|
this.starterSelectContainer.setVisible(false);
|
||||||
this.blockInput = false;
|
this.blockInput = false;
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue