mirror of
https://github.com/TES3MP/openmw-tes3mp.git
synced 2025-04-01 00:36:46 +00:00
Merge pull request #2117 from Capostrophic/aidata
Make Interiors of Illusion puzzle of Sotha Sil Expanded work (bug #4778)
This commit is contained in:
commit
93e566a08e
5 changed files with 16 additions and 2 deletions
|
@ -14,6 +14,7 @@
|
||||||
Bug #4746: Non-solid player can't run or sneak
|
Bug #4746: Non-solid player can't run or sneak
|
||||||
Bug #4750: Sneaking doesn't work in first person view if the player is in attack ready state
|
Bug #4750: Sneaking doesn't work in first person view if the player is in attack ready state
|
||||||
Bug #4768: Fallback numerical value recovery chokes on invalid arguments
|
Bug #4768: Fallback numerical value recovery chokes on invalid arguments
|
||||||
|
Bug #4778: Interiors of Illusion puzzle in Sotha Sil Expanded mod is broken
|
||||||
Feature #2229: Improve pathfinding AI
|
Feature #2229: Improve pathfinding AI
|
||||||
Feature #3442: Default values for fallbacks from ini file
|
Feature #3442: Default values for fallbacks from ini file
|
||||||
Feature #3610: Option to invert X axis
|
Feature #3610: Option to invert X axis
|
||||||
|
|
|
@ -431,6 +431,12 @@ namespace MWScript
|
||||||
std::string effect = runtime.getStringLiteral(runtime[0].mInteger);
|
std::string effect = runtime.getStringLiteral(runtime[0].mInteger);
|
||||||
runtime.pop();
|
runtime.pop();
|
||||||
|
|
||||||
|
if (!ptr.getClass().isActor())
|
||||||
|
{
|
||||||
|
runtime.push(0);
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
char *end;
|
char *end;
|
||||||
long key = strtol(effect.c_str(), &end, 10);
|
long key = strtol(effect.c_str(), &end, 10);
|
||||||
if(key < 0 || key > 32767 || *end != '\0')
|
if(key < 0 || key > 32767 || *end != '\0')
|
||||||
|
@ -659,6 +665,12 @@ namespace MWScript
|
||||||
std::string id = runtime.getStringLiteral(runtime[0].mInteger);
|
std::string id = runtime.getStringLiteral(runtime[0].mInteger);
|
||||||
runtime.pop();
|
runtime.pop();
|
||||||
|
|
||||||
|
if (!ptr.getClass().isActor())
|
||||||
|
{
|
||||||
|
runtime.push(0);
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
const MWMechanics::CreatureStats& stats = ptr.getClass().getCreatureStats(ptr);
|
const MWMechanics::CreatureStats& stats = ptr.getClass().getCreatureStats(ptr);
|
||||||
runtime.push(stats.getActiveSpells().isSpellActive(id) || stats.getSpells().isSpellActive(id));
|
runtime.push(stats.getActiveSpells().isSpellActive(id) || stats.getSpells().isSpellActive(id));
|
||||||
}
|
}
|
||||||
|
|
|
@ -536,7 +536,7 @@ namespace MWScript
|
||||||
|
|
||||||
Interpreter::Type_Integer value = 0;
|
Interpreter::Type_Integer value = 0;
|
||||||
|
|
||||||
if (ptr.getClass().getCreatureStats(ptr).getSpells().hasSpell(id))
|
if (ptr.getClass().isActor() && ptr.getClass().getCreatureStats(ptr).getSpells().hasSpell(id))
|
||||||
value = 1;
|
value = 1;
|
||||||
|
|
||||||
runtime.push (value);
|
runtime.push (value);
|
||||||
|
|
|
@ -23,6 +23,7 @@ namespace ESM {
|
||||||
|
|
||||||
mScale = 1.f;
|
mScale = 1.f;
|
||||||
mHasAI = false;
|
mHasAI = false;
|
||||||
|
mAiData.blank();
|
||||||
|
|
||||||
bool hasName = false;
|
bool hasName = false;
|
||||||
bool hasNpdt = false;
|
bool hasNpdt = false;
|
||||||
|
@ -160,7 +161,6 @@ namespace ESM {
|
||||||
mSpells.mList.clear();
|
mSpells.mList.clear();
|
||||||
mHasAI = false;
|
mHasAI = false;
|
||||||
mAiData.blank();
|
mAiData.blank();
|
||||||
mAiData.mServices = 0;
|
|
||||||
mAiPackage.mList.clear();
|
mAiPackage.mList.clear();
|
||||||
mTransport.mList.clear();
|
mTransport.mList.clear();
|
||||||
}
|
}
|
||||||
|
|
|
@ -18,6 +18,7 @@ namespace ESM
|
||||||
mInventory.mList.clear();
|
mInventory.mList.clear();
|
||||||
mTransport.mList.clear();
|
mTransport.mList.clear();
|
||||||
mAiPackage.mList.clear();
|
mAiPackage.mList.clear();
|
||||||
|
mAiData.blank();
|
||||||
mHasAI = false;
|
mHasAI = false;
|
||||||
|
|
||||||
bool hasName = false;
|
bool hasName = false;
|
||||||
|
|
Loading…
Reference in a new issue