elsid
ca93f8ee39
Compare initialized iterator
...
Comparsion of untilialized iterator is UB. Initialize with packages end.
2020-05-17 21:42:38 +02:00
elsid
e3cce0949e
Replace condition that may lead to UB by assert
...
If mPackages is empty it means package is a pointer to a deleted object
at line . We can assume it couldn't happen because execute is always called
next for this object at line 289.
2020-05-17 21:42:38 +02:00
Andrei Kortunov
9f27a0d095
Keep an AiWanderStorage when cloning an actor (bug #5267 )
2020-03-10 12:22:21 +04:00
capostrophic
fc0f813dcb
Add and use 'always active' AI package flag
...
Update documentation
2020-01-10 12:07:57 +03:00
capostrophic
2d87d287ba
Handle out-of-range actors' travel packages ( #5212 )
2020-01-09 14:17:54 +03:00
Andrei Kortunov
61ab7f3c1e
Implement actors movement deceleration (feature #4544 )
2019-10-31 14:41:12 +04:00
Grigory Latyshev
3872d7476b
Move makeOsgVec3f() to settingsutils.hpp
...
Remove all other makeOsgVec3f() implementations
2019-02-28 20:03:42 +00:00
Andrei Kortunov
3032b177a1
Remove redundant includes
2019-02-23 08:02:12 +04:00
Andrei Kortunov
2cac8b59b1
Use square distance to target
2018-08-29 17:20:32 +04:00
Marc Zinnschlag
20c53594de
Merged merge request !36
2018-08-18 12:06:35 +02:00
James Carty
513e99148e
Fix function with no return value
2018-08-17 20:18:20 +01:00
James Carty
6889432030
Move code to seperate functions for reusability
2018-08-16 00:26:02 +01:00
Andrei Kortunov
5a4d0cec3a
Use new logging system for game itself
2018-08-14 23:05:43 +04:00
Andrei Kortunov
3d1daaebab
Rework manual spellcasting (e.g. via scripts)
2018-07-12 16:24:25 +04:00
Andrei Kortunov
ec73011617
Clean temporary storage if we assign new AI package (bug #4464 )
2018-06-27 12:52:43 +04:00
Andrei Kortunov
ee45f54b53
Refactor AiTemporaryStorage usage
2018-06-27 12:48:34 +04:00
Andrei Kortunov
6ed2773299
Do not stack return packages
2018-06-08 21:53:47 +04:00
Andrei Kortunov
74a2cbe696
AI: return back after pursuit
2018-06-08 21:53:47 +04:00
Andrei Kortunov
3d0631cfcc
Store last AI package in savegame
2018-06-08 21:53:47 +04:00
Andrei Kortunov
3a0ee78d2b
AiTravel: store mHidden flag in savegame
2018-06-08 21:53:47 +04:00
Andrei Kortunov
18ff097e4a
Add the parameter to AiSequence::stack() to control ability to cancel other AI packages
2018-06-08 21:53:47 +04:00
scrawl
fde6e29628
Merge pull request #1326 from akortunov/spellpriority
...
Combat AI improvements [feedback needed]
2017-07-31 17:51:51 +00:00
Andrei Kortunov
548814bfbc
Added AiBreathe package (feature #1374 )
2017-07-25 10:58:04 +04:00
Andrei Kortunov
1a8f2bfc11
Combat AI: select target by priority
2017-06-16 16:11:12 +04:00
Allofich
4f08084e79
Make stationary actors return to position on load
...
Also makes wandering actors resume their previous destination when an interrupting combat or pursuit ends.
(Fixes #3656 )
2017-06-15 18:33:50 +09:00
Allofich
028762a7dc
Make guards that are attacked try to arrest player
...
(Fixes #3706 )
2017-06-15 01:47:10 +09:00
Ewan Higgs
38a2de3c51
convert std::autor_ptr to std::unique_ptr, originally by Ewan Higgs and updated by Bret Curtis
2017-06-09 16:49:25 +02:00
Allofich
2e5fd74db0
Fix invalid iterator warning
2017-04-20 19:30:35 +09:00
Allofich
6b53541571
Prevent AI actors from hitting unintended targets
...
(Fixes #3254 )
2017-02-12 19:51:19 +09:00
scrawl
03a10f217a
Catch exceptions in AiSequence::execute
2017-02-11 17:53:11 +01:00
Allofich
a46c4de918
Stop combat when adding an AI package to an actor
...
(Fixes #3722 )
2017-01-15 01:53:22 +09:00
Allofich
53e94b7c3f
Fix shadowing warnings
2016-10-06 23:33:52 +09:00
mrcheko
612c7f1a2f
Revert "Revert "Merge pull request #993 from mrcheko/pathfinding""
...
This reverts commit 3732979eec
.
2016-08-19 22:15:26 +03:00
scrawl
3732979eec
Revert "Merge pull request #993 from mrcheko/pathfinding"
...
This reverts commit 5190275b37
, reversing
changes made to d7845012bf
.
2016-08-14 18:04:33 +02:00
mrcheko
203804ff15
fix AiPackage repeating
2016-07-16 19:08:49 +03:00
MiroslavR
dc0bc5b68c
Implement Face instruction (Feature #1424 )
2016-07-09 02:16:47 +02:00
Allofich
b1be3596dc
Cleanup of #include statements
2016-06-18 10:56:28 +09:00
Allofich
065d6a391d
Don't repeat sequences of only one non-wander AI
2016-06-06 04:12:49 +09:00
Allofich
bce66c629a
Change editor-placed AI packages to cycle
2016-05-29 17:34:40 +09:00
scrawl
496cb85b01
Do not cancel Ai packages when on loading ( Fixes #3409 )
...
This piece of code was an attempt to fix up save games made before commit d3b76b7006
, but ended up introducing a new bug.
2016-05-28 20:27:05 +02:00
scrawl
3b31e8f66e
Do not set AiPackageDone flag for non-Aipackages ( Fixes #3392 )
2016-05-14 19:19:37 +02:00
Michał Moroz
40cc6a4164
Changed AiSequence::stack to push_back lower priority packages instead of push_front (Bug #3384 )
2016-05-04 13:55:36 +02:00
scrawl
93b2f09224
Workaround for some AI functions being incorrectly handled as AI packages (Bug #3378 )
2016-04-29 18:07:35 +02:00
scrawl
14e1911820
Fix memory leaks
2016-03-10 20:38:14 +01:00
scrawl
c4d38bb42d
Fix clang analyzer warnings
2016-02-16 19:17:04 +01:00
scrawl
48ac0bef3e
Repair save games affected by bug #3080 ( Fixes #3160 )
2016-02-11 16:34:02 +01:00
scrawl
d3b76b7006
Don't stack Ai packages ( Fixes #3101 , Fixes #3080 , Fixes #2697 )
2016-02-02 22:20:56 +01:00
scrawl
14b143231c
Don't crash OpGetTarget when the target disappeared ( Fixes #3048 )
2015-11-30 15:26:43 +01:00
dteviot
77a1d947cc
extracted MWMechanics::getPlayer()
2015-08-21 21:12:39 +12:00
scrawl
278076e609
Include cleanup
2015-07-25 04:14:22 +02:00