Skip to content

Commit

Permalink
Make "dt" fully affect model motion, not only idle movement animation.
Browse files Browse the repository at this point in the history
  • Loading branch information
MikuAuahDark committed Jan 9, 2019
1 parent ee16486 commit ffb61b7
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
3 changes: 2 additions & 1 deletion src/Live2LOVE.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -260,7 +260,8 @@ void live2love::Live2LOVE::setupMeshData()
void live2love::Live2LOVE::update(double dT)
{
elapsedTime = fmod((elapsedTime + dT), 31536000.0);
double t = elapsedTime * 2 * M_PI;
live2d::UtSystem::setUserTimeMSec(elapsedTime * 1000.0);
double t = fmod(elapsedTime, 1.0) * 2 * M_PI;
// Motion update
if (motion)
{
Expand Down
2 changes: 1 addition & 1 deletion src/Main.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -728,7 +728,7 @@ extern "C" int LUALIB_API luaopen_Live2LOVE(lua_State *L)
lua_pushcfunction(L, Live2LOVE_Live2LOVE_full);
lua_rawset(L, -3);
lua_pushstring(L, "_VERSION");
lua_pushstring(L, "0.4.1");
lua_pushstring(L, "0.4.2");
lua_rawset(L, -3);
lua_pushstring(L, "Live2DVersion");
lua_pushstring(L, live2d::Live2D::getVersionStr());
Expand Down

0 comments on commit ffb61b7

Please sign in to comment.