// onAddSubstanceToThis.js
(function () {
/*global adventurejs A*/
var p = adventurejs.Tangible.prototype;
/**
* Called when a substance asset is added to this,
* providing an opportunity to override default behavior
* through the use of
* <a href="/doc/Scripting_VerbReactions.html">verb effect hook</a>
* doAddSubstanceToThis.
* @memberOf adventurejs.Tangible
* @method adventurejs.Tangible#
* @method adventurejs.Tangible#onAddSubstanceToThis
* @param {Object} asset
*/
p.onAddSubstanceToThis = function Tangible_onAddSubstanceToThis(asset) {
if ("string" === typeof asset) asset = this.game.getAsset(asset);
if (!asset) return;
this.game.log(
"L1464",
"log",
"medium",
this.name + " onAddSubstanceToThis " + asset.name + ".",
"VerbActions"
);
var results = this.callAction("doAddSubstanceToThis", asset.name);
if ("undefined" !== typeof results) return results;
return;
};
})();