121 the track configuration of 2 adjacent tiles. trackconfig[0] stores the |
121 the track configuration of 2 adjacent tiles. trackconfig[0] stores the |
122 current tile (home tile) while [1] holds the neighbour */ |
122 current tile (home tile) while [1] holds the neighbour */ |
123 TrackBits trackconfig[TS_END]; |
123 TrackBits trackconfig[TS_END]; |
124 bool isflat[TS_END]; |
124 bool isflat[TS_END]; |
125 /* Note that ti->tileh has already been adjusted for Foundations */ |
125 /* Note that ti->tileh has already been adjusted for Foundations */ |
126 uint tileh[TS_END] = {ti->tileh, 0}; |
126 uint tileh[TS_END]; |
127 |
127 |
128 TLG tlg = GetTLG(ti->tile); |
128 TLG tlg = GetTLG(ti->tile); |
129 byte PCPstatus = 0; |
129 byte PCPstatus = 0; |
130 byte OverridePCP = 0; |
130 byte OverridePCP = 0; |
131 byte PPPpreferred[DIAGDIR_END] = {0xFF, 0xFF, 0xFF, 0xFF}; |
131 byte PPPpreferred[DIAGDIR_END]; |
132 byte PPPallowed[DIAGDIR_END] = {AllowedPPPonPCP[0], AllowedPPPonPCP[1], AllowedPPPonPCP[2], AllowedPPPonPCP[3]}; |
132 byte PPPallowed[DIAGDIR_END]; |
133 byte PPPbuffer[DIAGDIR_END]; |
133 byte PPPbuffer[DIAGDIR_END]; |
134 DiagDirection i; |
134 DiagDirection i; |
135 Track t; |
135 Track t; |
|
136 |
|
137 tileh[0] = ti->tileh; |
|
138 tileh[1] = 0; |
|
139 |
|
140 PPPpreferred[0] = PPPpreferred[1] = PPPpreferred[2] = PPPpreferred[3] = 0xFF; |
|
141 PPPallowed[0] = AllowedPPPonPCP[0]; |
|
142 PPPallowed[1] = AllowedPPPonPCP[1]; |
|
143 PPPallowed[2] = AllowedPPPonPCP[2]; |
|
144 PPPallowed[3] = AllowedPPPonPCP[3]; |
136 |
145 |
137 /* Find which rail bits are present, and select the override points. |
146 /* Find which rail bits are present, and select the override points. |
138 We don't draw a pylon: |
147 We don't draw a pylon: |
139 1) INSIDE a tunnel (we wouldn't see it anyway) |
148 1) INSIDE a tunnel (we wouldn't see it anyway) |
140 2) on the "far" end of a bridge head (the one that connects to bridge middle), |
149 2) on the "far" end of a bridge head (the one that connects to bridge middle), |