mirror of
https://github.com/CitizensDev/Citizens2.git
synced 2025-02-09 00:42:03 +01:00
Fixes for /npc command sequential
This commit is contained in:
parent
1fd6ccbad9
commit
244496dca3
@ -125,13 +125,14 @@ public class CommandTrait extends Trait {
|
|||||||
for (NPCCommand command : commandList) {
|
for (NPCCommand command : commandList) {
|
||||||
if (sequential) {
|
if (sequential) {
|
||||||
PlayerNPCCommand info = cooldowns.get(player.getUniqueId().toString());
|
PlayerNPCCommand info = cooldowns.get(player.getUniqueId().toString());
|
||||||
if (info != null && command.id < info.lastUsedId) {
|
if (info != null && command.id <= info.lastUsedId) {
|
||||||
if (info.lastUsedId == max) {
|
if (info.lastUsedId == max) {
|
||||||
info.lastUsedId = -1;
|
info.lastUsedId = -1;
|
||||||
}
|
} else {
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
}
|
||||||
Runnable runnable = new Runnable() {
|
Runnable runnable = new Runnable() {
|
||||||
@Override
|
@Override
|
||||||
public void run() {
|
public void run() {
|
||||||
|
Loading…
Reference in New Issue
Block a user