Skip to content

Dev#14

Open
billsonnn wants to merge 25 commits intomainfrom
dev
Open

Dev#14
billsonnn wants to merge 25 commits intomainfrom
dev

Conversation

@billsonnn
Copy link
Contributor

No description provided.

Dippys and others added 25 commits February 8, 2026 18:44
- Added weighted selection based on badges, account age, achievement score, friend count, room count, and furniture count
- Implemented 20s buffer window with automatic drawing logic
- Added support for both randomized and sequential serial numbers
- Implemented Landing View countdown timer (Header 2178)
- Added 'One-Per-Customer' anti-hoarding policy
- Refactored to lean, high-performance C# 12 patterns (Primary Constructors, Collection Expressions)
MessengerGrain:
- Add ILogger, replace 10 bare catch blocks with logged exceptions
- Replace .Ignore() with LogAndForget helper (logs on failure)
- Parallel online status checks on activation, search, and accept
- Timer-based delivered flag batching (RegisterGrainTimer + flush on deactivate)
- Batch RemoveFriendsAsync into single DB query and single composer call
- Hoist mySummary before AcceptFriendRequestsAsync loop
- Tracked delete for atomic request removal + friendship creation
- Bound session message history per conversation
- Remove hardcoded limits: searchLimit, pageSize, maxIgnoreCapacity
  now passed from handlers via IConfiguration

Handlers:
- Add missing PlayerId guard clause to GetHeightMapMessageHandler
- Add IConfiguration to HabboSearchMessageHandler, GetMessengerHistoryMessageHandler,
  IgnoreUserMessageHandler for configurable limits
- Delete duplicate no-op GetCreditsInfoMessageHandler

Primitives:
- Remove unused MESSENGER_STATE constant from OrleansStateNames
- Add searchLimit, pageSize, maxIgnoreCapacity params to IMessengerGrain

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Feat: Messenger & Friends & Relationships & Blocking
feat(catalog): implement LTD raffle system
Fix messenger timestamp to display properly.
Fix Ignoring to actually work
Copy link

@chatgpt-codex-connector chatgpt-codex-connector bot left a comment

Choose a reason for hiding this comment

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

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: cfda135c98

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment on lines +121 to +125
if (buffer <= 0 || _raffleFinished)
{
var instantWin = await TryFinalizeWinnerAsync(playerId, null, false);
return instantWin
? LtdRaffleEntryResult.Succeeded("instant")

Choose a reason for hiding this comment

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

P2 Badge Check one-per-customer before instant LTD purchase

This instant path runs before the LimitOnePerCustomer check, so once _raffleFinished is true (or when buffer is disabled) a player who already won can keep purchasing the same LTD series. In those modes the config flag is effectively bypassed, which breaks the contract implied by LimitOnePerCustomer and allows repeat winners when that setting is enabled.

Useful? React with 👍 / 👎.

Comment on lines +244 to +248
dbCtx.MessengerRequests.Add(
new MessengerRequestEntity
{
PlayerEntityId = myId,
RequestedPlayerEntityId = targetId,

Choose a reason for hiding this comment

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

P2 Badge Reject self-targeted friend requests

There is no guard against targetId == myId before persisting a request, so a player can friend-request themselves. When that self-request is accepted, AcceptFriendRequestsAsync tries to insert two identical friendship rows for the same (player_id, requested_id) pair, which violates the unique index and fails the accept flow with a database exception.

Useful? React with 👍 / 👎.

Comment on lines +1342 to +1343
var batch = _pendingDeliveredIds.ToList();
_pendingDeliveredIds.Clear();

Choose a reason for hiding this comment

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

P2 Badge Preserve delivered-message IDs on flush errors

The pending delivered-ID set is cleared before the DB update runs, so any transient failure in ExecuteUpdateAsync drops that batch permanently for the current session. Those messages remain Delivered = false and are re-delivered as offline messages later, causing duplicate chat deliveries after reconnect.

Useful? React with 👍 / 👎.

if (ctx.PlayerId <= 0)
return;

var searchLimit = _configuration.GetValue<int>("Turbo:Messenger:SearchResultLimit");

Choose a reason for hiding this comment

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

P1 Badge Add default fallback for messenger search limit

GetValue<int> returns 0 when Turbo:Messenger:SearchResultLimit is unset, and this commit does not add a Turbo:Messenger section to appsettings.json. In environments using repo defaults, that zero flows into SearchPlayersAsync(...).Take(searchLimit), so Habbo search always returns no users.

Useful? React with 👍 / 👎.

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.

3 participants