Module utilities

Useful things.

Functions

hasValue (tab, val) Check if table has value.
cropImage (imgpath, cropX, cropY, cropWidth, cropHeight) Crop images.


Functions

hasValue (tab, val)
Check if table has value.

Parameters:

  • tab Table
  • val Value

Returns:

    Boolean.
cropImage (imgpath, cropX, cropY, cropWidth, cropHeight)
Crop images. I'm using this instead of Love2D quads.

Parameters:

  • imgpath Path of the image
  • cropX X position where we'll start to crop the image (in pixels)
  • cropY Y position where we'll start to crop the image (in pixels)
  • cropWidth Width of the cropped image (in pixels)
  • cropHeight Height of the cropped image (in pixels)

Returns:

    Cropped image.
generated by LDoc 1.4.6 Last updated 2021-02-27 10:51:51