Sign in to follow this  
Shinjikro

How to make a config to either make a character a monster or a normal player

Recommended Posts

Shinjikro    5

So I made a mod (first wortox mod on the workshop since his release) and a commenter asked me if I could make a config so that wortox is either a monster and friendly things will attack him or that hes a normal character and friendly things don't attack him

p.s (prolly shouldn't have said I could do it until I knew how ;-;)

Share this post


Link to post
Share on other sites
Akarinnnnnn    4

to add a config, you can edit "configuration_options" Table in modinfo.lua

configuration_options = 
{
	{
		name="biantaiban"
		,label="加强"
		,options = {
				{data=true,description="开",hover="哈哈哈哈哈哈哈"},
				{data=false,description="关",hover="直面惨淡的人生"}
		}
		,default=false
	},
		
}

Then get it's data by this Function

GetModConfigData("biantaiban")

 

The next step, you may need other modder's help, i don't know much about it.

Share this post


Link to post
Share on other sites
Shinjikro    5
8 hours ago, Akarinnnnnn said:

to add a config, you can edit "configuration_options" Table in modinfo.lua


configuration_options = 
{
	{
		name="biantaiban"
		,label="加强"
		,options = {
				{data=true,description="开",hover="哈哈哈哈哈哈哈"},
				{data=false,description="关",hover="直面惨淡的人生"}
		}
		,default=false
	},
		
}

Then get it's data by this Function


GetModConfigData("biantaiban")

 

The next step, you may need other modder's help, i don't know much about it.

Yeah I already knew that >.<' 

Share this post


Link to post
Share on other sites

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
Sign in to follow this