Flood Fill? [Solved]

Started by KamikazeHighland, Thu 26/05/2011 05:33:09

Previous topic - Next topic

KamikazeHighland

Hi.  In AGS I can draw lines between points, but I'd also like to be able to flood fill the areas between those lines, if possible.  It's odd that I can't find this, since the room editor has this feature...  ::)

Mostly because I can't /skew/ a rectangle in-game... unless I can?

Khris

Unfortunately you have to code this yourself. Note that you have to use the DrawingSurface.GetPixel() command a lot, and it's slow.
(Why would the editor's drawing tools have any bearing on what drawing commands are available as script commands anyway? I don't see the connection.)

Same for skewing sprites, you have to code it yourself. I'd use DynamicSprites and copy the first one line by line to the second while constantly increasing the x coordinate.

KamikazeHighland

Quote from: Khris on Thu 26/05/2011 05:49:29
(Why would the editor's drawing tools have any bearing on what drawing commands are available as script commands anyway? I don't see the connection.)

Well, I don't know, if you can draw in the editor but you can't make a game using that editor where you can draw in a similar fashion..

Thanks for the quick reply!

Gilbert

There is module that offers this with some limitation (I think).

If that still doesn't suit your need, you have to script it yourself at the moment. I've written some codes when making the AGI picture decoder module, which you may also check.

KamikazeHighland

You've both actually been more helpful than you may realize, and I've worked around the issue.

Sometimes you just can't come up with an answer until /after/ you ask.  Thanks!

SMF spam blocked by CleanTalk