Module Sprite.Set


module Set: sig  end

val create : int -> 'a Sprite.set
create size creates a set of sprites.
val add : 'a Sprite.set -> 'a Sprite.t -> unit
add set sprite adds sprite to set. It does nothing if it was already in the set
val del : 'a Sprite.set -> 'a Sprite.t -> unit
del set sprite removes sprite from the given set
val clear : 'a Sprite.set -> unit
clear set removes all sprites from the given set.
val iter : ('a Sprite.t -> unit) -> 'a Sprite.set -> unit
iter fnctn set iterates a function over a set. The function may safely remove the sprite it operates on.
val iter_data : ('a Sprite.t -> 'a -> unit) -> 'a Sprite.set -> unit
val set_boundary : 'a Sprite.set -> int -> int -> int -> int -> unit
set_set_boundary min_x max_x min_y max_y
val set_collision : 'a Sprite.set -> int -> int -> unit
set_collision set width height creates collision structures for set set with bucket size set to (width, height).
val mem : 'a Sprite.set -> 'a Sprite.t -> bool
mem set sprite
Returns true if sprite is in set
val fold : ('a -> 'b Sprite.t -> 'a) -> 'b Sprite.set -> 'a -> 'a
fold fnctn set value folds a function through a set. The function may safely remove the sprite it operates on.
val fold_data : ('a -> 'b Sprite.t -> 'b -> 'a) -> 'b Sprite.set -> 'a -> 'a