Closed kenny1998cr closed 2 years ago
Last I tested, on the current version, pvp is enabled in the attacked area.
Last I tested, on the current version, pvp is enabled in the attacked area.
Hello LlmDl thanks for you reply, im currently using towny 0.97.2.18 and Flagwar 0.5.1 and the same issue happening. Even worldguad is disabled. Here's a video: https://youtu.be/4O5TtagW7h0
Edit: I think that the solution is when towny detects that the flag as being planted then force PVP on the attacking town [Towny] [Global Message] [FlagWar] Town-B (Settlement) (CostaRica,328, 148) is under attack by Leader kenny1998cr!
@EventHandler
public void onTownBlockPVPTestEvent(final TownBlockPVPTestEvent townBlockPVPTestEvent) {
if (!FlagWarConfig.isAllowingAttacks()
|| !Cell.parse(townBlockPVPTestEvent.getTownBlock().getWorldCoord()).isUnderAttack()) {
return;
}
townBlockPVPTestEvent.setPvp(true);
}
Is the code which makes any plot with a flag in it have PVP on. I'll test this myself but I'm sure it was working.
@EventHandler public void onTownBlockPVPTestEvent(final TownBlockPVPTestEvent townBlockPVPTestEvent) { if (!FlagWarConfig.isAllowingAttacks() || !Cell.parse(townBlockPVPTestEvent.getTownBlock().getWorldCoord()).isUnderAttack()) { return; } townBlockPVPTestEvent.setPvp(true); }
Is the code which makes any plot with a flag in it have PVP on. I'll test this myself but I'm sure it was working.
I just made a clear install of Towny and FlagWar but the issue appear, also I have allow attacks on true
I've been able to reproduce it, I think I have a fix for it.
I've been able to reproduce it, I think I have a fix for it.
Good ! And thanks for the fix LlmDl you are the best (I have to donate you for all the support :) ). This fix would take some time or is going to be quick? because my server need it asap, but take your time of course. Thanks again!.
Please explain your feature request to the best of your abilities: Well, in my server people start a battle for the flag, everything works good BUT the most important, players cannot use PvP in the attacking chunk because the town/nation mayor set the PvP permission Off, so the attackers cannot stop the defenders.
So my suggestion is: force the PvP on the attacked chunk, If the defenders wins= Just go back to the perms that the mayor set up previously. If the attackers wins= The normal warflag stuff, the winner keep the chunk.
Here I show a video with the example: https://youtu.be/aFfLULPQXeo