Jump to content




How to use paintutils?


  • You cannot reply to this topic
3 replies to this topic

#1 Konlab

  • Members
  • 595 posts
  • LocationKerbin

Posted 17 May 2014 - 07:46 PM

Please tell me how to use paintutils API?

thanks!

#2 MKlegoman357

  • Members
  • 1,170 posts
  • LocationKaunas, Lithuania

Posted 17 May 2014 - 07:50 PM

Like any other CC or Lua APIs. You can find all of Paintutils API functions on the wiki.

#3 Zudo

  • Members
  • 800 posts
  • LocationUK

Posted 20 May 2014 - 04:45 PM

local image = paintutils.loadImage(path) -- Loads and returns an image object from a path.

paintutils.drawImage(image, 0, 0) -- Draws it at 0,0.

paintutils.drawPixel(0, 0, colours.red) -- Draws a red pixel at 0, 0

paintutils.drawLine(0, 0, 0, 10, colours.red)-- Draws a line from 0,0 to 0,10 in the red.

Edited by ZudoHackz, 20 May 2014 - 04:45 PM.


#4 Konlab

  • Members
  • 595 posts
  • LocationKerbin

Posted 21 May 2014 - 06:09 AM

View PostZudoHackz, on 20 May 2014 - 04:45 PM, said:

local image = paintutils.loadImage(path) -- Loads and returns an image object from a path.

paintutils.drawImage(image, 0, 0) -- Draws it at 0,0.

paintutils.drawPixel(0, 0, colours.red) -- Draws a red pixel at 0, 0

paintutils.drawLine(0, 0, 0, 10, colours.red)-- Draws a line from 0,0 to 0,10 in the red.

Thanks!





3 user(s) are reading this topic

0 members, 3 guests, 0 anonymous users