Sign Up
Log In
Log In
or
Sign Up
Places
All Projects
Status Monitor
Collapse sidebar
openSUSE:Leap:15.0:Ports
7kaa
gcc6_char_cast.patch
Overview
Repositories
Revisions
Requests
Users
Attributes
Meta
File gcc6_char_cast.patch of Package 7kaa
--- src/OBULLET.cpp | 4 src/OGAMMAIN.cpp | 2 src/OUNITAAT.cpp | 12 - src/OUNITATB.cpp | 512 ++++++++++++++++++++++++------------------------ src/OU_MARI.cpp | 6 5 files changed, 268 insertions(+), 268 deletions(-) Index: a/src/OBULLET.cpp =================================================================== --- a/src/OBULLET.cpp +++ b/src/OBULLET.cpp @@ -38,9 +38,9 @@ const int SCAN_RANGE = SCAN_RADIUS * 2 + // from the closet to the far static char spiral_x[SCAN_RANGE*SCAN_RANGE] = - { 0, 0,-1, 0, 1,-1,-1, 1, 1, 0,-2, 0, 2, -1,-2,-2,-1, 1, 2, 2, 1,-2,-2, 2, 2}; + { 0, 0,(char)-1, 0, 1,(char)-1,(char)-1, 1, 1, 0,(char)-2, 0, 2, (char)-1,(char)-2,(char)-2,(char)-1, 1, 2, 2, 1,(char)-2,(char)-2, 2, 2}; static char spiral_y[SCAN_RANGE*SCAN_RANGE] = - { 0,-1, 0, 1, 0,-1, 1, 1,-1,-2, 0, 2, 0, -2,-1, 1, 2, 2, 1,-1,-2,-2, 2, 2,-2}; + { 0,(char)-1, 0, 1, 0,(char)-1, 1, 1,(char)-1,(char)-2, 0, 2, 0, (char)-2,(char)-1, 1, 2, 2, 1,(char)-1,(char)-2,(char)-2, 2, 2,(char)-2}; //--------- Begin of function Bullet::Bullet -------// Index: a/src/OGAMMAIN.cpp =================================================================== --- a/src/OGAMMAIN.cpp +++ b/src/OGAMMAIN.cpp @@ -671,7 +671,7 @@ void Game::multi_player_menu(int lobbied static char multi_player_option_flag[MULTI_PLAYER_OPTION_COUNT] = { - -1, 1, 1, -1, 1, + (char)-1, 1, 1, (char)-1, 1, }; game_mode = GAME_MULTI_PLAYER; Index: a/src/OUNITAAT.cpp =================================================================== --- a/src/OUNITAAT.cpp +++ b/src/OUNITAAT.cpp @@ -1513,8 +1513,8 @@ void UnitArray::arrange_units_in_group(i // int UnitArray::analyse_surround_location(int targetXLoc, int targetYLoc, int targetWidth, int targetHeight, char mobileType) { - static char xIncreTable[4] = { 1, 0, -1, 0}; - static char yIncreTable[4] = { 0, 1, 0, -1}; + static char xIncreTable[4] = { 1, 0, (char)-1, 0}; + static char yIncreTable[4] = { 0, 1, 0, (char)-1}; err_when(targetWidth<1 || targetWidth>4); Location *locPtr; @@ -1581,10 +1581,10 @@ void UnitArray::check_nearby_location(in #endif debug_result_check(analyseResult, targetWidth, targetHeight); - static char leftXIncreTable[4] = { 1, 0, -1, 0}; - static char leftYIncreTable[4] = { 0, 1, 0, -1}; - static char rightXIncreTable[4] = { -1, 0, 1, 0}; - static char rightYIncreTable[4] = { 0, 1, 0, -1}; + static char leftXIncreTable[4] = { 1, 0, (char)-1, 0}; + static char leftYIncreTable[4] = { 0, 1, 0, (char)-1}; + static char rightXIncreTable[4] = { (char)-1, 0, 1, 0}; + static char rightYIncreTable[4] = { 0, 1, 0, (char)-1}; err_when(targetWidth<1 || targetWidth>4); Location *locPtr; Index: a/src/OUNITATB.cpp =================================================================== --- a/src/OUNITATB.cpp +++ b/src/OUNITATB.cpp @@ -45,294 +45,294 @@ //------------------------------------------------------------------------------// static char attack_x_offset11[ATTACK_DIR][8] // target size 1x1 -= { { -1, -1, -1, 0, 0, 1, 1, 1}, - { -1, 0, -1, 1, -1, 1, 0, 1}, - { 0, 1, -1, 1, -1, 1, -1, 0}, - { 1, 1, 0, 1, -1, 0, -1, -1}, - { 1, 1, 1, 0, 0, -1, -1, -1}, - { 1, 0, 1, -1, 1, -1, 0, -1}, - { 0, -1, 1, -1, 1, -1, 1, 0}, - { -1, -1, 0, -1, 1, 0, 1, 1}}; += { { (char)-1, (char)-1, (char)-1, 0, 0, 1, 1, 1}, + { (char)-1, 0, (char)-1, 1, (char)-1, 1, 0, 1}, + { 0, 1, (char)-1, 1, (char)-1, 1, (char)-1, 0}, + { 1, 1, 0, 1, (char)-1, 0, (char)-1, (char)-1}, + { 1, 1, 1, 0, 0, (char)-1, (char)-1, (char)-1}, + { 1, 0, 1, (char)-1, 1, (char)-1, 0, (char)-1}, + { 0, (char)-1, 1, (char)-1, 1, (char)-1, 1, 0}, + { (char)-1, (char)-1, 0, (char)-1, 1, 0, 1, 1}}; static char attack_x_offset12[ATTACK_DIR][10] // target size 1x2 -= { { -1, -1, -1, -1, 0, 0, 1, 1, 1, 1}, - { -1, -1, 0, -1, 1, -1, 1, 0, 1, 1}, - { 0, 1, -1, 1, -1, 1, -1, 1, -1, 0}, - { 1, 1, 0, 1, -1, 1, -1, 0, -1, -1}, - { 1, 1, 1, 1, 0, 0, -1, -1, -1, -1}, - { 1, 1, 0, 1, -1, 1, -1, 0, -1, -1}, - { 0, -1, 1, -1, 1, -1, 1, -1, 1, 0}, - { -1, -1, 0, -1, 1, -1, 1, 0, 1, 1}}; += { { (char)-1, (char)-1, (char)-1, (char)-1, 0, 0, 1, 1, 1, 1}, + { (char)-1, (char)-1, 0, (char)-1, 1, (char)-1, 1, 0, 1, 1}, + { 0, 1, (char)-1, 1, (char)-1, 1, (char)-1, 1, (char)-1, 0}, + { 1, 1, 0, 1, (char)-1, 1, (char)-1, 0, (char)-1, (char)-1}, + { 1, 1, 1, 1, 0, 0, (char)-1, (char)-1, (char)-1, (char)-1}, + { 1, 1, 0, 1, (char)-1, 1, (char)-1, 0, (char)-1, (char)-1}, + { 0, (char)-1, 1, (char)-1, 1, (char)-1, 1, (char)-1, 1, 0}, + { (char)-1, (char)-1, 0, (char)-1, 1, (char)-1, 1, 0, 1, 1}}; static char attack_x_offset13[ATTACK_DIR][12] // target size 1x3 -= { { -1, -1, -1, -1, -1, 0, 0, 1, 1, 1, 1, 1}, - { -1, -1, 0, -1, 1, -1, 1, -1, 1, 0, 1, 1}, - { 0, 1, -1, 1, -1, 1, -1, 1, -1, 1, -1, 0}, - { 1, 1, 0, 1, -1, 1, -1, 1, -1, 0, -1, -1}, - { 1, 1, 1, 1, 1, 0, 0, -1, -1, -1, -1, -1}, - { 1, 1, 0, 1, -1, 1, -1, 1, -1, 0, -1, -1}, - { 0, -1, 1, -1, 1, -1, 1, -1, 1, -1, 1, 0}, - { -1, -1, 0, -1, 1, -1, 1, -1, 1, 0, 1, 1}}; += { { (char)-1, (char)-1, (char)-1, (char)-1, (char)-1, 0, 0, 1, 1, 1, 1, 1}, + { (char)-1, (char)-1, 0, (char)-1, 1, (char)-1, 1, (char)-1, 1, 0, 1, 1}, + { 0, 1, (char)-1, 1, (char)-1, 1, (char)-1, 1, (char)-1, 1, (char)-1, 0}, + { 1, 1, 0, 1, (char)-1, 1, (char)-1, 1, (char)-1, 0, (char)-1, (char)-1}, + { 1, 1, 1, 1, 1, 0, 0, (char)-1, (char)-1, (char)-1, (char)-1, (char)-1}, + { 1, 1, 0, 1, (char)-1, 1, (char)-1, 1, (char)-1, 0, (char)-1, (char)-1}, + { 0, (char)-1, 1, (char)-1, 1, (char)-1, 1, (char)-1, 1, (char)-1, 1, 0}, + { (char)-1, (char)-1, 0, (char)-1, 1, (char)-1, 1, (char)-1, 1, 0, 1, 1}}; static char attack_x_offset14[ATTACK_DIR][14] // target size 1x4 -= { { -1, -1, -1, -1, -1, -1, 0, 0, 1, 1, 1, 1, 1, 1}, - { -1, -1, 0, -1, 1, -1, 1, -1, 1, -1, 1, 0, 1, 1}, - { 0, 1, -1, 1, -1, 1, -1, 1, -1, 1, -1, 1, -1, 0}, - { 1, 1, 0, 1, -1, 1, -1, 1, -1, 1, -1, 0, -1, -1}, - { 1, 1, 1, 1, 1, 1, 0, 0, -1, -1, -1, -1, -1, -1}, - { 1, 1, 0, 1, -1, 1, -1, 1, -1, 1, -1, 0, -1, -1}, - { 0, -1, 1, -1, 1, -1, 1, -1, 1, -1, 1, -1, 1, 0}, - { -1, -1, 0, -1, 1, -1, 1, -1, 1, -1, 1, 0, 1, 1}}; += { { (char)-1, (char)-1, (char)-1, (char)-1, (char)-1, (char)-1, 0, 0, 1, 1, 1, 1, 1, 1}, + { (char)-1, (char)-1, 0, (char)-1, 1, (char)-1, 1, (char)-1, 1, (char)-1, 1, 0, 1, 1}, + { 0, 1, (char)-1, 1, (char)-1, 1, (char)-1, 1, (char)-1, 1, (char)-1, 1, (char)-1, 0}, + { 1, 1, 0, 1, (char)-1, 1, (char)-1, 1, (char)-1, 1, (char)-1, 0, (char)-1, (char)-1}, + { 1, 1, 1, 1, 1, 1, 0, 0, (char)-1, (char)-1, (char)-1, (char)-1, (char)-1, (char)-1}, + { 1, 1, 0, 1, (char)-1, 1, (char)-1, 1, (char)-1, 1, (char)-1, 0, (char)-1, (char)-1}, + { 0, (char)-1, 1, (char)-1, 1, (char)-1, 1, (char)-1, 1, (char)-1, 1, (char)-1, 1, 0}, + { (char)-1, (char)-1, 0, (char)-1, 1, (char)-1, 1, (char)-1, 1, (char)-1, 1, 0, 1, 1}}; static char attack_x_offset21[ATTACK_DIR][10] // target size 2x1 -= { { -1, -1, -1, 0, 0, 1, 1, 2, 2, 2}, - { -1, 0, -1, 1, -1, 2, 0, 2, 1, 2}, - { 0, 1, -1, 2, -1, 2, -1, 2, 0, 1}, - { 2, 1, 2, 0, 2, -1, 1, -1, 0, -1}, - { 2, 2, 2, 1, 1, 0, 0, -1, -1, -1}, - { 2, 1, 2, 0, 2, -1, 1, -1, 0, -1}, - { 0, 1, -1, 2, -1, 2, -1, 2, 0, 1}, - { -1, 0, -1, 1, -1, 2, 0, 2, 1, 2}}; += { { (char)-1, (char)-1, (char)-1, 0, 0, 1, 1, 2, 2, 2}, + { (char)-1, 0, (char)-1, 1, (char)-1, 2, 0, 2, 1, 2}, + { 0, 1, (char)-1, 2, (char)-1, 2, (char)-1, 2, 0, 1}, + { 2, 1, 2, 0, 2, (char)-1, 1, (char)-1, 0, (char)-1}, + { 2, 2, 2, 1, 1, 0, 0, (char)-1, (char)-1, (char)-1}, + { 2, 1, 2, 0, 2, (char)-1, 1, (char)-1, 0, (char)-1}, + { 0, 1, (char)-1, 2, (char)-1, 2, (char)-1, 2, 0, 1}, + { (char)-1, 0, (char)-1, 1, (char)-1, 2, 0, 2, 1, 2}}; static char attack_x_offset22[ATTACK_DIR][12] // target size 2x2 -= { { -1, -1, -1, -1, 0, 0, 1, 1, 2, 2, 2, 2}, - { -1, 0, -1, 1, -1, 2, -1, 2, 0, 2, 1, 2}, - { 0, 1, -1, 2, -1, 2, -1, 2, -1, 2, 0, 1}, - { 2, 2, 1, 2, 0, 2, -1, 1, -1, 0, -1, -1}, - { 2, 2, 2, 2, 1, 1, 0, 0, -1, -1, -1, -1}, - { 2, 1, 2, 0, 2, -1, 2, -1, 1, -1, 0, -1}, - { 1, 0, 2, -1, 2, -1, 2, -1, 2, -1, 1, 0}, - { -1, -1, 0, -1, 1, -1, 2, 0, 2, 1, 2, 2}}; += { { (char)-1, (char)-1, (char)-1, (char)-1, 0, 0, 1, 1, 2, 2, 2, 2}, + { (char)-1, 0, (char)-1, 1, (char)-1, 2, (char)-1, 2, 0, 2, 1, 2}, + { 0, 1, (char)-1, 2, (char)-1, 2, (char)-1, 2, (char)-1, 2, 0, 1}, + { 2, 2, 1, 2, 0, 2, (char)-1, 1, (char)-1, 0, (char)-1, (char)-1}, + { 2, 2, 2, 2, 1, 1, 0, 0, (char)-1, (char)-1, (char)-1, (char)-1}, + { 2, 1, 2, 0, 2, (char)-1, 2, (char)-1, 1, (char)-1, 0, (char)-1}, + { 1, 0, 2, (char)-1, 2, (char)-1, 2, (char)-1, 2, (char)-1, 1, 0}, + { (char)-1, (char)-1, 0, (char)-1, 1, (char)-1, 2, 0, 2, 1, 2, 2}}; static char attack_x_offset23[ATTACK_DIR][14] // target size 2x3 -= { { -1, -1, -1, -1, -1, 0, 0, 1, 1, 2, 2, 2, 2, 2}, - { -1, -1, 0, -1, 1, -1, 2, -1, 2, 0, 2, 1, 2, 2}, - { 0, 1, -1, 2, -1, 2, -1, 2, -1, 2, -1, 2, 0, 1}, - { 2, 2, 1, 2, 0, 2, -1, 2, -1, 1, -1, 0, -1, -1}, - { 2, 2, 2, 2, 2, 1, 1, 0, 0, -1, -1, -1, -1, -1}, - { 2, 2, 1, 2, 0, 2, -1, 2, -1, 1, -1, 0, -1, -1}, - { 0, 1, -1, 2, -1, 2, -1, 2, -1, 2, -1, 2, 0, 1}, - { -1, -1, 0, -1, 1, -1, 2, -1, 2, 0, 2, 1, 2, 2}}; += { { (char)-1, (char)-1, (char)-1, (char)-1, (char)-1, 0, 0, 1, 1, 2, 2, 2, 2, 2}, + { (char)-1, (char)-1, 0, (char)-1, 1, (char)-1, 2, (char)-1, 2, 0, 2, 1, 2, 2}, + { 0, 1, (char)-1, 2, (char)-1, 2, (char)-1, 2, (char)-1, 2, (char)-1, 2, 0, 1}, + { 2, 2, 1, 2, 0, 2, (char)-1, 2, (char)-1, 1, (char)-1, 0, (char)-1, (char)-1}, + { 2, 2, 2, 2, 2, 1, 1, 0, 0, (char)-1, (char)-1, (char)-1, (char)-1, (char)-1}, + { 2, 2, 1, 2, 0, 2, (char)-1, 2, (char)-1, 1, (char)-1, 0, (char)-1, (char)-1}, + { 0, 1, (char)-1, 2, (char)-1, 2, (char)-1, 2, (char)-1, 2, (char)-1, 2, 0, 1}, + { (char)-1, (char)-1, 0, (char)-1, 1, (char)-1, 2, (char)-1, 2, 0, 2, 1, 2, 2}}; static char attack_x_offset24[ATTACK_DIR][16] // target size 2x4 -= { { -1, -1, -1, -1, -1, -1, 0, 0, 1, 1, 2, 2, 2, 2, 2, 2}, - { -1, -1, 0, -1, 1, -1, 2, -1, 2, -1, 2, 0, 2, 1, 2, 2}, - { 0, 1, -1, 2, -1, 2, -1, 2, -1, 2, -1, 2, -1, 2, 0, 1}, - { 2, 2, 1, 2, 0, 2, -1, 2, -1, 2, -1, 1, -1, 0, -1, -1}, - { 2, 2, 2, 2, 2, 2, 1, 1, 0, 0, -1, -1, -1, -1, -1, -1}, - { 2, 2, 1, 2, 0, 2, -1, 2, -1, 2, -1, 1, -1, 0, -1, -1}, - { 0, 1, -1, 2, -1, 2, -1, 2, -1, 2, -1, 2, -1, 2, 0, 1}, - { -1, -1, 0, -1, 1, -1, 2, -1, 2, -1, 2, 0, 2, 1, 2, 2}}; += { { (char)-1, (char)-1, (char)-1, (char)-1, (char)-1, (char)-1, 0, 0, 1, 1, 2, 2, 2, 2, 2, 2}, + { (char)-1, (char)-1, 0, (char)-1, 1, (char)-1, 2, (char)-1, 2, (char)-1, 2, 0, 2, 1, 2, 2}, + { 0, 1, (char)-1, 2, (char)-1, 2, (char)-1, 2, (char)-1, 2, (char)-1, 2, (char)-1, 2, 0, 1}, + { 2, 2, 1, 2, 0, 2, (char)-1, 2, (char)-1, 2, (char)-1, 1, (char)-1, 0, (char)-1, (char)-1}, + { 2, 2, 2, 2, 2, 2, 1, 1, 0, 0, (char)-1, (char)-1, (char)-1, (char)-1, (char)-1, (char)-1}, + { 2, 2, 1, 2, 0, 2, (char)-1, 2, (char)-1, 2, (char)-1, 1, (char)-1, 0, (char)-1, (char)-1}, + { 0, 1, (char)-1, 2, (char)-1, 2, (char)-1, 2, (char)-1, 2, (char)-1, 2, (char)-1, 2, 0, 1}, + { (char)-1, (char)-1, 0, (char)-1, 1, (char)-1, 2, (char)-1, 2, (char)-1, 2, 0, 2, 1, 2, 2}}; static char attack_x_offset31[ATTACK_DIR][12] // target size 3x1 -= { { -1, -1, -1, 0, 0, 1, 1, 2, 2, 3, 3, 3}, - { -1, 0, -1, 1, -1, 2, 0, 3, 1, 3, 2, 3}, - { 1, 2, 0, 3, -1, 3, -1, 3, -1, 2, 0, 1}, - { 3, 2, 3, 1, 3, 0, 2, -1, 1, -1, 0, -1}, - { 3, 3, 3, 2, 2, 1, 1, 0, 0, -1, -1, -1}, - { 3, 2, 3, 1, 3, 0, 2, -1, 1, -1, 0, -1}, - { 1, 0, 2, -1, 3, -1, 3, -1, 3, 0, 2, 1}, - { -1, 0, -1, 1, -1, 2, 0, 3, 1, 3, 2, 3}}; += { { (char)-1, (char)-1, (char)-1, 0, 0, 1, 1, 2, 2, 3, 3, 3}, + { (char)-1, 0, (char)-1, 1, (char)-1, 2, 0, 3, 1, 3, 2, 3}, + { 1, 2, 0, 3, (char)-1, 3, (char)-1, 3, (char)-1, 2, 0, 1}, + { 3, 2, 3, 1, 3, 0, 2, (char)-1, 1, (char)-1, 0, (char)-1}, + { 3, 3, 3, 2, 2, 1, 1, 0, 0, (char)-1, (char)-1, (char)-1}, + { 3, 2, 3, 1, 3, 0, 2, (char)-1, 1, (char)-1, 0, (char)-1}, + { 1, 0, 2, (char)-1, 3, (char)-1, 3, (char)-1, 3, 0, 2, 1}, + { (char)-1, 0, (char)-1, 1, (char)-1, 2, 0, 3, 1, 3, 2, 3}}; static char attack_x_offset32[ATTACK_DIR][14] // target size 3x2 -= { { -1, -1, -1, -1, 0, 0, 1, 1, 2, 2, 3, 3, 3, 3}, - { -1, 0, -1, 1, -1, 2, -1, 3, 0, 3, 1, 3, 2, 3}, - { 1, 2, 0, 3, -1, 3, -1, 3, -1, 3, -1, 2, 0, 1}, - { 3, 2, 3, 1, 3, 0, 3, -1, 2, -1, 1, -1, 0, -1}, - { 3, 3, 3, 3, 2, 2, 1, 1, 0, 0, -1, -1, -1, -1}, - { 3, 2, 3, 1, 3, 0, 3, -1, 2, -1, 1, -1, 0, -1}, - { 1, 0, 2, -1, 3, -1, 3, -1, 3, -1, 3, 0, 2, 1}, - { -1, 0, -1, 1, -1, 2, -1, 3, 0, 3, 1, 3, 2, 3}}; += { { (char)-1, (char)-1, (char)-1, (char)-1, 0, 0, 1, 1, 2, 2, 3, 3, 3, 3}, + { (char)-1, 0, (char)-1, 1, (char)-1, 2, (char)-1, 3, 0, 3, 1, 3, 2, 3}, + { 1, 2, 0, 3, (char)-1, 3, (char)-1, 3, (char)-1, 3, (char)-1, 2, 0, 1}, + { 3, 2, 3, 1, 3, 0, 3, (char)-1, 2, (char)-1, 1, (char)-1, 0, (char)-1}, + { 3, 3, 3, 3, 2, 2, 1, 1, 0, 0, (char)-1, (char)-1, (char)-1, (char)-1}, + { 3, 2, 3, 1, 3, 0, 3, (char)-1, 2, (char)-1, 1, (char)-1, 0, (char)-1}, + { 1, 0, 2, (char)-1, 3, (char)-1, 3, (char)-1, 3, (char)-1, 3, 0, 2, 1}, + { (char)-1, 0, (char)-1, 1, (char)-1, 2, (char)-1, 3, 0, 3, 1, 3, 2, 3}}; static char attack_x_offset33[ATTACK_DIR][16] // target size 3x3 -= { { -1, -1, -1, -1, -1, 0, 0, 1, 1, 2, 2, 3, 3, 3, 3, 3}, - { -1, 0, -1, 1, -1, 2, -1, 3, -1, 3, 0, 3, 1, 3, 2, 3}, - { 1, 2, 0, 3, -1, 3, -1, 3, -1, 3, -1, 3, -1, 2, 0, 1}, - { 3, 3, 2, 3, 1, 3, 0, 3, -1, 2, -1, 1, -1, 0, -1, -1}, - { 3, 3, 3, 3, 3, 2, 2, 1, 1, 0, 0, -1, -1, -1, -1, -1}, - { 3, 2, 3, 1, 3, 0, 3, -1, 3, -1, 2, -1, 1, -1, 0, -1}, - { 1, 0, 2, -1, 3, -1, 3, -1, 3, -1, 3, -1, 3, 0, 2, 1}, - { -1, -1, 0, -1, 1, -1, 2, -1, 3, 0, 3, 1, 3, 2, 3, 3}}; += { { (char)-1, (char)-1, (char)-1, (char)-1, (char)-1, 0, 0, 1, 1, 2, 2, 3, 3, 3, 3, 3}, + { (char)-1, 0, (char)-1, 1, (char)-1, 2, (char)-1, 3, (char)-1, 3, 0, 3, 1, 3, 2, 3}, + { 1, 2, 0, 3, (char)-1, 3, (char)-1, 3, (char)-1, 3, (char)-1, 3, (char)-1, 2, 0, 1}, + { 3, 3, 2, 3, 1, 3, 0, 3, (char)-1, 2, (char)-1, 1, (char)-1, 0, (char)-1, (char)-1}, + { 3, 3, 3, 3, 3, 2, 2, 1, 1, 0, 0, (char)-1, (char)-1, (char)-1, (char)-1, (char)-1}, + { 3, 2, 3, 1, 3, 0, 3, (char)-1, 3, (char)-1, 2, (char)-1, 1, (char)-1, 0, (char)-1}, + { 1, 0, 2, (char)-1, 3, (char)-1, 3, (char)-1, 3, (char)-1, 3, (char)-1, 3, 0, 2, 1}, + { (char)-1, (char)-1, 0, (char)-1, 1, (char)-1, 2, (char)-1, 3, 0, 3, 1, 3, 2, 3, 3}}; static char attack_x_offset34[ATTACK_DIR][18] // target size 3x4 -= { { -1, -1, -1, -1, -1, -1, 0, 0, 1, 1, 2, 2, 3, 3, 3, 3, 3, 3}, - { -1, -1, 0, -1, 1, -1, 2, -1, 3, -1, 3, 0, 3, 1, 3, 2, 3, 3}, - { 1, 2, 0, 3, -1, 3, -1, 3, -1, 3, -1, 3, -1, 3, -1, 2, 0, 1}, - { 3, 3, 2, 3, 1, 3, 0, 3, -1, 3, -1, 2, -1, 1, -1, 0, -1, -1}, - { 3, 3, 3, 3, 3, 3, 2, 2, 1, 1, 0, 0, -1, -1, -1, -1, -1, -1}, - { 3, 3, 2, 3, 1, 3, 0, 3, -1, 3, -1, 2, -1, 1, -1, 0, -1, -1}, - { 1, 0, 2, -1, 3, -1, 3, -1, 3, -1, 3, -1, 3, -1, 3, 0, 2, 1}, - { -1, -1, 0, -1, 1, -1, 2, -1, 3, -1, 3, 0, 3, 1, 3, 2, 3, 3}}; += { { (char)-1, (char)-1, (char)-1, (char)-1, (char)-1, (char)-1, 0, 0, 1, 1, 2, 2, 3, 3, 3, 3, 3, 3}, + { (char)-1, (char)-1, 0, (char)-1, 1, (char)-1, 2, (char)-1, 3, (char)-1, 3, 0, 3, 1, 3, 2, 3, 3}, + { 1, 2, 0, 3, (char)-1, 3, (char)-1, 3, (char)-1, 3, (char)-1, 3, (char)-1, 3, (char)-1, 2, 0, 1}, + { 3, 3, 2, 3, 1, 3, 0, 3, (char)-1, 3, (char)-1, 2, (char)-1, 1, (char)-1, 0, (char)-1, (char)-1}, + { 3, 3, 3, 3, 3, 3, 2, 2, 1, 1, 0, 0, (char)-1, (char)-1, (char)-1, (char)-1, (char)-1, (char)-1}, + { 3, 3, 2, 3, 1, 3, 0, 3, (char)-1, 3, (char)-1, 2, (char)-1, 1, (char)-1, 0, (char)-1, (char)-1}, + { 1, 0, 2, (char)-1, 3, (char)-1, 3, (char)-1, 3, (char)-1, 3, (char)-1, 3, (char)-1, 3, 0, 2, 1}, + { (char)-1, (char)-1, 0, (char)-1, 1, (char)-1, 2, (char)-1, 3, (char)-1, 3, 0, 3, 1, 3, 2, 3, 3}}; static char attack_x_offset41[ATTACK_DIR][14] // target size 4x1 -= { { -1, -1, -1, 0, 0, 1, 1, 2, 2, 3, 3, 4, 4, 4}, - { -1, 0, -1, 1, -1, 2, 0, 3, 1, 4, 2, 4, 3, 4}, - { 1, 2, 0, 3, -1, 4, -1, 4, -1, 4, 0, 3, 1, 2}, - { 4, 3, 4, 2, 4, 1, 3, 0, 2, -1, 1, -1, 0, -1}, - { 4, 4, 4, 3, 3, 2, 2, 1, 1, 0, 0, -1, -1, -1}, - { 4, 3, 4, 2, 4, 1, 3, 0, 2, -1, 1, -1, 0, -1}, - { 1, 2, 0, 3, -1, 4, -1, 4, -1, 4, 0, 3, 1, 2}, - { -1, 0, -1, 1, -1, 2, 0, 3, 1, 4, 2, 4, 3, 4}}; += { { (char)-1, (char)-1, (char)-1, 0, 0, 1, 1, 2, 2, 3, 3, 4, 4, 4}, + { (char)-1, 0, (char)-1, 1, (char)-1, 2, 0, 3, 1, 4, 2, 4, 3, 4}, + { 1, 2, 0, 3, (char)-1, 4, (char)-1, 4, (char)-1, 4, 0, 3, 1, 2}, + { 4, 3, 4, 2, 4, 1, 3, 0, 2, (char)-1, 1, (char)-1, 0, (char)-1}, + { 4, 4, 4, 3, 3, 2, 2, 1, 1, 0, 0, (char)-1, (char)-1, (char)-1}, + { 4, 3, 4, 2, 4, 1, 3, 0, 2, (char)-1, 1, (char)-1, 0, (char)-1}, + { 1, 2, 0, 3, (char)-1, 4, (char)-1, 4, (char)-1, 4, 0, 3, 1, 2}, + { (char)-1, 0, (char)-1, 1, (char)-1, 2, 0, 3, 1, 4, 2, 4, 3, 4}}; static char attack_x_offset42[ATTACK_DIR][16] // target size 4x2 -= { { -1, -1, -1, -1, 0, 0, 1, 1, 2, 2, 3, 3, 4, 4, 4, 4}, - { -1, 0, -1, 1, -1, 2, -1, 3, 0, 4, 1, 4, 2, 4, 3, 4}, - { 1, 2, 0, 3, -1, 4, -1, 4, -1, 4, -1, 4, 0, 3, 1, 2}, - { 4, 3, 4, 2, 4, 1, 4, 0, 3, -1, 2, -1, 1, -1, 0, -1}, - { 4, 4, 4, 4, 3, 3, 2, 2, 1, 1, 0, 0, -1, -1, -1, -1}, - { 4, 3, 4, 2, 4, 1, 4, 0, 3, -1, 2, -1, 1, -1, 0, -1}, - { 1, 2, 0, 3, -1, 4, -1, 4, -1, 4, -1, 4, 0, 3, 1, 2}, - { -1, 0, -1, 1, -1, 2, -1, 3, 0, 4, 1, 4, 2, 4, 3, 4}}; += { { (char)-1, (char)-1, (char)-1, (char)-1, 0, 0, 1, 1, 2, 2, 3, 3, 4, 4, 4, 4}, + { (char)-1, 0, (char)-1, 1, (char)-1, 2, (char)-1, 3, 0, 4, 1, 4, 2, 4, 3, 4}, + { 1, 2, 0, 3, (char)-1, 4, (char)-1, 4, (char)-1, 4, (char)-1, 4, 0, 3, 1, 2}, + { 4, 3, 4, 2, 4, 1, 4, 0, 3, (char)-1, 2, (char)-1, 1, (char)-1, 0, (char)-1}, + { 4, 4, 4, 4, 3, 3, 2, 2, 1, 1, 0, 0, (char)-1, (char)-1, (char)-1, (char)-1}, + { 4, 3, 4, 2, 4, 1, 4, 0, 3, (char)-1, 2, (char)-1, 1, (char)-1, 0, (char)-1}, + { 1, 2, 0, 3, (char)-1, 4, (char)-1, 4, (char)-1, 4, (char)-1, 4, 0, 3, 1, 2}, + { (char)-1, 0, (char)-1, 1, (char)-1, 2, (char)-1, 3, 0, 4, 1, 4, 2, 4, 3, 4}}; static char attack_x_offset43[ATTACK_DIR][18] // target size 4x3 -= { { -1, -1, -1, -1, -1, 0, 0, 1, 1, 2, 2, 3, 3, 4, 4, 4, 4, 4}, - { -1, 0, -1, 1, -1, 2, -1, 3, -1, 4, 0, 4, 1, 4, 2, 4, 3, 4}, - { 1, 2, 0, 3, -1, 4, -1, 4, -1, 4, -1, 4, -1, 4, 0, 3, 1, 2}, - { 4, 3, 4, 2, 4, 1, 4, 0, 4, -1, 3, -1, 2, -1, 1, -1, 0, -1}, - { 4, 4, 4, 4, 4, 3, 3, 2, 2, 1, 1, 0, 0, -1, -1, -1, -1, -1}, - { 4, 3, 4, 2, 4, 1, 4, 0, 4, -1, 3, -1, 2, -1, 1, -1, 0, -1}, - { 1, 2, 0, 3, -1, 4, -1, 4, -1, 4, -1, 4, -1, 4, 0, 3, 1, 2}, - { -1, 0, -1, 1, -1, 2, -1, 3, -1, 4, 0, 4, 1, 4, 2, 4, 3, 4}}; += { { (char)-1, (char)-1, (char)-1, (char)-1, (char)-1, 0, 0, 1, 1, 2, 2, 3, 3, 4, 4, 4, 4, 4}, + { (char)-1, 0, (char)-1, 1, (char)-1, 2, (char)-1, 3, (char)-1, 4, 0, 4, 1, 4, 2, 4, 3, 4}, + { 1, 2, 0, 3, (char)-1, 4, (char)-1, 4, (char)-1, 4, (char)-1, 4, (char)-1, 4, 0, 3, 1, 2}, + { 4, 3, 4, 2, 4, 1, 4, 0, 4, (char)-1, 3, (char)-1, 2, (char)-1, 1, (char)-1, 0, (char)-1}, + { 4, 4, 4, 4, 4, 3, 3, 2, 2, 1, 1, 0, 0, (char)-1, (char)-1, (char)-1, (char)-1, (char)-1}, + { 4, 3, 4, 2, 4, 1, 4, 0, 4, (char)-1, 3, (char)-1, 2, (char)-1, 1, (char)-1, 0, (char)-1}, + { 1, 2, 0, 3, (char)-1, 4, (char)-1, 4, (char)-1, 4, (char)-1, 4, (char)-1, 4, 0, 3, 1, 2}, + { (char)-1, 0, (char)-1, 1, (char)-1, 2, (char)-1, 3, (char)-1, 4, 0, 4, 1, 4, 2, 4, 3, 4}}; static char attack_x_offset44[ATTACK_DIR][20] // target size 4x4 -= { { -1, -1, -1, -1, -1, -1, 0, 0, 1, 1, 2, 2, 3, 3, 4, 4, 4, 4, 4, 4}, - { -1, 0, -1, 1, -1, 2, -1, 3, -1, 4, -1, 4, 0, 4, 1, 4, 2, 4, 3, 4}, - { 1, 2, 0, 3, -1, 4, -1, 4, -1, 4, -1, 4, -1, 4, -1, 4, 0, 3, 1, 2}, - { 4, 4, 3, 4, 2, 4, 1, 4, 0, 4, -1, 3, -1, 2, -1, 1, -1, 0, -1, -1}, - { 4, 4, 4, 4, 4, 4, 3, 3, 2, 2, 1, 1, 0, 0, -1, -1, -1, -1, -1, -1}, - { 4, 3, 4, 2, 4, 1, 4, 0, 4, -1, 4, -1, 3, -1, 2, -1, 1, -1, 0, -1}, - { 2, 1, 3, 0, 4, -1, 4, -1, 4, -1, 4, -1, 4, -1, 4, -1, 3, 0, 2, 1}, - { -1, -1, 0, -1, 1, -1, 2, -1, 3, -1, 4, 0, 4, 1, 4, 2, 4, 3, 4, 4}}; += { { (char)-1, (char)-1, (char)-1, (char)-1, (char)-1, (char)-1, 0, 0, 1, 1, 2, 2, 3, 3, 4, 4, 4, 4, 4, 4}, + { (char)-1, 0, (char)-1, 1, (char)-1, 2, (char)-1, 3, (char)-1, 4, (char)-1, 4, 0, 4, 1, 4, 2, 4, 3, 4}, + { 1, 2, 0, 3, (char)-1, 4, (char)-1, 4, (char)-1, 4, (char)-1, 4, (char)-1, 4, (char)-1, 4, 0, 3, 1, 2}, + { 4, 4, 3, 4, 2, 4, 1, 4, 0, 4, (char)-1, 3, (char)-1, 2, (char)-1, 1, (char)-1, 0, (char)-1, (char)-1}, + { 4, 4, 4, 4, 4, 4, 3, 3, 2, 2, 1, 1, 0, 0, (char)-1, (char)-1, (char)-1, (char)-1, (char)-1, (char)-1}, + { 4, 3, 4, 2, 4, 1, 4, 0, 4, (char)-1, 4, (char)-1, 3, (char)-1, 2, (char)-1, 1, (char)-1, 0, (char)-1}, + { 2, 1, 3, 0, 4, (char)-1, 4, (char)-1, 4, (char)-1, 4, (char)-1, 4, (char)-1, 4, (char)-1, 3, 0, 2, 1}, + { (char)-1, (char)-1, 0, (char)-1, 1, (char)-1, 2, (char)-1, 3, (char)-1, 4, 0, 4, 1, 4, 2, 4, 3, 4, 4}}; static char attack_y_offset11[ATTACK_DIR][8] // target size 1x1 -= { { 0, 1, -1, 1, -1, 1, -1, 0}, - { 1, 1, 0, 1, -1, 0, -1, -1}, - { 1, 1, 1, 0, 0, -1, -1, -1}, - { 1, 0, 1, -1, 1, -1, 0, -1}, - { 0, -1, 1, -1, 1, -1, 1, 0}, - { -1, -1, 0, -1, 1, 0, 1, 1}, - { -1, -1, -1, 0, 0, 1, 1, 1}, - { -1, 0, -1, 1, -1, 1, 0, 1}}; += { { 0, 1, (char)-1, 1, (char)-1, 1, (char)-1, 0}, + { 1, 1, 0, 1, (char)-1, 0, (char)-1, (char)-1}, + { 1, 1, 1, 0, 0, (char)-1, (char)-1, (char)-1}, + { 1, 0, 1, (char)-1, 1, (char)-1, 0, (char)-1}, + { 0, (char)-1, 1, (char)-1, 1, (char)-1, 1, 0}, + { (char)-1, (char)-1, 0, (char)-1, 1, 0, 1, 1}, + { (char)-1, (char)-1, (char)-1, 0, 0, 1, 1, 1}, + { (char)-1, 0, (char)-1, 1, (char)-1, 1, 0, 1}}; static char attack_y_offset12[ATTACK_DIR][10] // target size 1x2 -= { { 0, 1, -1, 2, -1, 2, -1, 2, 0, 1}, - { 2, 1, 2, 0, 2, -1, 1, -1, 0, -1}, - { 2, 2, 2, 1, 1, 0, 0, -1, -1, -1}, - { 2, 1, 2, 0, 2, -1, 1, -1, 0, -1}, - { 0, 1, -1, 2, -1, 2, -1, 2, 0, 1}, - { -1, 0, -1, 1, -1, 2, 0, 2, 1, 2}, - { -1, -1, -1, 0, 0, 1, 1, 2, 2, 2}, - { -1, 0, -1, 1, -1, 2, 0, 2, 1, 2}}; += { { 0, 1, (char)-1, 2, (char)-1, 2, (char)-1, 2, 0, 1}, + { 2, 1, 2, 0, 2, (char)-1, 1, (char)-1, 0, (char)-1}, + { 2, 2, 2, 1, 1, 0, 0, (char)-1, (char)-1, (char)-1}, + { 2, 1, 2, 0, 2, (char)-1, 1, (char)-1, 0, (char)-1}, + { 0, 1, (char)-1, 2, (char)-1, 2, (char)-1, 2, 0, 1}, + { (char)-1, 0, (char)-1, 1, (char)-1, 2, 0, 2, 1, 2}, + { (char)-1, (char)-1, (char)-1, 0, 0, 1, 1, 2, 2, 2}, + { (char)-1, 0, (char)-1, 1, (char)-1, 2, 0, 2, 1, 2}}; static char attack_y_offset13[ATTACK_DIR][12] // target size 1x3 -= { { 1, 2, 0, 3, -1, 3, -1, 3, -1, 2, 0, 1}, - { 3, 2, 3, 1, 3, 0, 2, -1, 1, -1, 0, -1}, - { 3, 3, 3, 2, 2, 1, 1, 0, 0, -1, -1, -1}, - { 3, 2, 3, 1, 3, 0, 2, -1, 1, -1, 0, -1}, - { 1, 0, 2, -1, 3, -1, 3, -1, 3, 0, 2, 1}, - { -1, 0, -1, 1, -1, 2, 0, 3, 1, 3, 2, 3}, - { -1, -1, -1, 0, 0, 1, 1, 2, 2, 3, 3, 3}, - { -1, 0, -1, 1, -1, 2, 0, 3, 1, 3, 2, 3}}; += { { 1, 2, 0, 3, (char)-1, 3, (char)-1, 3, (char)-1, 2, 0, 1}, + { 3, 2, 3, 1, 3, 0, 2, (char)-1, 1, (char)-1, 0, (char)-1}, + { 3, 3, 3, 2, 2, 1, 1, 0, 0, (char)-1, (char)-1, (char)-1}, + { 3, 2, 3, 1, 3, 0, 2, (char)-1, 1, (char)-1, 0, (char)-1}, + { 1, 0, 2, (char)-1, 3, (char)-1, 3, (char)-1, 3, 0, 2, 1}, + { (char)-1, 0, (char)-1, 1, (char)-1, 2, 0, 3, 1, 3, 2, 3}, + { (char)-1, (char)-1, (char)-1, 0, 0, 1, 1, 2, 2, 3, 3, 3}, + { (char)-1, 0, (char)-1, 1, (char)-1, 2, 0, 3, 1, 3, 2, 3}}; static char attack_y_offset14[ATTACK_DIR][14] // target size 1x4 -= { { 1, 2, 0, 3, -1, 4, -1, 4, -1, 4, 0, 3, 1, 2}, - { 4, 3, 4, 2, 4, 1, 3, 0, 2, -1, 1, -1, 0, -1}, - { 4, 4, 4, 3, 3, 2, 2, 1, 1, 0, 0, -1, -1, -1}, - { 4, 3, 4, 2, 4, 1, 3, 0, 2, -1, 1, -1, 0, -1}, - { 1, 2, 0, 3, -1, 4, -1, 4, -1, 4, 0, 3, 1, 2}, - { -1, 0, -1, 1, -1, 2, 0, 3, 1, 4, 2, 4, 3, 4}, - { -1, -1, -1, 0, 0, 1, 1, 2, 2, 3, 3, 4, 4, 4}, - { -1, 0, -1, 1, -1, 2, 0, 3, 1, 4, 2, 4, 3, 4}}; += { { 1, 2, 0, 3, (char)-1, 4, (char)-1, 4, (char)-1, 4, 0, 3, 1, 2}, + { 4, 3, 4, 2, 4, 1, 3, 0, 2, (char)-1, 1, (char)-1, 0, (char)-1}, + { 4, 4, 4, 3, 3, 2, 2, 1, 1, 0, 0, (char)-1, (char)-1, (char)-1}, + { 4, 3, 4, 2, 4, 1, 3, 0, 2, (char)-1, 1, (char)-1, 0, (char)-1}, + { 1, 2, 0, 3, (char)-1, 4, (char)-1, 4, (char)-1, 4, 0, 3, 1, 2}, + { (char)-1, 0, (char)-1, 1, (char)-1, 2, 0, 3, 1, 4, 2, 4, 3, 4}, + { (char)-1, (char)-1, (char)-1, 0, 0, 1, 1, 2, 2, 3, 3, 4, 4, 4}, + { (char)-1, 0, (char)-1, 1, (char)-1, 2, 0, 3, 1, 4, 2, 4, 3, 4}}; static char attack_y_offset21[ATTACK_DIR][10] // target size 2x1 -= { { 0, 1, -1, 1, -1, 1, -1, 1, -1, 0}, - { 1, 1, 0, 1, -1, 1, -1, 0, -1, -1}, - { 1, 1, 1, 1, 0, 0, -1, -1, -1, -1}, - { 1, 1, 0, 1, -1, 1, -1, 0, -1, -1}, - { 0, -1, 1, -1, 1, -1, 1, -1, 1, 0}, - { -1, -1, 0, -1, 1, -1, 1, 0, 1, 1}, - { -1, -1, -1, -1, 0, 0, 1, 1, 1, 1}, - { -1, -1, 0, -1, 1, -1, 1, 0, 1, 1}}; += { { 0, 1, (char)-1, 1, (char)-1, 1, (char)-1, 1, (char)-1, 0}, + { 1, 1, 0, 1, (char)-1, 1, (char)-1, 0, (char)-1, (char)-1}, + { 1, 1, 1, 1, 0, 0, (char)-1, (char)-1, (char)-1, (char)-1}, + { 1, 1, 0, 1, (char)-1, 1, (char)-1, 0, (char)-1, (char)-1}, + { 0, (char)-1, 1, (char)-1, 1, (char)-1, 1, (char)-1, 1, 0}, + { (char)-1, (char)-1, 0, (char)-1, 1, (char)-1, 1, 0, 1, 1}, + { (char)-1, (char)-1, (char)-1, (char)-1, 0, 0, 1, 1, 1, 1}, + { (char)-1, (char)-1, 0, (char)-1, 1, (char)-1, 1, 0, 1, 1}}; static char attack_y_offset22[ATTACK_DIR][12] // target size 2x2 -= { { 0, 1, -1, 2, -1, 2, -1, 2, -1, 2, 0, 1}, - { 2, 2, 1, 2, 0, 2, -1, 1, -1, 0, -1, -1}, - { 2, 2, 2, 2, 1, 1, 0, 0, -1, -1, -1, -1}, - { 2, 1, 2, 0, 2, -1, 2, -1, 1, -1, 0, -1}, - { 1, 0, 2, -1, 2, -1, 2, -1, 2, -1, 1, 0}, - { -1, -1, 0, -1, 1, -1, 2, 0, 2, 1, 2, 2}, - { -1, -1, -1, -1, 0, 0, 1, 1, 2, 2, 2, 2}, - { -1, 0, -1, 1, -1, 2, -1, 2, 0, 2, 1, 2}}; += { { 0, 1, (char)-1, 2, (char)-1, 2, (char)-1, 2, (char)-1, 2, 0, 1}, + { 2, 2, 1, 2, 0, 2, (char)-1, 1, (char)-1, 0, (char)-1, (char)-1}, + { 2, 2, 2, 2, 1, 1, 0, 0, (char)-1, (char)-1, (char)-1, (char)-1}, + { 2, 1, 2, 0, 2, (char)-1, 2, (char)-1, 1, (char)-1, 0, (char)-1}, + { 1, 0, 2, (char)-1, 2, (char)-1, 2, (char)-1, 2, (char)-1, 1, 0}, + { (char)-1, (char)-1, 0, (char)-1, 1, (char)-1, 2, 0, 2, 1, 2, 2}, + { (char)-1, (char)-1, (char)-1, (char)-1, 0, 0, 1, 1, 2, 2, 2, 2}, + { (char)-1, 0, (char)-1, 1, (char)-1, 2, (char)-1, 2, 0, 2, 1, 2}}; static char attack_y_offset23[ATTACK_DIR][14] // target size 2x3 -= { { 1, 2, 0, 3, -1, 3, -1, 3, -1, 3, -1, 2, 0, 1}, - { 3, 2, 3, 1, 3, 0, 3, -1, 2, -1, 1, -1, 0, -1}, - { 3, 3, 3, 3, 2, 2, 1, 1, 0, 0, -1, -1, -1, -1}, - { 3, 2, 3, 1, 3, 0, 3, -1, 2, -1, 1, -1, 0, -1}, - { 1, 0, 2, -1, 3, -1, 3, -1, 3, -1, 3, 0, 2, 1}, - { -1, 0, -1, 1, -1, 2, -1, 3, 0, 3, 1, 3, 2, 3}, - { -1, -1, -1, -1, 0, 0, 1, 1, 2, 2, 3, 3, 3, 3}, - { -1, 0, -1, 1, -1, 2, -1, 3, 0, 3, 1, 3, 2, 3}}; += { { 1, 2, 0, 3, (char)-1, 3, (char)-1, 3, (char)-1, 3, (char)-1, 2, 0, 1}, + { 3, 2, 3, 1, 3, 0, 3, (char)-1, 2, (char)-1, 1, (char)-1, 0, (char)-1}, + { 3, 3, 3, 3, 2, 2, 1, 1, 0, 0, (char)-1, (char)-1, (char)-1, (char)-1}, + { 3, 2, 3, 1, 3, 0, 3, (char)-1, 2, (char)-1, 1, (char)-1, 0, (char)-1}, + { 1, 0, 2, (char)-1, 3, (char)-1, 3, (char)-1, 3, (char)-1, 3, 0, 2, 1}, + { (char)-1, 0, (char)-1, 1, (char)-1, 2, (char)-1, 3, 0, 3, 1, 3, 2, 3}, + { (char)-1, (char)-1, (char)-1, (char)-1, 0, 0, 1, 1, 2, 2, 3, 3, 3, 3}, + { (char)-1, 0, (char)-1, 1, (char)-1, 2, (char)-1, 3, 0, 3, 1, 3, 2, 3}}; static char attack_y_offset24[ATTACK_DIR][16] // target size 2x4 -= { { 1, 2, 0, 3, -1, 4, -1, 4, -1, 4, -1, 4, 0, 3, 1, 2}, - { 4, 3, 4, 2, 4, 1, 4, 0, 3, -1, 2, -1, 1, -1, 0, -1}, - { 4, 4, 4, 4, 3, 3, 2, 2, 1, 1, 0, 0, -1, -1, -1, -1}, - { 4, 3, 4, 2, 4, 1, 4, 0, 3, -1, 2, -1, 1, -1, 0, -1}, - { 1, 2, 0, 3, -1, 4, -1, 4, -1, 4, -1, 4, 0, 3, 1, 2}, - { -1, 0, -1, 1, -1, 2, -1, 3, 0, 4, 1, 4, 2, 4, 3, 4}, - { -1, -1, -1, -1, 0, 0, 1, 1, 2, 2, 3, 3, 4, 4, 4, 4}, - { -1, 0, -1, 1, -1, 2, -1, 3, 0, 4, 1, 4, 2, 4, 3, 4}}; += { { 1, 2, 0, 3, (char)-1, 4, (char)-1, 4, (char)-1, 4, (char)-1, 4, 0, 3, 1, 2}, + { 4, 3, 4, 2, 4, 1, 4, 0, 3, (char)-1, 2, (char)-1, 1, (char)-1, 0, (char)-1}, + { 4, 4, 4, 4, 3, 3, 2, 2, 1, 1, 0, 0, (char)-1, (char)-1, (char)-1, (char)-1}, + { 4, 3, 4, 2, 4, 1, 4, 0, 3, (char)-1, 2, (char)-1, 1, (char)-1, 0, (char)-1}, + { 1, 2, 0, 3, (char)-1, 4, (char)-1, 4, (char)-1, 4, (char)-1, 4, 0, 3, 1, 2}, + { (char)-1, 0, (char)-1, 1, (char)-1, 2, (char)-1, 3, 0, 4, 1, 4, 2, 4, 3, 4}, + { (char)-1, (char)-1, (char)-1, (char)-1, 0, 0, 1, 1, 2, 2, 3, 3, 4, 4, 4, 4}, + { (char)-1, 0, (char)-1, 1, (char)-1, 2, (char)-1, 3, 0, 4, 1, 4, 2, 4, 3, 4}}; static char attack_y_offset31[ATTACK_DIR][12] // target size 3x1 -= { { 0, 1, -1, 1, -1, 1, -1, 1, -1, 1, -1, 0}, - { 1, 1, 0, 1, -1, 1, -1, 1, -1, 0, -1, -1}, - { 1, 1, 1, 1, 1, 0, 0, -1, -1, -1, -1, -1}, - { 1, 1, 0, 1, -1, 1, -1, 1, -1, 0, -1, -1}, - { 0, -1, 1, -1, 1, -1, 1, -1, 1, -1, 1, 0}, - { -1, -1, 0, -1, 1, -1, 1, -1, 1, 0, 1, 1}, - { -1, -1, -1, -1, -1, 0, 0, 1, 1, 1, 1, 1}, - { -1, -1, 0, -1, 1, -1, 1, -1, 1, 0, 1, 1}}; += { { 0, 1, (char)-1, 1, (char)-1, 1, (char)-1, 1, (char)-1, 1, (char)-1, 0}, + { 1, 1, 0, 1, (char)-1, 1, (char)-1, 1, (char)-1, 0, (char)-1, (char)-1}, + { 1, 1, 1, 1, 1, 0, 0, (char)-1, (char)-1, (char)-1, (char)-1, (char)-1}, + { 1, 1, 0, 1, (char)-1, 1, (char)-1, 1, (char)-1, 0, (char)-1, (char)-1}, + { 0, (char)-1, 1, (char)-1, 1, (char)-1, 1, (char)-1, 1, (char)-1, 1, 0}, + { (char)-1, (char)-1, 0, (char)-1, 1, (char)-1, 1, (char)-1, 1, 0, 1, 1}, + { (char)-1, (char)-1, (char)-1, (char)-1, (char)-1, 0, 0, 1, 1, 1, 1, 1}, + { (char)-1, (char)-1, 0, (char)-1, 1, (char)-1, 1, (char)-1, 1, 0, 1, 1}}; static char attack_y_offset32[ATTACK_DIR][14] // target size 3x2 -= { { 0, 1, -1, 2, -1, 2, -1, 2, -1, 2, -1, 2, 0, 1}, - { 2, 2, 1, 2, 0, 2, -1, 2, -1, 1, -1, 0, -1, -1}, - { 2, 2, 2, 2, 2, 1, 1, 0, 0, -1, -1, -1, -1, -1}, - { 2, 2, 1, 2, 0, 2, -1, 2, -1, 1, -1, 0, -1, -1}, - { 0, 1, -1, 2, -1, 2, -1, 2, -1, 2, -1, 2, 0, 1}, - { -1, -1, 0, -1, 1, -1, 2, -1, 2, 0, 2, 1, 2, 2}, - { -1, -1, -1, -1, -1, 0, 0, 1, 1, 2, 2, 2, 2, 2}, - { -1, -1, 0, -1, 1, -1, 2, -1, 2, 0, 2, 1, 2, 2}}; += { { 0, 1, (char)-1, 2, (char)-1, 2, (char)-1, 2, (char)-1, 2, (char)-1, 2, 0, 1}, + { 2, 2, 1, 2, 0, 2, (char)-1, 2, (char)-1, 1, (char)-1, 0, (char)-1, (char)-1}, + { 2, 2, 2, 2, 2, 1, 1, 0, 0, (char)-1, (char)-1, (char)-1, (char)-1, (char)-1}, + { 2, 2, 1, 2, 0, 2, (char)-1, 2, (char)-1, 1, (char)-1, 0, (char)-1, (char)-1}, + { 0, 1, (char)-1, 2, (char)-1, 2, (char)-1, 2, (char)-1, 2, (char)-1, 2, 0, 1}, + { (char)-1, (char)-1, 0, (char)-1, 1, (char)-1, 2, (char)-1, 2, 0, 2, 1, 2, 2}, + { (char)-1, (char)-1, (char)-1, (char)-1, (char)-1, 0, 0, 1, 1, 2, 2, 2, 2, 2}, + { (char)-1, (char)-1, 0, (char)-1, 1, (char)-1, 2, (char)-1, 2, 0, 2, 1, 2, 2}}; static char attack_y_offset33[ATTACK_DIR][16] // target size 3x3 -= { { 1, 2, 0, 3, -1, 3, -1, 3, -1, 3, -1, 3, -1, 2, 0, 1}, - { 3, 3, 2, 3, 1, 3, 0, 3, -1, 2, -1, 1, -1, 0, -1, -1}, - { 3, 3, 3, 3, 3, 2, 2, 1, 1, 0, 0, -1, -1, -1, -1, -1}, - { 3, 2, 3, 1, 3, 0, 3, -1, 3, -1, 2, -1, 1, -1, 0, -1}, - { 1, 0, 2, -1, 3, -1, 3, -1, 3, -1, 3, -1, 3, 0, 2, 1}, - { -1, -1, 0, -1, 1, -1, 2, -1, 3, 0, 3, 1, 3, 2, 3, 3}, - { -1, -1, -1, -1, -1, 0, 0, 1, 1, 2, 2, 3, 3, 3, 3, 3}, - { -1, 0, -1, 1, -1, 2, -1, 3, -1, 3, 0, 3, 1, 3, 2, 3}}; += { { 1, 2, 0, 3, (char)-1, 3, (char)-1, 3, (char)-1, 3, (char)-1, 3, (char)-1, 2, 0, 1}, + { 3, 3, 2, 3, 1, 3, 0, 3, (char)-1, 2, (char)-1, 1, (char)-1, 0, (char)-1, (char)-1}, + { 3, 3, 3, 3, 3, 2, 2, 1, 1, 0, 0, (char)-1, (char)-1, (char)-1, (char)-1, (char)-1}, + { 3, 2, 3, 1, 3, 0, 3, (char)-1, 3, (char)-1, 2, (char)-1, 1, (char)-1, 0, (char)-1}, + { 1, 0, 2, (char)-1, 3, (char)-1, 3, (char)-1, 3, (char)-1, 3, (char)-1, 3, 0, 2, 1}, + { (char)-1, (char)-1, 0, (char)-1, 1, (char)-1, 2, (char)-1, 3, 0, 3, 1, 3, 2, 3, 3}, + { (char)-1, (char)-1, (char)-1, (char)-1, (char)-1, 0, 0, 1, 1, 2, 2, 3, 3, 3, 3, 3}, + { (char)-1, 0, (char)-1, 1, (char)-1, 2, (char)-1, 3, (char)-1, 3, 0, 3, 1, 3, 2, 3}}; static char attack_y_offset34[ATTACK_DIR][18] // target size 3x4 -= { { 1, 2, 0, 3, -1, 4, -1, 4, -1, 4, -1, 4, -1, 4, 0, 3, 1, 2}, - { 4, 3, 4, 2, 4, 1, 4, 0, 4, -1, 3, -1, 2, -1, 1, -1, 0, -1}, - { 4, 4, 4, 4, 4, 3, 3, 2, 2, 1, 1, 0, 0, -1, -1, -1, -1, -1}, - { 4, 3, 4, 2, 4, 1, 4, 0, 4, -1, 3, -1, 2, -1, 1, -1, 0, -1}, - { 1, 2, 0, 3, -1, 4, -1, 4, -1, 4, -1, 4, -1, 4, 0, 3, 1, 2}, - { -1, 0, -1, 1, -1, 2, -1, 3, -1, 4, 0, 4, 1, 4, 2, 4, 3, 4}, - { -1, -1, -1, -1, -1, 0, 0, 1, 1, 2, 2, 3, 3, 4, 4, 4, 4, 4}, - { -1, 0, -1, 1, -1, 2, -1, 3, -1, 4, 0, 4, 1, 4, 2, 4, 3, 4}}; += { { 1, 2, 0, 3, (char)-1, 4, (char)-1, 4, (char)-1, 4, (char)-1, 4, (char)-1, 4, 0, 3, 1, 2}, + { 4, 3, 4, 2, 4, 1, 4, 0, 4, (char)-1, 3, (char)-1, 2, (char)-1, 1, (char)-1, 0, (char)-1}, + { 4, 4, 4, 4, 4, 3, 3, 2, 2, 1, 1, 0, 0, (char)-1, (char)-1, (char)-1, (char)-1, (char)-1}, + { 4, 3, 4, 2, 4, 1, 4, 0, 4, (char)-1, 3, (char)-1, 2, (char)-1, 1, (char)-1, 0, (char)-1}, + { 1, 2, 0, 3, (char)-1, 4, (char)-1, 4, (char)-1, 4, (char)-1, 4, (char)-1, 4, 0, 3, 1, 2}, + { (char)-1, 0, (char)-1, 1, (char)-1, 2, (char)-1, 3, (char)-1, 4, 0, 4, 1, 4, 2, 4, 3, 4}, + { (char)-1, (char)-1, (char)-1, (char)-1, (char)-1, 0, 0, 1, 1, 2, 2, 3, 3, 4, 4, 4, 4, 4}, + { (char)-1, 0, (char)-1, 1, (char)-1, 2, (char)-1, 3, (char)-1, 4, 0, 4, 1, 4, 2, 4, 3, 4}}; static char attack_y_offset41[ATTACK_DIR][14] // target size 4x1 -= { { 0, 1, -1, 1, -1, 1, -1, 1, -1, 1, -1, 1, -1, 0}, - { 1, 1, 0, 1, -1, 1, -1, 1, -1, 1, -1, 0, -1, -1}, - { 1, 1, 1, 1, 1, 1, 0, 0, -1, -1, -1, -1, -1, -1}, - { 1, 1, 0, 1, -1, 1, -1, 1, -1, 1, -1, 0, -1, -1}, - { 0, -1, 1, -1, 1, -1, 1, -1, 1, -1, 1, -1, 1, 0}, - { -1, -1, 0, -1, 1, -1, 1, -1, 1, -1, 1, 0, 1, -1}, - { -1, -1, -1, -1, -1, -1, 0, 0, 1, 1, 1, 1, 1, 1}, - { -1, -1, 0, -1, 1, -1, 1, -1, 1, -1, 1, 0, 1, 1}}; += { { 0, 1, (char)-1, 1, (char)-1, 1, (char)-1, 1, (char)-1, 1, (char)-1, 1, (char)-1, 0}, + { 1, 1, 0, 1, (char)-1, 1, (char)-1, 1, (char)-1, 1, (char)-1, 0, (char)-1, (char)-1}, + { 1, 1, 1, 1, 1, 1, 0, 0, (char)-1, (char)-1, (char)-1, (char)-1, (char)-1, (char)-1}, + { 1, 1, 0, 1, (char)-1, 1, (char)-1, 1, (char)-1, 1, (char)-1, 0, (char)-1, (char)-1}, + { 0, (char)-1, 1, (char)-1, 1, (char)-1, 1, (char)-1, 1, (char)-1, 1, (char)-1, 1, 0}, + { (char)-1, (char)-1, 0, (char)-1, 1, (char)-1, 1, (char)-1, 1, (char)-1, 1, 0, 1, (char)-1}, + { (char)-1, (char)-1, (char)-1, (char)-1, (char)-1, (char)-1, 0, 0, 1, 1, 1, 1, 1, 1}, + { (char)-1, (char)-1, 0, (char)-1, 1, (char)-1, 1, (char)-1, 1, (char)-1, 1, 0, 1, 1}}; static char attack_y_offset42[ATTACK_DIR][16] // target size 4x2 -= { { 0, 1, -1, 2, -1, 2, -1, 2, -1, 2, -1, 2, -1, 2, 0, 1}, - { 2, 2, 1, 2, 0, 2, -1, 2, -1, 2, -1, 1, -1, 0, -1, -1}, - { 2, 2, 2, 2, 2, 2, 1, 1, 0, 0, -1, -1, -1, -1, -1, -1}, - { 2, 2, 1, 2, 0, 2, -1, 2, -1, 2, -1, 1, -1, 0, -1, -1}, - { 0, 1, -1, 2, -1, 2, -1, 2, -1, 2, -1, 2, -1, 2, 0, 1}, - { -1, -1, 0, -1, 1, -1, 2, -1, 2, -1, 2, 0, 2, 1, 2, 2}, - { -1, -1, -1, -1, -1, -1, 0, 0, 1, 1, 2, 2, 2, 2, 2, 2}, - { -1, -1, 0, -1, 1, -1, 2, -1, 2, -1, 2, 0, 2, 1, 2, 2}}; += { { 0, 1, (char)-1, 2, (char)-1, 2, (char)-1, 2, (char)-1, 2, (char)-1, 2, (char)-1, 2, 0, 1}, + { 2, 2, 1, 2, 0, 2, (char)-1, 2, (char)-1, 2, (char)-1, 1, (char)-1, 0, (char)-1, (char)-1}, + { 2, 2, 2, 2, 2, 2, 1, 1, 0, 0, (char)-1, (char)-1, (char)-1, (char)-1, (char)-1, (char)-1}, + { 2, 2, 1, 2, 0, 2, (char)-1, 2, (char)-1, 2, (char)-1, 1, (char)-1, 0, (char)-1, (char)-1}, + { 0, 1, (char)-1, 2, (char)-1, 2, (char)-1, 2, (char)-1, 2, (char)-1, 2, (char)-1, 2, 0, 1}, + { (char)-1, (char)-1, 0, (char)-1, 1, (char)-1, 2, (char)-1, 2, (char)-1, 2, 0, 2, 1, 2, 2}, + { (char)-1, (char)-1, (char)-1, (char)-1, (char)-1, (char)-1, 0, 0, 1, 1, 2, 2, 2, 2, 2, 2}, + { (char)-1, (char)-1, 0, (char)-1, 1, (char)-1, 2, (char)-1, 2, (char)-1, 2, 0, 2, 1, 2, 2}}; static char attack_y_offset43[ATTACK_DIR][18] // target size 4x3 -= { { 1, 2, 0, 3, -1, 3, -1, 3, -1, 3, -1, 3, -1, 3, -1, 2, 0, 1}, - { 3, 3, 2, 3, 1, 3, 0, 3, -1, 3, -1, 2, -1, 1, -1, 0, -1, -1}, - { 3, 3, 3, 3, 3, 3, 2, 2, 1, 1, 0, 0, -1, -1, -1, -1, -1, -1}, - { 3, 3, 2, 3, 1, 3, 0, 3, -1, 3, -1, 2, -1, 1, -1, 0, -1, -1}, - { 1, 0, 2, -1, 3, -1, 3, -1, 3, -1, 3, -1, 3, -1, 3, 0, 2, 1}, - { -1, -1, 0, -1, 1, -1, 2, -1, 3, -1, 3, 0, 3, 1, 3, 2, 3, 3}, - { -1, -1, -1, -1, -1, -1, 0, 0, 1, 1, 2, 2, 3, 3, 3, 3, 3, 3}, - { -1, -1, 0, -1, 1, -1, 2, -1, 3, -1, 3, 0, 3, 1, 3, 2, 3, 3}}; += { { 1, 2, 0, 3, (char)-1, 3, (char)-1, 3, (char)-1, 3, (char)-1, 3, (char)-1, 3, (char)-1, 2, 0, 1}, + { 3, 3, 2, 3, 1, 3, 0, 3, (char)-1, 3, (char)-1, 2, (char)-1, 1, (char)-1, 0, (char)-1, (char)-1}, + { 3, 3, 3, 3, 3, 3, 2, 2, 1, 1, 0, 0, (char)-1, (char)-1, (char)-1, (char)-1, (char)-1, (char)-1}, + { 3, 3, 2, 3, 1, 3, 0, 3, (char)-1, 3, (char)-1, 2, (char)-1, 1, (char)-1, 0, (char)-1, (char)-1}, + { 1, 0, 2, (char)-1, 3, (char)-1, 3, (char)-1, 3, (char)-1, 3, (char)-1, 3, (char)-1, 3, 0, 2, 1}, + { (char)-1, (char)-1, 0, (char)-1, 1, (char)-1, 2, (char)-1, 3, (char)-1, 3, 0, 3, 1, 3, 2, 3, 3}, + { (char)-1, (char)-1, (char)-1, (char)-1, (char)-1, (char)-1, 0, 0, 1, 1, 2, 2, 3, 3, 3, 3, 3, 3}, + { (char)-1, (char)-1, 0, (char)-1, 1, (char)-1, 2, (char)-1, 3, (char)-1, 3, 0, 3, 1, 3, 2, 3, 3}}; static char attack_y_offset44[ATTACK_DIR][20] // target size 4x4 -= { { 1, 2, 0, 3, -1, 4, -1, 4, -1, 4, -1, 4, -1, 4, -1, 4, 0, 3, 1, 2}, - { 4, 4, 3, 4, 2, 4, 1, 4, 0, 4, -1, 3, -1, 2, -1, 1, -1, 0, -1, -1}, - { 4, 4, 4, 4, 4, 4, 3, 3, 2, 2, 1, 1, 0, 0, -1, -1, -1, -1, -1, -1}, - { 4, 3, 4, 2, 4, 1, 4, 0, 4, -1, 4, -1, 3, -1, 2, -1, 1, -1, 0, -1}, - { 2, 1, 3, 0, 4, -1, 4, -1, 4, -1, 4, -1, 4, -1, 4, -1, 3, 0, 2, 1}, - { -1, -1, 0, -1, 1, -1, 2, -1, 3, -1, 4, 0, 4, 1, 4, 2, 4, 3, 4, 4}, - { -1, -1, -1, -1, -1, -1, 0, 0, 1, 1, 2, 2, 3, 3, 4, 4, 4, 4, 4, 4}, - { -1, 0, -1, 1, -1, 2, -1, 3, -1, 4, -1, 4, 0, 4, 1, 4, 2, 4, 3, 4}}; += { { 1, 2, 0, 3, (char)-1, 4, (char)-1, 4, (char)-1, 4, (char)-1, 4, (char)-1, 4, (char)-1, 4, 0, 3, 1, 2}, + { 4, 4, 3, 4, 2, 4, 1, 4, 0, 4, (char)-1, 3, (char)-1, 2, (char)-1, 1, (char)-1, 0, (char)-1, (char)-1}, + { 4, 4, 4, 4, 4, 4, 3, 3, 2, 2, 1, 1, 0, 0, (char)-1, (char)-1, (char)-1, (char)-1, (char)-1, (char)-1}, + { 4, 3, 4, 2, 4, 1, 4, 0, 4, (char)-1, 4, (char)-1, 3, (char)-1, 2, (char)-1, 1, (char)-1, 0, (char)-1}, + { 2, 1, 3, 0, 4, (char)-1, 4, (char)-1, 4, (char)-1, 4, (char)-1, 4, (char)-1, 4, (char)-1, 3, 0, 2, 1}, + { (char)-1, (char)-1, 0, (char)-1, 1, (char)-1, 2, (char)-1, 3, (char)-1, 4, 0, 4, 1, 4, 2, 4, 3, 4, 4}, + { (char)-1, (char)-1, (char)-1, (char)-1, (char)-1, (char)-1, 0, 0, 1, 1, 2, 2, 3, 3, 4, 4, 4, 4, 4, 4}, + { (char)-1, 0, (char)-1, 1, (char)-1, 2, (char)-1, 3, (char)-1, 4, (char)-1, 4, 0, 4, 1, 4, 2, 4, 3, 4}}; //--------- Begin of function UnitArray::get_target_x_offset ---------// // return x offset Index: a/src/OU_MARI.cpp =================================================================== --- a/src/OU_MARI.cpp +++ b/src/OU_MARI.cpp @@ -552,7 +552,7 @@ int UnitMarine::is_on_coast() //--------- Begin of function UnitMarine::extra_move ---------// void UnitMarine::extra_move() { - static char offset[3] = {0, 1, -1}; + static char offset[3] = {0, 1, (char)-1}; int curXLoc = next_x_loc(); int curYLoc = next_y_loc(); @@ -619,8 +619,8 @@ void UnitMarine::extra_move() void UnitMarine::process_extra_move() { - static short vector_x_array[] = { 0, 1, 1, 1, 0, -1, -1, -1}; // default vectors, temporary only - static short vector_y_array[] = {-1, -1, 0, 1, 1, 1, 0, -1}; + static short vector_x_array[] = { 0, 1, 1, 1, 0, (char)-1, (char)-1, (char)-1}; // default vectors, temporary only + static short vector_y_array[] = {(char)-1, (char)-1, 0, 1, 1, 1, 0, (char)-1}; if(!match_dir()) // process turning return;
Locations
Projects
Search
Status Monitor
Help
OpenBuildService.org
Documentation
API Documentation
Code of Conduct
Contact
Support
@OBShq
Terms
openSUSE Build Service is sponsored by
The Open Build Service is an
openSUSE project
.
Sign Up
Log In
Places
Places
All Projects
Status Monitor