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

fix: Magic NPCs now use spell range #1870

Merged
merged 5 commits into from
Aug 8, 2024

Conversation

kamronbatman
Copy link
Contributor

@kamronbatman kamronbatman commented Jul 13, 2024

Summary

  • Drastically streamlines the spell targeting by collapsing the target classes into a single SpellTarget<T> class.
  • Moves TargetRange to the spell itself so it can be used by MageAI.
  • Changes range check in MageAI to use TargetRange. This should fix target acquisition bugs

Copy link

github-actions bot commented Jul 13, 2024

Qodana for .NET

2 new problems were found

Inspection name Severity Problems
Namespace does not correspond to file location ◽️ Notice 2

💡 Qodana analysis was run in the pull request mode: only the changed files were checked
☁️ View the detailed Qodana report

Detected 18 dependencies

Third-party software list

This page lists the third-party software dependencies used in ModernUO

Dependency Version Licenses
Argon2.Bindings 1.16.1 MIT
BouncyCastle.Cryptography 2.4.0 MIT
CommunityToolkit.HighPerformance 8.2.2 MIT
LibDeflate.Bindings 1.0.2.120 GPL-3.0-only
MailKit 4.7.1 MIT
Microsoft.Extensions.FileSystemGlobbing 8.0.0 MIT
MimeKit 4.7.1 MIT
ModernUO.Serialization.Annotations 2.9.1 GPL-3.0-only
ModernUO.Serialization.Generator 2.11.3 GPL-3.0-only
Nerdbank.GitVersioning 3.6.139 MIT
PollGroup 1.5.1 BSD-3-Clause
Serilog.Sinks.Async 2.0.0 Apache-2.0
Serilog.Sinks.Console 6.0.0 Apache-2.0
Serilog 4.0.0 Apache-2.0
System.Formats.Asn1 8.0.1 MIT
System.IO.Hashing 8.0.0 MIT
System.Security.Cryptography.Pkcs 8.0.0 MIT
Zstd.Binaries 1.6.0 MIT
Contact Qodana team

Contact us at [email protected]

@kamronbatman kamronbatman force-pushed the kbatman/streamline_spell_range branch from 7046fc7 to 76ef524 Compare July 13, 2024 00:50
3Streamlines recall target
@kamronbatman kamronbatman force-pushed the kbatman/streamline_spell_range branch from cb24ff2 to f6d7e77 Compare July 13, 2024 01:10
Copy link

github-actions bot commented Aug 8, 2024

Qodana for .NET

2 new problems were found

Inspection name Severity Problems
Namespace does not correspond to file location ◽️ Notice 2

💡 Qodana analysis was run in the pull request mode: only the changed files were checked
☁️ View the detailed Qodana report

Detected 18 dependencies

Third-party software list

This page lists the third-party software dependencies used in ModernUO

Dependency Version Licenses
Argon2.Bindings 1.16.1 MIT
BouncyCastle.Cryptography 2.4.0 MIT
CommunityToolkit.HighPerformance 8.2.2 MIT
LibDeflate.Bindings 1.0.2.120 GPL-3.0-only
MailKit 4.7.1.1 MIT
Microsoft.Extensions.FileSystemGlobbing 8.0.0 MIT
MimeKit 4.7.1 MIT
ModernUO.Serialization.Annotations 2.9.1 GPL-3.0-only
ModernUO.Serialization.Generator 2.11.3 GPL-3.0-only
Nerdbank.GitVersioning 3.6.139 MIT
PollGroup 1.5.1 BSD-3-Clause
Serilog.Sinks.Async 2.0.0 Apache-2.0
Serilog.Sinks.Console 6.0.0 Apache-2.0
Serilog 4.0.1 Apache-2.0
System.Formats.Asn1 8.0.1 MIT
System.IO.Hashing 8.0.0 MIT
System.Security.Cryptography.Pkcs 8.0.0 MIT
Zstd.Binaries 1.6.0 MIT
Contact Qodana team

Contact us at [email protected]

Copy link
Contributor

@mdodkins mdodkins left a comment

Choose a reason for hiding this comment

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

Much cleaner! Looks good to me

@@ -350,15 +349,10 @@ public enum TeachResult
public BaseCreature(
AIType ai,
FightMode mode = FightMode.Closest,
int iRangePerception = 10,
int iRangePerception = DefaultRangePerception,
Copy link
Contributor

Choose a reason for hiding this comment

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

👍

@kamronbatman kamronbatman merged commit 9b7fea2 into main Aug 8, 2024
14 checks passed
@kamronbatman kamronbatman deleted the kbatman/streamline_spell_range branch August 8, 2024 14:05
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.

2 participants