FG Spreadshirt Swag
  1. #1

    [Bug&Fix] DMG effect's range tag not working

    Hello!
    I wanted a DMG effect to be melee only, but had to notice that it is not working. The wiki says it is possible to add a range to the DMG effect. It does not apply the DMG in any circumstance if I do something like:

    DMG: 2 melee
    or
    DMG: 1 ranged

    I found the mistake though, it is in the following file of the ruleset:

    manager_action_damage.lua lines 358 and 417.
    Code:
    local nEffectMod, nEffectCount = EffectManager.getEffectsBonus(rSource, "DMGW", true, aDamageFilter, rTarget);
    Code:
    aEffects, nEffects = EffectManager.getEffectsBonusByType(rSource, "DMG", true, aDamageFilter, rTarget);
    aDamageFilter is never initialized. What the developer intended here was to use the correctly initiated (lines 287-297) attack type filter (for melee, ranged, close and area).
    So to fix this, simply replace aDamageFilter with aAttackFilter at lines 358 and 417. Both variables are never used elsewhere, so this will not cause any other problems.

    I modified my ruleset myself, but I hope this will be fixed for future updates of FG so others don't have to wonder why this is not working.

    greetz,
    Cake

  2. #2

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
DICE PACKS BUNDLE

Log in

Log in