X-Git-Url: https://git.verplant.org/?a=blobdiff_plain;f=src%2Fbadguy.h;h=60b74c3089f92ceb9d2a300b20163e9a7fa0bd8d;hb=36cc92dc67c4cfdaceed7d47a4aa6992b407d1df;hp=a45a27ca568d1d0cb7dce76f42e6b1a879e220ad;hpb=43ae91e84ae574464a2ff634daa8a16e253b47fa;p=supertux.git diff --git a/src/badguy.h b/src/badguy.h index a45a27ca5..60b74c308 100644 --- a/src/badguy.h +++ b/src/badguy.h @@ -18,6 +18,7 @@ #include "type.h" #include "timer.h" #include "texture.h" +#include "physic.h" #include "collision.h" /* Enemy modes: */ @@ -32,13 +33,15 @@ typedef struct bad_guy_type { int mode; - int dying; + DyingType dying; int kind; - int seen; + bool seen; int dir; int frame; base_type base; + base_type old_base; timer_type timer; + physic_type physic; } bad_guy_type; @@ -50,19 +53,19 @@ enum { BAD_MONEY }; -texture_type img_bsod_squished_left, img_bsod_squished_right, +extern texture_type img_bsod_squished_left, img_bsod_squished_right, img_bsod_falling_left, img_bsod_falling_right, img_laptop_flat_left, img_laptop_flat_right, img_laptop_falling_left, img_laptop_falling_right; -texture_type img_bsod_left[4], img_bsod_right[4], +extern texture_type img_bsod_left[4], img_bsod_right[4], img_laptop_left[3], img_laptop_right[3], img_money_left[2], img_money_right[2]; -bitmask *bm_bsod; +extern bitmask *bm_bsod; void badguy_create_bitmasks(); -void badguy_init(bad_guy_type* pbad); +void badguy_init(bad_guy_type* pbad, float x, float y, int kind); void badguy_action(bad_guy_type* pbad); void badguy_draw(bad_guy_type* pbad); void badguy_collision(bad_guy_type* pbad, void* p_c_object, int c_object);