Ticket #3792: 3792.4.diff
File 3792.4.diff, 1.3 KB (added by , 8 years ago) |
---|
-
binaries/data/mods/public/simulation/components/Auras.js
Auras.prototype.Schema = 58 58 "<optional>" + 59 59 "<element name='AffectedPlayers' a:help='Affected players'>" + 60 60 "<text/>" + 61 61 "</element>" + 62 62 "</optional>" + 63 "<optional>" + 64 "<element name='Stackable' a:help='Allow multiple applications of this aura'>" + 65 "<data type='boolean'/>" + 66 "</element>" + 67 "</optional>" + 63 68 "</interleave>" + 64 69 "</element>" + 65 70 "</oneOrMore>"; 66 71 67 72 Auras.prototype.Init = function() … … Auras.prototype.Init = function() 81 86 } 82 87 }; 83 88 84 89 Auras.prototype.GetModifierIdentifier = function(name, mod) 85 90 { 86 return this.templateName + "/" + name + "/" + mod.value; 91 let identifier = name + "/" + mod.value + "/"; 92 if (this.template[name].Stackable) 93 return identifier + this.entity; 94 // We add add/mul to prevent applying the same aura of different templates 95 return identifier + (mod.add || 0) + "/" + (mod.multiply || 1); 87 96 }; 88 97 89 98 Auras.prototype.GetDescriptions = function() 90 99 { 91 100 var ret = {};