summaryrefslogtreecommitdiff
path: root/src/company_cmd.cpp
AgeCommit message (Collapse)Author
2021-02-18Fix: Whole status bar instead of money widget refreshed on money change (#8692)Jonathan G Rennison
This could result in the rest of the status bar being redrawn unnecessarily frequently
2021-01-22Change: Apply some consistency to singleplayer related commentsglx22
2021-01-22Fix: Never delete the last existing company in singleplayer modeglx22
2021-01-08Codechange: Remove min/max functions in favour of STL variants (#8502)Charles Pigott
2021-01-05Change: move "give money" from client-list to company windowPatric Stout
This is a much better location for this button, as you send money from one company to another company, not from player to player. This is based on work done by JGRPP in: https://github.com/JGRennison/OpenTTD-patches/commit/f82054339124cc6b89c5f4f9dac2d9da62f0108b and surrounding commits, which took the work from estys: https://www.tt-forums.net/viewtopic.php?p=1183311#p1183311 We did modify it to fix several bugs and clean up the code while here anyway. The callback was removed, as it meant a modified client could prevent anyone from seeing money was transfered. The message is now generated in the command itself, making that impossible.
2020-12-16Change: extend the allowed range for max loan setting (#8386)Pavel Stupnikov
2020-05-21Codechange: Use std::string for most of the user-settable custom names.Michael Lutz
2020-02-17Codechange: Avoid copying function parameters by using const referencesQuipyowert2
2019-12-21Codechange: Replace vehicle related FOR_ALL with range-based for loopsglx
2019-12-21Codechange: Replace FOR_ALL_GROUPS with range-based for loopsglx
2019-12-21Codechange: Replace FOR_ALL_COMPANIES with range-based for loopsglx
2019-11-10Cleanup: Removed SVN headersS. D. Cloudt
2019-09-14Fix #7479: Don't close construction windows when changing client nameNiels Martin Hansen
2019-05-01Feature: Add NotRoadTypes (NRT)peter1138
2019-04-29Codechange: Remove Company/OwnerByte typesCharles Pigott
2019-04-10Codechange: Use null pointer literal instead of the NULL macroHenry Wilson
2019-04-05Fix #7439: don't overwrite CompanyRemoveReason with ClientID (#7465)glx22
2019-03-20Remove: ENABLE_NETWORK switchPatric Stout
This switch has been a pain for years. Often disabling broke compilation, as no developer compiles OpenTTD without, neither do any of our official binaries. Additionaly, it has grown so hugely in our codebase, that it clearly shows that the current solution was a poor one. 350+ instances of "#ifdef ENABLE_NETWORK" were in the code, of which only ~30 in the networking code itself. The rest were all around the code to do the right thing, from GUI to NewGRF. A more proper solution would be to stub all the functions, and make sure the rest of the code can simply assume network is available. This was also partially done, and most variables were correct if networking was disabled. Despite that, often the #ifdefs were still used. With the recent removal of DOS, there is also no platform anymore which we support where networking isn't working out-of-the-box. All in all, it is time to remove the ENABLE_NETWORK switch. No replacement is planned, but if you feel we really need this option, we welcome any Pull Request which implements this in a way that doesn't crawl through the code like this diff shows we used to.
2019-02-10Codechange: In CmdCompanyCtrl, move client_id assignment to where it is ↵Peter Nelson
used, and document bit usage better.
2019-02-05Fix #7151: Hang when concurrently starting AIs in multiplayer, or with shift ↵Peter Nelson
pressed.
2019-02-04Add: CompanyCtrlAction enum for CMD_COMPANY_CTRL actionsglx
2019-02-02Change: Allow AI companies to start immediately.Samu
Allow multiple AIs to possibly start in the same tick. start_date = 0 becomes a special case, where random deviation does not occur. If start_date was not already 0, then a minimum value of 1 must apply.
2019-01-31Feature: Group liveries, and livery window usability enhancements. (#7108)PeterN
* Change: Replace checkbox in livery selection window with Default option in drop down selection. This reduces clutter in the UI and allows for primary/secondary colours to independently follow the default scheme if desired. * Feature: Add vehicle group liveries.
2018-10-31Doc: Lots and lots of doxymentation fixesCharles Pigott
2017-08-13(svn r27893) -Codechange: Use fallthrough attribute. (LordAro)frosch
2014-09-07(svn r26802) -Add: Command to set visibility of an engine for a company ↵alberth
(based on patch by Juanjo).
2014-05-11(svn r26578) -Fix (r26576): network compilation got brokenrubidium
2014-05-11(svn r26576) -Fix [FS#6003]: [Network] AIs would not reset certain network ↵rubidium
state information upon creation of their company
2014-04-25(svn r26509) -Codechange: replace strdup with stredup (the latter ensures ↵rubidium
the return is not NULL)
2014-04-23(svn r26486) -Codechange: replace a number of snprintfs with seprintfrubidium
2014-04-23(svn r26482) -Codechange: add an include that allows us to undefine/redefine ↵rubidium
"unsafe" functions to prevent them from being used, and thus having to care about certain aspects of their return values
2013-09-13(svn r25761) -Change: Disable story/goal buttons when there is no content to ↵zuu
show instead of when there is zero companies
2013-06-27(svn r25490) -Fix [FS#5610]: the face of the manager differed on clients ↵rubidium
when the company was started after the clients joined
2013-05-19(svn r25263) -Add: legend for linkgraph overlay (fonsinchen)rubidium
2013-02-14(svn r24995) -Codechange: Add flags to vehicle service interval for custom & ↵rubidium
ispercent (peter1138)
2012-12-23(svn r24846) -Add: Advanced settings to disable certain sound effects.frosch
2012-05-26(svn r24284) -Codechange: Remove NewsSubtypes and directly use NewsTypes and ↵frosch
NewsFlag instead.
2012-05-26(svn r24281) -Cleanup: Merge all company news subtypes into a single one; ↵frosch
they all behave the same.
2012-04-17(svn r24134) -Add: Configurable limits for tree planting.michi_cc
2012-01-17(svn r23822) -Fix-ish: when replaying make sure companies get created even ↵rubidium
if their creating client doesn't exist during the replay
2012-01-03(svn r23741) -Revert (r23740): the few parts that the Windows / non-network ↵rubidium
compiles stumble on
2012-01-03(svn r23740) -Codechange: remove some 300 unneeded includes from the .cpp filesrubidium
2012-01-03(svn r23728) -Fix [#FS4942-ish]: when cheating into another company, the ↵truebrain
SignList was not updated
2011-12-21(svn r23648) -Revert (r23646): partial revert; nobody has to know about my ↵truebrain
local changes and attempts
2011-12-21(svn r23646) -Fix [FS#4901]: rescan the Game Scripts when done downloading one.truebrain
2011-12-19(svn r23622) -Add: a set of events to trigger in a GameScripttruebrain
2011-12-19(svn r23601) -Fix: fix the conflict in window numbertruebrain
2011-12-02(svn r23398) -Fix: the AIEvent.ET_COMPANY_NEW was only triggered if a ↵truebrain
company named itself, which seems like a very odd place to do so. Trigger it when the company is created instead
2011-12-01(svn r23384) -Remove: no longer allow a binary to be without AI support; the ↵truebrain
parts some compilers failed at, are integrated in other parts of the code now too
2011-11-29(svn r23355) -Codechange: rename all AI* to Script* (Rubidium)truebrain