mirror of
https://gitlab.com/OpenMW/openmw.git
synced 2025-02-22 21:40:42 +00:00
expell->expel
This commit is contained in:
parent
d6220b7d03
commit
9ebbdc3a22
@ -265,7 +265,7 @@ namespace MWLua
|
|||||||
npcStats.setFactionReputation(factionId, existingReputation + value);
|
npcStats.setFactionReputation(factionId, existingReputation + value);
|
||||||
};
|
};
|
||||||
|
|
||||||
npc["expell"] = [](Object& actor, std::string_view faction) {
|
npc["expel"] = [](Object& actor, std::string_view faction) {
|
||||||
if (dynamic_cast<LObject*>(&actor) && !dynamic_cast<SelfObject*>(&actor))
|
if (dynamic_cast<LObject*>(&actor) && !dynamic_cast<SelfObject*>(&actor))
|
||||||
throw std::runtime_error("Local scripts can modify only self");
|
throw std::runtime_error("Local scripts can modify only self");
|
||||||
|
|
||||||
|
@ -837,14 +837,14 @@
|
|||||||
-- NPC.modifyFactionReputation(player, "mages guild", 5);
|
-- NPC.modifyFactionReputation(player, "mages guild", 5);
|
||||||
|
|
||||||
---
|
---
|
||||||
-- Expell NPC from given faction.
|
-- Expel NPC from given faction.
|
||||||
-- Throws an exception if there is no such faction.
|
-- Throws an exception if there is no such faction.
|
||||||
-- Note: expelled NPC still keeps his rank and reputation in faction, he just get an additonal flag for given faction.
|
-- Note: expelled NPC still keeps his rank and reputation in faction, he just get an additonal flag for given faction.
|
||||||
-- @function [parent=#NPC] expell
|
-- @function [parent=#NPC] expel
|
||||||
-- @param openmw.core#GameObject actor NPC object
|
-- @param openmw.core#GameObject actor NPC object
|
||||||
-- @param #string faction Faction ID
|
-- @param #string faction Faction ID
|
||||||
-- @usage local NPC = require('openmw.types').NPC;
|
-- @usage local NPC = require('openmw.types').NPC;
|
||||||
-- NPC.expell(player, "mages guild");
|
-- NPC.expel(player, "mages guild");
|
||||||
|
|
||||||
---
|
---
|
||||||
-- Clear expelling of NPC from given faction.
|
-- Clear expelling of NPC from given faction.
|
||||||
|
Loading…
x
Reference in New Issue
Block a user