Module Raylib.Vector2

Types

type t = t' ctyp
val t : t Ctypes.typ
val create : float -> float -> t

create x y

val x : t -> float

Vector x component

val y : t -> float

Vector y component

val set_x : t -> float -> unit
val set_y : t -> float -> unit
val zero : unit -> t
val one : unit -> t
val add : t -> t -> t
val add_value : t -> float -> t
val subtract : t -> t -> t
val subtract_value : t -> float -> t
val length : t -> float
val length_sqr : t -> float
val dot_product : t -> t -> float
val distance : t -> t -> float
val angle : t -> t -> float
val scale : t -> float -> t
val multiply : t -> t -> t
val negate : t -> t
val divide : t -> t -> t
val normalize : t -> t
val lerp : t -> t -> float -> t
val reflect : t -> t -> t
val rotate : t -> float -> t
val move_towards : t -> t -> float -> t