Check if position is valid on trigger MoveUser - #390
Conversation
WalkthroughThe changes extend command and navigation functionality in the game server. The Changes
Sequence Diagram(s)sequenceDiagram
participant U as User
participant C as CoordCommand
U->>C: Invoke command with coordinates and force flag
alt force flag is true
C->>C: Bypass coordinate validation
C->>U: Proceed with move operation
else force flag is false
C->>C: Perform normal coordinate validation
alt Coordinates valid
C->>U: Proceed with move operation
else Coordinates invalid
C->>U: Return error
end
end
sequenceDiagram
participant U as User
participant TC as TriggerContext
participant F as Field
U->>TC: Initiate MoveUser(portalId)
TC->>F: TryGetPortal(portalId)
alt Portal found
TC->>F: ValidPosition(portal.Position)
alt Portal position valid
TC->>U: Move user through portal
else Portal position invalid
TC->>U: Abort move operation
end
else Portal not found
TC->>U: Abort move operation (portal not found)
end
Suggested reviewers
Poem
📜 Recent review detailsConfiguration used: CodeRabbit UI 📒 Files selected for processing (8)
💤 Files with no reviewable changes (1)
🚧 Files skipped from review as they are similar to previous changes (2)
🧰 Additional context used🧬 Code Definitions (2)Maple2.Server.Game/PacketHandlers/RideHandler.cs (3)
Maple2.Server.Game/Model/Field/Actor/FieldPlayer.cs (5)
⏰ Context from checks skipped due to timeout of 90000ms (1)
🔇 Additional comments (13)
✨ Finishing Touches
🪧 TipsChatThere are 3 ways to chat with CodeRabbit:
Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments. CodeRabbit Commands (Invoked using PR comments)
Other keywords and placeholders
CodeRabbit Configuration File (
|
Summary by CodeRabbit
New Features
Refactor