Commit Graph

64 Commits

Author SHA1 Message Date
Darkvater dad5d5dd72 (svn r6774) -Codechange: Rename the badly named OWNER_SPECTATOR to PLAYER_SPECTATOR and
put it into player.h where it belongs (instead of map.h)
2006-10-14 15:49:43 +00:00
belugas 17eb65050b (svn r6631) -Codechange: Use accessors for click_state.
Another step toward merging XTDwidget.
The only two files not converted (window.h and widget.c) will be done at the very last commit)
2006-10-03 20:16:20 +00:00
belugas 753b572400 (svn r6619) -Codechange: Use accessors for disabled_state.
Another step toward merging XTDwidget.
The only two files not converted (window.h and widget.c) will be done at the very last commit)
2006-10-03 02:08:15 +00:00
belugas 1c56a5ae0f (svn r6499) -Codechange: Finally, got "byte event" outside of the union WindowEvent, which is now a struct 2006-09-23 02:39:24 +00:00
Darkvater 80814dbb1d (svn r6406) -Codechange: Rename TileOffsByDir to TileOffsByDiagDir because it accepts
DiagDirections, and add TileOffsByDir that handles Directions.
-Codechange: Make the treeloop use TileOffsByDir().
2006-09-05 23:21:41 +00:00
belugas 5771cd10f9 (svn r6205) -CodeChange : use a switch case instead of a cascade of if
-CodeChange : rename var Engine *e to Engine *eng, since we have WindowEvent *e in same fnct
-CodeChange : fix a broken tabulation on a switch case. SOme breathing spaces too
2006-08-29 00:17:47 +00:00
rubidium 27cee58ab8 (svn r6204) -Cleanup: replace non-indentation with spaces; like '}<TAB>else {' -> '} else {', tabs between code and comment, etc. 2006-08-28 18:53:03 +00:00
belugas 4c2abf1de5 (svn r6046) CodeChange : Rename WWT_5 Widget type to WWT_LABEL : a centered label
CodeChange : Move almost all fixed strings from ON_PAINT event to Widget array using WWT_LABEL.
Feature : All "Select Refit Cargo" are now centered, instead of been left aligned
2006-08-22 15:23:25 +00:00
rubidium 480af9c917 (svn r6045) -Cleanup: align all table-like structures using spaces, i.e. whitespace fixes only except for a few comments to make them uniform for the whole enum/struct. 2006-08-22 14:38:37 +00:00
tron b0135b4381 (svn r5723) - Move the declaration of DrawRoadDepotSprite() out of functions.h (but I'm not too happy with the new header)
- Use DiagDirection instead of plain int for the orientation of the depot graphics
- Rename the associated data tables with sprites to something more meaningful
2006-08-03 06:44:54 +00:00
belugas 6082507fea (svn r5609) CodeChange : Apply coding style 2006-07-26 03:33:12 +00:00
tron 2b27073156 (svn r5391) Miscellaneous, mostly bracing and whitespace, nothing spectacular 2006-06-27 21:25:53 +00:00
tron c9be4eed53 (svn r5219) CMD_CLEAR_AREA doesn't use p2, so don't pass anything seemingly meaningful 2006-06-10 20:08:19 +00:00
tron 0a72639c2d (svn r5210) Many small changes which piled up: const, unsigned, variable scope, CSE for readability, DeMorgan, if cascades -> switch, whitespace, parentheses, bracing, misc. 2006-06-10 08:37:41 +00:00
rubidium e5bd292dab (svn r4789) - Codechange: rename RoadType to RoadTileType and ROAD_{NORMAL,CROSSING,DEPOT} to ROAD_TILE_* for consistency 2006-05-09 08:25:31 +00:00
tron 81e6d68f95 (svn r4342) Change the first two parameters of commands - virtual pixel coordinates of the tile to operate on - to a TileIndex
Remove DoCommandByTile(), because now it does the same as DoCommand()
2006-04-10 07:15:58 +00:00
tron 554f659e30 (svn r3774) Remove some more magic numbers and types 2006-03-06 13:29:27 +00:00
tron f3fb21c96c (svn r3773) Shove some semantics down ottd's throat by replacing ints and magic numbers by enums and some related changes 2006-03-06 13:11:08 +00:00
tron 40fd4377b0 (svn r3747) Change HASBIT() to return 0/1 instead of 0/value of tested bit, because the name suggests it does the former and current behavior broke in some places in very subtle ways (for example HASBIT(x, 0) != HASBIT(y, 1) doesn't work, returning a bool after HASBIT(x, 9) neither) 2006-03-03 19:42:09 +00:00
tron 84fb96fe85 (svn r3511) More whitespace ([FS#46] by Rubidium) 2006-02-01 07:36:15 +00:00
tron bf98086de8 (svn r3298) Remove unused and write-only variables 2005-12-14 06:28:48 +00:00
peter1138 1c57091230 (svn r3270) Correct all (mis)uses of WWT_CLOSEBOX / WWT_TEXTBTN to reflect their actual use, and add "Close Window" tooltip where missing. 2005-12-07 15:48:52 +00:00
tron f7abff5f96 (svn r3181) -Bracing
-Indentation
-Whitespace
-DeMorgan's Law
-Test with NULL or 0 for non-booleans
-'\0' instead of 0 for chars
-Remove redundantly redundant comments (like DoFoo(); // Do foo)
-Join multiple short lines with a single statement
-Split single lines with multiple statements
-Avoid assignments in if
2005-11-14 19:48:04 +00:00
tron 833032adc0 (svn r3177) GB, CLRBIT, HASBIT, TOGGLEBIT 2005-11-14 08:09:57 +00:00
tron 4a14a586e2 (svn r3173) Use the trinary operator and switch to improve readability
Also align short cases nicely
2005-11-13 14:54:09 +00:00
peter1138 350f0f2cdb (svn r3157) - Feature: Added patch option to link the terraform toolbar to the rail, road, water and airport toolbars. If enabled, the terraform toolbar will open and close with those toolbars. 2005-11-09 07:25:55 +00:00
tron a227065ab7 (svn r2701) Insert Id tags into all source files 2005-07-24 14:12:37 +00:00
tron 559babcdc9 (svn r2673) Include functions.h directly, not globally via openttd.h 2005-07-22 07:02:20 +00:00
tron 0762aa9ec9 (svn r2669) Shuffle some more stuff around to reduce dependencies 2005-07-21 22:15:02 +00:00
tron 8c1d74162f (svn r2558) Change the internal map format from 7 arrays to one array of structs, this doesn't change the saved format for now. It's a stepping stone for further changes. 2005-07-13 18:04:01 +00:00
tron 6e72d514b7 (svn r2496) -Fix: [1179933] When toggling build/remove via keyboard the selection wasn't correctly redrawn 2005-06-29 08:14:09 +00:00
tron 3154e7148d (svn r2483) Replace almost 500 "uint tile" (and variants) with "TileIndex tile" 2005-06-24 12:38:35 +00:00
Darkvater 5fed47964e (svn r2420) - Codechange: magic number elminitation of cursorsprites. 2005-06-06 13:47:06 +00:00
Darkvater b438b1248c (svn r2397) - CodeChange: rename all "ttd" files to "openttd" files. 2005-06-02 19:30:21 +00:00
tron 204d08140a (svn r1867) Include tables/sprites.h only in files which need it 2005-02-13 11:18:02 +00:00
celestar 752b3f0dd6 (svn r1721) -Feature: It is now possible to build multiple road stations (up to 8) on
a single station.
Thanks to: Truelight for the saveload code, Darkvater and Hackykid for
network testing and Tron for proof-reading 1500 lines of diff.
2005-01-29 19:41:44 +00:00
tron 5885b31bb4 (svn r1713) Split off several functions which query/set information about a single tile from map.h and put them into a seperate file tile.h 2005-01-29 12:19:05 +00:00
darkvater 1a92141896 (svn r1617) -Fix: Ugly hack to only call ResetObjectToPlaceon childwindows of build-toolbar if the window is closed manually (with 'X'); if not checked ResetObjectToPlace is called twice resulting in undesired actions (eg. clicked button is unclicked immediately). 2005-01-23 15:25:17 +00:00
tron 44f48ce915 (svn r1610) Remove trailing whitespace (last time ever, i hope) 2005-01-23 13:09:35 +00:00
tron 189ca73707 (svn r1594) Convert all undefined parameter lists to (void) and add the appropriate warning flags in the Makefile 2005-01-22 20:23:18 +00:00
celestar f0e616ea2b (svn r1573) -Fix: Station and depot building mode is now terminated if the
corresponding windows are closed [ 1104277 ]
2005-01-20 08:36:15 +00:00
tron ae796740aa (svn r1536) Move GET_TILEHEIGHT, GET_TILETYPE and IS_TILETYPE to map.h, turn them into inline functions and add some asserts 2005-01-16 11:24:58 +00:00
darkvater ff23795f5b (svn r1485) -Fix: [1031451] Catchment area shows when buying sign. Catchment area wasn't reset when road station window was unselected
-Fix: small GUI glitch in terraform toolbar
2005-01-12 00:50:08 +00:00
dominik bfc670b4d9 (svn r1435) Fix: [ 1094092 ] Toolbars accessible via keyboard in spectator mode 2005-01-08 20:55:21 +00:00
tron 67161506ad (svn r1386) Move TileIndexDiff to map.h
Move _tileoffs_by_dir to map.[ch] and encapsulate it in TileOffsByDir()
2005-01-05 13:32:03 +00:00
truelight a94fe04a9a (svn r1348) -Feature: resizable windows. Read the comment in window.h to find out
how the system works. All useful windows are already made resizable. Enjoy :)
-Fix: fixed some GUI-glitches and flaws along the way
2005-01-03 19:45:18 +00:00
dominik 60052ffb45 (svn r1254) - Fix: [ 993500 ] High bridge rendering error
- Changed button to open landscaping toolbar
2004-12-23 18:14:12 +00:00
darkvater b4c80052fe (svn r1243) -Fix: Scenario road-building toolbar also stickified. Thx for the notice teeone 2004-12-23 11:36:22 +00:00
darkvater 222d6ca952 (svn r1212) -Feature: sticky windows all build-toolbars 2004-12-22 00:18:40 +00:00
tron 765ecfed84 (svn r1117) Move map arrays and some related macros into their own files map.c and map.h 2004-12-15 22:18:54 +00:00