PhaseTips: Tooltip UI Component for

Phasetips is a tooltip UI component made to be used with PhaserJS game framework.


Download it here or check the source code:

Let’s see how that works

To create a simple tooltip with a text that hovers over the target item all you have to do is:

var tip1 = new Phasetips({
    targetObject: targetObj, //can be any phaser object (sprite, group, text, image, etc...)
    context: "A cute bunny but with a lot of text, that needs to wrap!",
    strokeColor: 0xff0000, // red stroke
    position: "top" // where we want the tooltip to appear

The event listeneres for hoverOver/hoverOut are added via the plugin automatically.


Tagged , , , , , , , , . Bookmark the permalink.

Leave a Reply

Your email address will not be published. Required fields are marked *