bevy icon indicating copy to clipboard operation
bevy copied to clipboard

Added Sprite::sized(custom_size)

Open Kees-van-Beilen opened this issue 2 years ago • 1 comments

Objective

add a quick shorthand for creating a sprite with an custom size. This is often desired when working with custom units or scaled sprites and allows for a cleaner syntax in those cases/

Solution

Implemented a sized function on the Sprite struct which creates a Sprite, sets the custom size and leaves the rest at their default values


Changelog

  • Added Sprite::sized(custom_size: Vec2)

Kees-van-Beilen avatar Mar 11 '23 10:03 Kees-van-Beilen

Welcome, new contributor!

Please make sure you've read our contributing guide and we look forward to reviewing your pull request shortly ✨

github-actions[bot] avatar Mar 11 '23 10:03 github-actions[bot]