Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

3D Flip (Vertically and Horizontally) #1279

Open
3 tasks done
nallovint opened this issue May 9, 2024 · 3 comments
Open
3 tasks done

3D Flip (Vertically and Horizontally) #1279

nallovint opened this issue May 9, 2024 · 3 comments
Labels
✨ New extension A new extension

Comments

@nallovint
Copy link

Description

Flip sprites with a 3D rotation effect.

Note that the X origin point must be at the center for the best results.

Added vertical flipping to allow flipping in either, or both directions!

How to use the extension

Add the behavior to the sprite.
When adding the 'Flip' or 'Flip to side' actions, you can select to do Horizontally, Vertically or both.

Checklist

  • I've followed all of the best practices.
  • I confirm that this extension can be integrated to this GitHub repository, distributed and MIT licensed.
  • I am aware that the extension may be updated by anyone, and do not need my explicit consent to do so.

What tier of review do you aim for your extension?

Community (Unreviewed)

Example file

ThreeDFlip.zip

Extension file

ThreeDFlipNew.zip

@nallovint nallovint added the ✨ New extension A new extension label May 9, 2024
Copy link
Contributor

github-actions bot commented May 9, 2024

👋 Thanks for your submission! We are sorry, but the filename of the extension has unrecognized characters. Since filenames with weird character can cause all kinds of problems and security flaws, our system won't allow file names with other characters than normal latin upper- and lowercase characters or numbers. Additionally, the first character must be an uppercase character. Please update your original submission post with a new zip file containing your extension with another file name following those guidelines 🙏

@tristanbob
Copy link
Contributor

tristanbob commented May 10, 2024

@nallovint First off, thanks for your willingness to contribute to GDevelop! We will do our best to guide you along the process.

I started looking at this and frankly, I got carried away trying to update a lot of things like:

  • Replaced custom toggle logic with built-in property toggle action
  • Replaced deprecated conditions and actions
  • Used the shorter method to reference properties and parameters (but I had to rename some properties, such as "Width" to "StartingWidth" to avoid conflicts)
  • Changed from milliseconds to seconds

The changes in this submission would be considered "breaking", which means if someone updated this extension in their existing game they would have to update their events. This is not a huge problem, but we try to avoid it. If we want to implement the breaking changes, we always increase a major version number when we do it (1.x.x becomes 2.0.0) to let the user know. (This is called Semantic Versioning)

I have two ideas on how to move forward:

  1. Keep a single behavior with parameters to choose which axis (or both) to flip on
  • This would have breaking changes, especially if we want to name things better
  1. Create a new behavior for vertical flipping
  • Start fresh from the published extension and don't change anything to the behavior for horizontal flipping ("ThreeDFlip")
  • Create a new behavior called "ThreeDFlipVertical" (we can start by copying the horizontal behavior)
  • This would have no breaking changes

Any thoughts, @D8H or @VegeTato?

FYI - I closed your other issues so we would not get confused on which one to work with.

Updated project

This includes the changes I completed as mentioned above. It's not fully tested or cleaned up, but it might be helpful.
ThreeDFlipNewTristan.zip

@D8H
Copy link
Contributor

D8H commented May 10, 2024

  1. Keep a single behavior with parameters to choose which axis (or both) to flip on
  2. Create a new behavior for vertical flipping

I would vote for 3, have 2 actions: 1 to flip vertically and 1 to flip horizontally.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
✨ New extension A new extension
Projects
None yet
Development

No branches or pull requests

3 participants