| 1 | /*************************************************************************** |
| 2 | sprite.h - description |
| 3 | ------------------- |
| 4 | begin : Thu Jan 17 2002 |
| 5 | copyright : (C) 2002 by Waldemar Baraldi |
| 6 | email : [email protected] |
| 7 | ***************************************************************************/ |
| 8 | |
| 9 | /*************************************************************************** |
| 10 | * * |
| 11 | * This program is free software; you can redistribute it and/or modify * |
| 12 | * it under the terms of the GNU General Public License as published by * |
| 13 | * the Free Software Foundation; either version 2 of the License, or * |
| 14 | * (at your option) any later version. * |
| 15 | * * |
| 16 | ***************************************************************************/ |
| 17 | |
| 18 | #ifndef SPRITE_H |
| 19 | #define SPRITE_Hcxx . . $ `src/sprite.h:19:9`! |
| 20 | |
| 21 | #include "graphic.h"cxx . . $ `<file>/src/graphic.h`/ |
| 22 | #include "str.h"cxx . . $ `<file>/src/str.h`/ |
| 23 | #include "SDL.h" |
| 24 | |
| 25 | class Listcxx . . $ List#; |
| 26 | class Surfacecxx . . $ Surface#; |
| 27 | class ImageManagercxx . . $ ImageManager#; |
| 28 | class Imagecxx . . $ Image#; |
| 29 | |
| 30 | class Spritecxx . . $ Sprite#: public Graphiccxx . . $ Graphic#{ |
| 31 | |
| 32 | public: |
| 33 | |
| 34 | /** Constructor. |
| 35 | @param filenamebase El sprite es cargado usando <filenamebase>.spr <filenamebase>.png |
| 36 | */ |
| 37 | Spritecxx . . $ Sprite#Sprite(7c5e60030c36ad17).(Strcxx . . $ Str# * filenamebase, Strcxx . . $ Str# * filenameext, int nFrames, ImageManagercxx . . $ ImageManager# * im); |
| 38 | |
| 39 | /** Destructor.*/ |
| 40 | virtual ~cxx . . $ Sprite#`~Sprite`(ced63f7c635d850d).Spritecxx . . $ Sprite#(); |
| 41 | |
| 42 | virtual int nFramescxx . . $ Sprite#nFrames(b126dc7c1de90089).(); |
| 43 | |
| 44 | virtual int frameWidthcxx . . $ Sprite#frameWidth(57806aaf66c601ae).(ImageManagercxx . . $ ImageManager# * im); |
| 45 | virtual int frameHeightcxx . . $ Sprite#frameHeight(57806aaf66c601ae).(ImageManagercxx . . $ ImageManager# * im); |
| 46 | |
| 47 | virtual Surfacecxx . . $ Surface# * framecxx . . $ Sprite#frame(e8d7ae696153184b).(ImageManagercxx . . $ ImageManager# * im, int n); |
| 48 | |
| 49 | |
| 50 | protected: |
| 51 | Imagecxx . . $ Image# ** framescxx . . $ Sprite#frames.; |
| 52 | int n_framescxx . . $ Sprite#n_frames.; |
| 53 | Strcxx . . $ Str# * filenamebasecxx . . $ Sprite#filenamebase.; |
| 54 | Strcxx . . $ Str# * filenameextcxx . . $ Sprite#filenameext.; |
| 55 | }; |
| 56 | #endif |