no_sprite is now a #define for a all-zero sprite

pull/2/head
Sara 2023-05-05 22:14:01 +02:00
parent 3a5ec4a0d1
commit 750b30aa89
1 changed files with 1 additions and 3 deletions

View File

@ -104,9 +104,7 @@ extern text_style_t make_text_style(const char* font, SDL_Color color, int dpi,
extern SDL_Rect get_srcrect_from(spritesheet_t* sheet, int index); extern SDL_Rect get_srcrect_from(spritesheet_t* sheet, int index);
extern void set_active_view(const view_t* view); extern void set_active_view(const view_t* view);
inline sprite_t no_sprite() { #define no_sprite (sprite_t){NULL, 0.0, 0.0, {0.0, 0.0}, 0.0, 0.0, 0.0, 0, {0, 0, 0, 0}}
return (sprite_t){NULL, 0.0, 0.0, {0.0, 0.0}, 0.0, 0.0, 0.0, 0, {0, 0, 0, 0}};
}
#ifdef __cplusplus #ifdef __cplusplus
} }