拆分大文件
This commit is contained in:
@@ -155,8 +155,7 @@ use crate::module_bindings::{
|
||||
BigFishSessionGetInput as BindingBigFishSessionGetInput,
|
||||
BigFishSessionProcedureResult as BindingBigFishSessionProcedureResult,
|
||||
BigFishSessionSnapshot as BindingBigFishSessionSnapshot,
|
||||
BigFishVector2 as BindingBigFishVector2,
|
||||
BigFishWorksListInput as BindingBigFishWorksListInput,
|
||||
BigFishVector2 as BindingBigFishVector2, BigFishWorksListInput as BindingBigFishWorksListInput,
|
||||
BigFishWorksProcedureResult as BindingBigFishWorksProcedureResult,
|
||||
CombatOutcome as BindingCombatOutcome,
|
||||
CustomWorldAgentActionExecuteInput as BindingCustomWorldAgentActionExecuteInput,
|
||||
@@ -323,10 +322,10 @@ use crate::module_bindings::{
|
||||
get_runtime_setting_or_default_procedure::get_runtime_setting_or_default as _,
|
||||
get_runtime_snapshot_procedure::get_runtime_snapshot as _,
|
||||
get_story_session_state_procedure::get_story_session_state as _,
|
||||
list_big_fish_works_procedure::list_big_fish_works as _,
|
||||
list_custom_world_gallery_entries_procedure::list_custom_world_gallery_entries as _,
|
||||
list_custom_world_profiles_procedure::list_custom_world_profiles as _,
|
||||
list_custom_world_works_procedure::list_custom_world_works as _,
|
||||
list_big_fish_works_procedure::list_big_fish_works as _,
|
||||
list_platform_browse_history_procedure::list_platform_browse_history as _,
|
||||
list_profile_save_archives_procedure::list_profile_save_archives as _,
|
||||
list_profile_wallet_ledger_procedure::list_profile_wallet_ledger as _,
|
||||
@@ -1534,15 +1533,14 @@ impl SpacetimeClient {
|
||||
let procedure_input = BindingBigFishWorksListInput { owner_user_id };
|
||||
|
||||
self.call_after_connect(move |connection, sender| {
|
||||
connection.procedures().list_big_fish_works_then(
|
||||
procedure_input,
|
||||
move |_, result| {
|
||||
connection
|
||||
.procedures()
|
||||
.list_big_fish_works_then(procedure_input, move |_, result| {
|
||||
let mapped = result
|
||||
.map_err(|error| SpacetimeClientError::Procedure(error.to_string()))
|
||||
.and_then(map_big_fish_works_procedure_result);
|
||||
send_once(&sender, mapped);
|
||||
},
|
||||
);
|
||||
});
|
||||
})
|
||||
.await
|
||||
}
|
||||
@@ -3582,8 +3580,9 @@ fn map_big_fish_works_procedure_result(
|
||||
"SpacetimeDB procedure 未返回 big fish works 快照".to_string(),
|
||||
)
|
||||
})?;
|
||||
serde_json::from_str::<Vec<BigFishWorkSummaryRecord>>(&items_json)
|
||||
.map_err(|error| SpacetimeClientError::Runtime(format!("big fish works items_json 非法: {error}")))
|
||||
serde_json::from_str::<Vec<BigFishWorkSummaryRecord>>(&items_json).map_err(|error| {
|
||||
SpacetimeClientError::Runtime(format!("big fish works items_json 非法: {error}"))
|
||||
})
|
||||
}
|
||||
|
||||
fn map_big_fish_run_procedure_result(
|
||||
|
||||
Reference in New Issue
Block a user