MCPcopy Create free account
hub / github.com/ObEngine/ObEngine / UnknownGameObject

Method UnknownGameObject

include/Core/Scene/Exceptions.hpp:35–47  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

33 {
34 public:
35 UnknownGameObject(std::string_view sceneFile, std::string_view objectId,
36 const std::vector<std::string>& allObjectIds, DebugInfo info)
37 : Exception("UnknownGameObject", info)
38 {
39 this->error("GameObject with id '{}' does not exists inside Scene '{}'",
40 objectId, sceneFile);
41 std::vector<std::string> suggestions
42 = Utils::String::sortByDistance(objectId.data(), allObjectIds, 5);
43 std::transform(suggestions.begin(), suggestions.end(), suggestions.begin(),
44 Utils::String::quote);
45 this->hint("Try one of the GameObjects with id ({}...)",
46 fmt::join(suggestions, ", "));
47 }
48 };
49
50 class GameObjectAlreadyExists : public Exception

Callers

nothing calls this directly

Calls 7

sortByDistanceFunction · 0.85
joinFunction · 0.50
errorMethod · 0.45
dataMethod · 0.45
beginMethod · 0.45
endMethod · 0.45
hintMethod · 0.45

Tested by

no test coverage detected