Jump to content
Sign in to follow this  
error

Looking to Make a New Item

Recommended Posts

I just want to start by saying thank you to the members and staff of this site. There are a lot of useful guides here and tons of information for people wishing to create a server.

 

My plan is to make an item like the Star of Unity/Medal of Valar that can be collected at an NPC by players over a certain level. That is the easy part, however instead of it storing experience, kills, deaths, etc, I would like to to store a feature called "Essence". Then once a player kills a monster over, say level 50, it will add 1 Essence to the item. 

 

I have studied both the medal of valar and the star of unity codes and have yet to discover how the words appear on the item, such as "Honor", "Kills", "Deaths" etc. Is this something that is coded into the game.exe and is it possible to add an item with this new word on it? Or is it possible to add the word to the medal of valar without having to create a new item, and that new word be able to be read at an npc the same as honor or team contribution points can be?

Share this post


Link to post
Share on other sites

Hello @error!

These items u said store that values in item attribute, such as: min/max durability, str, etc. In order to display name it will require game.exe modification...

If you're not using Team Contribution Points in Medal of Valor you can change its name to essence and use it. Just change line 655 in StringSet.bin which is:

 

[655]	"Team Contribution: %d"

to something like that:

[655]	"Essence: %d"

After doing that, team contribution will be displayed as essence in medal of valor.

 

Another option is: 

- Using table serialization to store values for essence and display it in NPC or thought a local chat command.

  • Like 1

lelouch_signature_by_vahntheknight-d4uafwj.png

Share this post


Link to post
Share on other sites
	else if( _pItem->sType == 46 )	// 勇者之证
	{
        PushHint( _pItem->szName, COLOR_WHITE, 5, 1 );

		int show_attr[] = { ITEMATTR_VAL_STR, ITEMATTR_VAL_AGI, ITEMATTR_VAL_DEX, ITEMATTR_VAL_CON, ITEMATTR_VAL_STA };
		string show_text[] = { g_oLangRec.GetString(650), g_oLangRec.GetString(651), g_oLangRec.GetString(652), g_oLangRec.GetString(653), g_oLangRec.GetString(654) };
		int value = 0;
		const int count = sizeof(show_attr)/sizeof(show_attr[0]);
		for( int i=0; i<count; i++ )
		{
			value = item.sInstAttr[show_attr[i]];
			item.sInstAttr[show_attr[i]] = 0;
			sprintf( buf, "%s:%d", show_text[i].c_str(), value );
			PushHint( buf, GENERIC_COLOR );
		}

		sprintf( buf, g_oLangRec.GetString(655), _ItemData.sEndure[1] );
		PushHint( buf, GENERIC_COLOR );

		sprintf( buf, "%s:%d", g_oLangRec.GetString(848), _ItemData.sEnergy[1] );	// 乱斗点数
		PushHint( buf, GENERIC_COLOR );

		_AddDescriptor();
	}

inside 

void CItemCommand::AddHint( int x, int y )

client source code 

Share this post


Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Sign in to follow this  

×
×
  • Create New...