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

Function SetClientIdHelper

src/script/api/script_object.hpp:375–380  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

373 /** Helper to process a single ClientID argument. */
374 template <class T>
375 static inline void SetClientIdHelper(T &data)
376 {
377 if constexpr (std::is_same_v<ClientID, T>) {
378 if (data == INVALID_CLIENT_ID) data = (ClientID)UINT32_MAX;
379 }
380 }
381
382 /** Set all invalid ClientID's to the proper value. */
383 template <class Ttuple, size_t... Tindices>

Callers 1

SetClientIdsFunction · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected