Advertisement
zCool

Stick.cpp

May 20th, 2012
28
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C++ 0.27 KB | None | 0 0
  1. #include "Stick.h"
  2. #include <string>
  3.  
  4. Stick::Stick(int X, int Y, std::string sprite):Item(X, Y, sprite) {}
  5.  
  6. void Stick::generateCoordinates(int width, int height)
  7. {
  8.     if(width != 0 && height != 0)
  9.     {
  10.         m_X = rand() % width + 1;
  11.         m_Y = rand() % height + 1;
  12.     }
  13. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement