|
@@ -2047,13 +2047,13 @@ static bool SwapDirection(HighLightStyle
|
|
|
|
|
|
/** Calculates height difference between one tile and another
|
|
|
* Multiplies the result to suit the standard given by minimap - 50 meters high
|
|
|
* To correctly get the height difference we need the direction we are dragging
|
|
|
* in, as well as with what kind of tool we are dragging. For example a horizontal
|
|
|
* autorail tool that starts in bottom and ends at the top of a tile will need the
|
|
|
* maximum of SW,S and SE,N corners respectively. This is handled by the lookup table below
|
|
|
* maximum of SW, S and SE, N corners respectively. This is handled by the lookup table below
|
|
|
* See _tileoffs_by_dir in map.c for the direction enums if you can't figure out
|
|
|
* the values yourself.
|
|
|
* @param style HightlightStyle of drag. This includes direction and style (autorail, rect, etc.)
|
|
|
* @param distance amount of tiles dragged, important for horizontal/vertical drags
|
|
|
* ignored for others
|
|
|
* @param start_tile, end_tile start and end tile of drag operation
|
|
@@ -2392,13 +2392,13 @@ bool VpHandlePlaceSizingDrag()
|
|
|
|
|
|
if (_special_mouse_mode != WSM_SIZING) return true;
|
|
|
|
|
|
e.we.place.userdata = _thd.userdata;
|
|
|
|
|
|
/* stop drag mode if the window has been closed */
|
|
|
w = FindWindowById(_thd.window_class,_thd.window_number);
|
|
|
w = FindWindowById(_thd.window_class, _thd.window_number);
|
|
|
if (w == NULL) {
|
|
|
ResetObjectToPlace();
|
|
|
return false;
|
|
|
}
|
|
|
|
|
|
/* while dragging execute the drag procedure of the corresponding window (mostly VpSelectTilesWithMethod() ) */
|