Alexei Kotov
0b38e165f7
Avoid clearing the current weapon animation group if it's still going to be in use
2022-06-17 09:53:13 +00:00
psi29a
67e764a44a
Merge branch 'severecharacterdisorder' into 'master'
...
Make the character controller less miserable, round 4: juicy stuff (bug #5592 )
Closes #5592
See merge request OpenMW/openmw!2014
2022-06-15 11:42:17 +00:00
elsid
fdd84265b3
Use proper agent height and radius when render actor path
...
That are based on half extents used to find path over navmesh which is different
for interior and exterior cells.
Use common functions to get agent height and radius for actor path rendering and
navmesh generation.
2022-06-15 01:11:11 +02:00
Alexei Kotov
2b019864b7
Remove more legacy states
2022-06-14 13:47:16 +03:00
Alexei Kotov
30ef7ad81b
Properly cancel the landing animation during movement
2022-06-14 12:50:30 +03:00
Alexei Kotov
c2ac52c82a
Remove dead code
2022-06-14 12:50:30 +03:00
Alexei Kotov
61d382dc9f
Set the initial IdleState to CharState_None
2022-06-14 12:50:30 +03:00
Alexei Kotov
4ce08664e9
Fix swim spellcasting stance turning fallback
2022-06-14 12:50:30 +03:00
Alexei Kotov
5dfce6205a
Reset the idle animation after a movement animation ends
...
Fix non-biped actor idle reset
2022-06-14 12:50:30 +03:00
Alexei Kotov
1a646374b0
Always reset the idle animation after the landing animation ends
2022-06-14 12:50:30 +03:00
Alexei Kotov
69a1d8ac86
Restart idle instantly only after the hit state ends
2022-06-14 12:50:30 +03:00
Alexei Kotov
35db7b8319
Fix fallback for missing swim/sneak idle animations
2022-06-14 01:12:05 +03:00
Alexei Kotov
253de65d13
Fix knockout animation interruption/looping
2022-06-13 17:53:38 +03:00
Alexei Kotov
b8018024a6
Avoid passing weapon short group to refreshXAnims
2022-06-13 17:53:38 +03:00
Alexei Kotov
0a38c3ab78
Reset current animation states in a consistent way
2022-06-13 17:53:38 +03:00
Alexei Kotov
dd42a69ca5
Consolidate refreshIdleAnims
2022-06-13 17:53:38 +03:00
Alexei Kotov
2c3d385672
Consolidate refreshHitRecoilAnims
2022-06-13 17:53:38 +03:00
Alexei Kotov
a105ba14e4
Consolidate refreshJumpAnims
2022-06-13 12:59:18 +03:00
Alexei Kotov
ab46337c41
Rewrite handleTextKey using substring views
2022-06-13 12:28:12 +03:00
Alexei Kotov
9e6b7fed1a
Consolidate refreshMovementAnims()
2022-06-13 12:13:10 +03:00
psi29a
eac1d8599a
Merge branch 'lua_record_paths' into 'master'
...
Correct VFS paths in Lua records
See merge request OpenMW/openmw!1853
2022-06-12 18:45:24 +00:00
uramer
fd7965d77f
Use correctMeshPath instead of string constants
2022-06-12 11:30:29 +02:00
Alexei Kotov
c2e637d661
Mark setAttackingOrSpell as const
2022-06-12 03:02:23 +03:00
Alexei Kotov
47f574e14b
Move death state mapping out of playDeath/playRandomDeath
2022-06-12 02:58:04 +03:00
Alexei Kotov
b4e87abfe1
Clean up run-to-walk state conversion
2022-06-12 02:52:49 +03:00
Alexei Kotov
31d636ea20
Map movement animation groups with a switch
2022-06-12 02:49:13 +03:00
Alexei Kotov
45e6add5f5
Optimize clearAnimQueue(true)
2022-06-11 04:54:50 +03:00
Alexei Kotov
d4d4304f1e
Fix walk animation fallback replace call
2022-06-11 04:54:50 +03:00
Alexei Kotov
93068d71ea
Use std::string_view whenever reasonable in CharacterController
...
C++ Core Guidelines SL.str.2
2022-06-11 04:54:50 +03:00
Alexei Kotov
97d4206a3d
Improve CharacterController const-correctness
...
C++ Core Guidelines Con. 2
2022-06-11 02:08:43 +03:00
Alexei Kotov
788de7edcb
Initialize most of CharacterController in-class
...
See C++ Core Guidelines C.48
2022-06-11 00:40:14 +03:00
psi29a
af82140dda
Merge branch 'filter_physics_actors' into 'master'
...
Do not perform physics simulation for actors outside processing range
See merge request OpenMW/openmw!1934
2022-05-29 19:19:35 +00:00
Evil Eye
3c83117e99
Replace new with make_unique in openmw
2022-05-29 13:24:48 +02:00
elsid
bf76faeb2d
Increment iterator before fast forward
...
When player is located in the exterior cell AiTravel::fastForward may move
another actor into a cell outside active grid. This will remove the actor from
MWMechanics::Actors::mActors which invalidates current iterator in the
Actors::fastForwardAi loop.
2022-05-27 13:35:21 +02:00
elsid
ac5844cad2
Do not perform physics simulation for actors outside processing range
...
Actors with disabled collisions still have physics simulations. Assuming they
should not be processed at all instead of disabling collision add a new flag to
make them inactive.
2022-05-26 10:36:03 +02:00
psi29a
31c0c0cb58
Merge branch 'fix_initial_landing' into 'master'
...
Do not play landing animation for actors entering to scene without a reason (#6346 + #6513 )
Closes #6513 and #6346
See merge request OpenMW/openmw!1926
2022-05-26 06:15:59 +00:00
Evil Eye
921a4c7bca
Fix inverted logic
2022-05-25 16:49:03 +02:00
elsid
85c79d382c
Enable collisions for actor before adjusting position
...
Otherwise adjustPosition does not call traceDown and actor appears flying for
the first physics simulation.
2022-05-24 23:30:57 +02:00
elsid
6db4b78dcb
Fix playing explore music after loading the game from main menu
2022-05-23 01:08:53 +02:00
psi29a
f17d7fc00b
Merge branch 'string_view' into 'master'
...
Make getStringLiteral return a string_view
See merge request OpenMW/openmw!1896
2022-05-22 20:50:04 +00:00
Evil Eye
c6ca0e78c9
Make getStringLiteral return a string_view
2022-05-21 01:21:55 +02:00
elsid
19e471741a
Use PtrBase::mRef instead of getBase for mechanics objects
...
getBase adds a condition and can throw an exception. Which is redundant for
MWMechanics::Objects functions.
2022-05-21 00:41:57 +02:00
elsid
1bb1053569
Make all MWMechanics::Actor functions inline
2022-05-21 00:41:56 +02:00
elsid
77c09dff39
Store CharacterController by value in MWMechanics::Actor
2022-05-21 00:41:55 +02:00
elsid
e2c44d13f3
Use std::list to store mechanics actors
...
To make the order of elements deterministic. Using memory address based objects
as map key makes order of elements there nondeterministic. Later it can be
replaced with vector when there are no indirect munipulations with container
inside iteration loops.
Change map key to const MWWorld::LiveCellRefBase* to avoid erasing and inserting
elements on MWWorld::Ptr update.
2022-05-20 22:55:55 +02:00
elsid
ce3bba0cdc
Use std::list to store mechanics objects
...
To make the order of elements deterministic. Using memory address based objects
as map key makes order of elements there nondeterministic. Later it can be
replaced with vector when there are no indirect munipulations with container
inside iteration loops.
Change map key to const MWWorld::LiveCellRefBase* to avoid erasing and inserting
elements on MWWorld::Ptr update.
Store CharacterController by value instead of pointer to avoid redundant memory
allocation.
2022-05-20 00:47:10 +02:00
ζeh Matt
18f16eac4c
Refactor DetourNavigator to pass prng along, use world prng for AiWander
2022-05-17 20:37:15 +03:00
Evil Eye
2531e24ee3
Fix inverted logic
2022-05-16 18:29:16 +02:00
elsid
ef64587cbf
Mark unchanging static as const
2022-05-09 00:59:51 +02:00
elsid
66c9b6c199
Make MWMechanics::Actors local static variables to be members
2022-05-09 00:59:37 +02:00