Skip to content

Expanding node inputs / InputSocket arrays #21

@fydar

Description

@fydar

Support nodes having arrays of InputSockets so that they may accept an arbitrary amount of inputs. This is useful for nodes like the AddNode that would happily add an arbitrary amount of values together.

I have some basic editor support for this feature that allows InputSockets to be used in an array, however, the socket mapping API isn't sufficient for this and will need a rework.

image

The current socket mapping API only allocates an array of the exact sized required to connect all of the inputs. That will need to be changed as the number of inputs is not a fixed value anymore. Other API alternatives could include yield return for every input or returning struct-wrapped arrays that get concatenated together. Returning struct-wrapped is likely to make the smallest amount of allocations.

Whatever way I go about implementing this, there will be a slight performance regression.

Metadata

Metadata

Assignees

Labels

New feature or request📦 RPGCore.BehaviourIssue related to the RPGCore.Behaviour package

Projects

Status

Todo

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions