1
0
mirror of https://github.com/OpenTTD/OpenTTD.git synced 2025-08-12 09:09:09 +00:00

(svn r1701) Style police ^^

This commit is contained in:
tron
2005-01-27 21:18:03 +00:00
parent 99338d278d
commit 3e0dcfd47f
6 changed files with 12 additions and 13 deletions

View File

@@ -906,17 +906,20 @@ const ChunkHandler _engine_chunk_handlers[] = {
{ 'ENGS', LoadSave_ENGS, LoadSave_ENGS, CH_RIFF | CH_LAST},
};
/*
* returns true if an engine is valid, and it is of the specified type, and buildable by the current player, false otherwise
* returns true if an engine is valid, of the specified type, and buildable by
* the current player, false otherwise
*
* engine = index of the engine to check
* type = the type the engine should be of (VEH_xxx)
*/
bool IsEngineBuildable(int engine, byte type) {
Engine *e;
bool IsEngineBuildable(uint engine, byte type)
{
const Engine *e;
// check if it's an engine that is in the engine array
if (0 > engine || engine >= TOTAL_NUM_ENGINES ) return false;
if (engine >= TOTAL_NUM_ENGINES) return false;
e = DEREF_ENGINE(engine);
@@ -928,7 +931,3 @@ bool IsEngineBuildable(int engine, byte type) {
return true;
}