- tab_string = tab_string ..
- "button[8,4.75;3.75,0.5;btn_reset_singleplayer;".. fgettext("Reset singleplayer world") .. "]"
- end
- tab_string = tab_string ..
- "box[0,4.25;3.5,1.1;#999999]" ..
- "label[0.25,4.25;" .. fgettext("GUI scale factor") .. "]" ..
- "scrollbar[0.25,4.75;3,0.4;sb_gui_scaling;horizontal;" ..
- gui_scale_to_scrollbar() .. "]" ..
- "tooltip[sb_gui_scaling;" ..
- fgettext("Scaling factor applied to menu elements: ") ..
- dump(core.setting_get("gui_scaling")) .. "]"
-
- if PLATFORM == "Android" then
- tab_string = tab_string ..
- "box[3.75,3.55;3.75,1.8;#999999]" ..
- "checkbox[3.9,3.45;cb_touchscreen_target;".. fgettext("Touch free target") .. ";"
- .. dump(core.setting_getbool("touchtarget")) .. "]"
- end
-
- if core.setting_get("touchscreen_threshold") ~= nil then
- tab_string = tab_string ..
- "label[4.3,4.1;" .. fgettext("Touchthreshold (px)") .. "]" ..
- "dropdown[3.85,4.55;3.85;dd_touchthreshold;0,10,20,30,40,50;" ..
- ((tonumber(core.setting_get("touchscreen_threshold"))/10)+1) .. "]"
- end
-
- if core.setting_getbool("enable_shaders") then
- tab_string = tab_string ..
- "checkbox[8,0.5;cb_bumpmapping;".. fgettext("Bumpmapping") .. ";"
- .. dump(core.setting_getbool("enable_bumpmapping")) .. "]"..
- "checkbox[8,1.0;cb_generate_normalmaps;".. fgettext("Generate Normalmaps") .. ";"
- .. dump(core.setting_getbool("generate_normalmaps")) .. "]"..
- "checkbox[8,1.5;cb_parallax;".. fgettext("Parallax Occlusion") .. ";"
- .. dump(core.setting_getbool("enable_parallax_occlusion")) .. "]"..
- "checkbox[8,2.0;cb_waving_water;".. fgettext("Waving Water") .. ";"
- .. dump(core.setting_getbool("enable_waving_water")) .. "]"..
- "checkbox[8,2.5;cb_waving_leaves;".. fgettext("Waving Leaves") .. ";"
- .. dump(core.setting_getbool("enable_waving_leaves")) .. "]"..
- "checkbox[8,3.0;cb_waving_plants;".. fgettext("Waving Plants") .. ";"
- .. dump(core.setting_getbool("enable_waving_plants")) .. "]"
- else
- tab_string = tab_string ..
- "textlist[8.33,0.7;4,1;;#888888" .. fgettext("Bumpmapping") .. ";0;true]" ..
- "textlist[8.33,1.2;4,1;;#888888" .. fgettext("Generate Normalmaps") .. ";0;true]" ..
- "textlist[8.33,1.7;4,1;;#888888" .. fgettext("Parallax Occlusion") .. ";0;true]" ..
- "textlist[8.33,2.2;4,1;;#888888" .. fgettext("Waving Water") .. ";0;true]" ..
- "textlist[8.33,2.7;4,1;;#888888" .. fgettext("Waving Leaves") .. ";0;true]" ..
- "textlist[8.33,3.2;4,1;;#888888" .. fgettext("Waving Plants") .. ";0;true]"
- end
- return tab_string
-end
-
---------------------------------------------------------------------------------
-local function handle_settings_buttons(this, fields, tabname, tabdata)
- if fields["cb_fancy_trees"] then
- core.setting_set("new_style_leaves", fields["cb_fancy_trees"])
- return true