yapf/yapf_settings.h
author celestar
Fri, 29 Dec 2006 12:33:26 +0000
branchcustombridgeheads
changeset 5596 fdbe3e553294
parent 5081 f71d1d2da6ed
permissions -rw-r--r--
(svn r7614) [cbh] - Codechange: Moved the DiagDirection of the bridge head from m5 bits 0..1 to m4 bits 5..6
3900
4984308f9125 (svn r4987) Feature: Merged YAPF into trunk. Thanks to devs for continuous support and users for testing.
KUDr
parents:
diff changeset
     1
/* $Id$ */
4984308f9125 (svn r4987) Feature: Merged YAPF into trunk. Thanks to devs for continuous support and users for testing.
KUDr
parents:
diff changeset
     2
#if !defined(YAPF_SETTINGS_H) || defined(YS_DEF)
4984308f9125 (svn r4987) Feature: Merged YAPF into trunk. Thanks to devs for continuous support and users for testing.
KUDr
parents:
diff changeset
     3
4984308f9125 (svn r4987) Feature: Merged YAPF into trunk. Thanks to devs for continuous support and users for testing.
KUDr
parents:
diff changeset
     4
# ifndef  YAPF_SETTINGS_H
4984308f9125 (svn r4987) Feature: Merged YAPF into trunk. Thanks to devs for continuous support and users for testing.
KUDr
parents:
diff changeset
     5
#  define  YAPF_SETTINGS_H
4984308f9125 (svn r4987) Feature: Merged YAPF into trunk. Thanks to devs for continuous support and users for testing.
KUDr
parents:
diff changeset
     6
# endif
4984308f9125 (svn r4987) Feature: Merged YAPF into trunk. Thanks to devs for continuous support and users for testing.
KUDr
parents:
diff changeset
     7
4984308f9125 (svn r4987) Feature: Merged YAPF into trunk. Thanks to devs for continuous support and users for testing.
KUDr
parents:
diff changeset
     8
# ifndef YS_DEF
4984308f9125 (svn r4987) Feature: Merged YAPF into trunk. Thanks to devs for continuous support and users for testing.
KUDr
parents:
diff changeset
     9
/*
4549
60410aa1aa88 (svn r6381) -Cleanup: make the '/* */' comments that span multiple lines more uniform.
rubidium
parents: 4411
diff changeset
    10
 *  if YS_DEF is not defined, we will only do following declaration:
60410aa1aa88 (svn r6381) -Cleanup: make the '/* */' comments that span multiple lines more uniform.
rubidium
parents: 4411
diff changeset
    11
 *  typedef struct YapfSettings {
60410aa1aa88 (svn r6381) -Cleanup: make the '/* */' comments that span multiple lines more uniform.
rubidium
parents: 4411
diff changeset
    12
 *    bool   disable_node_optimization;
60410aa1aa88 (svn r6381) -Cleanup: make the '/* */' comments that span multiple lines more uniform.
rubidium
parents: 4411
diff changeset
    13
 *    uint32 max_search_nodes;
60410aa1aa88 (svn r6381) -Cleanup: make the '/* */' comments that span multiple lines more uniform.
rubidium
parents: 4411
diff changeset
    14
 *    .... all other yapf related settings ...
60410aa1aa88 (svn r6381) -Cleanup: make the '/* */' comments that span multiple lines more uniform.
rubidium
parents: 4411
diff changeset
    15
 *  } YapfSettings;
60410aa1aa88 (svn r6381) -Cleanup: make the '/* */' comments that span multiple lines more uniform.
rubidium
parents: 4411
diff changeset
    16
 *
60410aa1aa88 (svn r6381) -Cleanup: make the '/* */' comments that span multiple lines more uniform.
rubidium
parents: 4411
diff changeset
    17
 *  otherwise we will just expand YS_DEF_xx macros and then #undef them
60410aa1aa88 (svn r6381) -Cleanup: make the '/* */' comments that span multiple lines more uniform.
rubidium
parents: 4411
diff changeset
    18
 */
3900
4984308f9125 (svn r4987) Feature: Merged YAPF into trunk. Thanks to devs for continuous support and users for testing.
KUDr
parents:
diff changeset
    19
#  define YS_DEF_BEGIN typedef struct YapfSettings {
4984308f9125 (svn r4987) Feature: Merged YAPF into trunk. Thanks to devs for continuous support and users for testing.
KUDr
parents:
diff changeset
    20
#  define YS_DEF(type, name) type name;
4984308f9125 (svn r4987) Feature: Merged YAPF into trunk. Thanks to devs for continuous support and users for testing.
KUDr
parents:
diff changeset
    21
#  define YS_DEF_END } YapfSettings;
4984308f9125 (svn r4987) Feature: Merged YAPF into trunk. Thanks to devs for continuous support and users for testing.
KUDr
parents:
diff changeset
    22
4984308f9125 (svn r4987) Feature: Merged YAPF into trunk. Thanks to devs for continuous support and users for testing.
KUDr
parents:
diff changeset
    23
# endif /* !YS_DEF */
4984308f9125 (svn r4987) Feature: Merged YAPF into trunk. Thanks to devs for continuous support and users for testing.
KUDr
parents:
diff changeset
    24
4984308f9125 (svn r4987) Feature: Merged YAPF into trunk. Thanks to devs for continuous support and users for testing.
KUDr
parents:
diff changeset
    25
# ifndef   YS_DEF_BEGIN
4984308f9125 (svn r4987) Feature: Merged YAPF into trunk. Thanks to devs for continuous support and users for testing.
KUDr
parents:
diff changeset
    26
#  define  YS_DEF_BEGIN
4984308f9125 (svn r4987) Feature: Merged YAPF into trunk. Thanks to devs for continuous support and users for testing.
KUDr
parents:
diff changeset
    27
# endif // YS_DEF_BEGIN
4984308f9125 (svn r4987) Feature: Merged YAPF into trunk. Thanks to devs for continuous support and users for testing.
KUDr
parents:
diff changeset
    28
4984308f9125 (svn r4987) Feature: Merged YAPF into trunk. Thanks to devs for continuous support and users for testing.
KUDr
parents:
diff changeset
    29
# ifndef   YS_DEF_END
4984308f9125 (svn r4987) Feature: Merged YAPF into trunk. Thanks to devs for continuous support and users for testing.
KUDr
parents:
diff changeset
    30
#  define  YS_DEF_END
4984308f9125 (svn r4987) Feature: Merged YAPF into trunk. Thanks to devs for continuous support and users for testing.
KUDr
parents:
diff changeset
    31
# endif // YS_DEF_END
4984308f9125 (svn r4987) Feature: Merged YAPF into trunk. Thanks to devs for continuous support and users for testing.
KUDr
parents:
diff changeset
    32
4984308f9125 (svn r4987) Feature: Merged YAPF into trunk. Thanks to devs for continuous support and users for testing.
KUDr
parents:
diff changeset
    33
YS_DEF_BEGIN
4984308f9125 (svn r4987) Feature: Merged YAPF into trunk. Thanks to devs for continuous support and users for testing.
KUDr
parents:
diff changeset
    34
	YS_DEF(bool  , disable_node_optimization)  ///< whether to use exit-dir instead of trackdir in node key
4984308f9125 (svn r4987) Feature: Merged YAPF into trunk. Thanks to devs for continuous support and users for testing.
KUDr
parents:
diff changeset
    35
	YS_DEF(uint32, max_search_nodes)           ///< stop path-finding when this number of nodes visited
4984308f9125 (svn r4987) Feature: Merged YAPF into trunk. Thanks to devs for continuous support and users for testing.
KUDr
parents:
diff changeset
    36
	YS_DEF(bool  , ship_use_yapf)              ///< use YAPF for ships
4984308f9125 (svn r4987) Feature: Merged YAPF into trunk. Thanks to devs for continuous support and users for testing.
KUDr
parents:
diff changeset
    37
	YS_DEF(bool  , road_use_yapf)              ///< use YAPF for road
4984308f9125 (svn r4987) Feature: Merged YAPF into trunk. Thanks to devs for continuous support and users for testing.
KUDr
parents:
diff changeset
    38
	YS_DEF(bool  , rail_use_yapf)              ///< use YAPF for rail
3981
dc7c472bfcf4 (svn r5169) - CodeChange: [YAPF] RVs now use YAPF_TILE_LENGTH as base unit and 2 configurable settings (slope and crossing penalties) for cost calculation
KUDr
parents: 3935
diff changeset
    39
	YS_DEF(uint32, road_slope_penalty)         ///< penalty for up-hill slope
4411
c8eaf5401817 (svn r6164) -Fix [YAPF]: Road vehicles preferring bends - added yapf.road_curve_penalty setting with default value 100 (=YAPF_TILE_LENGTH) that is saved only in MP games (mart3p)
KUDr
parents: 3981
diff changeset
    40
	YS_DEF(uint32, road_curve_penalty)         ///< penalty for curves
3981
dc7c472bfcf4 (svn r5169) - CodeChange: [YAPF] RVs now use YAPF_TILE_LENGTH as base unit and 2 configurable settings (slope and crossing penalties) for cost calculation
KUDr
parents: 3935
diff changeset
    41
	YS_DEF(uint32, road_crossing_penalty)      ///< penalty for level crossing
3900
4984308f9125 (svn r4987) Feature: Merged YAPF into trunk. Thanks to devs for continuous support and users for testing.
KUDr
parents:
diff changeset
    42
	YS_DEF(bool  , rail_firstred_twoway_eol)   ///< treat first red two-way signal as dead end
4984308f9125 (svn r4987) Feature: Merged YAPF into trunk. Thanks to devs for continuous support and users for testing.
KUDr
parents:
diff changeset
    43
	YS_DEF(uint32, rail_firstred_penalty)      ///< penalty for first red signal
4984308f9125 (svn r4987) Feature: Merged YAPF into trunk. Thanks to devs for continuous support and users for testing.
KUDr
parents:
diff changeset
    44
	YS_DEF(uint32, rail_firstred_exit_penalty) ///< penalty for first red exit signal
4984308f9125 (svn r4987) Feature: Merged YAPF into trunk. Thanks to devs for continuous support and users for testing.
KUDr
parents:
diff changeset
    45
	YS_DEF(uint32, rail_lastred_penalty)       ///< penalty for last red signal
4984308f9125 (svn r4987) Feature: Merged YAPF into trunk. Thanks to devs for continuous support and users for testing.
KUDr
parents:
diff changeset
    46
	YS_DEF(uint32, rail_lastred_exit_penalty)  ///< penalty for last red exit signal
4984308f9125 (svn r4987) Feature: Merged YAPF into trunk. Thanks to devs for continuous support and users for testing.
KUDr
parents:
diff changeset
    47
	YS_DEF(uint32, rail_station_penalty)       ///< penalty for non-target station tile
4984308f9125 (svn r4987) Feature: Merged YAPF into trunk. Thanks to devs for continuous support and users for testing.
KUDr
parents:
diff changeset
    48
	YS_DEF(uint32, rail_slope_penalty)         ///< penalty for up-hill slope
4984308f9125 (svn r4987) Feature: Merged YAPF into trunk. Thanks to devs for continuous support and users for testing.
KUDr
parents:
diff changeset
    49
	YS_DEF(uint32, rail_curve45_penalty)       ///< penalty for curve
4984308f9125 (svn r4987) Feature: Merged YAPF into trunk. Thanks to devs for continuous support and users for testing.
KUDr
parents:
diff changeset
    50
	YS_DEF(uint32, rail_curve90_penalty)       ///< penalty for 90-deg curve
4984308f9125 (svn r4987) Feature: Merged YAPF into trunk. Thanks to devs for continuous support and users for testing.
KUDr
parents:
diff changeset
    51
	YS_DEF(uint32, rail_depot_reverse_penalty) ///< penalty for reversing in the depot
4984308f9125 (svn r4987) Feature: Merged YAPF into trunk. Thanks to devs for continuous support and users for testing.
KUDr
parents:
diff changeset
    52
	YS_DEF(uint32, rail_crossing_penalty)      ///< penalty for level crossing
4984308f9125 (svn r4987) Feature: Merged YAPF into trunk. Thanks to devs for continuous support and users for testing.
KUDr
parents:
diff changeset
    53
	YS_DEF(uint32, rail_look_ahead_max_signals)///< max. number of signals taken into consideration in look-ahead load balancer
4984308f9125 (svn r4987) Feature: Merged YAPF into trunk. Thanks to devs for continuous support and users for testing.
KUDr
parents:
diff changeset
    54
	YS_DEF(int32 , rail_look_ahead_signal_p0)  ///< constant in polynomial penalty function
4984308f9125 (svn r4987) Feature: Merged YAPF into trunk. Thanks to devs for continuous support and users for testing.
KUDr
parents:
diff changeset
    55
	YS_DEF(int32 , rail_look_ahead_signal_p1)  ///< constant in polynomial penalty function
4984308f9125 (svn r4987) Feature: Merged YAPF into trunk. Thanks to devs for continuous support and users for testing.
KUDr
parents:
diff changeset
    56
	YS_DEF(int32 , rail_look_ahead_signal_p2)  ///< constant in polynomial penalty function
3931
ca6abd14504a (svn r5066) -Feature: [YAPF] Train selects the best station platform by length
KUDr
parents: 3900
diff changeset
    57
3935
d0b7f6681727 (svn r5076) CodeChange: [YAPF] Platform selection feature related settings added into regular savegames (breaks savegame compatibility only with r5070 and 5071).
KUDr
parents: 3931
diff changeset
    58
	YS_DEF(uint32, rail_longer_platform_penalty)           ///< penalty for longer  station platform than train
d0b7f6681727 (svn r5076) CodeChange: [YAPF] Platform selection feature related settings added into regular savegames (breaks savegame compatibility only with r5070 and 5071).
KUDr
parents: 3931
diff changeset
    59
	YS_DEF(uint32, rail_longer_platform_per_tile_penalty)  ///< penalty for longer  station platform than train (per tile)
d0b7f6681727 (svn r5076) CodeChange: [YAPF] Platform selection feature related settings added into regular savegames (breaks savegame compatibility only with r5070 and 5071).
KUDr
parents: 3931
diff changeset
    60
	YS_DEF(uint32, rail_shorter_platform_penalty)          ///< penalty for shorter station platform than train
d0b7f6681727 (svn r5076) CodeChange: [YAPF] Platform selection feature related settings added into regular savegames (breaks savegame compatibility only with r5070 and 5071).
KUDr
parents: 3931
diff changeset
    61
	YS_DEF(uint32, rail_shorter_platform_per_tile_penalty) ///< penalty for shorter station platform than train (per tile)
5081
f71d1d2da6ed (svn r7145) Remove extra semicolons
tron
parents: 4549
diff changeset
    62
YS_DEF_END
3900
4984308f9125 (svn r4987) Feature: Merged YAPF into trunk. Thanks to devs for continuous support and users for testing.
KUDr
parents:
diff changeset
    63
4984308f9125 (svn r4987) Feature: Merged YAPF into trunk. Thanks to devs for continuous support and users for testing.
KUDr
parents:
diff changeset
    64
#undef YS_DEF_BEGIN
4984308f9125 (svn r4987) Feature: Merged YAPF into trunk. Thanks to devs for continuous support and users for testing.
KUDr
parents:
diff changeset
    65
#undef YS_DEF
4984308f9125 (svn r4987) Feature: Merged YAPF into trunk. Thanks to devs for continuous support and users for testing.
KUDr
parents:
diff changeset
    66
#undef YS_DEF_END
4984308f9125 (svn r4987) Feature: Merged YAPF into trunk. Thanks to devs for continuous support and users for testing.
KUDr
parents:
diff changeset
    67
4984308f9125 (svn r4987) Feature: Merged YAPF into trunk. Thanks to devs for continuous support and users for testing.
KUDr
parents:
diff changeset
    68
#endif /* !YAPF_SETTINGS_H || YS_DEF */