mirror of
https://github.com/OpenTTD/OpenTTD.git
synced 2025-03-06 14:27:16 +00:00
(svn r2626) static, const, misc.
This commit is contained in:
parent
1d11bbb34d
commit
59d4ab3752
@ -379,14 +379,14 @@ void ShowNetworkNeedCompanyPassword(void)
|
|||||||
|
|
||||||
#endif /* ENABLE_NETWORK */
|
#endif /* ENABLE_NETWORK */
|
||||||
|
|
||||||
void ShowRenameSignWindow(SignStruct *ss)
|
void ShowRenameSignWindow(const SignStruct *ss)
|
||||||
{
|
{
|
||||||
_rename_id = ss->index;
|
_rename_id = ss->index;
|
||||||
_rename_what = 0;
|
_rename_what = 0;
|
||||||
ShowQueryString(ss->str, STR_280B_EDIT_SIGN_TEXT, 30, 180, 1, 0);
|
ShowQueryString(ss->str, STR_280B_EDIT_SIGN_TEXT, 30, 180, 1, 0);
|
||||||
}
|
}
|
||||||
|
|
||||||
void ShowRenameWaypointWindow(Waypoint *wp)
|
void ShowRenameWaypointWindow(const Waypoint *wp)
|
||||||
{
|
{
|
||||||
int id = wp->index;
|
int id = wp->index;
|
||||||
|
|
||||||
|
2
signs.h
2
signs.h
@ -58,6 +58,6 @@ void UpdateAllSignVirtCoords(void);
|
|||||||
void PlaceProc_Sign(TileIndex tile);
|
void PlaceProc_Sign(TileIndex tile);
|
||||||
|
|
||||||
/* misc.c */
|
/* misc.c */
|
||||||
void ShowRenameSignWindow(SignStruct *ss);
|
void ShowRenameSignWindow(const SignStruct *ss);
|
||||||
|
|
||||||
#endif /* SIGNS_H */
|
#endif /* SIGNS_H */
|
||||||
|
@ -1214,7 +1214,7 @@ static void EffectVehicle_Tick(Vehicle *v)
|
|||||||
_effect_tick_procs[v->subtype](v);
|
_effect_tick_procs[v->subtype](v);
|
||||||
}
|
}
|
||||||
|
|
||||||
Vehicle *CheckClickOnVehicle(ViewPort *vp, int x, int y)
|
Vehicle *CheckClickOnVehicle(const ViewPort *vp, int x, int y)
|
||||||
{
|
{
|
||||||
Vehicle *found = NULL, *v;
|
Vehicle *found = NULL, *v;
|
||||||
uint dist, best_dist = (uint)-1;
|
uint dist, best_dist = (uint)-1;
|
||||||
|
@ -302,7 +302,7 @@ TileIndex GetVehicleOutOfTunnelTile(const Vehicle *v);
|
|||||||
bool UpdateSignalsOnSegment(TileIndex tile, byte direction);
|
bool UpdateSignalsOnSegment(TileIndex tile, byte direction);
|
||||||
void SetSignalsOnBothDir(TileIndex tile, byte track);
|
void SetSignalsOnBothDir(TileIndex tile, byte track);
|
||||||
|
|
||||||
Vehicle *CheckClickOnVehicle(ViewPort *vp, int x, int y);
|
Vehicle *CheckClickOnVehicle(const ViewPort *vp, int x, int y);
|
||||||
//uint GetVehicleWeight(Vehicle *v);
|
//uint GetVehicleWeight(Vehicle *v);
|
||||||
|
|
||||||
void DecreaseVehicleValue(Vehicle *v);
|
void DecreaseVehicleValue(Vehicle *v);
|
||||||
|
494
viewport.c
494
viewport.c
File diff suppressed because it is too large
Load Diff
@ -14,11 +14,10 @@ struct ViewPort {
|
|||||||
void SetSelectionRed(bool);
|
void SetSelectionRed(bool);
|
||||||
|
|
||||||
/* viewport.c */
|
/* viewport.c */
|
||||||
Point MapXYZToViewport(ViewPort *vp, uint x, uint y, uint z);
|
|
||||||
void AssignWindowViewport(Window *w, int x, int y,
|
void AssignWindowViewport(Window *w, int x, int y,
|
||||||
int width, int height, uint32 follow_flags, byte zoom);
|
int width, int height, uint32 follow_flags, byte zoom);
|
||||||
void SetViewportPosition(Window *w, int x, int y);
|
void SetViewportPosition(Window *w, int x, int y);
|
||||||
ViewPort *IsPtInWindowViewport(Window *w, int x, int y);
|
ViewPort *IsPtInWindowViewport(const Window *w, int x, int y);
|
||||||
Point GetTileBelowCursor(void);
|
Point GetTileBelowCursor(void);
|
||||||
void ZoomInOrOutToCursorWindow(bool in, Window * w);
|
void ZoomInOrOutToCursorWindow(bool in, Window * w);
|
||||||
Point GetTileZoomCenterWindow(bool in, Window * w);
|
Point GetTileZoomCenterWindow(bool in, Window * w);
|
||||||
@ -36,7 +35,7 @@ void AddChildSpriteScreen(uint32 image, int x, int y);
|
|||||||
void StartSpriteCombine(void);
|
void StartSpriteCombine(void);
|
||||||
void EndSpriteCombine(void);
|
void EndSpriteCombine(void);
|
||||||
|
|
||||||
void HandleViewportClicked(ViewPort *vp, int x, int y);
|
void HandleViewportClicked(const ViewPort *vp, int x, int y);
|
||||||
void PlaceObject(void);
|
void PlaceObject(void);
|
||||||
void SetRedErrorSquare(TileIndex tile);
|
void SetRedErrorSquare(TileIndex tile);
|
||||||
void SetTileSelectSize(int w, int h);
|
void SetTileSelectSize(int w, int h);
|
||||||
|
@ -56,7 +56,7 @@ static inline bool IsRailWaypoint(byte m5)
|
|||||||
int32 RemoveTrainWaypoint(TileIndex tile, uint32 flags, bool justremove);
|
int32 RemoveTrainWaypoint(TileIndex tile, uint32 flags, bool justremove);
|
||||||
Station *ComposeWaypointStation(TileIndex tile);
|
Station *ComposeWaypointStation(TileIndex tile);
|
||||||
Waypoint *GetWaypointByTile(TileIndex tile);
|
Waypoint *GetWaypointByTile(TileIndex tile);
|
||||||
void ShowRenameWaypointWindow(Waypoint *cp);
|
void ShowRenameWaypointWindow(const Waypoint *cp);
|
||||||
void DrawWaypointSprite(int x, int y, int image, int railtype);
|
void DrawWaypointSprite(int x, int y, int image, int railtype);
|
||||||
void UpdateWaypointSign(Waypoint *cp);
|
void UpdateWaypointSign(Waypoint *cp);
|
||||||
void FixOldWaypoints(void);
|
void FixOldWaypoints(void);
|
||||||
|
2
window.h
2
window.h
@ -399,7 +399,7 @@ typedef struct {
|
|||||||
assert_compile(WINDOW_CUSTOM_SIZE >= sizeof(refit_d));
|
assert_compile(WINDOW_CUSTOM_SIZE >= sizeof(refit_d));
|
||||||
|
|
||||||
typedef struct {
|
typedef struct {
|
||||||
uint16 follow_vehicle;
|
VehicleID follow_vehicle;
|
||||||
int32 scrollpos_x;
|
int32 scrollpos_x;
|
||||||
int32 scrollpos_y;
|
int32 scrollpos_y;
|
||||||
} vp_d;
|
} vp_d;
|
||||||
|
Loading…
Reference in New Issue
Block a user