your current location:首页 > news>Out of Combat Minecraft

Out of Combat Minecraft

2024-12-15 03:12:41|Myriagame |source:minecraft skins

Out of Combat

Minecraft images


Overview

The following is an introduction to the function of the Out of Combat module:

Support almost all the main versions, that is, 1.12.2, 1.16.1-1.16.5, 1.18-1.18.2, 1.20.1, 1.20.6.

As it represents its name, it brings a simple but easy-to-configure Out-OF-Combat mechanism to Minecraft.

Simple means that its logic and mechanism are very simple:

(T1, T2, T3 are independent variables, indicating the number of Minecraft games tick))

Check whether the player is not attacked during a given time/whether it is harmed within a given time.T1, T2;

If the player is neither attacked nor harmed in time, it will start calculating the time to withdraw from the battle.T1, T2;

If the player attack/hurt, please clear the corresponding timer and non -combat timer;

If Out-OF-Combat Time ExceeDed, the player quits the battle.T3,

The NBT label updated by the event is used as a timer to achieve the above logic.

In addition, the additional countdown timer will suspend the tick of the non -combat timer, but it will not be removed.It can be used for other combat mechanisms.

For example, assuming that players can get the ability similar to "invincible" in your Modpack.When these skills are activated, they may still be in battle, but will not be harmed.

If you are willing, you can make the countdown of this countdown countdown equal to the duration of skills.In this way, the combat timer will wait for the skill to be disabled, and then continue.

NBT name and structure:

These 4 NBT tags are stored in the player's persistence data, and the structure is as follows: Forgetata/PlayerPersisted.

 ForgetA: {playerPersisted: {out_of_combat: {noattackingtime: 0L // nottacking timer noatttime: 0L // Not Being Damaged Timer Stopoutofcombattimer: 0L // Countdown. BeFore This is Count to 0 0 0 0 0 0 0 0 0 0 0, Out-OUT-COMBAT TIMER Will Not Tick. Outofcombattime: 0L // Out of Combat Timer}} 

This means that you can use your MOD or Crafttweaker / Kubejs script or any other similar script to easily modify their values.No complicated API or special integration/compatibility.

Minecraft images

Minecraft images

Minecraft images

In addition to other statements, MCMOD.CN, all open public editing content uses the BY-NC-SA 3.0 protocol.