Game Development Community

Visual Collision Vertex Plotter Online

by Pete111 · in Torque Game Builder · 03/01/2005 (4:11 pm) · 23 replies

Hi - I built a little visual plotter online at:
http://www.ramspeed.com

-It's rough but works OK until we have a built-in app.
I'll upload an exe that will allow you to load local images soon.

thanks
Page «Previous 1 2
#1
03/01/2005 (5:44 pm)
Nice start, but I couldn't get it to load any of my PNG files. I navigated to the files, then clicked on the one to load and it didn't load anything.
#2
03/01/2005 (6:10 pm)
Opps - it's a bit depth problem - I'll upload the fix right now. Thanks Jason.
#3
03/01/2005 (6:48 pm)
Ah, that worked. But some of my images are pretty big, and the layout doesn't expand with the window size, so a big sprite gets trampled by the interface elements. :) I guess you could simply make it bigger, but a dynamic layout would be best.

Good work, though. I'll use this!
#4
03/02/2005 (1:54 am)
Very cool Pete!! Thx!
#5
03/02/2005 (2:32 am)
That's so cool!

I was gearing myself up to have PSP open in one window and the Java point plotter in another and constantly switch between them. This little app makes life much easier.

Some kind of zoom option would be great for working on sprites with a slightly complicated layout, but other than that, it's great :)
#6
03/02/2005 (2:33 am)
Guys,

Thanks for helping each other, it really helps us focus on more pressing T2D dev-issues like bug-fixes etc.

- Melv.
#7
03/02/2005 (2:37 am)
Just noticed that in the standalone app, you can't copy and paste the collision point text. I can highlight it, but as soon as I release the mouse button, it deselects.
#8
03/02/2005 (6:15 am)
Hmm, I'll make the image area larger, allow copying of the text...I thought it was I made the field editable... and maybe add a zoom button. I was thinking a zoom would be nice too, Philip! Glad I help out!
#9
03/02/2005 (6:43 am)
I would make sure it can't draw concave shapes otherwise ppl might spend too much time on a shape that is incompatable
#10
03/02/2005 (6:58 am)
This might be a really silly question, but what constitues a concave shape? If I had a sprite that had bumps and dips in it, (like the blob below) can I not follow the contours of it?

www.philspcmods.com/images/t2d/blob.gif
#11
03/02/2005 (7:16 am)
@Philip: You can't. That's concave.

Go through all your points and check its neighbour points. If the interior angle is more than 180-deg, it's concave.

Another way of thinking about it is to draw all the lines that define your polygon so that they extend out to infinity. If they intersect any of the other lines in the polygon, it's concave.

So many different ways to define this.

This may sound brutal but is extremely common in engines as it allows certain assumptions/constraints to be made. Supporting concave polygons requires the engine to decompose them into discreet convex polygons which takes time and extra effort for very little reward in certain cases.

Most 2D games get away with this because it actually doesn't matter in most instances, particular for high-paced games. You definately don't want your polygon to exactly match the contours of an object. Lots of people get hung-up on being precise when most of the time, games are quite the opposite. The shooter demo has really crude collision polygons, especially for the ship. The pool demo has collision detection for the pockets (which are concave) but the nieve implementation would try to have a polygon that completely defined the pocket. All you really need is something that the ball collides with in the pocket, in this case we did a box.

Another way to deal with this is with your art. If you've got a ship with a big gun sticking out and you also want this to be part of the collision-detection solution then simply draw it seperately, mount it as an object and give it a collision poly. The same would go for a large player with arms or legs.

Hope I don't sound "preachy" here. :)

- Melv.
#12
03/02/2005 (7:36 am)
Preach away :) I'm all for learning this stuff!

I haven't gotten to defining my own collisions yet, but I'll check out my art before I start, and decide if a rough poly will do it, or if I should split the sprites into smaller mounted sections.

The fact that mounting everything together (if I go that way) will be so easy is one of the reasons that I'm making as much progress as I am! T2D truly rocks!
#13
03/02/2005 (10:31 am)
Cool.

Continuing my preach then ... I'd definately be careful about worrying about being so precise with your collision polygons. The less edges, the faster your game will run. Next to rendering, collision-detection can become the most intensive part of your game.

I heard someone once say that a good rule of thumb is to make your enemys' collision-polygons slightly bigger and you players slightly smaller. That way you make the player happier. :)

- Melv.
#14
03/02/2005 (10:34 am)
Lol good point... I know when you know a game messes up when you "should've" killed something (3d or 2d) you definately notice and feel cheated, while you hardly ever notice (or care) when you slip by through a glitch or quirk.

America's Army comes to mind with that comment Melv lol... had friends who had many mice casulaties in fits of rage lol
#15
03/02/2005 (12:14 pm)
OK - I'm uploading a new executable version that is now 800x600 and fixed the copy functionality from the display field. This should allow for editing larger sprites...it's still kinda crummy but hey...! I didnt bother modifying the shockwave version...
#16
03/02/2005 (12:32 pm)
Sweet! Everything works as far as I can tell. Thanks, Pete!
#17
03/02/2005 (2:31 pm)
You guys are cool.

- Melv.
#18
03/02/2005 (7:10 pm)
Niiiice :)
#19
03/03/2005 (7:45 am)
Great tool - saved me loads of time.
#20
03/08/2005 (7:34 pm)
Hmmm... looks like the online version is no longer there. Is there a MAC version of your program?
Page «Previous 1 2