完善 server-rs DDD 重构计划与骨架

This commit is contained in:
Codex
2026-04-29 11:51:30 +08:00
parent 39200ea9cc
commit aa2e9b36d7
98 changed files with 1261 additions and 11 deletions

View File

@@ -0,0 +1,3 @@
//! 战斗应用编排过渡落位。
//!
//! 这里只返回结算结果与待处理事件,不直接写入其他上下文表。

View File

@@ -0,0 +1,3 @@
//! 战斗写入命令过渡落位。
//!
//! 用于表达创建战斗、使用技能、逃离和结算等输入,不直接携带表行类型。

View File

@@ -0,0 +1,4 @@
//! 战斗领域模型过渡落位。
//!
//! 后续迁移 `BattleState` 与行动结算规则时,只保留单聚合内部状态变化;
//! 背包奖励、成长记账和任务联动由应用服务或 SpacetimeDB 事务 adapter 编排。

View File

@@ -0,0 +1,3 @@
//! 战斗领域错误过渡落位。
//!
//! 错误保持纯领域语义,不能绑定 HTTP 状态码或 SpacetimeDB 字符串格式。

View File

@@ -0,0 +1,3 @@
//! 战斗领域事件过渡落位。
//!
//! 用于表达战斗胜利、切磋完成、奖励待发放和战斗被终止等事实。

View File

@@ -1,3 +1,9 @@
mod application;
mod commands;
mod domain;
mod errors;
mod events;
use std::{error::Error, fmt};
use module_runtime_item::{