MCPcopy Create free account
hub / github.com/OpenStarbound/OpenStarbound / toJson

Method toJson

source/game/StarItemDatabase.cpp:171–176  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

169}
170
171Json ItemDatabase::toJson(ItemConstPtr const& itemPtr) const {
172 if (itemPtr)
173 return itemPtr->descriptor().toJson();
174 else
175 return Json();
176}
177
178bool ItemDatabase::hasItem(String const& itemName) const {
179 return m_items.contains(itemName);

Callers 4

applyAugmentMethod · 0.45
ageItemMethod · 0.45
tryCreateItemMethod · 0.45
addBlueprintsMethod · 0.45

Calls 2

JsonClass · 0.85
descriptorMethod · 0.45

Tested by

no test coverage detected