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

Cannot fish in orgrimmar [$10 awarded] #4510

Closed
skxawng-cu opened this issue Feb 8, 2021 · 9 comments · Fixed by #5114
Closed

Cannot fish in orgrimmar [$10 awarded] #4510

skxawng-cu opened this issue Feb 8, 2021 · 9 comments · Fixed by #5114

Comments

@skxawng-cu
Copy link
Contributor

skxawng-cu commented Feb 8, 2021

Related chromiecraft/chromiecraft#124

Cannot fish in orgrimmar

CURRENT BEHAVIOUR:

Frishing in orgrimmar is bugged.
Console log.
Fishable areaId 4374 are not properly defined in skill_fishing_base_level.

EXPECTED BLIZZLIKE BEHAVIOUR:
STEPS TO REPRODUCE THE PROBLEM:
  1. Fish in Orgrimmar and look at DBErrors.log file.
EXTRA NOTES:
AC HASH/COMMIT:

71b40ed

OPERATING SYSTEM:

Ubuntu 20.04

MODULES:

Anticheat
DuelReset
Transmog

OTHER CUSTOMIZATIONS:

The $10 bounty on this issue has been claimed at Bountysource.

@ghost
Copy link

ghost commented Feb 10, 2021

I've been able to fish in Orgrimmar without issue in Valley of Spirits and Valley of Honour. Do you have any screenshots/video of what this issue looks like?

@ghost ghost added 1-19 labels Feb 10, 2021
@Kitzunu
Copy link
Member

Kitzunu commented Feb 10, 2021

Same

@skxawng-cu
Copy link
Contributor Author

I test it again after updated an work. Thanks.

@skxawng-cu
Copy link
Contributor Author

I re open the issue because I confirm that female troll can not fish in Orgrimmar. Greets

@ghost
Copy link

ghost commented Mar 3, 2021

I can confirm the issue happening for a female troll currently on ChromieCraft, here is the video.

@ghost
Copy link

ghost commented Mar 4, 2021

I'm trying to debug this issue, looking through code, the culprit seems to be how the nearest point to player is calculated when casting Fishing spell, file src/server/game/Spells/Spell.cpp, line 1334:

m_caster->GetNearPoint(m_caster, x, y, z, DEFAULT_WORLD_OBJECT_SIZE, dis, m_caster->GetOrientation() + angle);

The m_caster position in this case is dependent on Player height, and since female trolls have a slightly bigger height value, this potential fishing bobber location falls into if (liquidLevel <= ground) clause, making the fishing attempt fail. I wonder what would be the best way to fix this, ideally without introducing a special case for female trolls...

In case anyone cares, here is how to confirm the issue quickly:

$ .go creature gurky
Gurky is at the Orgrimmar Valley of Honor, at the fishing pier where the issue manifests.
$ /target player
$ .levelup 60
$ .modify money 999999
Buy fishing pole, learn apprentice fishing.
$ .setskill 356 300 300
Try fishing while standing on a pier. If the player character is for ex. a male troll, the fishing will be successful. If the player character is a female troll, the fishing will constantly fail. 

@Buggyswires
Copy link

Buggyswires commented Mar 24, 2021

Same issue for Human Male. No fishing possible in either Valley of Spirits or Valley of Honor

Update: fishing works if you stand in the lake in the Valley of Honor and the Bobber lands near the middle (close to Tharl Stonebleeder - GUID 6497)

@Yehonal Yehonal changed the title Cannot fish in orgrimmar Cannot fish in orgrimmar [$10] Mar 26, 2021
@Yehonal Yehonal added the Bounty label Mar 26, 2021
@UltraNix
Copy link
Contributor

UltraNix commented Apr 3, 2021

The problem is with calculations in WorldObject::GetMinHeightInWater()
As I understand correclty, it does return the ground level in shallow water?
If I recall correctly, unit begins swimming at 75% of collision height.

@UltraNix
Copy link
Contributor

UltraNix commented Apr 3, 2021

if (canSwim && unit->GetMap()->IsInWater(x, y, max_z - Z_OFFSET_FIND_HEIGHT))
{
        // do not allow creatures to walk on
        // water level while swimming
        max_z = max_z - GetMinHeightInWater();
}

IsInWater means also shallow water, so max_z-GetMinHeightInWater() might be under the ground.

UltraNix added a commit to UltraNix/azerothcore-wotlk that referenced this issue Apr 3, 2021
Content 1-19 automation moved this from To do to Done Apr 4, 2021
@Yehonal Yehonal changed the title Cannot fish in orgrimmar [$10] Cannot fish in orgrimmar [$10 awarded] Apr 21, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Content 1-19
  
Done
Status: Done
Development

Successfully merging a pull request may close this issue.

7 participants