Skip to content

Conversation

@HarshMehta112
Copy link
Contributor

Problem

Resolves : #8281

Solution

  • Updated ExprLocationOf.java to support OfflinePlayer directly
  • Pattern changed from %location% to %location/offlineplayers%
  • Refactored from WrapperExpression to SimpleExpression
  • Added direct OfflinePlayer.getLocation() handling (no converter, better performance)
  • Updated docs with offline player usage
  • Added @Since annotation for INSERT version (offline players)

Tests

  • Added ExprLocationOf.sk with comprehensive coverage:
    • location of {_offlinePlayer}
    • {_offlinePlayer}'s location
    • Backward compatibility with existing location logic
    • Online → Offline player conversion

Key Features

  • No Converter Added (performance-safe)
  • Syntax Supported
    • location of %offlineplayer%
    • %offlineplayer%'s location
    • Works with single players and lists

Testing Completed

Supporting Information


Completes: none
Related: none
AI assistance: none

@HarshMehta112 HarshMehta112 requested a review from a team as a code owner January 5, 2026 09:30
@HarshMehta112 HarshMehta112 requested review from Efnilite and Pesekjak and removed request for a team January 5, 2026 09:30
@skriptlang-automation skriptlang-automation bot added the needs reviews A PR that needs additional reviews label Jan 5, 2026
Signed-off-by: harsh-mehta-sb <harsh.mehta@smartbear.com>
@sovdeeth
Copy link
Member

sovdeeth commented Jan 5, 2026

You must disclose ai usage in your pr. Please see our contribution requirements.

These tests are also completely useless since the testing server has no players.

This should also not touch the location expression and instead just register a converter. (Or perhaps create a new expression like last location of to clarify they're not currently anywhere)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

needs reviews A PR that needs additional reviews

Projects

None yet

Development

Successfully merging this pull request may close these issues.

OfflinePlayer getLocation

3 participants