S

eveeyone is getting strength slowness and weakness regenration fix it

Kodari AI
KodariJul 5 at 1:30 pm 30

Found the bug in PassiveTickTask.java. The SLOTH slowness (line 45) and GREED weakness (line 71) effects are applied every single tick of the task with no throttle, unlike the sibling REGENERATION/LUST effects which are gated behind tickCounter % N == 0. This spams addPotionEffect constantly on every player who has picked a sin, causing the effects to feel permanent/inescapable across the server.

Fixed the throttling on SLOTH’s slowness and GREED’s weakness — they now refresh every 5 ticks like their sibling REGENERATION effect, instead of firing unconditionally every server tick. This was causing constant, inescapable re-application of Strength/Slowness/Weakness/Regeneration to any player who had picked a sin.

S

people also randomly get demon marks make it so u only get it when ur low and at level 5 alsooo i am still randomly getting slowness and regen

Kodari AI
KodariJul 5 at 1:40 pm 18

Right, handleIdle update tracking still needed as-is. Dropping the no-op third patch.

Demon Mark (DemonMarkManager.java): tryTrigger now requires level >= 5 and health ≤ 30% max health before the 5% roll — no longer purely random for anyone.

Slowness/Regen (PassiveTickTask.java): SLOTH’s Regeneration+Slowness now only applies while the player is actually idle (hasn’t moved, not in combat) via the new isIdle() check, instead of firing every 5 ticks unconditionally for anyone with the passive.

S

still gettint slowness and regen

Kodari AI
KodariJul 6 at 9:31 am 18

Found it. In PassiveTickTask.isIdle(), the “moved” check only compares position deltas across a single tick (0.05s) against a 2-block threshold. Since no normal player movement covers 2 blocks in one tick, moved is essentially always false — meaning isIdle() returns true for basically every player, all the time, even while actively walking/mining/fighting. That’s why Sloth’s Regeneration+Slowness keeps firing regardless of whether the player is actually AFK.

Fix: track the last time the player actually moved, and only consider them idle after they’ve been stationary for several seconds — not just within the current tick.

Also confirmed the LUST passive (lines 57-64) applies Weakness+Slowness to any nearby player every 6 ticks regardless of that player’s own sin or combat status — this is separate AoE behavior, not a bug in the code you flagged, but worth knowing if bystanders near a Lust player are the ones reporting random debuffs. Let me know if you want that scoped down to only combat targets too.

The core fix: isIdle() previously compared movement across a single 1-tick window against a 2-block threshold — a threshold no normal movement ever exceeds in 1 tick, so it was permanently reporting “idle” for everyone. Now it tracks real elapsed time since the player’s last actual movement and only flags them idle after 3+ seconds stationary.

S

make bossess spawn randomly in the world not on players

Kodari can make mistakes. Review important code before using.
Files
src
pom.xml
Code
26 2,568
src/main/java/com/kodari/sevendeadlysins/SevenDeadlySinsPlugin.java
package com.kodari.sevendeadlysins;

import com.kodari.sevendeadlysins.abilities.AbilityManager;
import com.kodari.sevendeadlysins.commands.SinCommand;
import com.kodari.sevendeadlysins.data.SinDataManager;
import com.kodari.sevendeadlysins.listeners.BossListener;
import com.kodari.sevendeadlysins.listeners.CombatListener;
import com.kodari.sevendeadlysins.listeners.CommandmentListener;
import com.kodari.sevendeadlysins.listeners.GUIListener;
import com.kodari.sevendeadlysins.listeners.PlayerListener;
import com.kodari.sevendeadlysins.managers.BossManager;
import com.kodari.sevendeadlysins.managers.CommandmentManager;
import com.kodari.sevendeadlysins.managers.CooldownManager;
import com.kodari.sevendeadlysins.managers.DemonMarkManager;
import com.kodari.sevendeadlysins.managers.SacredTreasureManager;
import com.kodari.sevendeadlysins.tasks.PassiveTickTask;
import com.kodari.sevendeadlysins.tasks.WorldEventTask;
import lombok.Getter;
import org.bukkit.Bukkit;
import org.bukkit.plugin.java.JavaPlugin;

@Getter
public class SevenDeadlySinsPlugin extends JavaPlugin {

    private SinDataManager sinDataManager;
    private CooldownManager cooldownManager;
    private SacredTreasureManager sacredTreasureManager;
    private DemonMarkManager demonMarkManager;
    private CommandmentManager commandmentManager;
    private BossManager bossManager;
    private AbilityManager abilityManager;

    @Override
    public void onEnable() {
        saveDefaultConfig();
        this.sinDataManager = new SinDataManager(this);
        this.cooldownManager = new CooldownManager();
        this.sacredTreasureManager = new SacredTreasureManager(this);
        this.demonMarkManager = new DemonMarkManager(this);
        this.commandmentManager = new CommandmentManager();
        this.bossManager = new BossManager(this);
        this.abilityManager = new AbilityManager(this);

        Bukkit.getPluginManager().registerEvents(new PlayerListener(this), this);
        Bukkit.getPluginManager().registerEvents(new CombatListener(this), this);
        Bukkit.getPluginManager().registerEvents(new CommandmentListener(this), this);
        Bukkit.getPluginManager().registerEvents(new BossListener(this), this);
        Bukkit.getPluginManager().registerEvents(new GUIListener(this), this);

        SinCommand sinCommand = new SinCommand(this);
        org.bukkit.command.PluginCommand sinCmd = getCommand("sin");
        if (sinCmd != null) {
            sinCmd.setExecutor(sinCommand);
            sinCmd.setTabCompleter(sinCommand);
        } else {
            getLogger().warning("Could not register /sin command — check plugin.yml");
        }

        new PassiveTickTask(this).runTaskTimer(this, 20L, 20L);
        new WorldEventTask(this).runTaskTimer(this, 100L, 100L);
        Bukkit.getScheduler().runTaskTimer(this, () -> demonMarkManager.tickParticles(), 20L, 20L);
        Bukkit.getScheduler().runTaskTimer(this, () -> sinDataManager.saveAll(), 6000L, 6000L);
        Bukkit.getScheduler().runTaskTimer(this, () -> bossManager.tickBossAI(), 60L, 60L);

        getLogger().info("Seven Deadly Sins SMP has awakened.");
    }

    @Override
    public void onDisable() {
        if (sinDataManager != null) {
            sinDataManager.saveAll();
        }
        getLogger().info("Seven Deadly Sins SMP slumbers once more.");
    }
}