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

Method Select

src/network/network_content.cpp:845–852  ·  view source on GitHub ↗

* Select a specific content id. * @param cid the content ID to select */

Source from the content-addressed store, hash-verified

843 * @param cid the content ID to select
844 */
845void ClientNetworkContentSocketHandler::Select(ContentID cid)
846{
847 ContentInfo *ci = this->GetContent(cid);
848 if (ci == nullptr || ci->state != ContentInfo::State::Unselected) return;
849
850 ci->state = ContentInfo::State::Selected;
851 this->CheckDependencyState(*ci);
852}
853
854/**
855 * Unselect a specific content id.

Callers 4

ToggleSelectedStateMethod · 0.95
OnReceiveContentInfoMethod · 0.80
OnReceiveContentInfoMethod · 0.80
ConContentFunction · 0.80

Calls 2

GetContentMethod · 0.95
CheckDependencyStateMethod · 0.95

Tested by

no test coverage detected