Optionaloptions: ContainerOptions<ContainerChild>Optionaloptions: FlightOptionsOptionaloptions: FlightOptionsdrops every live flight at once without dispatching arrivals - a scene change, say
Removes all internal references and listeners as well as removes children from the display list.
Do not use a Container after calling destroy.
drives every live flight, then forgets the arrived ones (arrival first, callback after)
Owns the projectile flights a game has in the air: one
addper shot, oneupdate(dt)driving them all,onArrivedispatched exactly once per arrival, and no bookkeeping left to the caller.Ownership follows who made the sprite. A sprite you pass stays yours - the manager positions it but never parents or destroys it, so layering and scene teardown stay the caller's. A texture builds a manager sprite instead: parented here and destroyed on arrival, cancel or clear. Destroying the
Flightsnode itself clears first, so manager-built sprites never outlive it.Example