sets the normalized cursor of the animation on a node with flipbook animation * This is only useful nodes with flipbook animations. The cursor is normalized. * * @name gui.set_flipbook_cursor * @param node [type:node] node to set the cursor for * @param cursor [type:number] cursor value */
| 4569 | * @param cursor [type:number] cursor value |
| 4570 | */ |
| 4571 | static int LuaSetFlipbookCursor(lua_State* L) |
| 4572 | { |
| 4573 | DM_LUA_STACK_CHECK(L, 0); |
| 4574 | |
| 4575 | Scene* scene = GuiScriptInstance_Check(L); |
| 4576 | HNode node; |
| 4577 | LuaCheckNodeInternal(L, 1, &node); |
| 4578 | |
| 4579 | if (dmGui::GetNodeIsBone(scene, node)) |
| 4580 | { |
| 4581 | return DM_LUA_ERROR("cannot set cursor for bone"); |
| 4582 | } |
| 4583 | |
| 4584 | dmGui::SetNodeFlipbookCursor(scene, node, luaL_checknumber(L, 2)); |
| 4585 | |
| 4586 | return 0; |
| 4587 | } |
| 4588 | |
| 4589 | /*# gets the playback rate of the flipbook animation on a node |
| 4590 | * This is only useful nodes with flipbook animations. Gets the playback rate of the flipbook animation on a node. |
nothing calls this directly
no test coverage detected