LINE-DRAWING METHOD FOR GAME_SYSTEM

RPG Maker VX Ace

Draw lines directly onto a bitmap.

  • Trihan
  • 04/01/2013 11:18 PM
  • 5146 views
This script, developed for RPG Maker VX Ace from pseudocode provided by FlyingJester, allows you to draw a line between two specified points on a bitmap.

To use it, simply call $game_system.draw_line(bitmap, x1, y1, x2, y2, colour) where bitmap is the bitmap object you want to draw the line on, x1 and y1 are the X and Y coordinate of the first point, x2 and y2 are the X and Y coordinate of the second point, and colour is any valid instance of the Color class.

Posts

Pages: 1
That much I assumed, but it doesn't directly answer any of my questions.
It seems to be code for an in-game graphics editor. The code defines drawing each pixel in a line between two points. You would have to code the other stuff in, like the stuff involved in moving some kind of cursor to the two points you want.
I'm not sure how to make use of this. What exactly is a bitmap in this context? Where can I actually draw these lines? How do I define a bitmap?
Trihan
"It's more like a big ball of wibbly wobbly...timey wimey...stuff."
3359
Oops, noticed a slight error in my instructions! *edits*
Nice job! It looks like you tried hard too make it. I was going to make an artpad demo game and this was the best script I could find. Totall credit to you.
Pages: 1