FTB Quests Integration
events.listen('ftbquests.custom_task.75381f79', function (event) {
log.info('Custom task!')
event.checkTimer = 20
event.check = function (task, player) {
if (player.world.daytime && player.world.raining) {
task.progress++
}
}
})
events.listen('ftbquests.custom_reward.e4f76908', function (event) {
log.info('Custom reward!')
event.player.tell('Hello!')
})
events.listen('ftbquests.completed.abc', function (event) {
event.notifiedPlayers.tell('Custom task completed!')
})
events.listen('ftbquests.completed.ding', function (event) {
event.onlineMembers.playSound('entity.experience_orb.pickup')
})
events.listen('entity.death', function (event) {
if(event.server
&& event.source.actual
&& event.source.actual.player
&& event.source.actual.mainHandItem.id.equals('minecraft:wooden_sword')
&& event.entity.type.equals('minecraft:zombie')) {
event.source.actual.data.ftbquests.addProgress('12345678', 1)
}
})