I am doing just for fun a virtual desktop to play Magic The Gathering with friends. I am using Delphi 2010. The cards are represented in the application by TImage components (loading PNG files of the cards loaded from a database). The point here is that in MTG a very common thing to do is to tap a card (rotating it 90º degrees to right). There is a simple way to do this? I really don’t need the “animation”, just the card rotated once is clicked (animation would be nice though). The game should work simultaneously with many cards and they can be moved anywhere in the form. I am thinking in having the image of the card tapped and untapped in the database but this may be an overkill if there is a nice and efficient way to rotate the cards.
Any ideas?
Or you can leave the
TImageand use e.g.TPaintBoxand GDI+ library. GDI+ has theRotateFlipmethod directly for doing this. Using theGDI+ Library for Delphiit would look like:Such an overkill, doesn’t it 😕