[PLUGIN] Canvas

Post your completed addons to share with the community

Post » Thu Apr 24, 2014 2:54 pm

Neither example makes use of the canvas plugin at all.
If your vision so exceeds your ability, then look to something closer.
Moderator
B
120
S
28
G
68
Posts: 4,847
Reputation: 48,295

Post » Thu Apr 24, 2014 3:15 pm

zenox98 wrote:Neither example makes use of the canvas plugin at all.


In your last post, the first link that you mention (https://www.scirra.com/forum/is-there-a-way-to-give-a-sprite-a-trail_p557543?#p557543) has a post from Yann that use the Canvas plugin (http://dl.dropbox.com/u/23551572/C2/trail.capx).

-EDIT-

The more I think of it, the more I conclude that R0J0hound also meant not using the canvas plugin for the trail effect... :roll:

So thanks anyway @zenox98 ;)
composer - multimedia artist
www.eli0s.com/en/
B
53
S
21
G
3
Posts: 1,127
Reputation: 8,095

Post » Sat May 10, 2014 10:46 am

Hello guys, I'm new to construct2 and I'm trying to create a colouring book for my 5 years old kid. I'm finding a lot of good words on Canvas plugin but I'm finding it hard to use the plugin (I come form an art background).
Is there a tutorial or a guided help on how to take advantage of the this awesome plugin.

Thanks a lot :)
B
5
Posts: 5
Reputation: 262

Post » Mon May 12, 2014 12:05 am

check the Lemmings example, I'm pretty sure page 8 or 9 has another file you can use.
B
12
S
3
G
1
Posts: 347
Reputation: 2,866

Post » Mon May 12, 2014 4:37 am

@zixofranic
There isn't really any documentation but the are descriptions in the editor when adding expressions, actions or conditions.

For a coloring book you want a paint bucket fill like mspaint right? Look at the "floodfill canvas with color" action to do that.
However the only limitation with that is Just make sure the canvas is completely opaque, aka has no transparency. Transparency can cause the flood fill to hang the game currently.
B
79
S
24
G
54
Posts: 4,749
Reputation: 40,761

Post » Mon May 12, 2014 1:30 pm

@R0J0hound @ghost thanks you guys, I'll check it out
B
5
Posts: 5
Reputation: 262

Post » Thu May 15, 2014 9:02 pm

Hi, I'm also trying to do a coloring book and I can't find a way to make it work with just a simple test. Firefox or chrome hang for a while then pop-up the javascript error using the floodfill action. What I'm doing wrong? Attached is a .capx of the test I'm trying.
You do not have the required permissions to view the files attached to this post.
B
3
Posts: 7
Reputation: 189

Post » Thu May 15, 2014 11:18 pm

Here you go, i had this problem too and almost cracked my head over it, the problem is that flood fill can not work with non integer numbers, so add int() to your X and Y values and also using "red" as a color won't work, you need to give the color code or use rgb.

canvas_test.capx
You do not have the required permissions to view the files attached to this post.
Image
B
59
S
21
G
11
Posts: 482
Reputation: 10,718

Post » Fri May 16, 2014 12:07 pm

Lof wrote:Here you go, i had this problem too and almost cracked my head over it, the problem is that flood fill can not work with non integer numbers, so add int() to your X and Y values and also using "red" as a color won't work, you need to give the color code or use rgb.

canvas_test.capx


Thank you! Now is working. I could never figure it out this solution.
B
3
Posts: 7
Reputation: 189

Post » Sat May 17, 2014 8:27 pm

Someone knows why in the example I provide the floodfill doesn't fill all and leaves white pixels between the black lines? Is something of the canvas or the drawing I'm using? Is there way yo have a clean floodfill without those white pixels?
B
3
Posts: 7
Reputation: 189

PreviousNext

Return to Completed Addons

Who is online

Users browsing this forum: Yahoo [Bot], zenox98 and 2 guests