truelight
505566da5c
(svn r6047) -Codechange: FOR_ALL now _only_ loops valid items, and skips invalid ones
...
-Codechange: use IsValidXXX where ever possible
Note: both changes to prepare for new pool system, which needs those changes.
For every pool there are 2 ugly lines, which will be removed when done
implementing new pool system.
Based on FS#13 by blathijs, partly implemented.
18 years ago
rubidium
908d3bcfe6
(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.
18 years ago
rubidium
db397d5a75
(svn r6002) -Cleanup: remove the now redundant BASE_YEAR constant.
18 years ago
truelight
054dd2802b
(svn r5972) -Fix: usr strrchr instead of your own function (tnx Darkvater)
...
-Codechange: added some comments and const correctness (Darkvater)
18 years ago
truelight
17127970fe
(svn r5968) -Feature: add auto-completion in chat-window. It completes Player-Names and
...
Town-Names (that order) using <tab>. Based on FS#28 by egladil.
18 years ago
truelight
7abad2b20e
(svn r5946) -Add: merged the TGP branch to mainline. TGP adds:
...
- New optional landscape generator (TerraGenesis Perlin)
- Load heightmaps (either BMP or PNG)
- Progress dialog while generating worlds (no longer a 'hanging' screen)
- New dialogs for NewGame, Create Scenario and Play Heightmap
- Easier to configure your landscape
- More things to configure (tree-placer, ..)
- Speedup of world generation
- New console command 'restart': restart the map EXACTLY as it was when you
first started it (needs a game made after or with this commit)
- New console command 'getseed': get the seed of your map and share it with
others (of course only works with generated maps)
- Many new, world generation related, things
- Many internal cleanups and rewrites
Many tnx to those people who helped making this:
Belugas, DaleStan, glx, KUDr, RichK67, Rubidium, and TrueLight (alfabetic)
Many tnx to those who helped testing:
Arnau, Bjarni, and tokai (alfabetic)
And to all other people who helped testing and sending comments / bugs
Stats: 673 lines changed, 3534 new lines, 79 new strings
18 years ago
truelight
d3f2180438
(svn r5944) -Merge TGP (r5578, r5579, r5724, r5726): -Feature: filter for textboxes to only
...
allow certain patterns (like numbers only)
18 years ago
rubidium
c55962f8a2
(svn r5916) -Cleanup: use MIN_YEAR/MAX_YEAR for the year boundaries and BASE_YEAR when comparing _cur_year with a 'full' year.
...
-Cleanup: replace some magic '1920' values with BASE_YEAR.
18 years ago
rubidium
9fc837ad85
(svn r5887) -Cleanup: move date related functions, defines and variables to date.[ch]
...
-Cleanup: fix whitespace related coding style issues in date.[ch]
-Cleanup: make original comments doxygen compatible and remove/change outdated comments
18 years ago
Darkvater
97c3b5cad8
(svn r5767) - Cleanup: Improve upon the header file mess regarding fios. Move all relevant types from hal.h into fios.h, eliminate the unneccessary passing of a global variable, and extern variables in header files (declare in fios.c and misc_gui.c
18 years ago
Darkvater
7ce6a95eb9
(svn r5655) -Fix [SF 1424115]: Reversed arrow-sign in the multiplayer list column headers on sort by name
18 years ago
belugas
40a8964911
(svn r5609) CodeChange : Apply coding style
18 years ago
tron
772fbda3e3
(svn r5391) Miscellaneous, mostly bracing and whitespace, nothing spectacular
18 years ago
tron
347473b0b0
(svn r5226) Reduce the mess that sending chat messages is
...
This also fixes a bug:
-Fix: It was possible to rename a signs or waypoints with the chat box
18 years ago
Darkvater
2128dbec13
(svn r4892) - Fix [FS#162]: SEGV when sorting an empty server list. (glx)
19 years ago
Darkvater
26db3ac91f
(svn r4623) - Codechange: s/byte/PlayerID/
19 years ago
tron
5b7e846fd4
(svn r4315) Remove MAX_QUERYSTR_LEN, rather use lengthof() the real thing
19 years ago
tron
0099dc31f5
(svn r4314) -Fix: a buffer overflow of the chat box introduced in r1263. Don't tell the Textbuf an arbitrary number as size of the string buffer, but the real lengthof() it
19 years ago
tron
59f0e69521
(svn r4313) The parent window of the chat box is always the main toolbar (?!), therefore don't pass this information as parameter
19 years ago
tron
2e2235e3cf
(svn r4312) Calculate the maximum pixel width of the entered text in the chat box from the "text box"-widget instead of hardcoding an arbitrary - and wrong - number
19 years ago
tron
90927c22a5
(svn r4310) The chat box has no visible window title, therefore remove the string
19 years ago
tron
98b51c36e2
(svn r4309) The initial string of the chat box is always the empty string, so don't jump through hoops to check if nothing was entered and simplify the code
19 years ago
tron
f5dac4082c
(svn r4304) The chat box' parent window (the main toolbar, wtf?) doesn't care for the WE_ON_EDIT_TEXT_CANCEL event, so don't send one. This code looks like it was mindlessly copy&pasted from the query box
19 years ago
Darkvater
c8a85d5419
(svn r4301) - Fix: the maxlength parameter of Textbuf is supposed to be the size of the buffer (so length of string + '\0'), but in the code it was a mix of both. It didn't cause any problems though, only an occasionaly one-less character than allowed. (thanks Tron for noticing)
19 years ago
Darkvater
0d310e213a
(svn r3933) - [ 1439907 ] Increase client list window width so at least most languages fit (wikipedian).
19 years ago
tron
1c3e8630fe
(svn r3511) More whitespace ([FS#46] by Rubidium)
19 years ago
Darkvater
009e9bf424
(svn r3501) - Load the lobby-window with up-to-date data upon opening
19 years ago
Darkvater
bfe7040cde
(svn r3499) - Fix: a few gui glitches in the network window:
...
1. disable widgets also when the active companies/spectators is bigger than the max.
This can happen if the server has changed the settings.
2. updated scroll-count in the lobby as the window is higher.
19 years ago
Darkvater
35e369336e
(svn r3494) - Update several languages. Thanks all translators online atm (Bjarni, glx, MeusH, Tron, me, my sister)
...
- Remove the most blatant of untranslated or wrongly-outdated strings.
19 years ago
Darkvater
3f7cb3d0eb
(svn r3478) - Fix: In the network game list do the default sorting on connectivity (so servers which you can join are on top) and sort on names as a second criteria on clients and connectivity.
19 years ago
Darkvater
35c5738689
(svn r3469) - Fix: plug a possible memleak with subsequential strdup's without freeing the previous value and make it possible to ban offline clients
19 years ago
Darkvater
0855449106
(svn r3442) - Fix: Only windows has stricmp. So define strcasecmp to stricmp when using MSVC
19 years ago
Darkvater
227769d709
(svn r3441) - Feature: Allow the network game list to be sorted (by name/clients/compatibility ascending/descending)
19 years ago
Darkvater
1ba8bcd0de
(svn r3439) - CodeChange: Remove a whole bunch of global variables and put them into the WP() macro. Also combine more than one WP-custom element. For this the maximum size of w->custom (WP) has been increased, and multiple types put inside one with possibly moved to the corresponding gui file if it is only used there.
19 years ago
Darkvater
f99a200470
(svn r3438) - Fix: first request company data, then general. Yes, it should be the other way around, but with the current network code this doesn't work. So workaround (have some nice promise from TrueLight for fixing ;))
19 years ago
Darkvater
1be559cfb8
(svn r3435) - Fix a warning, removed unused extern and some comments in network_gamelist.c
19 years ago
Darkvater
7eaac72326
(svn r3434) - Correctly update all network information when pressing refresh in the lobby. Also always allow the join button to a server unless all clients are used up (otherwise you can always join an existing company
19 years ago
Darkvater
f14df34790
(svn r3429) - Feature (Followup): Change the gamelist window to accomodate for the new information.
19 years ago
Darkvater
082aa38f79
(svn r3427) - Feature: Allow seeing and setting the maximum amount of companies and spectators for a server. This can be changed/viewed during runtime as well in the console.
19 years ago
tron
849fff602d
(svn r3336) byte -> WindowClass, uint16 -> WindowNumber
19 years ago
Darkvater
eea9e95278
(svn r3322) - Fix: Network window crash when it receives invalid information for example from the integrated nightly, so validate the network-input when it is received
...
- CodeChange: added str_validate(char *str) function that checks if a string contains only printable characters and if not, replaces those characters by question marks. Also move IsValidAsciiChar() to string.h
19 years ago
tron
a2533d5ee6
(svn r3298) Remove unused and write-only variables
19 years ago
peter1138
5f3dc36983
(svn r3270) Correct all (mis)uses of WWT_CLOSEBOX / WWT_TEXTBTN to reflect their actual use, and add "Close Window" tooltip where missing.
19 years ago
tron
ea1921d2e0
(svn r3211) Fix typo in r3181
19 years ago
tron
9d0e7b6458
(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
19 years ago
tron
81e5b16d71
(svn r3172) static, const
19 years ago
tron
181d586a7c
(svn r3078) Some more stuff, which piled up:
...
- const, whitespace, indentation, bracing, GB/SB, pointless casts
- use the trinary operator where appropriate
- data types (uint[] -> AcceptedCargo, ...)
- if cascade -> switch
- if (ptr) -> if (ptr != NULL)
- DeMorgan's Law
- Fix some comments
- 0 -> '\0', change magic numbers to symbolic constants
19 years ago
tron
647cbd6bdd
(svn r2701) Insert Id tags into all source files
19 years ago
tron
54cbd01825
(svn r2673) Include functions.h directly, not globally via openttd.h
19 years ago
Darkvater
09195e0bda
(svn r2624) - Fix: oops, forgot to change the already in use DrawStringCenteredTruncated() functions.
19 years ago