Jump to content
  • 0

New Config Option



Hey all,


I wanted to make a CONFIG option for the count of member in a party.

// config.cpp

char max_party_member = 8;

TOKEN ("max_party_member")
	str_to_number(max_party_member, value_string);
	max_party_member = MINMAX(2, max_party_member, 20);
	fprintf(stderr, "MAX_PARTY_MEMBER_COUNT: %dn", max_party_member);

// config.h

extern char max_party_member;

// party.h

PARTY_MAX_MEMBER = max_party_member,

thats what i did but in party.h there has to be a constant value so i cant change the value of it. Does anyone know the solution of it?

Link to comment

1 answer to this question

Recommended Posts

  • 0

You can't do this. You must be define a variable for that.


Like this ;



extern int g_iMaxPartyMember;


int g_iMaxPartyMember = 8; // Max Party Member is 8 (Default)

	sys_log(0,"Party Max Member changed with %d",g_iMaxPartyMember);

And search this in char.cpp

	else if (pchLeader->GetParty())
	   	if (pchLeader->GetParty()->GetMemberCount() == PARTY_MAX_MEMBER)

replace with this

	else if (pchLeader->GetParty())
	   	if (pchLeader->GetParty()->GetMemberCount() == g_iMaxPartyMember)

Best Regards


  • Love 2

Do not be sorry, be better.

Link to comment

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...

Important Information

Terms of Use / Privacy Policy / Guidelines / We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.