Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Homunculus Re-sync with kro Tables and Updates[missing updates] #8114

Open
wants to merge 31 commits into
base: master
Choose a base branch
from

Conversation

AoShinRO
Copy link
Contributor

@AoShinRO AoShinRO commented Jan 20, 2024

  • Addressed Issue(s):
  • Server Mode: Renewal
  • Description of Pull Request:

[07/07/11]
updating renewal homunculus stats formulas [Newer Formulas are based on it with little changes]

ATK  = Floor((STR + DEX + LUK) ÷ 3) + Floor(Level ÷ 10)
MATK = (Level + INT + Floor((INT + DEX + LUK) ÷ 3) + Floor(Level ÷ 10)) × 2
HIT  = Level + DEX + 150
CRI  = Floor(LUK ÷ 3) + 1
DEF  = (VIT + Floor(Level ÷ 10)) × 2 + Floor((AGI + Floor(Level ÷ 10)) ÷ 2) + Floor(Level ÷ 2)
MDEF = (VIT + Floor(Level ÷ 10))  + Floor((INT + Floor(Level ÷ 10)) ÷ 4) + Floor(Level ÷ 4)
FLEE = Level + AGI + Floor(Level ÷ 10)

image

according to
http://ww4.enjoy.ne.jp/~to4/R/hom.html
https://irowiki.org/wiki/Homunculus_System

Added Updt [March 3, 2019]

 Increases physical and magical damage of homunculus.

according to ->
https://www.divine-pride.net/forum/index.php?/topic/3723-kro-jobs-improvement-project/&do=findComment&comment=5516

missing line update from [March 3, 2019]

skill delay of nomal homunculus skill (Lif, Amistr, Vanilmirth and Filir) are replaced with cooldown.

according to:
https://www.divine-pride.net/forum/index.php?/topic/3723-kro-jobs-improvement-project/&do=findComment&comment=5516
http://ro.gnjoy.com/news/devnote/View.asp?category=3&seq=3769886&curpage=2
https://ro.gnjoy.com/news/update/View.asp?seq=218&curpage=1

Newer Growthing Tables -> [May 27, 2020]

- Increases bonus HP and SP gained from raising base level of basic homunculus.
- Increases bonus HP and SP gained from evolving homunculus.
- Increases bonus HP and SP gained from raising base level of homunculus S.
- Increases bonus HP and SP gained from changing homunculus to homunculus S.
(The HP and SP increasing effects only apply to new homunculi that are created after this update).

according to:
https://www.divine-pride.net/forum/index.php?/topic/3723-kro-jobs-improvement-project/&do=findComment&comment=7644
https://ro.gnjoy.com/news/notice/View.asp?BBSMode=10001&seq=7288&curpage=33

image

ToDo->

  • Confirm Homunc S new Growthing HP & SP Tbl
  • Adjust new SP Growthing tables

Added most aproximated value for Homun_F_Tablet
according to -> https://www.youtube.com/watch?v=DUJzfcSPnRI

[BugFix~]Homun Cooldown now are showed on player hotkeybar to prevent skillspamming by UserAI and Player
[BugFix~]Homun SP e Max SP always showed with 100 value when you reach 32k+ SP, packet and cliend actually supports higher values then INT16_MAX, capping to INT32_MAX/100 now

@AoShinRO AoShinRO changed the title base-hom-missing-updt + smallfix Base Homunculus Skill Cooldown + New Homunculus Growthing Table [missing updts] Jan 24, 2024
@AoShinRO AoShinRO marked this pull request as draft January 24, 2024 14:56
@AoShinRO AoShinRO marked this pull request as ready for review January 24, 2024 18:51
@AoShinRO AoShinRO changed the title Base Homunculus Skill Cooldown + New Homunculus Growthing Table [missing updts] Homunculus Re-sync with kro Tables and Updates[missing updates] Jan 25, 2024
src/map/skill.cpp Outdated Show resolved Hide resolved
Copy link
Contributor

@aleos89 aleos89 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

General cleanup to reduce repeated code.

#ifdef RENEWAL
if (hd != nullptr)
{
skill_blockhomun_start(hd, skill_id, skill_get_cooldown(skill_id, skill_lv));
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looking back at this again, I noticed a few homunculus skills still use skill_get_time2() instead of skill_get_cooldown() for renewal. Is this intended?

Rather than us repeating this code all over the place, it might be best to update the skill_blockhomun_start() to something like:

int skill_blockhomun_start(struct homun_data *hd, uint16 skill_id, uint16 skill_lv)	//[orn]
{
	nullpo_retr(-1, hd);

	if (!skill_db.exists(skill_id))
		return -1;

#ifdef RENEWAL
	if (hd->master == nullptr)
		return -1;

	int tick = skill_get_cooldown(skill_id, skill_lv);
#else
	int tick = skill_get_time2(skill_id, skill_lv);
#endif

	auto skill = util::vector_get(hd->blockskill, skill_id);

	if (tick < 1 && skill != hd->blockskill.end()) {
		hd->blockskill.erase(skill);
		return -1;
	}

	hd->blockskill.push_back(skill_id);

#ifdef RENEWAL
	skill_blockpc_start(hd->master, skill_id, tick);
#endif

	return add_timer(gettick() + tick, skill_blockhomun_end, hd->bl.id, skill_id);
}

I can't review it since it's not in this PR, but don't forget the function header define needs to be updated to match the new argument.

Copy link
Contributor Author

@AoShinRO AoShinRO Feb 2, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

in the prerenewal homunculus S continue to use cooldown instead of duration, kro update just changed aftercastdelay to cooldown in homunculus base, If this is done, the database would need to be reworked, changing several duration2 nodes for cooldown in renewal and vice versa in prere, I don't think that be right, but i can clean some block_pc from code by putting it on blockhomun

src/map/skill.cpp Outdated Show resolved Hide resolved
src/map/skill.cpp Show resolved Hide resolved
src/map/skill.cpp Outdated Show resolved Hide resolved
src/map/skill.cpp Outdated Show resolved Hide resolved
src/map/skill.cpp Show resolved Hide resolved
src/map/skill.cpp Outdated Show resolved Hide resolved
src/map/skill.cpp Show resolved Hide resolved
src/map/skill.cpp Outdated Show resolved Hide resolved
src/map/skill.cpp Outdated Show resolved Hide resolved
@AoShinRO AoShinRO marked this pull request as draft February 2, 2024 14:09
@AoShinRO AoShinRO marked this pull request as ready for review February 3, 2024 13:12
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants