1 /* 2 * Abuse - dark 2D side-scrolling platform game 3 * Copyright (c) 1995 Crack dot Com 4 * Copyright (c) 2005-2011 Sam Hocevar <sam@hocevar.net> 5 * 6 * This software was released into the Public Domain. As with most public 7 * domain software, no warranty is made or implied by Crack dot Com, by 8 * Jonathan Clark, or by Sam Hocevar. 9 */ 10 11 #ifndef __SUPER_MORPH_HPP__ 12 #define __SUPER_MORPH_HPP__ 13 14 #include "transimage.h" 15 16 class super_morph 17 { 18 public : 19 int t; 20 unsigned char *movers; 21 int w,h; 22 super_morph(TransImage *h1, TransImage *h2, int aneal_steps, void (*stat_fun)(int)); ~super_morph()23 ~super_morph() { if (t) free(movers); } 24 } ; 25 26 27 struct stepper 28 { 29 long x,y,r,g,b,dx,dy,dr,dg,db; 30 } ; 31 32 class smorph_player 33 { 34 stepper *steps; 35 unsigned char *hole; 36 public : 37 int w,h,f_left,t; 38 smorph_player(super_morph *m, palette *pal, image *i1, image *i2, int frames, int dir); 39 int show(image *screen, int x, int y, ColorFilter *fil, palette *pal, int blur_threshold); ~smorph_player()40 ~smorph_player() { free(hole); free(steps); } 41 } ; 42 43 44 #endif 45