–2 votes

I am new to this engine, and I joined Brackeys game jam 2022.1.
I was trying to do some ui, when I came with the idea of making a scale animation for the TextureButton Node.

The TextureButton node doesn't have transform. So I can't use scale.

I did an area 2d to detect when mouse entered.

What I tried to do looks something like this:

                func _on_Area2D_mouse_entered():
                    self.set_size(21, 21)     

And gives me error.

in Engine by (13 points)

1 Answer

0 votes
Best answer

try .rect_scale(Vector2(x,y))

by (215 points)
selected by

Thank you very much!

Welcome to Godot Engine Q&A, where you can ask questions and receive answers from other members of the community.

Please make sure to read Frequently asked questions and How to use this Q&A? before posting your first questions.
Social login is currently unavailable. If you've previously logged in with a Facebook or GitHub account, use the I forgot my password link in the login box to set a password for your account. If you still can't access your account, send an email to [email protected] with your username.