Solved [WG 6.2] RegionGroupFlag parseInput - Arguments Not Applicable?

Discussion in 'Spigot Plugin Development' started by Ladinn, Apr 13, 2017.

  1. Hey all,

    I'm trying to set region group flags after creating a WorldGuard region- I've tried everything, read forum thread after forum thread, but I'm still getting the same error.

    The offending code:
    Code (Text):
            RegionGroupFlag groupFlag = DefaultFlag.CHEST_ACCESS.getRegionGroupFlag();
            RegionGroup groupValue = groupFlag.parseInput(WorldGuardPlugin.inst(), null, "non_members");
                 
            region.setFlag(groupFlag, groupValue);
    The error is appearing for parseInput. Eclipse is saying:
    But, this page states that...

    The best thread I found on this is here, but it sounds like this wasn't an issue for them.

    Thanks for your help in advance!

    EDIT:
    Solved with:
    Code (Text):
    region.setFlag(DefaultFlag.CHEST_ACCESS,StateFlag.State.DENY);    
    region.setFlag(DefaultFlag.CHEST_ACCESS.getRegionGroupFlag(), RegionGroup.NON_MEMBERS);
     
    #1 Ladinn, Apr 13, 2017
    Last edited: Apr 14, 2017
    • Informative Informative x 1