private GamePipe AddPipe(GameSpawner spawner, GamePipeEnd end) { GamePipe newPipe = new GamePipe(spawner, end); pipes.Add(newPipe); spawner.AttachPipe(newPipe); if (onPipeAdded != null) { onPipeAdded(newPipe); } return(newPipe); }
public void AttachPipeToSpawner(GamePipe pipe, GameSpawner spawner) { spawner.AttachPipe(pipe); }