Jak zrobić strefę AFK na serwerze Minecraft (getafkzone) How to Create an AFK Zone on Your Minecraft Server (getafkzone)
Ten poradnik pokazuje, jak zainstalować wtyczkę getafkzone i skonfigurować działającą strefę AFK z nagrodami, paskiem bossbar oraz szansami zależnymi od rangi.
This guide shows you how to install the getafkzone plugin and set up a working AFK zone with rewards, a bossbar, and rank-based chances.
Instalacja wtyczki
- Pobierz najnowszą wersję z SpigotMC.
- Otwórz folder główny serwera i wrzuć plik
.jardo/plugins. - Zrestartuj serwer. Sprawdź konsolę lub użyj
/plugins, aby potwierdzić załadowanie.
Utwórz strefę AFK
- Zaznacz dwa rogi drewnianym patykiem po uruchomieniu:
- Utwórz region AFK (zastąp
<name>własną nazwą):
- Przeładuj wtyczkę:
Twoja strefa AFK powinna teraz działać na ustawieniach domyślnych.
Przykładowa konfiguracja
afk:
test:
first:
==: org.bukkit.Location
world: world
x: 329.0
y: 206.0
z: -92.0
pitch: 0.0
yaw: 0.0
second:
==: org.bukkit.Location
world: world
x: 338.0
y: 209.0
z: -82.0
pitch: 0.0
yaw: 0.0
reward:
commands:
- say {player} test!
permissions:
'1': { permission: afk.vip, chance: 50 }
time: 600
p-color: GREEN
p-style: SOLID
bar-name: '&a✦ &7| &fNagroda za: &a{time} &8(&a{percent}%&8) &7| &fszansa: &7{chance}'
Konfiguracja nagród (komendy)
Zastąp przykładową komendę własnymi. Użyj placeholdera {player} w miejscu nicku gracza:
- give {player} diamond 1
- eco give {player} 250
Bossbar — kolor, styl i nazwa
p-color ustawia kolor (np. GREEN), p-style styl (np. SOLID), a bar-name to tekst. Dostępne placeholdery:
{time}— pozostały czas do nagrody,{percent}— procent postępu,{chance}— szansa pobrana z warstwy permisji.
p-style: SOLID
bar-name: '&a✦ &7| &fNagroda za: &a{time} &8(&a{percent}%&8) &7| &fszansa: &7{chance}'
Szanse według permisji (VIP/SVIP/MVIP)
Wyższe rangi mogą mieć lepsze szanse. Przykład: VIP 10%, SVIP 30%, MVIP 50%.
'1': { permission: afk.vip, chance: 10 }
'2': { permission: afk.svip, chance: 30 }
'3': { permission: afk.mvip, chance: 50 }
Jeśli gracz ma wiele z tych permisji, wtyczka zwykle wybierze najbardziej odpowiednią/najwyższą. Utrzymuj unikalne rangi, aby uniknąć niejasności.
Przełączniki globalne
Możesz wyłączyć elementy wizualne dla wszystkich, ustawiając je na false:
title: true
actionbar: true
Format czasu dla {time}
Steruj etykietami jednostek i kolejnością wyświetlania:
min: ' {min}m'
hour: ' {hour}h'
day: '{day}d'
format: "{d}{h}{m}{s}"
Przykład: ustawienie format: "{d}{h}{m}" pokaże 1d 1h 1m.
Pasek postępu w actionbarze
Dostosuj znak, długość i kolory paska postępu:
char: "I"
size: 100
no-active: "&7"
active: "&a"
Spróbuj kwadratu lub kropki dla char i dopasuj size do 10/20/50 itd.
Rozwiązywanie problemów
Wtyczka się nie włączyła
- Po restarcie sprawdź błędy w konsoli startowej.
- Upewnij się, że plik
.jarjest w/pluginsi nie jest uszkodzony. - Zweryfikuj zgodność wersji serwera (Paper/Spigot) z wersją wtyczki.
Strefa AFK nie działa po utworzeniu
- Sprawdź, czy poprawnie zaznaczyłeś dwa rogi (
/azone selector→ patyk → PPM/LPM). - Uruchom
/azone create <name>, a następnie/azone reload. - Upewnij się, że gracz faktycznie stoi wewnątrz zdefiniowanego prostopadłościanu.
Install the Plugin
- Download the latest version from SpigotMC.
- Open your server’s root folder and drop the
.jarinto/plugins. - Restart the server. Check the console or run
/pluginsto confirm it loaded.
Create an AFK Zone
- Select two corners with a wooden stick after running:
- Create the AFK region (replace
<name>with your own):
- Reload the plugin:
Your AFK zone should now be active with default settings.
Example Configuration
afk:
test:
first:
==: org.bukkit.Location
world: world
x: 329.0
y: 206.0
z: -92.0
pitch: 0.0
yaw: 0.0
second:
==: org.bukkit.Location
world: world
x: 338.0
y: 209.0
z: -82.0
pitch: 0.0
yaw: 0.0
reward:
commands:
- say {player} test!
permissions:
'1': { permission: afk.vip, chance: 50 }
time: 600
p-color: GREEN
p-style: SOLID
bar-name: '&a✦ &7| &fYou get the basic reward in: &a{time} &8(&a{percent}%&8) &7| &fchance: &7{chance}'
Configure Rewards (commands)
Replace the sample command with your own. Use the {player} placeholder where the player name should be:
- give {player} diamond 1
- eco give {player} 250
Bossbar — color, style, and name
p-color controls color (e.g., GREEN), p-style is the style (e.g., SOLID), and bar-name is the text. Placeholders:
{time}— time remaining to the reward,{percent}— progress percentage,{chance}— chance pulled from the permission tier.
p-style: SOLID
bar-name: '&a✦ &7| &fReward in: &a{time} &8(&a{percent}%&8) &7| &fchance: &7{chance}'
Chances by Permission (VIP/SVIP/MVIP)
Give higher ranks better chances. Example: VIP 10%, SVIP 30%, MVIP 50%.
'1': { permission: afk.vip, chance: 10 }
'2': { permission: afk.svip, chance: 30 }
'3': { permission: afk.mvip, chance: 50 }
If a player has multiple of these permissions, the plugin will typically use the most relevant/highest one. Keep ranks unique to avoid ambiguity.
Global Toggles
You can disable visual elements for everyone by switching them to false:
title: true
actionbar: true
Time Format for {time}
Control unit labels and output order:
min: ' {min}m'
hour: ' {hour}h'
day: '{day}d'
format: "{d}{h}{m}{s}"
For example, changing to format: "{d}{h}{m}" will show 1d 1h 1m.
Actionbar Progress Bar
Customize the character, length, and colors of the progress bar:
char: "I"
size: 100
no-active: "&7"
active: "&a"
Try a square or dot for char, and adjust size to 10/20/50/etc. as you like.
Troubleshooting
The plugin didn’t load
- Check the startup console for errors after restart.
- Make sure the
.jaris in/pluginsand not corrupted. - Verify your server (Paper/Spigot) version is compatible with the plugin release.
The AFK zone doesn’t work after creation
- Ensure you selected two corners properly (
/azone selector→ stick → right/left click). - Run
/azone create <name>and then/azone reload. - Confirm the player is actually standing inside the defined cuboid.