mirror of
https://github.com/DorkSquadRR/DorkNet.git
synced 2026-10-26 07:28:45 -07:00
Refactor URL coverage documentation and update StoreService for color variants
- Updated `url-coverage.md` to clarify the behavior of the `api/rooms/v2/myRecent` endpoint. - Enhanced `StoreService.cs` to include new properties for color variants: `combination_id` and `descriptor`. - Modified logic in `StoreService` to validate color variants based on the new descriptor instead of swatch GUID. - Updated database bootstrap scripts to create new tables for `RoomConsumables` and `RoomConsumableOwnership`, including necessary indexes. - Revised README to reflect changes in debugging options and the introduction of `DorkNet.DebugMod`. - Updated documentation on request expectations to clarify server-side behavior for room visibility. - Enhanced installation script to provide clearer instructions for enabling the debug console. - Added a new document detailing the process for dumping avatar items and color variants from the Rec Room client.
This commit is contained in:
@@ -40,6 +40,51 @@ public class RoomCurrencyPurchaseOfferEntity
|
||||
public DateTime UpdatedAt { get; set; } = DateTime.UtcNow;
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// One creator-made consumable for sale in a room — the 2023 client's
|
||||
/// in-room "shop" (RoomConsumablesManager). Wire identity is
|
||||
/// <see cref="PublicId"/> ("RoomConsumableId" on the wire); the desc DTO
|
||||
/// the client deserialises is {RoomConsumableId, RoomId, Name,
|
||||
/// Description, ImageName, PriceAndCurrency:{Price, CurrencyId}}.
|
||||
/// <see cref="CurrencyId"/> is null for token-priced items, otherwise
|
||||
/// the <see cref="RoomCurrencyEntity.PublicId"/> of a room currency.
|
||||
/// </summary>
|
||||
public class RoomConsumableEntity
|
||||
{
|
||||
public long Id { get; set; }
|
||||
public Guid PublicId { get; set; } = Guid.NewGuid();
|
||||
public long RoomId { get; set; }
|
||||
public long CreatorPlayerId { get; set; }
|
||||
[MaxLength(128)] public string Name { get; set; } = string.Empty;
|
||||
[MaxLength(1024)] public string Description { get; set; } = string.Empty;
|
||||
[MaxLength(256)] public string ImageName { get; set; } = string.Empty;
|
||||
public long Price { get; set; }
|
||||
public Guid? CurrencyId { get; set; }
|
||||
public bool IsDeleted { get; set; }
|
||||
public DateTime CreatedAt { get; set; } = DateTime.UtcNow;
|
||||
public DateTime UpdatedAt { get; set; } = DateTime.UtcNow;
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// One (player, room consumable) inventory stack. The client keeps a
|
||||
/// per-item optimistic-concurrency token: purchase and consume requests
|
||||
/// carry {CurrentConcurrencyCode, NewConcurrencyCode} and the server
|
||||
/// stores the new code on success — the wire inventory row is
|
||||
/// {RoomConsumableId, AccountId, Count, ConcurrencyCode, ModifiedAt,
|
||||
/// Consumable:{desc}}. <c>Consumable</c> must NEVER be null: the 2023
|
||||
/// client NREs in RoomConsumablesManager while processing the
|
||||
/// room-join inventory fetch if it is.
|
||||
/// </summary>
|
||||
public class RoomConsumableOwnershipEntity
|
||||
{
|
||||
public long Id { get; set; }
|
||||
public long PlayerId { get; set; }
|
||||
public long RoomConsumableId { get; set; }
|
||||
public int Count { get; set; }
|
||||
public Guid ConcurrencyCode { get; set; } = Guid.NewGuid();
|
||||
public DateTime ModifiedAt { get; set; } = DateTime.UtcNow;
|
||||
}
|
||||
|
||||
public class UgcPurchasableEntity
|
||||
{
|
||||
public long Id { get; set; }
|
||||
|
||||
Reference in New Issue
Block a user