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

Port complete leash and lead system #1905

Merged

Conversation

leoCottret
Copy link
Collaborator

@leoCottret leoCottret commented Sep 24, 2022

Summary

SUMMARY: Features "Port complete leash and lead system"

Purpose of change

I love my cows. After the quadruped armors to protect them I needed a reliable system to move them.
Fixes #781

No but seriously I like this system and thought it would be a great addition in CBN.

Describe the solution

Port the leash and lead system from DDA.
Now animals with the PET_WONT_FOLLOW flag won't follow you by default, but you can attach a leash to them and lead them to move them.
Go here for the complete set of features, it's well explained.

Only difference, I increased the range at which you loose hold of the leash, which means you can safely have up to 6 animals on a leash, whereas with the DDA limitation I couldn't keep more than 2 at a time.
Also, as a side note, this avoids this problem , now animals on a leash can go through Z level just fine.
Otherwise, same features.

Testing

  • I spawned several cows and tried every possibilities for tie/untie/leash/unleash/lead/...
  • And yes of course they don't follow you by default anymore
  • Same with dog, but they follow you by default while they see you, stop when they don't, you can solve that by attaching a leash to them
  • I'll continue testing everything a bit just in case

For the reviewer, I had to include the effect.h in monster.h to be able to set permanent effects (cf ".set_permanent()"), because they are working in CBN but a bit tricky to use. In DDA they added functions to set an effect as permanent when adding the effect. If there's a better system let me know.

Additional context

fyeah
f yeah!

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.

PET_WONT_FOLLOW flag doesn't work
2 participants