mirror of
https://github.com/overte-org/overte.git
synced 2025-04-13 03:42:10 +02:00
added final animations and json to the resource
This commit is contained in:
parent
27ed468946
commit
395a4cc9c4
4 changed files with 11 additions and 11 deletions
Binary file not shown.
Binary file not shown.
|
@ -990,7 +990,7 @@
|
|||
"data": {
|
||||
"currentState": "masterIdle",
|
||||
"triggerTimeMin": 10.0,
|
||||
"triggerTimeMax": 40.0,
|
||||
"triggerTimeMax": 60.0,
|
||||
"transitionVar": "timeToFidget",
|
||||
"states": [
|
||||
{
|
||||
|
@ -1032,7 +1032,7 @@
|
|||
"currentState": "masterIdle1",
|
||||
"triggerRandomSwitch": "masterIdleSwitch",
|
||||
"randomSwitchTimeMin": 10.0,
|
||||
"randomSwitchTimeMax": 40.0,
|
||||
"randomSwitchTimeMax": 60.0,
|
||||
"states": [
|
||||
{
|
||||
"id": "masterIdle1",
|
||||
|
@ -1079,7 +1079,7 @@
|
|||
"data": {
|
||||
"url": "qrc:///avatar/animations/idleWS_all.fbx",
|
||||
"startFrame": 1.0,
|
||||
"endFrame": 1313.0,
|
||||
"endFrame": 1620.0,
|
||||
"timeScale": 1.0,
|
||||
"loopFlag": true
|
||||
},
|
||||
|
@ -1237,9 +1237,9 @@
|
|||
"id": "movement4",
|
||||
"type": "clip",
|
||||
"data": {
|
||||
"url": "qrc:///avatar/animations/idleWS.fbx",
|
||||
"url": "qrc:///avatar/animations/idleWS_all.fbx",
|
||||
"startFrame": 1,
|
||||
"endFrame": 1314,
|
||||
"endFrame": 1620,
|
||||
"timeScale": 1.0,
|
||||
"loopFlag": false
|
||||
},
|
||||
|
@ -1273,9 +1273,9 @@
|
|||
"id": "movement7",
|
||||
"type": "clip",
|
||||
"data": {
|
||||
"url": "qrc:///avatar/animations/idleWS.fbx",
|
||||
"url": "qrc:///avatar/animations/idleWS_all.fbx",
|
||||
"startFrame": 1,
|
||||
"endFrame": 1314,
|
||||
"endFrame": 1620,
|
||||
"timeScale": 1.0,
|
||||
"loopFlag": false
|
||||
},
|
||||
|
@ -1301,7 +1301,7 @@
|
|||
"data": {
|
||||
"currentState": "transitionToAltIdle1",
|
||||
"triggerTimeMin": 10.0,
|
||||
"triggerTimeMax": 40.0,
|
||||
"triggerTimeMax": 60.0,
|
||||
"transitionVar": "finishAltIdle2",
|
||||
"states": [
|
||||
{
|
||||
|
|
|
@ -26,6 +26,7 @@ const AnimPoseVec& AnimRandomSwitch::evaluate(const AnimVariantMap& animVars, co
|
|||
|
||||
AnimRandomSwitch::RandomSwitchState::Pointer desiredState = _currentState;
|
||||
if (abs(_randomSwitchEvaluationCount - context.getEvaluationCount()) > 1 || animVars.lookup(_triggerRandomSwitchVar, false)) {
|
||||
|
||||
// get a random number and decide which motion to choose.
|
||||
bool currentStateHasPriority = false;
|
||||
float dice = randFloatInRange(0.0f, 1.0f);
|
||||
|
@ -35,10 +36,9 @@ const AnimPoseVec& AnimRandomSwitch::evaluate(const AnimVariantMap& animVars, co
|
|||
float upperBound = lowerBound + (randState->getPriority() / _totalPriorities);
|
||||
if ((dice > lowerBound) && (dice < upperBound)) {
|
||||
desiredState = randState;
|
||||
break;
|
||||
} else {
|
||||
lowerBound = upperBound;
|
||||
}
|
||||
lowerBound = upperBound;
|
||||
|
||||
// this indicates if the curent state is one that can be selected randomly, or is one that was transitioned to by the random duration timer.
|
||||
currentStateHasPriority = currentStateHasPriority || (_currentState == randState);
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue