File tree Expand file tree Collapse file tree 2 files changed +5
-6
lines changed Expand file tree Collapse file tree 2 files changed +5
-6
lines changed Original file line number Diff line number Diff line change @@ -20,6 +20,10 @@ public class VillagerHandler implements Listener {
20
20
21
21
@ EventHandler
22
22
public void onVillagerClick (PlayerInteractEntityEvent event ) {
23
+ //Checks if the thing is a villager
24
+ if (event .getRightClicked ().getType () != EntityType .VILLAGER ) {
25
+ return ;
26
+ }
23
27
//DECLARATION OF INDEPENDENCE
24
28
//Player
25
29
Player player = event .getPlayer ();
@@ -94,11 +98,6 @@ public void onVillagerClick(PlayerInteractEntityEvent event) {
94
98
return ;
95
99
}
96
100
97
- //Checks if the thing is a villager
98
- if (clickedEntity .getType () != EntityType .VILLAGER ) {
99
- return ;
100
- }
101
-
102
101
//Checks if ALL the toggles are off?
103
102
if (!configProfession && !configJobSite && !configLastWorked && !configRestocks && !configHome && !configLastSlept && !configInventory ) {
104
103
player .sendMessage (villInfoPrefix );
Original file line number Diff line number Diff line change 1
1
name : VillagerInfo
2
2
author : IllogicalSong (Special thanks to Peashooter101)
3
3
description : Easy access to information from villager's brains generally only accessable through the /data command.
4
- version : ' ${project.version} '
4
+ version : ' 1.1.1 '
5
5
main : adhdmc.villagerinfo.VillagerInfo
6
6
api-version : 1.13
7
7
commands :
You can’t perform that action at this time.
0 commit comments