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
dteviot
8e2fe1985d
Fixed errors pointed out by Zini.
...
1. Removed "Actor" from name of function isActorNearInactiveCell().
2. Corrected case of CoordinateConverter member function names.
2015-09-12 14:17:46 +12:00
dteviot
1dfe438a5d
reduce "reset if stuck" AiWander timeout.
...
Now is about 14 seconds, instead of 300.
2015-08-30 16:43:35 +12:00
dteviot
f2c9b9351f
Try going right and left to "unstick" actor.
2015-08-30 10:06:09 +12:00
dteviot
31d82b6b0c
Unifiy evadeObstacles() logic between AiWander and AiPackage
...
Can't use same code, but logic is now same.
2015-08-30 08:32:47 +12:00
dteviot
f59e918a3b
removed useless code.
...
zTurn ignores turns < 0.0087 radians.
2015-08-29 17:34:33 +12:00
Marc Zinnschlag
a52b947efe
Merge remote-tracking branch 'dteviot/MagicEffectsRefactorDraft3'
2015-08-23 12:11:30 +02:00
dteviot
77a1d947cc
extracted MWMechanics::getPlayer()
2015-08-21 21:12:39 +12:00
dteviot
85bc41dedb
replaced FLT_MAX with numeric_limits.
2015-08-21 19:34:28 +12:00
dteviot
942a987d52
centralize the world/cell coordinate conversion logic.
2015-08-16 18:55:02 +12:00
Arthur Moore
08d5aaf0fc
Remove more comments
2015-07-31 18:23:07 -04:00
Arthur Moore
6fce49bfb5
Don't warn twice when unable to play an idle animation
2015-07-31 18:01:02 -04:00
Arthur Moore
61c3835637
Don't try to play animations we know are bad
...
Prevents log spam
2015-07-31 18:01:02 -04:00
Arthur Moore
5ea596f38d
Refactor onChooseActionStatePerFrameActions
...
This prevents playIdle errors from tyring to play idleAnimation 0
2015-07-30 08:15:45 -04:00
Arthur Moore
f69de1f263
Alert the user if trying to play a non-idle animation
...
Continue to propagate success/failure up the call stack.
2015-07-30 08:08:58 -04:00
dteviot
c7aacaee70
extracted function returnToStartLocation().
2015-07-26 17:29:32 +12:00
dteviot
5e519ef550
extract function isPackageFinished().
2015-07-26 17:29:01 +12:00
dteviot
ad0d807103
extracted function reactionTimeActions().
2015-07-26 17:28:32 +12:00
dteviot
9c0e3d6c28
extracted functions doPerFrameActionsForState() and onChooseActionStatePerFrameActions().
2015-07-26 17:25:44 +12:00
dteviot
76f95eafe7
extract function onWalkingStatePerFrameActions().
2015-07-26 17:25:00 +12:00
dteviot
5ec310dfba
extract function onIdleStatePerFrameActions().
2015-07-26 17:24:33 +12:00
dteviot
00eef585af
renamed mPlayedIdle to mIdleAnimation.
2015-07-19 18:04:42 +12:00
dteviot
22f49128cc
replaced multiple booleans with single state variable.
2015-07-19 18:02:13 +12:00
dteviot
1ed6e95c07
Got rid of some radians to degrees to radians conversions.
2015-07-19 18:01:25 +12:00
dteviot
3ebe9fb34f
renamed mRotate to mTurnActorGivingGreetingToFacePlayer
2015-07-19 18:00:49 +12:00
dteviot
e294cd95cd
extracted function playIdleDialogueRandomly()
2015-07-12 17:15:14 +12:00
dteviot
22059d68f6
Remove duplicated code.
2015-07-12 17:14:48 +12:00
dteviot
0b089a5564
extracted function evadeObstacles()
2015-07-12 16:38:36 +12:00
dteviot
1ef78b1e56
extracted playGreetingIfPlayerGetsTooClose()
2015-07-12 16:37:31 +12:00
dteviot
df421fce92
extracted function setPathToAnAllowedNode()
2015-07-12 16:35:15 +12:00
dteviot
b508846a64
Renamed mStoredAvailableNodes to mPopulateAvailableNodes.
...
Don't call getAllowedNodes() needlessly.
2015-07-12 16:32:48 +12:00
dteviot
f1774ee7c3
Fixed compile failing on OSX and Linux.
2015-07-08 19:34:33 +12:00
dteviot
52cf8541f5
End point tolerance restored to 64 units.
...
Corrected problem pointed out by Scrawl.
Destination needs tolerance of 64 to avoid overcrowding.
2015-07-08 18:41:03 +12:00
dteviot
1239667cb4
AiWander uses points between PathGrid points ( Fixes #1317 )
...
When there is only on PathGrid point within a NPC's wander distance, expand possible wander destinations by using positions between PathGrid points.
2015-07-05 18:21:35 +12:00
dteviot
eb2aa965b9
Extracted function SetCurrentNodeToClosestAllowedNode()
2015-07-05 18:17:18 +12:00
dteviot
f942db2b27
Simplified code.
2015-07-05 18:08:09 +12:00
dteviot
9a02a85a24
Pulled duplicate code into function.
2015-07-05 18:07:14 +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
dteviot
fae93e3d82
Bugfix: was not resetting mStuckCount.
2015-07-04 19:00:27 +12:00
dteviot
46a654286b
Remove fix for #1317
...
Expanding the AiWander distance for path grid nodes causes bigger problems than it solved.
2015-07-04 18:57:56 +12:00
dteviot
164994f3d3
Made PathFinder::buildPath() private.
...
Now all paths are built by calling PathFinder::buildSyncedPath().
Also removed useless comment.
2015-07-04 18:47:26 +12:00
scrawl
59db9664ba
Pass the CharacterController to AiPackage::execute
2015-06-26 17:47:04 +02:00
scrawl
a5670b5133
Merge branch 'master' of https://github.com/OpenMW/openmw into osg
...
Conflicts:
apps/opencs/CMakeLists.txt
apps/opencs/main.cpp
apps/openmw/mwworld/player.hpp
2015-06-22 20:09:02 +02:00
dteviot
c65e7a31e7
Aquatic creatures no longer try to get onto land.
...
AiWander for aquatic creatures no longer uses path grid points as they're usually on land.
2015-06-21 16:23:40 +12:00
scrawl
3663511cdb
Merge branch 'master' of https://github.com/OpenMW/openmw into osg
...
Conflicts:
apps/opencs/CMakeLists.txt
extern/ogre-ffmpeg-videoplayer/CMakeLists.txt
2015-06-16 19:53:41 +02:00
scrawl
5347d407d8
Disallow AiWander fast-forward for water creatures
...
Pathgrid nodes are usually above the water level, so appearing at a random node would have the creature break out of the water level it's supposed to be constrained to.
2015-06-15 20:13:59 +02:00
scrawl
98a77f68a3
Fix AiWander::fastForward using incorrect pathgrid coordinates when actor recently moved to a new cell
2015-06-15 20:04:36 +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
fd50be0fb8
Restore various gameplay
2015-05-30 01:00:24 +02:00