Jump to content

Question

Posted

Hi friends , 

 

Im having some problems to set a default crest when faction is selected, 

i cant get the method  to set a default crest from crestcache (previously loaded in data/crest)  for all faction members.

 

can i get some help with this ? 

 

sorry for my bad english.

 

Greetings 

2 answers to this question

Recommended Posts

  • 0
Posted

Hola cabezon .

Te paso esta solucion :

Remplazar XXXXXXXX por el ID de la crest .

 

CharInfo.java

 

if(_inSpecialEvent)
		{
			writeD(0);
			writeD(0);
			writeD(0);
			writeD(0);
		}
		else
		{
			writeD(_activeChar.getClanId());
			writeD(_activeChar.getClanCrestId());
			writeD(_activeChar.getAllyId());
			writeD(_activeChar.getAllyCrestId());
		}
	
		if(_activeChar.factionId == 1)
		{
			writeD(_activeChar.getClanId());
			writeD(XXXXXXXX);
			writeD(_activeChar.getAllyId());
			writeD(_activeChar.getAllyCrestId());
		}
		else if(_activeChar.factionId == 2)
		{
			writeD(_activeChar.getClanId());
			writeD(XXXXXXXX);
			writeD(_activeChar.getAllyId());
			writeD(_activeChar.getAllyCrestId());
		}
		else
		{
			writeD(_activeChar.getClanId());
			writeD(_activeChar.getClanCrestId());
			writeD(_activeChar.getAllyId());
			writeD(_activeChar.getAllyCrestId());
		}

UserInfo.java

 

		if(_activeChar.factionId == 1)
		{
			writeD(_activeChar.getClanId());
			writeD(268436170);
			writeD(_activeChar.getAllyId());
			writeD(_activeChar.getAllyCrestId());
		}
		else if(_activeChar.factionId == 2)
		{
			writeD(_activeChar.getClanId());
			writeD(XXXXXXXX);
			writeD(_activeChar.getAllyId());
			writeD(_activeChar.getAllyCrestId());
		}
		else
		{
		writeD(_activeChar.getClanId());
		writeD(_activeChar.getClanCrestId());
		writeD(_activeChar.getAllyId());
		writeD(_activeChar.getAllyCrestId()); // ally crest id
		}
		
		// 0x40 leader rights
		// siege flags: attacker - 0x180 sword over name, defender - 0x80 shield, 0xC0 crown (|leader), 0x1C0 flag (|leader)
		writeD(_relation);

Esto lo saque de :

http://l2devsadmins.net/l2devsAdmins2-0-11/index.php?topic=13689.msg69486#new

  • 0
Posted
On 1/29/2020 at 4:03 PM, Rumble said:

Hola cabezon .

Te paso esta solucion :

Remplazar XXXXXXXX por el ID de la crest .

 

CharInfo.java

 


if(_inSpecialEvent)
		{
			writeD(0);
			writeD(0);
			writeD(0);
			writeD(0);
		}
		else
		{
			writeD(_activeChar.getClanId());
			writeD(_activeChar.getClanCrestId());
			writeD(_activeChar.getAllyId());
			writeD(_activeChar.getAllyCrestId());
		}
	
		if(_activeChar.factionId == 1)
		{
			writeD(_activeChar.getClanId());
			writeD(XXXXXXXX);
			writeD(_activeChar.getAllyId());
			writeD(_activeChar.getAllyCrestId());
		}
		else if(_activeChar.factionId == 2)
		{
			writeD(_activeChar.getClanId());
			writeD(XXXXXXXX);
			writeD(_activeChar.getAllyId());
			writeD(_activeChar.getAllyCrestId());
		}
		else
		{
			writeD(_activeChar.getClanId());
			writeD(_activeChar.getClanCrestId());
			writeD(_activeChar.getAllyId());
			writeD(_activeChar.getAllyCrestId());
		}

UserInfo.java

 


		if(_activeChar.factionId == 1)
		{
			writeD(_activeChar.getClanId());
			writeD(268436170);
			writeD(_activeChar.getAllyId());
			writeD(_activeChar.getAllyCrestId());
		}
		else if(_activeChar.factionId == 2)
		{
			writeD(_activeChar.getClanId());
			writeD(XXXXXXXX);
			writeD(_activeChar.getAllyId());
			writeD(_activeChar.getAllyCrestId());
		}
		else
		{
		writeD(_activeChar.getClanId());
		writeD(_activeChar.getClanCrestId());
		writeD(_activeChar.getAllyId());
		writeD(_activeChar.getAllyCrestId()); // ally crest id
		}
		
		// 0x40 leader rights
		// siege flags: attacker - 0x180 sword over name, defender - 0x80 shield, 0xC0 crown (|leader), 0x1C0 flag (|leader)
		writeD(_relation);

Esto lo saque de :

http://l2devsadmins.net/l2devsAdmins2-0-11/index.php?topic=13689.msg69486#new

 

Gracias Jericko ! 

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

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