diff --git a/graphics/ui/cursors.svg b/graphics/ui/cursors.svg new file mode 100644 index 0000000..8ddbebf --- /dev/null +++ b/graphics/ui/cursors.svg @@ -0,0 +1,292 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + image/svg+xml + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/out/cursors/button.cur b/out/cursors/button.cur new file mode 100644 index 0000000..0c9d514 Binary files /dev/null and b/out/cursors/button.cur differ diff --git a/out/cursors/button.png b/out/cursors/button.png new file mode 100644 index 0000000..8c234c5 Binary files /dev/null and b/out/cursors/button.png differ diff --git a/out/cursors/standard.cur b/out/cursors/standard.cur new file mode 100644 index 0000000..7d8cf53 Binary files /dev/null and b/out/cursors/standard.cur differ diff --git a/out/cursors/standard.png b/out/cursors/standard.png new file mode 100644 index 0000000..47f8444 Binary files /dev/null and b/out/cursors/standard.png differ diff --git a/src/ui/BaseView.ts b/src/ui/BaseView.ts index 84b2339..8265bc7 100644 --- a/src/ui/BaseView.ts +++ b/src/ui/BaseView.ts @@ -62,6 +62,8 @@ module TK.SpaceTac.UI { this.audio = new Audio(this); this.debug = this.gameui.debug; + this.input.setDefaultCursor("url(cursors/standard.cur), pointer"); + this.events.once("shutdown", () => this.shutdown()); } diff --git a/src/ui/common/UIButton.ts b/src/ui/common/UIButton.ts index 831bd7a..ee9871b 100644 --- a/src/ui/common/UIButton.ts +++ b/src/ui/common/UIButton.ts @@ -83,7 +83,7 @@ module TK.SpaceTac.UI { base.height ), hitAreaCallback: Phaser.Geom.Rectangle.Contains, - useHandCursor: clickable + cursor: "url(cursors/button.cur), pointer" }); // On mask