Jonathan G Rennison
838b166726
Merge branch 'master' into jgrpp
...
# Conflicts:
# src/cheat_gui.cpp
# src/command.cpp
# src/command_func.h
# src/company_base.h
# src/debug.cpp
# src/debug.h
# src/economy.cpp
# src/engine_type.h
# src/graph_gui.cpp
# src/misc_cmd.cpp
# src/misc_cmd.h
# src/network/core/os_abstraction.cpp
# src/openttd.cpp
# src/saveload/saveload.cpp
# src/saveload/saveload.h
# src/settings_type.h
# src/ship_cmd.cpp
# src/stdafx.h
# src/tests/bitmath_func.cpp
# src/town_cmd.cpp
# src/town_gui.cpp
3 months ago
merni-ns
5a88027a19
Feature: Infinite money mode ( #11902 )
4 months ago
Jonathan G Rennison
97e6f3062e
Adding of _t to (u)int types, and WChar to char32_t
...
See: eaae0bb5e
4 months ago
Jonathan G Rennison
55d78a23be
Merge branch 'master' into jgrpp
...
# Conflicts:
# src/3rdparty/squirrel/include/squirrel.h
# src/blitter/32bpp_sse_func.hpp
# src/bridge_map.h
# src/clear_map.h
# src/company_manager_face.h
# src/console_func.h
# src/core/bitmath_func.hpp
# src/core/endian_func.hpp
# src/core/random_func.hpp
# src/depot_map.h
# src/elrail_func.h
# src/fontcache.h
# src/industry_map.h
# src/map_func.h
# src/newgrf_spritegroup.h
# src/object_map.h
# src/rail.h
# src/rail_map.h
# src/road_func.h
# src/road_map.h
# src/saveload/saveload.h
# src/saveload/saveload_error.hpp
# src/settings_gui.cpp
# src/sl/oldloader.h
# src/sprite.h
# src/spritecache.h
# src/station_func.h
# src/station_map.h
# src/story_base.h
# src/strings_func.h
# src/tile_cmd.h
# src/tile_map.h
# src/tile_type.h
# src/town.h
# src/town_map.h
# src/tree_map.h
# src/tunnel_map.h
# src/tunnelbridge_map.h
# src/vehicle_func.h
# src/viewport_func.h
# src/void_map.h
# src/water.h
# src/water_map.h
# src/widget_type.h
4 months ago
Charles Pigott
1e60734660
Fix: Compilation with DEBUG_DUMP_COMMANDS enabled ( #11607 )
5 months ago
Jonathan G Rennison
59ea48c541
Scheduled dispatch: Allow moving dispatch schedules in schedule list
8 months ago
frosch
b6c8f301be
Codechange: Silence warnings about intentionally unused parameters.
8 months ago
Jonathan G Rennison
644d2632f8
Move command log functions to their own header, fix missing include
...
See: #586
9 months ago
Jonathan G Rennison
731a79b224
Fix truncation of dump_command_log console command output
10 months ago
Jonathan G Rennison
d03465db59
Set default values for DoCommandPEx optional parameters
12 months ago
Jonathan G Rennison
cd9930542d
GS: Add GSAsyncMode(bool) class to set async mode of script DoCommands
...
In asynchronous mode, don't wait for result of executed command,
just fire-and-forget, and return estimated cost/result
12 months ago
dP
e3169c73bd
Fix: Restore using founder client name as company manager name ( #10535 )
1 year ago
dP
c73b88ddca
Fix: Don't send unused tile field over the network ( #10507 )
1 year ago
dP
b5bc001d42
Codechange: Swap comments for CommandHelper::Post overloads ( #10454 )
1 year ago
Rubidium
fe2bcd2a58
Codechange: migrate size related functions to Map structure
1 year ago
Jonathan G Rennison
f32733ef22
Command: Replace binary_length field with auxiliary data
...
Use for CMD_ADD_PLAN_LINE
1 year ago
Jonathan G Rennison
bd2593ca48
Add function to enqueue a DoCommandP call
2 years ago
Michael Lutz
dd93244853
Fix: The first tile in commands received from a client wasn't validated properly.
2 years ago
Jonathan G Rennison
ff3473fe6a
Add support for multiple scheduled dispatch schedules per order list
2 years ago
Michael Lutz
2e39637db2
Codechange: Don't use a global for the 'not enough cash' message.
2 years ago
Michael Lutz
3e85e833a7
Codechange: Add support for additional command result values.
2 years ago
Michael Lutz
8503854655
Codechange: Pass unpacked command arguments to command callbacks (except Script).
2 years ago
Michael Lutz
d85348b1d1
Codechange: Template the command callback function type to allow unpacked arguments.
2 years ago
Michael Lutz
de45a8729c
Codechange: Add DoCommand::Post specialization for commands that take no TileIndex.
...
This adds a new Post overloads that still take a TileIndex which
is used to place any error windows or text effects.
2 years ago
Michael Lutz
4f3ea3907e
Codechange: Un-bitstuff commands taking a ClientID (i.e. CMD_CLIENT_ID).
2 years ago
Michael Lutz
ccefa76a46
Codechange: Template DoCommandPInternal.
2 years ago
Michael Lutz
eab18f06a4
Codechange: Pass additional data as byte stream to command callbacks.
2 years ago
Michael Lutz
0f64ee5ce1
Codechange: Template DoCommandP to automagically reflect the parameters of the command proc.
...
When finished, this will allow each command handler to take individually
different parameters, obliviating the need for bit-packing.
2 years ago
Michael Lutz
e740c24eb7
Codechange: Template DoCommand to automagically reflect the parameters of the command proc.
...
When finished, this will allow each command handler to take individually
different parameters, obliviating the need for bit-packing.
2 years ago
Michael Lutz
c88b104ec6
Codechange: Use wrapper struct to automatically manage command depth tracking.
2 years ago
Michael Lutz
996b16de70
Codechange: Use lambdas instead of CommandContainer to manage station picker commands.
2 years ago
Michael Lutz
a05fd7aa50
Change: [Network] Transfer command data as serialized byte stream without fixed structure.
...
The data will be transmitted as the length followed by the serialized data. This allows the command
data to be different for every command type in the future.
2 years ago
Michael Lutz
123c7f99c3
Codechange: Move command callback declarations to the cmd header files.
2 years ago
Michael Lutz
33ca4f2b99
Codechange: Let the compile generate the master command table out of templated command traits.
...
This is using a non-intrusive type-traits like templated system, which
allows compile-time validation that the command table and the command
enum match up.
2 years ago
Michael Lutz
a38bbefe1b
Codechange: Untangle command code, flags and error string for DoCommand*.
2 years ago
Michael Lutz
549caca39c
Codechange: Move command arguments to the back of the networked command function calls.
2 years ago
Michael Lutz
b6933a2ebd
Codechange: Move command arguments to the back of the DoCommand function call.
2 years ago
rubidium42
2e136285e1
Codechange: move from C-string to std::string for DoCommand
3 years ago
Jonathan G Rennison
dfecdf3afb
Merge branch 'master' into jgrpp
...
# Conflicts:
# src/dock_gui.cpp
# src/rail_gui.cpp
# src/road_gui.cpp
# src/terraform_gui.cpp
# src/vehicle.cpp
# src/video/allegro_v.cpp
# src/video/cocoa/cocoa_v.mm
# src/video/dedicated_v.cpp
# src/video/sdl2_v.cpp
# src/video/sdl_v.cpp
# src/video/win32_v.cpp
3 years ago
frosch
d9b4413bc9
Codechange: rename sound ids to make more sense. ( #8701 )
3 years ago
Patric Stout
62cdadb582
Change: move "give money" from client-list to company window
...
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:
f820543391
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.
3 years ago
Jonathan G Rennison
bbbda0739b
Add third DoCommand parameter p3
4 years ago
Jonathan G Rennison
11a9a4dc0c
Fix no error message when attaching new template/virtual vehicle fails
...
See: #187
4 years ago
Jonathan G Rennison
cbdd9f84d8
Merge branch 'master' into jgrpp
...
# Conflicts:
# src/console_gui.cpp
# src/lang/korean.txt
# src/video/sdl2_v.cpp
# src/video/sdl2_v.h
# src/window.cpp
# src/window_gui.h
5 years ago
S. D. Cloudt
13cc8a0cee
Cleanup: Removed SVN headers
5 years ago
Jonathan G Rennison
674732cd68
Merge: Codechange: Use null pointer literal instead of the NULL macro
5 years ago
Henry Wilson
7c8e7c6b6e
Codechange: Use null pointer literal instead of the NULL macro
5 years ago
Jonathan G Rennison
4bf4862674
Add AI/game script DoCommand calls to command log
5 years ago
Jonathan G Rennison
ba34ec7ade
Merge branch 'master' into jgrpp
...
Replace build and refit, and group collapse implementations
Fix template creation build and refit
# Conflicts:
# Makefile.bundle.in
# config.lib
# src/animated_tile.cpp
# src/blitter/32bpp_anim.hpp
# src/blitter/32bpp_base.hpp
# src/blitter/8bpp_base.hpp
# src/blitter/null.hpp
# src/build_vehicle_gui.cpp
# src/command.cpp
# src/command_func.h
# src/console_gui.cpp
# src/core/smallstack_type.hpp
# src/date.cpp
# src/debug.cpp
# src/genworld_gui.cpp
# src/ground_vehicle.hpp
# src/group_gui.cpp
# src/lang/korean.txt
# src/linkgraph/linkgraph_gui.h
# src/main_gui.cpp
# src/misc_gui.cpp
# src/network/core/game.h
# src/network/core/packet.cpp
# src/network/core/udp.cpp
# src/network/core/udp.h
# src/network/network_content.cpp
# src/network/network_type.h
# src/network/network_udp.cpp
# src/newgrf_house.h
# src/openttd.cpp
# src/order_cmd.cpp
# src/order_gui.cpp
# src/os/unix/crashlog_unix.cpp
# src/os/windows/crashlog_win.cpp
# src/osk_gui.cpp
# src/pathfinder/opf/opf_ship.cpp
# src/rail_cmd.cpp
# src/rail_gui.cpp
# src/saveload/saveload.cpp
# src/settings.cpp
# src/settings_gui.cpp
# src/smallmap_gui.h
# src/station_base.h
# src/station_cmd.cpp
# src/table/gameopt_settings.ini
# src/table/newgrf_debug_data.h
# src/table/settings.ini
# src/timetable_gui.cpp
# src/toolbar_gui.cpp
# src/train_gui.cpp
# src/vehicle.cpp
# src/vehicle_gui.cpp
# src/vehiclelist.cpp
# src/viewport.cpp
# src/widgets/dropdown.cpp
# src/window_gui.h
5 years ago
Patric Stout
e3c639a09f
Remove: ENABLE_NETWORK switch
...
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.
5 years ago