Fix some compiler warnings and add update docs #89
No reviewers
Labels
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
IllusionMods/IllusionModdingAPI!89
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "fix-warns"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Pull Request Overview
This PR focuses on fixing compiler warnings and adding missing documentation throughout the KKAPI codebase. The changes primarily address namespace inconsistencies, obsolete API usage warnings, and missing XML documentation comments for public APIs.
KKAPIas the root namespaceGameObject.FindObjectOfTypecalls withUnityEngine.Object.FindObjectOfTypeReviewed Changes
Copilot reviewed 24 out of 24 changed files in this pull request and generated 3 comments.
Show a summary per file
Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.
@ -166,3 +166,3 @@/// <inheritdoc cref="AddActionIcon(int,Vector3,Sprite,Sprite,Action,Action{TriggerEnterExitEvent},bool,bool)"/>[Obsolete][Obsolete("Use another overload", true)]public static void AddActionIcon(int mapNo, Vector3 position, Sprite iconOn, Sprite iconOff, Action onOpen, Action<TriggerEnterExitEvent> onCreated)Adding
trueas the second parameter makes this a compile-time error instead of just a warning. This is a breaking change that could prevent existing code from compiling. Consider usingfalseif backwards compatibility is needed.The cast to
(int)was removed but the variableresis still declared asinttype. Either change the variable type to matchHooks._modeSextype or restore the cast.This change introduces a potential null reference exception. The original
GameObject.FindObjectOfTypewould return null if no object is found, butUnityEngine.Object.FindObjectOfTypebehavior may differ. Consider adding a null check before accessing the checkWindow property.