Jump to content
  • 0

change party name to show current baselvl and #rank_level


sumano

Question


  • Group:  Members
  • Topic Count:  23
  • Topics Per Day:  0.01
  • Content Count:  54
  • Reputation:   0
  • Joined:  04/24/12
  • Last Seen:  

hi rathena

how to remove party and add baselevel and #rank_level show in party

 

i have script ranking like level system 

 

ex.

GM (Level : 99/70|Rank : 3)

 

thanks

Link to comment
Share on other sites

1 answer to this question

Recommended Posts


  • Group:  Members
  • Topic Count:  23
  • Topics Per Day:  0.01
  • Content Count:  54
  • Reputation:   0
  • Joined:  04/24/12
  • Last Seen:  

i make it work show hp sp and party status

 

but i change it to #rank_level why it show Lv.0 but i level 2

 

and teleport name party remove

void clif_charnameupdate (struct map_session_data *ssd)
{
	unsigned char buf[103];
	char tmp[30];	// Mod: HP/SP
	int cmd = 0x195, ps = -1;
	struct party_data *p = NULL;
	struct guild *g = NULL;

	nullpo_retv(ssd);

	if( ssd->fakename[0] )
		return; //No need to update as the party/guild was not displayed anyway.

	WBUFW(buf,0) = cmd;
	WBUFL(buf,2) = ssd->bl.id;

	memcpy(WBUFP(buf,6), ssd->status.name, NAME_LENGTH);

	if (!battle_config.display_party_name) {
		if (ssd->status.party_id > 0 && ssd->status.guild_id > 0 && (g = ssd->guild) != NULL)
			p = party_search(ssd->status.party_id);
	}else{
		if (ssd->status.party_id > 0)
			p = party_search(ssd->status.party_id);
	}

	if( ssd->status.guild_id > 0 && (g = ssd->guild) != NULL )
	{
		int i;
		ARR_FIND(0, g->max_member, i, g->member[i].account_id == ssd->status.account_id && g->member[i].char_id == ssd->status.char_id);
		if( i < g->max_member ) ps = g->member[i].position;
	}

	//sprintf(tmp, "HP:%d%%,SP:%d%%,Party:", ssd->battle_status.hp*100/ssd->battle_status.max_hp, ssd->battle_status.sp*100/ssd->battle_status.max_sp);
	sprintf(tmp, "Synergy Lv. :%d%%,SP:%d%%,Party:", pc_readglobalreg_str(ssd,"#rank_level"), ssd->battle_status.sp*100/ssd->battle_status.max_sp);
	
	if( p )
		//memcpy(WBUFP(buf,30), p->party.name, NAME_LENGTH);
		strcat(tmp,"Yes");
	else
		//WBUFB(buf,30) = 0;
		strcat(tmp,"No");
		memcpy(WBUFP(buf,30), tmp, NAME_LENGTH);

	if( g && ps >= 0 && ps < MAX_GUILDPOSITION )
	{
		memcpy(WBUFP(buf,54), g->name,NAME_LENGTH);
		memcpy(WBUFP(buf,78), g->position[ps].name, NAME_LENGTH);
	}
	else
	{
		WBUFB(buf,54) = 0;
		WBUFB(buf,78) = 0;
	}

	// Update nearby clients
	clif_send(buf, packet_len(cmd), &ssd->bl, AREA);
}
Edited by sumano
Link to comment
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
Answer this question...

×   Pasted as rich text.   Paste as plain text instead

  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.

×
×
  • Create New...