2
\$\begingroup\$

I have a basic prototype working with health, resources and units. The problem is: How do I select multiple units? I have an idea of making an rectangle which dynamically extends with the mouse position. I think I need to convert this rectangle to transparent rectangle.

\$\endgroup\$

1 Answer 1

3
\$\begingroup\$

pygame.draw.rect should be enough to draw transparent rectangles, according to documentation if you use width > 0, then the rectangle won't be filled.

\$\endgroup\$
3
  • \$\begingroup\$ thanks buddy ... Its worked perfectly...... Anyone know easy implementation of a* Algorithm in RTS....Coz unit intersect with other unit and building....I think implementing a* would we so confusing,,,,,, \$\endgroup\$
    – piyush_dev
    Oct 30, 2012 at 14:33
  • 3
    \$\begingroup\$ @piyush3dxyz It's not the idea you stack up questions one after the other. Threads are just that they handle one question and if you're satisfied with the answer given you mark them so that your question is solved. As for your A* first do some own research. If you can't figure it out post a new question. Search if the question is already asked though. \$\endgroup\$
    – Sidar
    Oct 30, 2012 at 15:01
  • \$\begingroup\$ ok i got it.... \$\endgroup\$
    – piyush_dev
    Oct 31, 2012 at 13:41

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .