Jump to content

Search the Community

Showing results for tags 'starling'.

  • Search By Tags

    Type tags separated by commas.
  • Search By Author

Content Type


Forums

  • HTML5 Game Coding
    • News
    • Game Showcase
    • Facebook Instant Games
    • Web Gaming Standards
    • Coding and Game Design
    • Paid Promotion (Buy Banner)
  • Frameworks
    • Pixi.js
    • Phaser 3
    • Phaser 2
    • Babylon.js
    • Panda 2
    • melonJS
    • Haxe JS
    • Kiwi.js
  • General
    • General Talk
    • GameMonetize
  • Business
    • Collaborations (un-paid)
    • Jobs (Hiring and Freelance)
    • Services Offered
    • Marketplace (Sell Apps, Websites, Games)

Find results in...

Find results that contain...


Date Created

  • Start

    End


Last Updated

  • Start

    End


Filter by number of...

Joined

  • Start

    End


Group


Website URL


Twitter


Skype


Location


Interests

Found 1 result

  1. Hi, I am using an existing sprite sheet (generated by TexturePacker originally for a starling based project). Actual sprite canvas is bigger and contains some transparent area. However, while creating the sprite sheet in TP, "Trim" option was selected and result is a subtexture entry like below: <SubTexture name="button1" x="63" y="1171" width="60" height="110" frameX="-12" frameY="-20" frameWidth="160" frameHeight="160"/>In Phaser, I am using following code to add this button : var tab1 = new Phaser.Button(this.game, 18, 34, 'mysheet');tab1.frameName = 'button1';grp.add(tab1); //group is Phaser.group created in my game scene.My button is being added fine at the desired location. However, when I do mouseover I find that hitArea of button is off by exactly frameX and frameY value of atlas XML. So some area of button is not getting hand cursor at all while some "transparent" area near button is showing it. I tried changing value in XML for this button to 0 for both frameX and frameY and button was added at correct location. However, I feel thats not right solution, given that same assets are being used for starling project and I don't want to make manual changes. There must be something which I am missing in this process. Any clue, what I am missing? Thanks in advance
×
×
  • Create New...