Added dialog events to scripted player events

This commit is contained in:
luisc committed 2022-01-12 22:59:03 -06:00
1 parent b024f800ae
commit 04def38b63
11 files changed
+102 -18

No files matched your search

@@ -60,14 +60,12 @@ public class FactionOptions {
if(faction == null)
return;
EventHooks.onFactionPoints(new FactionEvent.FactionPoints(new ScriptPlayer((EntityPlayerMP) player), faction, decrease, points));
if(!faction.hideFaction){
String message = decrease?"faction.decreasepoints":"faction.increasepoints";
player.addChatMessage(new ChatComponentTranslation(message, faction.name, points));
}
data.increasePoints(factionId, decrease?-points:points);
data.increasePoints(factionId, decrease?-points:points,player);
}
}