Browse Source

Clang-tidy: readability-static-definition-in-anonymous-namespace

pull/2243/head
Anders Jenbo 5 years ago
parent
commit
19d980582f
  1. 2
      Source/controls/plrctrls.cpp
  2. 4
      Source/gamemenu.cpp
  3. 2
      Source/player.cpp
  4. 10
      Source/sync.cpp

2
Source/controls/plrctrls.cpp

@ -1010,7 +1010,7 @@ void SpellBookMove(AxisDirection dir)
}
}
static const Direction FaceDir[3][3] = {
const Direction FaceDir[3][3] = {
// NONE UP DOWN
{ DIR_OMNI, DIR_N, DIR_S }, // NONE
{ DIR_W, DIR_NW, DIR_SW }, // LEFT

4
Source/gamemenu.cpp

@ -131,7 +131,7 @@ void gamemenu_sound_music_toggle(const char *const *names, TMenuItem *menu_item,
menu_item->pszStr = names[1];
}
static int gamemenu_slider_music_sound(TMenuItem *menu_item)
int gamemenu_slider_music_sound(TMenuItem *menu_item)
{
return gmenu_slider_get(menu_item, VOLUME_MIN, VOLUME_MAX);
}
@ -174,7 +174,7 @@ void gamemenu_get_speed()
gmenu_slider_set(&sgOptionsMenu[3], 20, 50, sgGameInitInfo.nTickRate);
}
static int gamemenu_slider_gamma()
int gamemenu_slider_gamma()
{
return gmenu_slider_get(&sgOptionsMenu[2], 30, 100);
}

2
Source/player.cpp

@ -100,7 +100,7 @@ void WalkSides(int pnum, Point vel, const DirectionSettings &walkParams)
player.position.temp = player.position.future;
}
static constexpr std::array<const DirectionSettings, 8> directionSettings { {
constexpr std::array<const DirectionSettings, 8> directionSettings { {
// clang-format off
{ DIR_S, { 1, 1 }, { 0, -32 }, { 0, 0 }, SDIR_S, PM_WALK2, WalkDownwards },
{ DIR_SW, { 0, 1 }, { 32, -16 }, { 0, 0 }, SDIR_SW, PM_WALK2, WalkDownwards },

10
Source/sync.cpp

@ -19,7 +19,7 @@ uint16_t sgwLRU[MAXMONSTERS];
int sgnSyncItem;
int sgnSyncPInv;
static void sync_one_monster()
void sync_one_monster()
{
for (int i = 0; i < nummonsters; i++) {
int m = monstactive[i];
@ -32,7 +32,7 @@ static void sync_one_monster()
}
}
static void sync_monster_pos(TSyncMonster *p, int ndx)
void sync_monster_pos(TSyncMonster *p, int ndx)
{
p->_mndx = ndx;
p->_mx = monster[ndx].position.tile.x;
@ -44,7 +44,7 @@ static void sync_monster_pos(TSyncMonster *p, int ndx)
sgwLRU[ndx] = monster[ndx]._msquelch == 0 ? 0xFFFF : 0xFFFE;
}
static bool sync_monster_active(TSyncMonster *p)
bool sync_monster_active(TSyncMonster *p)
{
int i, m, ndx;
uint32_t lru;
@ -68,7 +68,7 @@ static bool sync_monster_active(TSyncMonster *p)
return true;
}
static bool sync_monster_active2(TSyncMonster *p)
bool sync_monster_active2(TSyncMonster *p)
{
int i, m, ndx;
uint32_t lru;
@ -96,7 +96,7 @@ static bool sync_monster_active2(TSyncMonster *p)
return true;
}
static void SyncPlrInv(TSyncHeader *pHdr)
void SyncPlrInv(TSyncHeader *pHdr)
{
int ii;
ItemStruct *pItem;

Loading…
Cancel
Save