Download Data/CharacterEffectCompositeDef/Conscience_Guilty.lua from sirnii/myspace: direct link, hf CLI and curl.
- Browser
- Download file 1.64 kB
-
https://huggingface.co/spaces/sirnii/myspace/resolve/main/Data/CharacterEffectCompositeDef/Conscience_Guilty.lua
- Command line
-
hf download hf://spaces/sirnii/myspace/Data/CharacterEffectCompositeDef/Conscience_Guilty.lua
-
curl -L -o Conscience_Guilty.lua https://huggingface.co/spaces/sirnii/myspace/resolve/main/Data/CharacterEffectCompositeDef/Conscience_Guilty.lua
1.64 kB
| -- ========== GENERATED BY CharacterEffectCompositeDef Editor DO NOT EDIT MANUALLY! ========== | |
| PlaceObj('CharacterEffectCompositeDef', { | |
| 'Id', "Conscience_Guilty", | |
| 'Parameters', { | |
| PlaceObj('PresetParamNumber', { | |
| 'Name', "days", | |
| 'Value', 1, | |
| 'Tag', "<days>", | |
| }), | |
| PlaceObj('PresetParamPercent', { | |
| 'Name', "decrease", | |
| 'Value', 15, | |
| 'Tag', "<decrease>%", | |
| }), | |
| }, | |
| 'Comment', "conversations related", | |
| 'object_class', "StatusEffect", | |
| 'unit_reactions', { | |
| PlaceObj('UnitReaction', { | |
| Event = "OnNewDay", | |
| Handler = function (self, target) | |
| Conscience_CheckExpiration(self, target, "guilty_start_time") | |
| end, | |
| }), | |
| PlaceObj('UnitReaction', { | |
| Event = "OnCalcPersonalMorale", | |
| Handler = function (self, target, value) | |
| return value - 1 | |
| end, | |
| }), | |
| }, | |
| 'DisplayName', T(374563958345, --[[CharacterEffectCompositeDef Conscience_Guilty DisplayName]] "Guilty"), | |
| 'Description', T(117856843594, --[[CharacterEffectCompositeDef Conscience_Guilty Description]] "Morale decreased by 1 for a day."), | |
| 'AddEffectText', T(446826511839, --[[CharacterEffectCompositeDef Conscience_Guilty AddEffectText]] "<em><DisplayName></em> is feeling guilty and lost Morale"), | |
| 'OnAdded', function (self, obj) | |
| self:SetParameter("guilty_start_time", Game.CampaignTime) | |
| end, | |
| 'OnRemoved', function (self, obj) | |
| -- Handles old guilty modifiers, new guilty applies morale modifier | |
| local stats = UnitPropertiesStats:GetProperties() | |
| for i, stat in ipairs(stats) do | |
| obj:RemoveModifier("guilty_" .. stat.id, stat.id) | |
| end | |
| end, | |
| 'type', "Debuff", | |
| 'Icon', "UI/Hud/Status effects/encumbered", | |
| 'HasFloatingText', true, | |
| }) | |