Auto max skill on level up

07/09/2020 22:42 theunrealz#1
Hi, I have tried to set max skill level upon leveling up, but it didn't work- skills don't get maxed.

This is the part of my code of Mover.cpp:

Code:
#if __VER >= 11 // __SYS_PLAYER_DATA
		g_dpDBClient.SendUpdatePlayerData( (CUser*)this );
#else	// __SYS_PLAYER_DATA
		g_DPCoreClient.SendPartyMemberJob( (CUser*)this );
		g_DPCoreClient.SendFriendChangeJob( (CUser*)this );
		if( m_idGuild != 0 )
			g_DPCoreClient.SendGuildChangeJobLevel( (CUser*)this );
#endif	// __SYS_PLAYER_DATA
		SetHitPoint( GetMaxHitPoint() );
		SetManaPoint( GetMaxManaPoint() );
		SetFatiguePoint( GetMaxFatiguePoint() );
	
		g_UserMng.AddSetLevel( this, (WORD)m_nLevel );
		( (CUser*)this )->AddSetGrowthLearningPoint( m_nRemainGP );
		( (CUser*)this )->AddSetExperience( GetExp1(), (WORD)m_nLevel, m_nSkillPoint, m_nSkillLevel );
		( (CUser*)this )->m_playTaskBar.InitTaskBarShorcutKind( SHORTCUT_SKILL );
		( (CUser*)this )->AddTaskBar();
		((CUser*)this)->AddSetState( m_nStr, m_nSta, m_nDex, m_nInt, m_nRemainGP );
#if __VER >= 13 // __HONORABLE_TITLE			// ´ÞÀÎ
		((CUser*)this)->CheckHonorStat();
		((CUser*)this)->AddHonorListAck();
		g_UserMng.AddHonorTitleChange( this, m_nHonor);
#endif	// __HONORABLE_TITLE			// ´ÞÀÎ
	}
#endif // __WORLDSERVER

#ifdef __WORLDSERVER
	//  CUser* pUser;

	LPSKILL pSkill = NULL;
	ItemProp* pSkillProp = NULL;

	for (int i = 0; i < MAX_SKILL_JOB; i++)
	{
		pSkill = &(((CUser*)this)->m_aJobSkill[i]);

		if (pSkill == NULL || pSkill->dwSkill == 0xffffffff)
			continue;

		pSkillProp = prj.GetSkillProp(pSkill->dwSkill);

		if (pSkillProp == NULL)
			continue;

		pSkill->dwLevel = pSkillProp->dwExpertMax;
		((CUser*)this)->AddSetSkill(pSkill->dwSkill, pSkill->dwLevel);
	}
#endif // __WORLDSERVER 
}
Not sure if I missed something.

The files are V19 official.

Any idea?
Thanks!
07/10/2020 08:00 Steffen Tequila#2
just make copy paste from another source.
95% of all sources have that: "#define __AUTO_SKILL_MAX"
07/10/2020 08:39 theunrealz#3
Quote:
Originally Posted by Steffen Tequila View Post
just make copy paste from another source.
95% of all sources have that: "#define __AUTO_SKILL_MAX"
Thanks!!

Quote:
Originally Posted by Steffen Tequila View Post
just make copy paste from another source.
95% of all sources have that: "#define __AUTO_SKILL_MAX"
How I can know the client changes I need to do if im copying from the source?

1. I added all blocks with #define __AUTO_SKILL_MAX (also quick job change),
2. rebuild the project
3. Copied the output and used the new server files (account, world server etc)
4. executed merger2.exe and copied the datasub's to the client

I still don't see anything works - the max level skills and the quick jobchange.
Any idea if i'm missing something?
07/10/2020 12:36 Blazing.Flyff#4
Quote:
Originally Posted by theunrealz View Post
Thanks!!



How I can know the client changes I need to do if im copying from the source?

1. I added all blocks with #define __AUTO_SKILL_MAX (also quick job change),
2. rebuild the project
3. Copied the output and used the new server files (account, world server etc)
4. executed merger2.exe and copied the datasub's to the client

I still don't see anything works - the max level skills and the quick jobchange.
Any idea if i'm missing something?
You got anydesk or Teamvwier? i Can help you.
07/10/2020 13:06 theunrealz#5
Quote:
Originally Posted by Blazing.Flyff View Post
You got anydesk or Teamvwier? i Can help you.
Sure. Let's talk private.