From c1413464930fa82073800a6c58334099bbef370b Mon Sep 17 00:00:00 2001 From: manuel Date: Thu, 7 Apr 2011 00:02:36 +0200 Subject: adding normal points --- pacman-c++/point.cpp | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) create mode 100644 pacman-c++/point.cpp (limited to 'pacman-c++/point.cpp') diff --git a/pacman-c++/point.cpp b/pacman-c++/point.cpp new file mode 100644 index 0000000..8837bba --- /dev/null +++ b/pacman-c++/point.cpp @@ -0,0 +1,17 @@ +#include "point.h" +#include "constants.h" + +namespace +{ + QPixmap *pixmap = NULL; +} + +Point::Point(QGraphicsItem *parent) + : PixmapItem(parent) +{ + if (pixmap == NULL) + pixmap = new QPixmap(":/points"); + setPixmap(*pixmap); + + //setSprite(rand * 20 + Constants::sprite_margin, Constants::sprite_margin, Constants::field_size.width, Constants::field_size.height); +} -- cgit v1.2.3