7-28-25 @ 11:39pm
This commit is contained in:
28
Gameplay/TempBall.cs
Normal file
28
Gameplay/TempBall.cs
Normal file
@@ -0,0 +1,28 @@
|
||||
using Godot;
|
||||
using System;
|
||||
|
||||
public partial class TempBall : Area2D
|
||||
{
|
||||
public bool _active = false, _hovered = false, _held = false;
|
||||
|
||||
public void SetSprite(string PATH)
|
||||
{
|
||||
GetNode<Sprite2D>("Image").Texture = GD.Load<Texture2D>(PATH);
|
||||
}
|
||||
|
||||
private void OnMouseEntered()
|
||||
{
|
||||
if (_active)
|
||||
{
|
||||
_hovered = true;
|
||||
}
|
||||
}
|
||||
|
||||
private void OnMouseExited()
|
||||
{
|
||||
if (_active)
|
||||
{
|
||||
_hovered = false;
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user