+//from 16_sprit.h\r
+#ifdef __WATCOMC__\r
+#include <hw/vga/vrl.h>\r
+\r
+typedef struct vrs_container{\r
+ // Size of a .vrs blob in memory\r
+ // minus header\r
+ dword data_size;\r
+ union{\r
+ byte far *buffer;\r
+ struct vrs_header far *vrs_hdr;\r
+ };\r
+ // Array of corresponding vrl line offsets\r
+ vrl1_vgax_offset_t **vrl_line_offsets;\r
+} vrs_container_t;\r
+\r
+typedef struct vrl_container{\r
+ // Size of a .vrl blob in memory\r
+ // minus header\r
+ dword data_size;\r
+ union{\r
+ byte far *buffer;\r
+ struct vrl1_vgax_header far *vrl_header;\r
+ };\r
+ // Pointer to a corresponding vrl line offsets struct\r
+ vrl1_vgax_offset_t *line_offsets;\r
+} vrl_container_t;\r
+\r
+typedef struct sprite\r
+{\r
+ // VRS container from which we will extract animation and image data\r
+ vrs_container_t spritesheet;\r
+ // Container for a vrl sprite\r
+ vrl_container_t sprite_vrl_cont;\r
+ // Current sprite id\r
+ int curr_spri_id;\r
+ // Index of a current sprite in an animation sequence\r
+ int curr_anim_spri;\r
+ // Current animation sequence\r
+ struct vrs_animation_list_entry_t *curr_anim_list;\r
+ // Index of current animation in relevant VRS offsets table\r
+ int curr_anim;\r
+ // Delay in time units untill we should change sprite\r
+ int delay;\r
+ // Position of sprite on screen\r
+ int x, y;\r
+} sprite_t;\r
+#endif\r
+\r
+//newer structs\r
+typedef struct\r
+{\r
+ int x; //entity exact position on the viewable map\r
+ int y; //entity exact position on the viewable map\r
+ int tx; //entity tile position on the viewable map\r
+ int ty; //entity tile position on the viewable map\r
+ int triggerx; //entity's trigger box tile position on the viewable map\r
+ int triggery; //entity's trigger box tile position on the viewable map\r
+// int sheetsetx; //NOT USED YET! entity sprite sheet set on the image x\r
+// int sheetsety; //NOT USED YET! entity sprite sheet set on the image y\r
+ nibble d; //direction to render sprite!! wwww\r
+ nibble pred; //prev. direction for animation changing\r
+ word dire; //sprite in use\r
+ nibble q; //loop variable for anumation and locking the playing to compleate the animation cycle to prevent issues with misalignment www\r
+ word speed; //entity speed!\r
+ word spt; //speed per tile\r
+#ifdef __WATCOMC__\r
+ sprite_t spri; // sprite used by entity\r
+#endif\r
+ sword hp; //hitpoints of the entity\r
+ nibble overdraww, overdrawh; // how many pixels to "overdraw" so that moving sprites with edge pixels don't leave streaks.\r
+ // if the sprite's edge pixels are clear anyway, you can set this to 0.\r
+ nibble /*int*/ persist_aniframe; // gonna be increased to 1 before being used, so 0 is ok for default\r
+} entity_t;\r
+\r
+typedef struct\r
+{\r
+ int x; //entity exact position on the viewable map\r
+ int y; //entity exact position on the viewable map\r
+ int tx; //entity tile position on the viewable map\r
+ int ty; //entity tile position on the viewable map\r
+\r
+#ifdef __WATCOMC__\r
+ sprite_t spri; // sprite used by entity\r
+#endif\r
+ sword hp; //hitpoints of the entity\r
+} static_map_entity_t;\r
+\r
+//===========================================================================//\r
+\r