[PLUGIN] Canvas

Post your completed addons to share with the community

Post » Tue Apr 12, 2016 11:24 pm

How do I change the path color/line width settings during drawing path without affecting the path previously drawn until that point? Is it possible with one canvas object or do I need another instance for this?
B
24
S
7
G
4
Posts: 108
Reputation: 3,811

Post » Wed Apr 13, 2016 1:15 am

@Waltuo
Use the "begin path" action to not use any previous paths with the draw path action.
Ex:

move to (0,0)
line to (10,10)
draw path "black" 1.0
begin path
line to (20,20)
draw path "blue" 2.0
B
79
S
24
G
52
Posts: 4,725
Reputation: 39,713

Post » Thu Apr 14, 2016 8:37 am

Hi R0J0hound

Thank you very much for this useful plugin!

One question: is it possible to control the line properties when I draw it? (E.g., plot dotted / dashed lines?)

Thanks!
B
6
S
2
Posts: 2
Reputation: 404

Post » Thu Apr 14, 2016 5:58 pm

@ayeletpn
There's the "line dash setting" action.
B
79
S
24
G
52
Posts: 4,725
Reputation: 39,713

Post » Fri Apr 15, 2016 5:59 am

Thanks!
B
6
S
2
Posts: 2
Reputation: 404

Post » Tue Apr 19, 2016 3:37 pm

Hello, please, I think this plugin I can get what I want but do not know how.

I have 3 graphics:

Background.
1 Plane.
Canvas object.

The canvas object is a graphic with transparent areas.

I want those transparent areas in the canvas graphic object, cleared areas in Figure 1 Plan.

Image

Image

As I can get this?

I tried the destination over effect but not sure to do well.

Sorry for my english.
B
21
S
9
G
12
Posts: 474
Reputation: 8,733

Post » Tue Apr 19, 2016 5:29 pm

Thanks @R0J0hound , everything's working as it should now!
B
24
S
7
G
4
Posts: 108
Reputation: 3,811

Post » Tue Apr 19, 2016 6:21 pm

@Mirlas
You can do that with any other sprite as well. Basically you use a layer with "force own texture" and put the canvas and plane in it. The canvas has the "destination out" blend.

layer 1: force own texture=true
--- canvas: blend="destination-in"
--- plane
layer 0
B
79
S
24
G
52
Posts: 4,725
Reputation: 39,713

Post » Tue Apr 19, 2016 11:20 pm

Ok, I already got it, thanks!.
B
21
S
9
G
12
Posts: 474
Reputation: 8,733

Post » Thu Apr 21, 2016 7:53 am

Hi @R0j0,
I'm new in construct 2. Now, i'm trying change color of a sprite by a gradient , I have used rgbaAt() to get color of the pixel on gradient, but I don't know how change color of sprite by the return value of rgbaAt() ?
Plesea for me any idea, and sorry because my bad english :(
B
6
S
1
Posts: 4
Reputation: 354

PreviousNext

Return to Completed Addons

Who is online

Users browsing this forum: edisone and 3 guests