Impact

This forum is read only and just serves as an archive. If you have any questions, please post them on github.com/phoboslab/impact

1 decade ago by MikeL

Is there a built in way to group entities? For example, if I want 3 different groups of 4 enemy ships with each group following its own movement pattern? Thought I may have seen something like it in the docs, but can't seem to find it. Thanks in advance.

1 decade ago by dominic

No, there's no built in way to manage groups in Impact yet.

You could create a new, invisible, entity type (e.g. EntityGroup) that just has a reference to all its children. These children could still be spawned, updated and drawn like normal, but in your EntityGroup&039;s #update() method you could set their velocity, position etc. to move them in union.
Page 1 of 1
« first « previous next › last »