Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR JAVA

spigot kill entity

@EventHandler
	public void onEntitySpawn(EntitySpawnEvent event) {
		if (event.getEntityType() == EntityType.CREEPER) {
			if (event.getEntity() instanceof Damageable) {
				
				Damageable creeper = (Damageable) event.getEntity();
				creeper.damage(1000);
			}
		}
    }
 
PREVIOUS NEXT
Tagged: #spigot #kill #entity
ADD COMMENT
Topic
Name
5+7 =