Hotspot fixes
git-svn-id: svn://svn.code.sf.net/p/sc2/code/trunk@170 8092fc87-c524-0410-9efc-e669fe64eaf9
This commit is contained in:
@@ -41,7 +41,7 @@ static void
|
||||
process_image (FRAMEPTR FramePtr, SDL_Surface *img[], AniData *ani, int cel_ct)
|
||||
{
|
||||
TFB_Image *tfbimg;
|
||||
int hx = 0, hy = 0;
|
||||
int hx, hy;
|
||||
|
||||
TYPE_SET (FramePtr->TypeIndexAndFlags, WANT_PIXMAP << FTYPE_SHIFT);
|
||||
INDEX_SET (FramePtr->TypeIndexAndFlags, cel_ct);
|
||||
@@ -50,13 +50,11 @@ process_image (FRAMEPTR FramePtr, SDL_Surface *img[], AniData *ani, int cel_ct)
|
||||
{
|
||||
if (ani[cel_ct].transparent_color != -1)
|
||||
SDL_SetColorKey(img[cel_ct], SDL_SRCCOLORKEY, ani[cel_ct].transparent_color);
|
||||
|
||||
if (ani[cel_ct].hotspot_x != -1)
|
||||
hx = ani[cel_ct].hotspot_x;
|
||||
if (ani[cel_ct].hotspot_y != -1)
|
||||
hy = ani[cel_ct].hotspot_y;
|
||||
}
|
||||
|
||||
hx = ani[cel_ct].hotspot_x;
|
||||
hy = ani[cel_ct].hotspot_y;
|
||||
|
||||
FramePtr->DataOffs = (BYTE *)TFB_LoadImage (img[cel_ct]) - (BYTE *)FramePtr;
|
||||
|
||||
tfbimg = (TFB_Image *)((BYTE *)FramePtr + FramePtr->DataOffs);
|
||||
|
||||
Reference in New Issue
Block a user