patch something
This commit is contained in:
parent
9161dfeb2c
commit
3b8f2a6cd7
3 changed files with 9 additions and 5 deletions
|
@ -1,3 +1,3 @@
|
|||
# giants
|
||||
# Giants
|
||||
|
||||
Add giants to your Minecraft server by installing a Spigot plugin.
|
||||
This plugin adds naturally spawning giants to your Minecraft server.
|
2
pom.xml
2
pom.xml
|
@ -2,7 +2,7 @@
|
|||
<modelVersion>4.0.0</modelVersion>
|
||||
<groupId>giants</groupId>
|
||||
<artifactId>giants</artifactId>
|
||||
<version>21.1.0</version>
|
||||
<version>21.1.1</version>
|
||||
|
||||
<properties>
|
||||
<maven.compiler.source>1.8</maven.compiler.source>
|
||||
|
|
|
@ -118,10 +118,14 @@ public class Main extends JavaPlugin implements Listener {
|
|||
LivingEntity entity = (LivingEntity) pos.getWorld().spawnEntity(pos, EntityType.GIANT);
|
||||
if (ai) {
|
||||
LivingEntity passenger = (LivingEntity) pos.getWorld().spawnEntity(pos, EntityType.HUSK);
|
||||
new PotionEffect(PotionEffectType.INVISIBILITY, Integer.MAX_VALUE, 1).apply((LivingEntity) passenger);
|
||||
new PotionEffect(PotionEffectType.INVISIBILITY, Integer.MAX_VALUE, 1)
|
||||
.apply((LivingEntity) passenger);
|
||||
new PotionEffect(PotionEffectType.WEAKNESS, Integer.MAX_VALUE, 255)
|
||||
.apply((LivingEntity) passenger);
|
||||
passenger.setCustomName("Giant");
|
||||
passenger.setCustomNameVisible(false);
|
||||
passenger.setHealth(0.5D);
|
||||
passenger.setInvulnerable(true);
|
||||
passenger.setPersistent(true);
|
||||
entity.addPassenger(passenger);
|
||||
}
|
||||
for (Entry<PotionEffectType, Integer> t : effects.entrySet()) {
|
||||
|
|
Loading…
Reference in a new issue