Slice 2 (WIP): class carrier (GoInGameRequest.ClassId) + Warrior cone archetype
The per-player class travels on GoInGameRequest.ClassId (client reads a ClassSelection singleton); GoInGameServerSystem seeds the class at spawn via ClassTraits (AbilityRef + permanent trait StatModifiers on a reserved ClassSourceId; CharacterStatsRef stays Default so the DRG-asymmetry deltas ride the replicated OwnerSendType.All buffer). AbilityFireSystem gains the aim-directed Cone archetype: cooldown predicted both worlds, server-only cone damage to living enemies (same-tick, SourceTick-stamped, like the melee cleave). 345/345. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
This commit is contained in:
@@ -0,0 +1,16 @@
|
||||
using Unity.Entities;
|
||||
|
||||
namespace ProjectM.Simulation
|
||||
{
|
||||
/// <summary>
|
||||
/// Slice 2: the local player's chosen class (a <see cref="CharacterId"/> byte), staged in the CLIENT world as a
|
||||
/// singleton by the menu / WorldLauncher before going in-game. <see cref="GoInGameRequest"/> picks it up
|
||||
/// (GoInGameClientSystem) so the server seeds the right class at spawn. NOT replicated — it is client-local
|
||||
/// intent; the class travels to the server via the RPC, then back to all clients via the seeded StatModifiers +
|
||||
/// the replicated AbilityRef. 0 = unset (the server defaults to Warrior).
|
||||
/// </summary>
|
||||
public struct ClassSelection : IComponentData
|
||||
{
|
||||
public byte ClassId;
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user