scrawl
fa5198d7b2
Fix an assertion
2013-07-14 14:59:24 +02:00
Chris Robinson
5ee889e8b6
Attach the camera to the Head node in first-person
2013-07-13 16:12:38 -07:00
Chris Robinson
2d7620e774
Rotate the neck when looking up and down in first-person
2013-07-13 12:39:06 -07:00
Chris Robinson
908f010c74
Reset the NPC object root when switching POV
...
When in first person, the skeleton in the .1st.nif file is used. In
particular, these have extra finger bones that are used by the first
person models.
2013-07-12 22:31:57 -07:00
scrawl
7a2d1cd8ce
Security skill
2013-05-19 18:40:37 +02:00
Chris Robinson
f83ee5d316
Play ready/unready animations on the upper body
2013-05-13 03:32:00 -07:00
Chris Robinson
a9928bb842
Split up the UpperBody group
...
Also recognize the [un]equip start and stop text keys.
2013-05-13 02:09:22 -07:00
Chris Robinson
70dc2f77ad
Move the priority enum to MWMechanics
2013-05-13 00:54:44 -07:00
Chris Robinson
bbb38c61cc
Fix queued animations
2013-05-12 05:08:01 -07:00
Chris Robinson
3988866ecd
Make sure active groups are updated after a state is auto-disabled
2013-05-12 04:34:37 -07:00
Chris Robinson
2c556e4036
Be smarter about handling non-moving animations
...
Don't rely on being told by the play method, so the animation can
automatically change without impacting the character controller.
2013-05-12 04:29:42 -07:00
Chris Robinson
4ea347ac52
Use shared pointers to store animation sources
...
This ensures references to the sources stay valid as long it the object
is, rather than becoming invalidated whenever one is added or removed.
2013-05-11 19:38:23 -07:00
Chris Robinson
6b8a687a79
Add methods to disable an animation
...
And rename WeaponState to WeaponType
2013-05-10 22:22:39 -07:00
Chris Robinson
6605aa7dec
Create three bone groups
...
This still won't work as expected. Currently there is only one priority level,
and only one animation state per priority level can be active at a time.
It's close, though.
2013-05-10 20:45:09 -07:00
Chris Robinson
abc676eedd
Allow specifying which bone groups to play an animation on
2013-05-10 20:05:09 -07:00
Chris Robinson
56eede2610
Search more aggressively for an animation velocity
2013-05-10 19:31:33 -07:00
Chris Robinson
5a9c1e1245
Don't explicitly track the last position
2013-05-10 18:58:14 -07:00
Chris Robinson
7c3b014193
Figure out which animations to play based on priority
...
Bone group will also be taken into account later.
2013-05-10 18:37:44 -07:00
Chris Robinson
921f534980
Parameterize the number of bone groups
2013-05-10 16:35:43 -07:00
Chris Robinson
8a9b0eb5f7
Store the AnimSource in the animation state
2013-05-10 15:27:29 -07:00
Chris Robinson
58efce5008
Rename animation layers to animation states
2013-05-10 04:01:30 -07:00
Chris Robinson
ccff364b52
Use a map of active layers instead of an array
...
A bit of an upheaval. Each animation is now a "layer", instead of each layer
having an animation. Incidentally, this is much closer to how Ogre handles
animation states.
In the future, each layer will have a priority, which will be used to determine
which one affects a given bone group (which we currently only have one of).
2013-05-10 03:08:07 -07:00
Chris Robinson
d5490b0f8f
Fix an outdated comment
2013-05-09 23:07:50 -07:00
Chris Robinson
8e38dc410f
Allow loading multiple animation sources
...
Animation sources are treated differently from base objects. When given
"path\file.nif", base objects will look for "path\xfile.nif" and use that
if it exists (falling back to the original name if not found). Animation
sources will instead use "path\xfile.kf", ignoring it if the file doesn't
exist.
2013-05-07 16:59:32 -07:00
Chris Robinson
e85bc8b2cd
Only load one Nif for Animation objects
...
This breaks quite a bit, but it's needed for the transition to using the
.kf files.
2013-05-06 23:11:26 -07:00
Chris Robinson
6a3ba41170
Don't store camera nodes, we don't need them.
2013-05-06 21:46:11 -07:00
Chris Robinson
4b15da076b
Move getStateInfo into the character controller
2013-04-30 19:26:41 -07:00
gus
766d1efa84
Render weapon and shield. Only shield can be seen right now as weapons need to be drawed out.
2013-04-28 11:41:01 +01:00
Chris Robinson
9a2a32f2a5
Add a method to clear all Animation sources except the first
...
The first needs to remain, since that's where any mSkelBase entity comes from,
and where any retrieved nodes are from.
2013-04-25 05:02:11 -07:00
Chris Robinson
9be20b90f1
Fix potential infinite loop when layer 0 is empty
2013-04-25 03:35:40 -07:00
Chris Robinson
86fda1bff6
Only set mSkelBase from the first objectlist
2013-04-25 00:52:26 -07:00
Chris Robinson
7eac37be23
Make sure the old layer is cleared before starting the next
2013-04-25 00:18:02 -07:00
Chris Robinson
09fc50948b
Add methods to disable and get info for a layer
2013-04-25 00:08:16 -07:00
Chris Robinson
24f1eba902
Keep track of whether an animation supplies movement
...
Also handle it when it doesn't.
2013-04-24 22:45:43 -07:00
Chris Robinson
0817d59f23
Allow specifying where to start in an animation
2013-04-24 19:09:36 -07:00
Chris Robinson
333354fe62
Remove the character controller from the Animation class
2013-04-24 07:10:41 -07:00
Chris Robinson
b80891099e
Don't use the character controller to handle text keys
...
The Animation class has the Ptr and can call to whatever subsystem is needed.
2013-04-24 06:48:34 -07:00
Chris Robinson
e8cabc9434
Pass the loop count from loopgroup to the play method
...
Instead of queueing each iteration separately.
2013-04-24 06:32:11 -07:00
Chris Robinson
c58dfbe921
Specify the loop count to Animation::play
2013-04-24 04:56:39 -07:00
Chris Robinson
7241267d5c
Make an AnimationValue for each animation layer
2013-04-24 04:41:52 -07:00
Chris Robinson
102b3bdef9
Update position by reference
2013-04-24 01:57:51 -07:00
Chris Robinson
9e05ee53da
Avoid looking for the controller if there is no NonAccum node
...
Also, make sure there is a controller before updating the position.
2013-04-24 01:18:08 -07:00
Chris Robinson
544011e096
Fix 'start' text key fallback lookup
2013-04-24 00:40:58 -07:00
Chris Robinson
7e2995bc2f
Fix setting up active controllers
2013-04-23 19:43:26 -07:00
Chris Robinson
8c9e2e0ee9
Improve handling of reaching the stop animation text key
2013-04-23 05:34:08 -07:00
Chris Robinson
c4806f01f8
Use a separate list of controllers to update
...
This should make it easier to figure out what controllers need to be updated
for various animation sources and layers.
2013-04-23 04:08:09 -07:00
Chris Robinson
e4c5aac966
Keep track of the animation layers a given object list is animating on
...
This only tracks layers they explicitly animate on. They may animate on other
layers as well, if nothing else is animating on them.
2013-04-23 02:48:11 -07:00
Chris Robinson
e378176937
Don't update controllers that have already been updated
2013-04-23 00:15:31 -07:00
Chris Robinson
8782ae6976
Separate some Animation fields into a separate AnimLayer class
2013-04-22 23:52:28 -07:00
Chris Robinson
c3ce49798a
Fix animation velocity calculation
2013-04-22 21:34:39 -07:00