btw if you gonna iterate over list and remove elements in the process then better start from the end and do 'downto' or indexes will mess up

also you might wanna check out generic collections that allow you to create TList<TSprite>
in delphi its generics.collections unit and in lazarus fgl unit