From 2b21a91f91b253638a9779244880b0c81a438f89 Mon Sep 17 00:00:00 2001 From: Flameshadowxeroshin Date: Sun, 22 Jul 2012 11:44:45 -0500 Subject: [PATCH] Add ResetSelection binding to MusicWheel, add MusicWheel to Luadocs --- Docs/Luadoc/Lua.xml | 4 ++++ Docs/Luadoc/LuaDocumentation.xml | 8 ++++++++ src/MusicWheel.cpp | 2 ++ 3 files changed, 14 insertions(+) diff --git a/Docs/Luadoc/Lua.xml b/Docs/Luadoc/Lua.xml index 6eaa249d63..76476fd88b 100644 --- a/Docs/Luadoc/Lua.xml +++ b/Docs/Luadoc/Lua.xml @@ -889,6 +889,10 @@ + + + + diff --git a/Docs/Luadoc/LuaDocumentation.xml b/Docs/Luadoc/LuaDocumentation.xml index 052cb597a4..6bc7b1e69f 100644 --- a/Docs/Luadoc/LuaDocumentation.xml +++ b/Docs/Luadoc/LuaDocumentation.xml @@ -2609,6 +2609,14 @@ save yourself some time, copy this for undocumented things: Loads the ModIconRow of Player pn from the Metrics in group sMetricsGroup. + + + Returns true if the MusicWheel is currently handling Roulette selection. + + + Tries to set the MusicWheel's selection based on preferred song, preferred course, and current sort order. Returns false on failure. + + Returns a command from the specified element and value. diff --git a/src/MusicWheel.cpp b/src/MusicWheel.cpp index 04714fba25..964f73ae4c 100644 --- a/src/MusicWheel.cpp +++ b/src/MusicWheel.cpp @@ -1619,10 +1619,12 @@ class LunaMusicWheel: public Luna { public: static int IsRouletting( T* p, lua_State *L ){ lua_pushboolean( L, p->IsRouletting() ); return 1; } + static int ResetSelection( T* p, lua_State *L ){ lua_pushboolean( L, p->SelectSongOrCourse() ); return 1; } LunaMusicWheel() { ADD_METHOD( IsRouletting ); + ADD_METHOD( ResetSelection ); } };