Mod

Out of Combat

Quick rating

Out of Combat

No reviews yet

Bring a simple but easily configurable Out-of-Combat mechanic into Minecraft.

Mod Loaders
Forge
Minecraft

Community voices

Reviews

Versions
Loading versions…
Match includes

Click once to include, again to exclude, again to clear

Rating Any
Any 0.5 1.0 1.5 2.0 2.5 3.0 3.5 4.0 4.5 5.0
Min
Max
Play Status
Reviews
Time Played
hrs+
Verified developers only
Has developer response
List view
Grid view
Compact view
Sort by
Date
Rating
Helpful
Unhelpful
Edited
Sort ascending
Delete this review?

This removes your review from the project. You can write a new review after.

Review submitted for moderation

Your review has been sent to moderators, who will check that it meets our guidelines before it appears publicly.

No reviews yet. Be the first to review this project!

Get it on

Available Platforms

About

Project Details

Type
Mod
Latest Version
out_of_combat-1.20.1-1.1.1.jar

For authors

Embed Badge

If you're the author of this project, you can embed a live badge anywhere that supports HTML or Markdown. It updates automatically whenever ratings change.

Custom banner text
ModDex rating badge preview

Use HTML for any page that supports it, or Markdown for README files and Markdown-based descriptions.

Identifiers

Platform IDs

CurseForge ID

Resources

External Links

Source Issues Wiki Discord

About

Description

Out of Combat


Overview

Out of Combat mod.

Support nearly ALL major versions, namely, 1.12.2, 1.16.1-1.16.5, 1.18-1.18.2, 1.20.1, 1.20.6.

As what its name represents, it brings a simple but easily configurable Out-of-Combat mechanic into Minecraft.

Simple means its logic and mechanic are both simple:

(T1, T2, T3 are independent variables, representing number of Minecraft game ticks)

  1. Detect if player has not attacked for a given time T1 / been damaged for a given time T2.

  2. If player has neither attacked for T1 nor been damaged for T2, start to count the out-of-combat time.

    If player attacks / is damaged, clear the corresponding timer and the out-of-combat timer.

  3. If out-of-combat time exceeded T3, player is out of combat.

3 NBT tags updated by events serve as timers, to fulfill the logic above.

Besides, an additional countdown timer will pause the ticking of the out-of-combat timer, but not clear it. It can be used in other combat mechanics.

For example, assuming player can get "Invulnerable"-like abilities in your modpack. when those abilities are activated, they may still in combat, but will not be damaged. If you would like to do so, you may let this countdown timer countdown for the time equals to the abilities' durations. So that the out-of-combat timer will wait for the abilities to deactivate, and continues after that.

Documents for Usage

Config File

1.12.2 version: config/out_of_combat.cfg (GitHub)

1.16.x version: config/out_of_combat-common.toml (GitHub)

1.18+ version: config/out_of_combat-common.toml (GitHub)

It is well documented in its comments.

Default values are large, means this mod are not effective until you modify this config file.

NBT Names and Structure

These 4 NBT tags are saved in player's persisted data: ForgeData/PlayerPersisted, with the structure below.

ForgeData: {
    PlayerPersisted: {
        out_of_combat: {
            noAttackingTime: 0L         // No Attacking Timer
            noAttackedTime: 0L          // Not Being Damaged Timer
            stopOutOfCombatTimer: 0L    // Countdown. Before This is count to 0, Out-of-Combat timer will not tick.
            outOfCombatTime: 0L         // Out of Combat Timer
        }
    }
}

That means, you can easily manipulate the value of each of them with your mods or CraftTweaker/KubeJS scripts or any other scripts like them.

No need for complex APIs or special integrations/compatibilities.


Future Plans

Support other Minecraft versions.

Screenshots

Gallery

This project has no gallery images yet.

Versions

Files

Relations

Project Relations

More like this

Similar Mods

Suggestions use data such as tags, dependencies, dependents, descriptions, titles, and more to rank how much they overlap with this mod.

On ModDex

Community snapshot

0
Ratings
0
Followers
0
In stacks

By the numbers

Statistics

~12,000
Downloads
Last Updated
Created
Last synced
When ModDex last fetched and imported data for this project from CurseForge or Modrinth. High-traffic and active projects are checked more often.
Next pipeline sync