-
Notifications
You must be signed in to change notification settings - Fork 8
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
Add Vector2 Operations #630
base: master
Are you sure you want to change the base?
Conversation
🦋 Changeset detectedLatest commit: d11bff4 The changes in this PR will be included in the next version bump. This PR includes changesets to release 1 package
Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
PR Reviewer Guide 🔍Here are some key observations to aid the review process:
|
PR Code Suggestions ✨Explore these optional code suggestions:
|
User description
New Nodes
Basic Vector Operations
[x1,y1] + [x2,y2] = [x1+x2, y1+y2]
[x1,y1] - [x2,y2] = [x1-x2, y1-y2]
k*[x,y] = [kx,ky]
Vector Analysis
[x1,y1]·[x2,y2] = x1*x2 + y1*y2
|[x,y]| = √(x² + y²)
[x,y] → [x/|v|, y/|v|]
PR Type
Enhancement, Tests
Description
Added new Vector2 operation nodes for vector math.
Implemented nodes:
add
,subtract
,scale
,dot
,length
,normalize
.Comprehensive tests for all nodes, covering edge cases.
Ensured input immutability and handling of zero vectors.
Changes walkthrough 📝
6 files
Add node for Vector2 addition
Add node for Vector2 dot product calculation
Add node for Vector2 length calculation
Add node for Vector2 normalization
Add node for Vector2 scalar multiplication
Add node for Vector2 subtraction
1 files
Register new Vector2 operation nodes
6 files
Add tests for Vector2 addition node
Add tests for Vector2 dot product node
Add tests for Vector2 length node
Add tests for Vector2 normalization node
Add tests for Vector2 scalar multiplication node
Add tests for Vector2 subtraction node
1 files
Document addition of Vector2 operation nodes