the game where you go into mines and start crafting! but for consoles (forked directly from smartcmd's github)
at main 67 lines 2.6 kB view raw
1#pragma once 2 3#include "../media/xuiscene_settings_options.h" 4#include "XUI_Ctrl_SliderWrapper.h" 5#include "XUI_CustomMessages.h" 6 7#define SLIDER_SETTINGS_AUTOSAVE 0 8#define SLIDER_SETTINGS_DIFFICULTY 1 9 10#define OPTIONS_SLIDER_SETTINGS_MAX SLIDER_SETTINGS_DIFFICULTY + 1 11class CScene_SettingsOptions : public CXuiSceneImpl 12{ 13protected: 14 CXuiCtrlSliderWrapper m_SliderA[OPTIONS_SLIDER_SETTINGS_MAX]; 15 CXuiControl m_DifficultyText; 16 CXuiCheckbox m_ViewBob; 17 CXuiCheckbox m_InGameGamertags; 18 CXuiCheckbox m_Hints; 19 CXuiCheckbox m_Tooltips; 20 CXuiCheckbox m_MashUpWorlds; 21 22 // Message map. Here we tie messages to message handlers. 23 XUI_BEGIN_MSG_MAP() 24 XUI_ON_XM_INIT( OnInit ) 25 XUI_ON_XM_KEYDOWN( OnKeyDown ) 26 XUI_ON_XM_NOTIFY_PRESS_EX(OnNotifyPressEx) 27 XUI_ON_XM_NOTIFY_VALUE_CHANGED( OnNotifyValueChanged ) 28 XUI_ON_XM_CONTROL_NAVIGATE( OnControlNavigate ) 29 XUI_ON_XM_TRANSITION_START(OnTransitionStart) 30 XUI_ON_XM_SPLITSCREENPLAYER_MESSAGE(OnCustomMessage_Splitscreenplayer) 31 XUI_END_MSG_MAP() 32 33 BEGIN_CONTROL_MAP() 34 MAP_CONTROL(IDC_XuiViewBob, m_ViewBob) 35 MAP_CONTROL(IDC_XuiInGameGamertags, m_InGameGamertags) 36 MAP_CONTROL(IDC_XuiShowHints, m_Hints) 37 MAP_CONTROL(IDC_XuiShowTooltips, m_Tooltips) 38 MAP_CONTROL(IDC_XuiSliderAutosave, m_SliderA[SLIDER_SETTINGS_AUTOSAVE]) 39 MAP_CONTROL(IDC_XuiSliderDifficulty, m_SliderA[SLIDER_SETTINGS_DIFFICULTY]) 40 MAP_CONTROL(IDC_XuiDifficultyText, m_DifficultyText) 41 MAP_CONTROL(IDC_XuiMashUpWorlds, m_MashUpWorlds) 42 END_CONTROL_MAP() 43 44 HRESULT OnInit( XUIMessageInit* pInitData, BOOL& bHandled ); 45 HRESULT OnKeyDown(XUIMessageInput *pInputData, BOOL& bHandled); 46 HRESULT OnNotifyPressEx(HXUIOBJ hObjPressed, XUINotifyPress* pNotifyPressData,BOOL& rfHandled); 47 HRESULT OnNotifyValueChanged( HXUIOBJ hObjSource, XUINotifyValueChanged* pNotifyValueChanged, BOOL& bHandled ); 48 HRESULT OnControlNavigate(XUIMessageControlNavigate *pControlNavigateData, BOOL& bHandled); 49 HRESULT OnTransitionStart( XUIMessageTransition *pTransition, BOOL& bHandled ); 50 HRESULT OnCustomMessage_Splitscreenplayer(bool bJoining, BOOL& bHandled); 51 52 int m_iPad; 53 static int m_iDifficultySettingA[4]; 54 static int m_iDifficultyTitleSettingA[4]; 55 static int m_iAutosaveSettingA[4]; 56 57 D3DXVECTOR3 m_OriginalPosition; 58 59public: 60 61 // Define the class. The class name must match the ClassOverride property 62 // set for the scene in the UI Authoring tool. 63 XUI_IMPLEMENT_CLASS( CScene_SettingsOptions, L"CScene_SettingsOptions", XUI_CLASS_SCENE ) 64 65private: 66 bool m_bMashUpWorldsUnhideOption; 67};