[PLUGIN] Polygon (update 2013-04-23)

Post your completed addons to share with the community

Post » Fri Jan 18, 2013 12:55 am

I made a slight little change on the plugin.
The clear action was clearing the vertex list and its canvas but the texture wasn't updated.
Now it works as expected (:
B
60
S
22
G
14
Posts: 1,479
Reputation: 16,346

Post » Fri Jan 18, 2013 1:50 am

Wow, fantastic! This will be very useful!
B
90
S
30
G
24
Posts: 3,189
Reputation: 32,400

Post » Mon Jan 21, 2013 9:46 am

@rexrainbow @yann Data being stored in JSON format, we don't see anything that would make this fail on CocoonJS. Also, unless it's doing "software-rendering" by drawing pixels manually one by one to the canvas, it should also get quite a nice speed boost from our rendering system :)
B
9
S
4
G
4
Posts: 383
Reputation: 3,616

Post » Mon Jan 21, 2013 6:03 pm

@ludei thanks for the info (:
And yeah as far as drawing goes, I use the canvas context fill/stroke javascript functions and in webgl mode I copy the texture to the webgl context.
B
60
S
22
G
14
Posts: 1,479
Reputation: 16,346

Post » Mon Jan 21, 2013 7:16 pm

If you can add physics to the vertices then you could make soft body dynamics like in the game Gish.
B
37
S
19
G
18
Posts: 613
Reputation: 10,231

Post » Mon Jan 21, 2013 7:55 pm

This looks pretty cool, but do you think it's possible to fill the polygon with a sprite which would then get 'stretched' up nicely?
B
13
S
3
G
4
Posts: 35
Reputation: 3,358

Post » Mon Jan 21, 2013 10:17 pm

@Ethan
yeah I dunno how hard it would be, and to me it would make more sense to be a behavior on top of this plugin than a feature inside the plugin.
And also remember that drawing polygons is expensive. By looking at the "you shouldn't do that" 3D demo where there's like 30 polygons it's already quite slow (:.


@jasper
Heheheheheh asking for new features are you? :D
I was thinking about that. I left that aside since I didn't need it and I wanted to make it work nicely without worrying about textures (tiling/not tiling/... etc).
But we'll see if I can do something about it. I'm starting to get the hang of C2's SDK.
Don't expect it too soon though, but if you see that in one month I still didn't try you are allowed to ask again :D
Yann2013-01-21 22:17:59
B
60
S
22
G
14
Posts: 1,479
Reputation: 16,346

Post » Tue Jan 22, 2013 3:06 am

This looks awesome! I suppose it could be used to "fake" dynamic collision polygons. :) Thanks!
B
37
S
9
G
7
Posts: 143
Reputation: 6,017

Post » Tue Jan 22, 2013 9:56 am

@basspenguin
Yeah in theory, but I have yet to see a concrete application of "dynamic collision" you can't achieve with a few sprites.
B
60
S
22
G
14
Posts: 1,479
Reputation: 16,346

Post » Sun Jan 27, 2013 12:19 am

Cool, that will be definitively useful.

Here's just a feature suggestion: draw curved surfaces by interpolating between polygon vertices, e.g. cubic curves. I think technically it should be something like subdividing a polygon into curved surface.
B
42
S
11
G
4
Posts: 505
Reputation: 7,267

PreviousNext

Return to Completed Addons

Who is online

Users browsing this forum: Lordshiva1948 and 3 guests