gets the playback rate of the flipbook animation on a node * This is only useful nodes with flipbook animations. Gets the playback rate of the flipbook animation on a node. * * @name gui.get_flipbook_playback_rate * @param node [type:node] node to set the cursor for * @return rate [type:number] playback rate */
| 4594 | * @return rate [type:number] playback rate |
| 4595 | */ |
| 4596 | static int LuaGetFlipbookPlaybackRate(lua_State* L) |
| 4597 | { |
| 4598 | DM_LUA_STACK_CHECK(L, 1); |
| 4599 | |
| 4600 | Scene* scene = GuiScriptInstance_Check(L); |
| 4601 | HNode node; |
| 4602 | LuaCheckNodeInternal(L, 1, &node); |
| 4603 | |
| 4604 | if (dmGui::GetNodeIsBone(scene, node)) |
| 4605 | { |
| 4606 | return DM_LUA_ERROR("cannot get playback rate for bone"); |
| 4607 | } |
| 4608 | |
| 4609 | lua_pushnumber(L, dmGui::GetNodeFlipbookPlaybackRate(scene, node)); |
| 4610 | |
| 4611 | return 1; |
| 4612 | } |
| 4613 | |
| 4614 | /*# sets the playback rate of the flipbook animation on a node |
| 4615 | * This is only useful nodes with flipbook animations. Sets the playback rate of the flipbook animation on a node. Must be positive. |
nothing calls this directly
no test coverage detected