Jump to content

Essentials Flash Question


Ninjadoodle
 Share

Recommended Posts

Hi @enpu

I love the 'Essetials' Flash class - it's a really nice shortcut. I'm just wondering if there is a way to set the area of the flash?

This might be a bit elaborate for the plugin, but here is a case scenario ...

I have a square with an image and a dark border. I would like to flash the image without flashing the border as well.

I know I can do this by inserting the border as a child, but that causes other problems in my game.

Having an option of setting the Flash Area inside the sprite being flashed would be awesome.

No problem if this is a little too complex, just wanted to ask :)

 

Link to comment
Share on other sites

@Ninjadoodle

I just added four new parameters to the flash function, which allows you to cut it from left, top, right and bottom:

// Cut flash 100px from left and 50px from right
sprite.flash(400, '#ff0000', null, 100, 0, 50, 0);

flashcutting.gif.cfe340f6fce559b78fe7f0c2f67fe276.gif

I have attached new version of the plugin here, could you test how it works before i publish it?

panda2-plugin-essentials-1_2_2.zip

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...