add npc/creature ignore list
This commit is contained in:
parent
6a75e5a158
commit
38dd2a08e6
3 changed files with 18 additions and 1 deletions
|
@ -62,6 +62,11 @@ this.onCombatStart = function(e)
|
||||||
return
|
return
|
||||||
end
|
end
|
||||||
|
|
||||||
|
if config.ignored[e.actor.object.id] or config.ignored[e.actor.object.baseObject.id] then
|
||||||
|
log("Ignored NPC or creature detected, not helping.")
|
||||||
|
return
|
||||||
|
end
|
||||||
|
|
||||||
if isFriendlyActor(e.actor) then
|
if isFriendlyActor(e.actor) then
|
||||||
log("Friendly actor, not helping.")
|
log("Friendly actor, not helping.")
|
||||||
return
|
return
|
||||||
|
|
|
@ -15,7 +15,8 @@ this.default = {
|
||||||
-- combat
|
-- combat
|
||||||
combatEnable = true,
|
combatEnable = true,
|
||||||
combatDistance = 850,
|
combatDistance = 850,
|
||||||
combatDialogue = true
|
combatDialogue = true,
|
||||||
|
ignored = {}
|
||||||
}
|
}
|
||||||
|
|
||||||
function this.getConfig()
|
function this.getConfig()
|
||||||
|
|
|
@ -116,6 +116,17 @@ combatCategory:createYesNoButton({
|
||||||
|
|
||||||
-- }}}
|
-- }}}
|
||||||
|
|
||||||
|
template:createExclusionsPage({
|
||||||
|
label = "Ignored NPCs/Creatures",
|
||||||
|
description = "Guards will not respond to these NPCs or creatures attacking the player.",
|
||||||
|
showAllBlocked = false,
|
||||||
|
filters = {
|
||||||
|
{label = "NPCs", type = "Object", objectType = tes3.objectType.npc},
|
||||||
|
{label = "Creatures", type = "Object", objectType = tes3.objectType.creature}
|
||||||
|
},
|
||||||
|
variable = createTableVar("ignored")
|
||||||
|
})
|
||||||
|
|
||||||
return template
|
return template
|
||||||
|
|
||||||
-- vim:fdm=marker
|
-- vim:fdm=marker
|
||||||
|
|
Loading…
Add table
Reference in a new issue