MCPcopy Create free account
hub / github.com/OGSR/OGSR-Engine / GetGoodwill

Method GetGoodwill

ogsr_engine/xrGame/script_game_object_inventory_owner.cpp:415–425  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

413//////////////////////////////////////////////////////////////////////////
414
415int CScriptGameObject::GetGoodwill(CScriptGameObject* pToWho)
416{
417 CInventoryOwner* pInventoryOwner = smart_cast<CInventoryOwner*>(&object());
418
419 if (!pInventoryOwner)
420 {
421 ai().script_engine().script_log(ScriptStorage::eLuaMessageTypeError, "GetGoodwill available only for InventoryOwner");
422 return 0;
423 }
424 return RELATION_REGISTRY().GetGoodwill(pInventoryOwner->object_id(), pToWho->object().ID());
425}
426
427void CScriptGameObject::SetGoodwill(int goodwill, CScriptGameObject* pWhoToSet)
428{

Callers

nothing calls this directly

Calls 5

RELATION_REGISTRYClass · 0.85
script_logMethod · 0.80
objectFunction · 0.50
object_idMethod · 0.45
objectMethod · 0.45

Tested by

no test coverage detected