mirror of
https://github.com/OpenMW/openmw.git
synced 2025-02-07 07:45:35 +00:00
End pursue package if the target doens't have a bounty
This commit is contained in:
parent
dff86dc1e2
commit
af40d7ce80
2 changed files with 5 additions and 1 deletions
|
@ -1152,7 +1152,7 @@ namespace MWMechanics
|
||||||
if (npcStats.getCrimeId() != -1)
|
if (npcStats.getCrimeId() != -1)
|
||||||
{
|
{
|
||||||
// if you've paid for your crimes and I haven't noticed
|
// if you've paid for your crimes and I haven't noticed
|
||||||
if (npcStats.getCrimeId() <= world->getPlayer().getCrimeId() || playerStats.getBounty() <= 0)
|
if (npcStats.getCrimeId() <= world->getPlayer().getCrimeId())
|
||||||
{
|
{
|
||||||
// Calm witness down
|
// Calm witness down
|
||||||
if (ptr.getClass().isClass(ptr, "Guard"))
|
if (ptr.getClass().isClass(ptr, "Guard"))
|
||||||
|
|
|
@ -12,6 +12,7 @@
|
||||||
#include "actorutil.hpp"
|
#include "actorutil.hpp"
|
||||||
#include "character.hpp"
|
#include "character.hpp"
|
||||||
#include "creaturestats.hpp"
|
#include "creaturestats.hpp"
|
||||||
|
#include "npcstats.hpp"
|
||||||
|
|
||||||
namespace MWMechanics
|
namespace MWMechanics
|
||||||
{
|
{
|
||||||
|
@ -47,6 +48,9 @@ namespace MWMechanics
|
||||||
if (target.getClass().getCreatureStats(target).isDead())
|
if (target.getClass().getCreatureStats(target).isDead())
|
||||||
return true;
|
return true;
|
||||||
|
|
||||||
|
if (target.getClass().getNpcStats(target).getBounty() <= 0)
|
||||||
|
return true;
|
||||||
|
|
||||||
actor.getClass().getCreatureStats(actor).setDrawState(DrawState::Nothing);
|
actor.getClass().getCreatureStats(actor).setDrawState(DrawState::Nothing);
|
||||||
|
|
||||||
// Set the target destination
|
// Set the target destination
|
||||||
|
|
Loading…
Reference in a new issue