Tooltips par dessus les icônes

Le zIndex des tooltips n'était pas positionné
This commit is contained in:
Vincent Vandemeulebrouck 2021-02-21 23:45:32 +01:00
parent e5738aaca3
commit 11479556dc
2 changed files with 2 additions and 0 deletions

View File

@ -282,6 +282,7 @@ export const tmrTokenZIndex = {
rencontre: 50,
trounoir: 60,
demireve: 70,
tooltip: 100,
}
/* -------------------------------------------- */

View File

@ -100,6 +100,7 @@ export class PixiTMR {
addTooltip(sprite, text) {
if (text) {
sprite.tooltip = new PIXI.Text(text, tooltipStyle);
sprite.tooltip.zIndex = tmrTokenZIndex.tooltip;
sprite.isOver = false;
sprite.interactive = true;
sprite.on('pointerdown', event => this.onClickBackground(event))