Andrei Kortunov
ee45f54b53
Refactor AiTemporaryStorage usage
2018-06-27 12:48:34 +04:00
Andrei Kortunov
fed10e87aa
Store integer actor ID in AI packages (bug #4036 )
2018-06-08 19:57:41 +04:00
David Cernat
22521578eb
Merge pull request #349 from OpenMW/master
...
Add OpenMW commits up to 28 Nov 2017
2017-11-29 03:52:15 +02:00
scrawl
c50b18b3bb
Move PathgridGraph out of CellStore
...
By definition this is not 'Mutable state of a cell' and does not belong in CellStore.
This change should improve startup times (graph is now loaded on demand) and edits to 'pathgrid.hpp' no longer cause the entirety of OpenMW to be rebuilt.
2017-11-27 21:20:31 +00:00
David Cernat
2ba1c84cf7
Merge pull request #335 from OpenMW/master while resolving conflicts
...
# Conflicts:
# apps/openmw/mwgui/container.cpp
2017-11-12 06:35:15 +02:00
rexelion
f0649849b8
changed variable name to be more descriptive
2017-11-11 12:00:23 +00:00
rexelion
69a56eaea3
don't initialise rangeAttackOfTarget
2017-11-10 10:44:53 +00:00
rexelion
983c33c4c8
don't use a pointer for ActionWeapon
2017-11-09 14:23:26 +00:00
rexelion
cab0002461
Backing up distance is now dependent on opponents's weapon range; don't back up from ranged oponents
2017-11-07 17:57:23 +00:00
David Cernat
721b218cc2
Merge pull request #258 from OpenMW/master while resolving conflicts
...
# Conflicts:
# .travis.yml
# README.md
2017-08-05 00:09:34 +03:00
Koncord
6222c20e82
[Client] Convert MechanicsHelper to namespace
2017-06-27 16:43:53 +08:00
David Cernat
fa3baac0f3
Merge pull request #228 from OpenMW/master while resolving conflicts
...
# Conflicts:
# .travis.yml
# CMakeLists.txt
# apps/openmw/main.cpp
2017-06-18 18:16:10 +03:00
Andrei Kortunov
62b24eb078
Combat AI: do not use range weapons under water
2017-06-16 12:20:31 +04:00
Bret Curtis
d785344fad
purge all instances of <boost/shared_ptr.hpp>, clean up unused headers
2017-06-09 19:08:53 +02: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
David Cernat
a4165325fa
[Client] Improve synchronization of Actor swings
2017-04-25 01:47:43 +03:00
David Cernat
ce9605957a
[Client] Use different way of preventing attacks on players in dialogue
2017-04-25 01:11:01 +03:00
David Cernat
edb155869b
Merge pull request #201 from OpenMW/master
...
Add OpenMW commits up to 19 Apr 2017
2017-04-19 22:12:33 +03:00
David Cernat
2e8714afaa
[Client] Rethink and restructure tes3mp combat code so it works for NPCs
2017-04-19 22:06:04 +03:00
Allofich
5a00b239ac
Reduce scope of variables
2017-04-20 01:22:30 +09:00
scrawl
8752ae9c6a
Fix include
2017-02-10 06:28:23 +01:00
Allofich
5d2090684a
Store mHitAttemptActorId in save files
2017-02-07 01:26:26 +09:00
Allofich
25c64dbb0f
Make combat engagement logic more like vanilla
...
(Fixes #2678 , Fixes #3705 )
2017-02-07 01:25:12 +09:00
Allofich
e10c4d8814
Stop combat between AI when canFight is false
2016-12-26 22:42:42 +09:00
Leon Krieg
739cd5ba45
Fixed more spelling mistakes
2016-12-15 13:09:40 +01:00
Allofich
a6dae51d87
Require line of sight for AI attacks ( Fixes #3646 )
2016-12-07 01:35:30 +09:00
MiroslavR
5e46121046
Implement fleeing AI ( Closes #1118 )
2016-11-16 20:15:25 +01:00
Martijn Bakker
45ffdbb284
fixed a segmentation fault when entering a cell which contains someone already attacking you
2016-09-30 00:40:13 +01:00
Allofich
04c13ffab3
Add unarmed attack selection to chooseBestAttack()
2016-09-22 00:45:54 +09:00
mrcheko
229cb4b386
remove dynamic_cast to ActionPotion
2016-09-20 23:00:00 +03:00
mrcheko
48765f2ff2
fix using potion as weapon
2016-09-19 23:43:26 +03:00
scrawl
65dc12cdd6
Remove unused parameter
2016-09-13 02:48:36 +02:00
Allofich
3bbde312b9
Remove unneeded code
2016-09-12 19:54:06 +09:00
Allofich
c98d4e0473
Allow dodging for bipedal creatures
2016-09-10 23:56:31 +09:00
Allofich
7bc4535c0d
Make NPCs dodge according to target's weapon reach
2016-09-10 23:30:46 +09:00
scrawl
05e4542d33
Merge pull request #1048 from mrcheko/pathfinding
...
Pathfinding unification v2
2016-09-06 13:19:18 +02:00
Allofich
5c2bc515fe
Remove overridden code in aicombat
2016-09-04 02:13:09 +09:00
Allofich
0d63d75bb0
Remove no longer used parameter
2016-09-03 22:40:24 +09:00
Allofich
286e4bb98f
Remove attacktype movement
2016-09-03 21:16:59 +09:00
Allofich
154dcc942c
Let NPCs use attack type regardless of movement
2016-09-01 22:43:33 +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
e2cd87fcc7
fix veritcal aiming
2016-08-07 19:23:08 +03:00
mrcheko
293a0f768c
use real distance to target to determinate 'ready to attack' state
2016-07-27 23:43:32 +03:00
mrcheko
8d4f0660ce
fix hardcoded melee attack ranges
2016-07-12 00:17:43 +03:00
mrcheko
d2fe6fe857
Merge remote-tracking branch 'refs/remotes/origin/master' into pathfinding
...
# Conflicts:
# apps/openmw/mwmechanics/aiactivate.cpp
# apps/openmw/mwmechanics/aicombat.cpp
# apps/openmw/mwmechanics/aicombat.hpp
# apps/openmw/mwmechanics/aifollow.cpp
# apps/openmw/mwmechanics/aipackage.cpp
# apps/openmw/mwmechanics/aipackage.hpp
# apps/openmw/mwmechanics/aiwander.cpp
# apps/openmw/mwmechanics/aiwander.hpp
2016-07-09 22:59:54 +03:00
terrorfisch
be25e2ba75
Make NPCs use both hands in weaponless combat.
2016-06-20 10:24:51 +02:00
Allofich
b1be3596dc
Cleanup of #include statements
2016-06-18 10:56:28 +09:00
scrawl
8fcc1911d9
Use fCombatDistance as the creature attack range
2016-06-10 23:47:01 +02:00
Roman Proskuryakov
d7046878a8
Fix uninitialized values in MWMechanics::AiCombat
2016-05-07 20:41:47 +03:00
mrcheko
b304e98568
implement ActionWeapon::getCombatRange (move logic from AiCombat)
2016-01-15 21:49:27 +03:00
scrawl
daa94cc50e
Fix cppcheck warnings
2016-01-03 20:19:38 +01:00
mrcheko
bcb1f4ed05
refactor AiCombat: remove all pathfinding code, adopt new version of
...
AiPackage::pathTo;
fix couple of warnings;
2016-01-03 15:33:52 +03:00
mrcheko
d7d5cc6689
Merge remote-tracking branch 'upstream/master' into pathfinding
...
Conflicts:
apps/openmw/mwmechanics/aicombat.cpp
apps/openmw/mwmechanics/aifollow.cpp
apps/openmw/mwmechanics/aipackage.cpp
apps/openmw/mwmechanics/aipackage.hpp
apps/openmw/mwmechanics/aiwander.cpp
apps/openmw/mwmechanics/pathfinding.hpp
Ogre::Vector3->osg::Vec3f; REACTION_INTERVAL->AI_REACTION_TIME; MakeOgreVec3->MakeOsgVec3
2015-12-29 19:15:40 +03:00
scrawl
3453353091
AiCombat distance check takes into account collision box ( Fixes #1699 )
2015-11-18 19:00:43 +01:00
dteviot
5369d20682
Moved pathfinding logic from AiCombat to Pathfinding.
2015-09-19 15:34:02 +12:00
Marc Zinnschlag
96880b4dfe
Merge remote-tracking branch 'scrawl/tabs'
2015-09-17 09:30:31 +02:00
scrawl
c4b5a41ac3
Improve combat AI vertical aiming ( Fixes #1366 , Fixes #1330 )
2015-09-17 03:41:15 +02:00
scrawl
a47617c21f
Fix tab indentations in apps/ and components/
2015-09-16 20:45:37 +02:00
dteviot
0feae19140
AiCombat use evadeObstacles() from AiPackage.
2015-09-14 19:57:22 +12:00
dteviot
2b9e22f593
extracted function stopAttack().
2015-08-09 14:29:38 +12:00
dteviot
0884a3796f
extracted function isTargetMagicallyHidden().
2015-08-09 14:20:55 +12:00
dteviot
038851420d
Removed unneeded temp variables.
...
Corrected case of function names.
2015-08-09 14:18:55 +12:00
dteviot
50ddcd1953
more attack logic moved into AiCombatStorage.
2015-08-09 14:10:08 +12:00
dteviot
0735e3e06e
move start attack logic to AiCombatStorage.
...
Basically, copied from mrchenko's 1d4be08f6e4c2dbd89cc0c3408a8231ee4497277
2015-08-09 14:08:42 +12:00
dteviot
1676bf917e
CombatMove logic moved into AiCombatStorage.
...
Basically, copied from mrcheko's 1d4be08f6e4c2dbd89cc0c3408a8231ee4497277
2015-08-09 14:06:52 +12:00
dteviot
58f732ebc9
Update path following checks each frame in AiCombat.
2015-08-04 18:20:05 +12:00
dteviot
ad9bab0b68
Removed redundant if.
2015-08-04 18:17:08 +12:00
dteviot
4256e151b1
Fixed error in deciding type of attack
2015-08-04 18:15:58 +12:00
Marc Zinnschlag
26ea3aa1ad
Merge remote-tracking branch 'dteviot/refactoringAiWander'
2015-07-30 10:26:40 +02:00
dteviot
04aee1fe20
extracted function reactionTimeActions().
2015-07-26 17:32:29 +12:00
dteviot
b3d5b47fea
extracted function UpdateActorsMovement().
2015-07-26 17:23:45 +12:00
dteviot
aba7225817
Removed some duplicated operations.
2015-07-26 11:15:21 +12:00
scrawl
b3f5ac5dbb
Include cleanup
2015-07-25 02:11:49 +02:00
scrawl
e6b28d84f0
Outdated comment fix
2015-07-25 00:28:47 +02:00
dteviot
1ed6e95c07
Got rid of some radians to degrees to radians conversions.
2015-07-19 18:01:25 +12:00
mrcheko
c773ed9f9a
move checkWayIsClear to pathfinding; move shortcut logic to separate func (AiPackage::shortcutPath); rework AiPackage::pathTo
2015-07-04 18:00:16 +03:00
scrawl
6bcea21e14
Use fCombatDelayCreature, fCombatDelayNpc for random delays between aicombat attacks (Bug #1876 )
2015-07-04 05:19:05 +02:00
scrawl
a7bd050928
Accurate attack timings in AiCombat
2015-07-03 05:58:12 +02:00
scrawl
82740c1645
Remove completely broken code
2015-07-03 02:29:42 +02:00
scrawl
d07b176b36
Take into account hit recovery, knockdown and other animations for AiCombat attack timing
2015-07-03 02:18:35 +02:00
scrawl
520a832a9a
Remove an already resolved todo comment
2015-07-02 22:24:23 +02:00
scrawl
a1432b0255
Move attackingOrSpell flag to the CharacterController
2015-07-02 19:14:28 +02:00
scrawl
59db9664ba
Pass the CharacterController to AiPackage::execute
2015-06-26 17:47:04 +02:00
scrawl
cad18969e3
Merge branch 'master' of https://github.com/OpenMW/openmw into osg
...
Conflicts:
apps/openmw/mwmechanics/aicombat.cpp
apps/openmw/mwmechanics/aitravel.cpp
2015-06-14 16:32:13 +02:00
dteviot
cb8ca2f03a
Moved logic for building a Sync'ed path from AiCombat to PathFinding.
...
Is now used by AiFollow, which should fix "running in circles" bug caused when recalc a path and closest way point is the one NPC has just passed.
2015-06-11 18:31:35 +12:00
scrawl
a0b0ae9bd1
Remove an unused variable
2015-06-04 21:51:24 +02:00
scrawl
4bb3cbf0fb
Remove last remains of Ogre
2015-06-03 23:04:35 +02:00
scrawl
7bacb9418d
Various math code ported to osg
2015-06-03 19:41:19 +02:00
scrawl
58ebf57154
Apply a comment that got lost in the endless depths of my git stash
2015-06-02 17:13:30 +02:00
scrawl
22f01b1232
Merge branch 'master' of https://github.com/OpenMW/openmw into osg
...
Conflicts:
apps/launcher/graphicspage.cpp
apps/opencs/editor.cpp
apps/opencs/model/doc/document.cpp
apps/opencs/view/render/cell.cpp
apps/opencs/view/render/mousestate.cpp
apps/opencs/view/render/textoverlay.cpp
apps/opencs/view/render/worldspacewidget.cpp
apps/openmw/mwclass/creature.cpp
apps/openmw/mwclass/npc.cpp
apps/openmw/mwgui/inventorywindow.cpp
apps/openmw/mwgui/loadingscreen.cpp
apps/openmw/mwgui/mapwindow.cpp
apps/openmw/mwgui/pickpocketitemmodel.cpp
apps/openmw/mwgui/waitdialog.cpp
apps/openmw/mwmechanics/combat.cpp
apps/openmw/mwmechanics/mechanicsmanagerimp.cpp
apps/openmw/mwrender/globalmap.cpp
apps/openmw/mwworld/physicssystem.cpp
apps/openmw/mwworld/refdata.cpp
apps/openmw/mwworld/scene.cpp
apps/openmw/mwworld/worldimp.cpp
components/sdlutil/sdlinputwrapper.cpp
extern/shiny/Main/Factory.cpp
extern/shiny/Main/MaterialInstance.cpp
extern/shiny/Main/Platform.cpp
extern/shiny/Main/ShaderSet.cpp
2015-05-23 20:33:44 +02:00
Rohit Nirmal
396fba7fa9
Silence -Wreorder warnings, and remove -Wno-reorder.
2015-05-21 22:46:44 -05:00
scrawl
ccab8cc9a1
Register Player in the PhysicsSystem
2015-05-12 17:40:42 +02:00
scrawl
8c810e3620
Move rng to components
2015-04-22 17:58:55 +02:00
scrawl
4e69e7cc0f
OpenMW compiles and runs w/o render window
2015-04-01 17:02:15 +02:00
dteviot
eb1090a1b6
Waypoint check only considers X & Y distance ( Fixes #2423 )
...
When pathfinder checks if actor has reached a waypoint, ignore actor's altitude.
2015-03-23 20:09:46 +13:00
dteviot
3f28634d1f
consolidate random number logic
...
Note, I suspect Rng::rollClosedProbability() is not needed. The only difference between it and rollProbability() is that one time in 37k (on Windows), it will give an output of 1.0.
On some versions of Linux, the value of 1.0 will occur about 1 time in 4 billion.
2015-03-15 14:07:47 +13:00
dteviot
ca8c8c6aa4
fixing MSVC 2013 warning C4244: & C4305
...
conversion from 'const float' to 'int', possible loss of data
conversion from 'double' to 'int', possible loss of data
conversion from 'float' to 'int', possible loss of data
2015-03-08 17:42:07 +13:00
scrawl
81925645a3
Unreachable enemies combat AI fix ( Fixes #2271 )
2015-02-14 16:51:54 +01:00
scrawl
f35c9b7a69
Clang warning fixes (thanks hemite)
2015-01-27 23:12:20 +01:00