- Joined
- Nov 11, 2006
- Messages
- 7,661
The RectList concept is cool, as well as the underlying concept of creating more unique shapes like triangles or polygons from rectangles 
But IMO I think the modifiers and the way triangles are integrated (by subtracting vertices) is a bit counterintuitive/clunky. I feel like I'd need to go back to the reference documentation each time to make a triangle, and I wouldn't be super confident of getting the order right so I think it'd be a bit frustrating for the user. Not to mention the name, since once something is a triangle, it is no longer a Rect(angle).
I think I'm also still having a hard time understanding why modifiers are needed.
If you want to support triangles, I'd personally make a separate class for a Triangle and a Rect--and then they can share some common function API (e.g. ContainsUnit). And maybe a polygon/N-gon class for making a shape out of multiple rects. Maybe it could be a "WonderShape" library.
In my head that'd be a bit more intuitive. And maybe leaning a bit more on function-based APIs--less on naming and string-based APIs since those are a little harder to get intellisense assistance on.
But IMO I think the modifiers and the way triangles are integrated (by subtracting vertices) is a bit counterintuitive/clunky. I feel like I'd need to go back to the reference documentation each time to make a triangle, and I wouldn't be super confident of getting the order right so I think it'd be a bit frustrating for the user. Not to mention the name, since once something is a triangle, it is no longer a Rect(angle).

If you want to support triangles, I'd personally make a separate class for a Triangle and a Rect--and then they can share some common function API (e.g. ContainsUnit). And maybe a polygon/N-gon class for making a shape out of multiple rects. Maybe it could be a "WonderShape" library.
