mirror of
https://github.com/OpenTTD/OpenTTD.git
synced 2025-03-10 08:00:05 +00:00
(svn r13298) -Codechange: remove unused _total_signs
This commit is contained in:
parent
cfb962c7f1
commit
437d5d9798
@ -24,7 +24,6 @@
|
|||||||
#include "table/strings.h"
|
#include "table/strings.h"
|
||||||
|
|
||||||
SignID _new_sign_id;
|
SignID _new_sign_id;
|
||||||
uint _total_signs;
|
|
||||||
bool _sign_sort_dirty;
|
bool _sign_sort_dirty;
|
||||||
|
|
||||||
/* Initialize the sign-pool */
|
/* Initialize the sign-pool */
|
||||||
@ -115,7 +114,6 @@ CommandCost CmdPlaceSign(TileIndex tile, uint32 flags, uint32 p1, uint32 p2)
|
|||||||
InvalidateWindow(WC_SIGN_LIST, 0);
|
InvalidateWindow(WC_SIGN_LIST, 0);
|
||||||
_sign_sort_dirty = true;
|
_sign_sort_dirty = true;
|
||||||
_new_sign_id = si->index;
|
_new_sign_id = si->index;
|
||||||
_total_signs++;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
return CommandCost();
|
return CommandCost();
|
||||||
@ -162,7 +160,6 @@ CommandCost CmdRenameSign(TileIndex tile, uint32 flags, uint32 p1, uint32 p2)
|
|||||||
|
|
||||||
InvalidateWindow(WC_SIGN_LIST, 0);
|
InvalidateWindow(WC_SIGN_LIST, 0);
|
||||||
_sign_sort_dirty = true;
|
_sign_sort_dirty = true;
|
||||||
_total_signs--;
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -202,7 +199,6 @@ void PlaceProc_Sign(TileIndex tile)
|
|||||||
*/
|
*/
|
||||||
void InitializeSigns()
|
void InitializeSigns()
|
||||||
{
|
{
|
||||||
_total_signs = 0;
|
|
||||||
_Sign_pool.CleanPool();
|
_Sign_pool.CleanPool();
|
||||||
_Sign_pool.AddBlockToPool();
|
_Sign_pool.AddBlockToPool();
|
||||||
}
|
}
|
||||||
@ -241,13 +237,10 @@ static void Save_SIGN()
|
|||||||
*/
|
*/
|
||||||
static void Load_SIGN()
|
static void Load_SIGN()
|
||||||
{
|
{
|
||||||
_total_signs = 0;
|
|
||||||
int index;
|
int index;
|
||||||
while ((index = SlIterateArray()) != -1) {
|
while ((index = SlIterateArray()) != -1) {
|
||||||
Sign *si = new (index) Sign();
|
Sign *si = new (index) Sign();
|
||||||
SlObject(si, _sign_desc);
|
SlObject(si, _sign_desc);
|
||||||
|
|
||||||
_total_signs++;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
_sign_sort_dirty = true;
|
_sign_sort_dirty = true;
|
||||||
|
@ -40,12 +40,6 @@ static inline SignID GetMaxSignIndex()
|
|||||||
return GetSignPoolSize() - 1;
|
return GetSignPoolSize() - 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
static inline uint GetNumSigns()
|
|
||||||
{
|
|
||||||
extern uint _total_signs;
|
|
||||||
return _total_signs;
|
|
||||||
}
|
|
||||||
|
|
||||||
static inline bool IsValidSignID(uint index)
|
static inline bool IsValidSignID(uint index)
|
||||||
{
|
{
|
||||||
return index < GetSignPoolSize() && GetSign(index)->IsValid();
|
return index < GetSignPoolSize() && GetSign(index)->IsValid();
|
||||||
|
Loading…
Reference in New Issue
Block a user