Jump to content

Recommended Posts

You have to create a table called configuration_options in modinfo.lua

configuration_options = { --  A exemple config:
    { 
        name = "FASTERHANDS", -- ID (string)
        label = "Faster Hands?", -- Option Name (string)
        hover = "Harvest quicker or not", -- Mouse Over text (string)
        options =   {
            {description = "Yes", data = true}, -- The options. Description (string). data (Any).
            {description = "No", data = false},
        },
        default = true, -- What is "from fabric" (Any)
    },
    {
		--other config
	},
}

 And then you call GetModConfigData to get the option selected by the user, using the ID:

local option_selected = GetModConfigData("FASTERHANDS")

 

Edited by Leonidas IV

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
  • Create New...