Differential D368 Diff 14795 binaries/data/mods/public/simulation/components/StatusEffectsReceiver.js
Changeset View
Changeset View
Standalone View
Standalone View
binaries/data/mods/public/simulation/components/StatusEffectsReceiver.js
Show All 15 Lines | |||||
* @return {Object} - An object containing the status effects which currently affect the entity. | * @return {Object} - An object containing the status effects which currently affect the entity. | ||||
*/ | */ | ||||
StatusEffectsReceiver.prototype.GetActiveStatuses = function() | StatusEffectsReceiver.prototype.GetActiveStatuses = function() | ||||
{ | { | ||||
return this.activeStatusEffects; | return this.activeStatusEffects; | ||||
}; | }; | ||||
/** | /** | ||||
* Quantify how much the effect does, relative to the maximum amount. | |||||
* For now just check if there is some effect. | |||||
*/ | |||||
StatusEffectsReceiver.prototype.GetRelativeStatusEffect = function(effectData, effectType, bonusMultiplier, attackerOwner) | |||||
{ | |||||
// return canTakeEffect ? | |||||
// Attacking.GetTotalAttackEffects( | |||||
// this.entity, | |||||
// effectData, | |||||
// effectType, | |||||
// bonusMultiplier, | |||||
// QueryMiragedInterface(this.entity, IID_Resistance) | |||||
// ) / this.max : | |||||
// 0; | |||||
return effectData[effectType] ? 1 : 0; | |||||
}; | |||||
/** | |||||
* Called by Attacking effects. Adds status effects for each entry in the effectData. | * Called by Attacking effects. Adds status effects for each entry in the effectData. | ||||
* | * | ||||
* @param {Object} effectData - An object containing the status effects to give to the entity. | * @param {Object} effectData - An object containing the status effects to give to the entity. | ||||
* @param {number} attacker - The entity ID of the attacker. | * @param {number} attacker - The entity ID of the attacker. | ||||
* @param {number} attackerOwner - The player ID of the attacker. | * @param {number} attackerOwner - The player ID of the attacker. | ||||
* @param {number} bonusMultiplier - A value to multiply the damage with (not implemented yet for SE). | * @param {number} bonusMultiplier - A value to multiply the damage with (not implemented yet for SE). | ||||
* | * | ||||
* @return {Object} - The codes of the status effects which were processed. | * @return {Object} - The codes of the status effects which were processed. | ||||
▲ Show 20 Lines • Show All 134 Lines • Show Last 20 Lines |
Wildfire Games · Phabricator