namespace Godot { public partial class Node { public T GetNode(NodePath path) where T : class { return (T)(object)GetNode(path); } public T GetNodeOrNull(NodePath path) where T : class { return GetNode(path) as T; } public T GetChild(int idx) where T : class { return (T)(object)GetChild(idx); } public T GetChildOrNull(int idx) where T : class { return GetChild(idx) as T; } public T GetOwner() where T : class { return (T)(object)GetOwner(); } public T GetOwnerOrNull() where T : class { return GetOwner() as T; } public T GetParent() where T : class { return (T)(object)GetParent(); } public T GetParentOrNull() where T : class { return GetParent() as T; } } }