-
Notifications
You must be signed in to change notification settings - Fork 1.8k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
fixed SampledAnimCurve _findFrameIndex error #66
Conversation
|
||
var index = (ratio / eachLength) | 0; | ||
return index; | ||
if ((index - formatIndex) < EPSILON) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
这个计算的目的是?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
判断是否正中那一帧
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
那应该加个 abs 吧?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
不用, formatIndex 是 用 index 取整算来的,index 是肯定比 formatIndex 大的
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
明白了,既然这样,建议变量名改一下, formatIndex -> floorIndex
fixed SampledAnimCurve _findFrameIndex error
fix new EventTarget() Bug
* NewGenAnim * Fix/Optimize simple directional blending * Class transition by type (#29) * Transition & Gradient transition (#30) * The default ExitCondition should be 1.0 * Do correct graph eval * Fix PoseSubgraph connect() signature order (#31) * Graph defaults test (#32) * Conditions (#33) * Trigger (#34) * Transition should only be considered when satemachine exited (#35) * Add layer.name (#36) * Fix some behaviours; add API to query poses and transition (#37) Fix single frame exit condition behaviours; Fix pose -> subgraph behaviours * Support self transition; refactor sub state machine implementation (#38) * Temp * Flat whole layer statemachine * Add test for test reset triggers * Allow self transition * Self transition test * Fix deserialize (#39) * update animgraph template (#40) * The inheritance of any state (#41) * StateMachine events (#42) * Fix state machine events; Allow multiple transitions between two nodes (#43) * Transition priority test (#44) * Optimize variable bind (#45) * Fix variable bind errors (#46) * Expose blend algorithm to editor (#47) * Cont (#48) * update animgraph template (#49) * update animgraph template * update animgraph template * Pose speed (#50) * blend tree add EditorExtendable data (#51) * Correct pose blend duration (#52) * Export some types (#53) * animation pose EditorExtendable (#54) (cherry picked from commit d5dd5f3) * Implement clone() (#55) * Fix trigger condition serialization (#56) * Add variable type: integer (#57) * Optimize 0 weight case (#58) * Relative duration (#59) * update_hdr_skybox (#9230) * Rename.. (#60) * Optimize animation blend item export (#61) * Fix Type (#62) * modify aniamtion graph template data (#63) * modify aniamtion graph template data * add animation graph component template * Fix serialize issue (#64) * Optimize (#65) * Remove MotionState.startRatio, loop (#66) * Update (#67) * Fix circular reference (#68) * CR (#69) * Fix exit time greater than 1 (#70) Co-authored-by: 黄森斌 <arsen2010@126.com> Co-authored-by: linshunjun <49218738+linshunjun@users.noreply.github.com>
* NewGenAnim * Fix/Optimize simple directional blending * Class transition by type (#29) * Transition & Gradient transition (#30) * The default ExitCondition should be 1.0 * Do correct graph eval * Fix PoseSubgraph connect() signature order (#31) * Graph defaults test (#32) * Conditions (#33) * Trigger (#34) * Transition should only be considered when satemachine exited (#35) * Add layer.name (#36) * Fix some behaviours; add API to query poses and transition (#37) Fix single frame exit condition behaviours; Fix pose -> subgraph behaviours * Support self transition; refactor sub state machine implementation (#38) * Temp * Flat whole layer statemachine * Add test for test reset triggers * Allow self transition * Self transition test * Fix deserialize (#39) * update animgraph template (#40) * The inheritance of any state (#41) * StateMachine events (#42) * Fix state machine events; Allow multiple transitions between two nodes (#43) * Transition priority test (#44) * Optimize variable bind (#45) * Fix variable bind errors (#46) * Expose blend algorithm to editor (#47) * Cont (#48) * update animgraph template (#49) * update animgraph template * update animgraph template * Pose speed (#50) * blend tree add EditorExtendable data (#51) * Correct pose blend duration (#52) * Export some types (#53) * animation pose EditorExtendable (#54) (cherry picked from commit d5dd5f3) * Implement clone() (#55) * Fix trigger condition serialization (#56) * Add variable type: integer (#57) * Optimize 0 weight case (#58) * Relative duration (#59) * update_hdr_skybox (#9230) * Rename.. (#60) * Optimize animation blend item export (#61) * Fix Type (#62) * modify aniamtion graph template data (#63) * modify aniamtion graph template data * add animation graph component template * Fix serialize issue (#64) * Optimize (#65) * Remove MotionState.startRatio, loop (#66) * Update (#67) * Fix circular reference (#68) * CR (#69) * Fix exit time greater than 1 (#70) Co-authored-by: 黄森斌 <arsen2010@126.com> Co-authored-by: linshunjun <49218738+linshunjun@users.noreply.github.com>
Update jsb.ts
Merge dev branch
update fireball-x/fireball#957
@jareguo