mirror of
https://gitlab.com/MaddoScientisto/cirnogodot.git
synced 2026-06-08 19:55:54 +00:00
Rotate bullet pattern to face parent
This commit is contained in:
parent
ed86ffd184
commit
7d267c406d
19 changed files with 1325 additions and 1245 deletions
|
|
@ -4,8 +4,9 @@ namespace Cirno.Scripts.Utils;
|
|||
|
||||
public static class ActivationHelper
|
||||
{
|
||||
public static void UseTargets(Node activator, string target, ActivationType activationType = ActivationType.Toggle)
|
||||
public static bool UseTargets(Node activator, string target, ActivationType activationType = ActivationType.Toggle)
|
||||
{
|
||||
var res = false;
|
||||
GD.Print($"Trying to use targets called: {target}");
|
||||
var targetList = activator.GetTree().GetNodesInGroup(target);
|
||||
foreach (var t in targetList)
|
||||
|
|
@ -15,8 +16,10 @@ public static class ActivationHelper
|
|||
if (t is IActivable activable)
|
||||
{
|
||||
GD.Print($"Activating {t.Name}");
|
||||
activable.Activate(activationType);
|
||||
res |= activable.Activate(activationType);
|
||||
}
|
||||
}
|
||||
|
||||
return res;
|
||||
}
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue