1
0
mirror of https://github.com/vcmi/vcmi.git synced 2024-12-26 22:57:00 +02:00

Better positioning of the melee cursors.

This commit is contained in:
OnionKnight 2009-08-14 02:13:22 +00:00
parent ccbc2ebf6f
commit ce86e88fa3

View File

@ -47,6 +47,36 @@ void CCursorHandler::draw1()
{ {
x-=16; x-=16;
y-=16; y-=16;
// Properly align the melee attack cursors.
if (mode == 1) {
switch (number) {
case 7: // Bottom left
x -= 6;
y += 16;
break;
case 8: // Left
x -= 16;
y += 11;
break;
case 9: // Top left
x -= 6;
y -= 6;
break;
case 10: // Top right
x += 16;
y -= 6;
break;
case 11: // Right
x += 16;
y += 11;
break;
case 12: // Bottom right
x += 16;
y += 16;
break;
}
}
} }
else if(mode==0 && number>0) else if(mode==0 && number>0)
{ {