LargeRaids is a vanilla game experience enhancement plugin for raids, which were added to the game in the Village & Pillage Update. It expands the raid's mechanism to accommodate for the multiplayer environment with higher difficulties, higher raid omen levels, more raiders, more waves and better rewards.
This is a fork of the original LargeRaids plugin, updated to the latest Minecraft versions. All the latest builds for each version can be found in the releases tab. Older versions are no longer supported.
This plugin will work for both Spigot and Paper, but the latter is recommended because one of the optional extensions (MythicMobs) relies on it.
In build.gradle.kts, change the variable mcVersion to the new version. Go to LargeRaids.java and change the version also. Then run 'gradlew build'. If there are still errors, the source code will need to be manually updated to be compatible with the new Minecraft version.
In addition to fixing errors, you should look at the Mojang mapping for the groupsSpawned
variable. If it is not J
, then you should change it at RaidWrapper.setGroupsSpawned()
.
For any large raid, the minimum Hero of the Village effect given is level 2. This affects all versions of LargeRaids (including versions from the original mod author), and is caused by vanilla giving out the effect before RaidFinishEvent
is fired.
This fork now uses Paper's gradle build system. Run 'gradlew build' to generate the output JARs. If you wish to import this project into your IDE, import it as a gradle project after you've run the command.
The API for the plugin has a separate repository. The instructions are duplicated here for your convenience.
You can add the project as your dependency by including the JitPack repository in your pom.xml
:
<repositories>
<repository>
<id>jitpack.io</id>
<url>https://jitpack.io</url>
</repository>
</repositories>
Then after add the dependency like so (replace VERSION
with the version provided by the jitpack badge located at the start of this document):
<dependency>
<groupId>com.github.zhenghanlee</groupId>
<artifactId>LargeRaids-API</artifactId>
<version>VERSION</version>
</dependency>
You can add the project as your dependency by including the JitPack repository:
allprojects {
repositories {
...
maven { url 'https://jitpack.io' }
}
}
Then after add the dependency like so (replace VERSION
with the version provided by the jitpack badge located at the start of this document):
dependencies {
implementation 'com.github.zhenghanlee:LargeRaids-API:VERSION'
}
Plugin plugin = Bukkit.getPluginManager().getPlugin("LargeRaids");
if (plugin != null) {
LargeRaids lr = (LargeRaids) plugin;
// Rest of the operations here
}
A LargeRaid object can be obtained from either a Bukkit's Location
or Bukkit's Raid
instance.
RaidManager raidManager = lr.getRaidManager(); // where lr is a LargeRaids instance
Optional<LargeRaid> raid = raidManager.getLargeRaid(location);
We can get the number of kills a player have in a large raid when it finishes (or any time of the raid) as follows:
@EventHandler
public void onRaidFinish(RaidFinishEvent evt) {
Raid raid = evt.getRaid(); // Vanilla raid
if (raid.getStatus() != RaidStatus.VICTORY)
return;
Optional<LargeRaid> largeRaid = raidManager.getLargeRaid(raid);
if (!largeRaid.isPresent()) // No corresponding LargeRaid instance
return;
Optional<Integer> killCount = largeRaid.map(LargeRaid::getPlayerKills)
.map(map -> map.get(player.getUniqueId()));
if (!killCount.isPresent()) // Player is not a hero of this raid
return;
// Perform operations with the kill count (e.g. rewarding players based on kill count)
}