MCPcopy Create free account
hub / github.com/OpenTTD/OpenTTD / SetCargoMask

Method SetCargoMask

src/linkgraph/linkgraph_gui.cpp:428–433  ·  view source on GitHub ↗

* Set a new cargo mask and rebuild the cache. * @param cargo_mask New cargo mask. */

Source from the content-addressed store, hash-verified

426 * @param cargo_mask New cargo mask.
427 */
428void LinkGraphOverlay::SetCargoMask(CargoTypes cargo_mask)
429{
430 this->cargo_mask = cargo_mask;
431 this->RebuildCache();
432 this->window->GetWidget<NWidgetBase>(this->widget_id)->SetDirty(this->window);
433}
434
435/**
436 * Set a new company mask and rebuild the cache.

Callers 2

SetOverlayCargoMaskMethod · 0.80
UpdateOverlayCargoesMethod · 0.80

Calls 3

RebuildCacheMethod · 0.95
SetDirtyMethod · 0.45

Tested by

no test coverage detected