Changeset - r11962:0e3a6981e508
[Not reviewed]
master
0 8 0
smatz - 15 years ago 2009-05-21 22:43:25
smatz@openttd.org
(svn r16373) -Codechange: use () instead of (void) for functions without parameters
8 files changed with 17 insertions and 17 deletions:
0 comments (0 inline, 0 general)
src/group.h
Show inline comments
 
@@ -48,13 +48,13 @@ static inline bool IsAllGroupID(GroupID 
 
#define FOR_ALL_GROUPS_FROM(g, start) for (g = Group::Get(start); g != NULL; g = (g->index + 1U < Group::GetPoolSize()) ? Group::Get(g->index + 1) : NULL) if (g->IsValid())
 
#define FOR_ALL_GROUPS(g) FOR_ALL_GROUPS_FROM(g, 0)
 

	
 
/**
 
 * Get the current size of the GroupPool
 
 */
 
static inline uint GetGroupArraySize(void)
 
static inline uint GetGroupArraySize()
 
{
 
	const Group *g;
 
	uint num = 0;
 

	
 
	FOR_ALL_GROUPS(g) num++;
 

	
src/group_cmd.cpp
Show inline comments
 
@@ -59,13 +59,13 @@ Group::~Group()
 

	
 
bool Group::IsValid() const
 
{
 
	return this->owner != INVALID_OWNER;
 
}
 

	
 
void InitializeGroup(void)
 
void InitializeGroup()
 
{
 
	_Group_pool.CleanPool();
 
	_Group_pool.AddBlockToPool();
 
}
 

	
 

	
src/industry_cmd.cpp
Show inline comments
 
@@ -1843,13 +1843,13 @@ struct ProbabilityHelper {
 
	IndustryType ind; ///< industry id correcponding
 
};
 

	
 
/**
 
 * Try to create a random industry, during gameplay
 
 */
 
static void MaybeNewIndustry(void)
 
static void MaybeNewIndustry()
 
{
 
	Industry *ind;               // will receive the industry's creation pointer
 
	IndustryType rndtype, j;     // Loop controlers
 
	const IndustrySpec *ind_spc;
 
	uint num = 0;
 
	ProbabilityHelper cumulative_probs[NUM_INDUSTRYTYPES]; // probability collector
src/landscape.cpp
Show inline comments
 
@@ -523,13 +523,13 @@ void GetTileDesc(TileIndex tile, TileDes
 

	
 
/**
 
 * Has a snow line table already been loaded.
 
 * @return true if the table has been loaded already.
 
 * @ingroup SnowLineGroup
 
 */
 
bool IsSnowLineSet(void)
 
bool IsSnowLineSet()
 
{
 
	return _snow_line != NULL;
 
}
 

	
 
/**
 
 * Set a variable snow line, as loaded from a newgrf file.
 
@@ -552,13 +552,13 @@ void SetSnowLine(byte table[SNOW_LINE_MO
 

	
 
/**
 
 * Get the current snow line, either variable or static.
 
 * @return the snow line height.
 
 * @ingroup SnowLineGroup
 
 */
 
byte GetSnowLine(void)
 
byte GetSnowLine()
 
{
 
	if (_snow_line == NULL) return _settings_game.game_creation.snow_line;
 

	
 
	YearMonthDay ymd;
 
	ConvertDateToYMD(_date, &ymd);
 
	return _snow_line->table[ymd.month][ymd.day];
 
@@ -566,32 +566,32 @@ byte GetSnowLine(void)
 

	
 
/**
 
 * Get the highest possible snow line height, either variable or static.
 
 * @return the highest snow line height.
 
 * @ingroup SnowLineGroup
 
 */
 
byte HighestSnowLine(void)
 
byte HighestSnowLine()
 
{
 
	return _snow_line == NULL ? _settings_game.game_creation.snow_line : _snow_line->highest_value;
 
}
 

	
 
/**
 
 * Get the lowest possible snow line height, either variable or static.
 
 * @return the lowest snow line height.
 
 * @ingroup SnowLineGroup
 
 */
 
byte LowestSnowLine(void)
 
byte LowestSnowLine()
 
{
 
	return _snow_line == NULL ? _settings_game.game_creation.snow_line : _snow_line->lowest_value;
 
}
 

	
 
/**
 
 * Clear the variable snow line table and free the memory.
 
 * @ingroup SnowLineGroup
 
 */
 
void ClearSnowLine(void)
 
void ClearSnowLine()
 
{
 
	free(_snow_line);
 
	_snow_line = NULL;
 
}
 

	
 
/** Clear a piece of landscape
src/landscape.h
Show inline comments
 
@@ -20,18 +20,18 @@ enum {
 
struct SnowLine {
 
	byte table[SNOW_LINE_MONTHS][SNOW_LINE_DAYS]; ///< Height of the snow line each day of the year
 
	byte highest_value; ///< Highest snow line of the year
 
	byte lowest_value;  ///< Lowest snow line of the year
 
};
 

	
 
bool IsSnowLineSet(void);
 
bool IsSnowLineSet();
 
void SetSnowLine(byte table[SNOW_LINE_MONTHS][SNOW_LINE_DAYS]);
 
byte GetSnowLine(void);
 
byte HighestSnowLine(void);
 
byte LowestSnowLine(void);
 
void ClearSnowLine(void);
 
byte GetSnowLine();
 
byte HighestSnowLine();
 
byte LowestSnowLine();
 
void ClearSnowLine();
 

	
 
uint GetPartialZ(int x, int y, Slope corners);
 
uint GetSlopeZ(int x, int y);
 
void GetSlopeZOnEdge(Slope tileh, DiagDirection edge, int *z1, int *z2);
 
int GetSlopeZInCorner(Slope tileh, Corner corner);
 
Slope GetFoundationSlope(TileIndex tile, uint *z);
src/saveload/group_sl.cpp
Show inline comments
 
@@ -14,24 +14,24 @@ static const SaveLoad _group_desc[] = {
 
  SLE_VAR(Group, owner,              SLE_UINT8),
 
  SLE_VAR(Group, vehicle_type,       SLE_UINT8),
 
  SLE_VAR(Group, replace_protection, SLE_BOOL),
 
  SLE_END()
 
};
 

	
 
static void Save_GRPS(void)
 
static void Save_GRPS()
 
{
 
	Group *g;
 

	
 
	FOR_ALL_GROUPS(g) {
 
		SlSetArrayIndex(g->index);
 
		SlObject(g, _group_desc);
 
	}
 
}
 

	
 

	
 
static void Load_GRPS(void)
 
static void Load_GRPS()
 
{
 
	int index;
 

	
 
	while ((index = SlIterateArray()) != -1) {
 
		Group *g = new (index) Group();
 
		SlObject(g, _group_desc);
src/thread_morphos.cpp
Show inline comments
 
@@ -154,13 +154,13 @@ public:
 

	
 
private:
 
	/**
 
	 * On thread creation, this function is called, which calls the real startup
 
	 *  function. This to get back into the correct instance again.
 
	 */
 
	static void Proxy(void)
 
	static void Proxy()
 
	{
 
		struct Task *child = FindTask(NULL);
 
		struct OTTDThreadStartupMessage *msg;
 

	
 
		/* Make sure, we don't block the parent. */
 
		SetTaskPri(child, -5);
src/transparency_gui.cpp
Show inline comments
 
@@ -143,10 +143,10 @@ static const WindowDesc _transparency_de
 
	WDP_ALIGN_TBR, 94, 219, 49, 219, 49,
 
	WC_TRANSPARENCY_TOOLBAR, WC_NONE,
 
	WDF_STD_TOOLTIPS | WDF_STD_BTN | WDF_DEF_WIDGET | WDF_STICKY_BUTTON,
 
	_transparency_widgets, _nested_transparency_widgets, lengthof(_nested_transparency_widgets)
 
);
 

	
 
void ShowTransparencyToolbar(void)
 
void ShowTransparencyToolbar()
 
{
 
	AllocateWindowDescFront<TransparenciesWindow>(&_transparency_desc, 0);
 
}
0 comments (0 inline, 0 general)