This commit is contained in:
2026-04-27 22:50:18 +08:00
parent ded6f6ee2a
commit b6c6640548
77 changed files with 5240 additions and 833 deletions

View File

@@ -294,6 +294,8 @@ pub mod puzzle_agent_session_row_type;
pub mod puzzle_agent_stage_type;
pub mod puzzle_draft_compile_input_type;
pub mod puzzle_generated_images_save_input_type;
pub mod puzzle_leaderboard_entry_row_type;
pub mod puzzle_leaderboard_submit_input_type;
pub mod puzzle_publication_status_type;
pub mod puzzle_publish_input_type;
pub mod puzzle_run_drag_input_type;
@@ -442,6 +444,7 @@ pub mod submit_big_fish_input_procedure;
pub mod submit_big_fish_message_procedure;
pub mod submit_custom_world_agent_message_procedure;
pub mod submit_puzzle_agent_message_procedure;
pub mod submit_puzzle_leaderboard_entry_procedure;
pub mod swap_puzzle_pieces_procedure;
pub mod treasure_interaction_action_type;
pub mod treasure_record_procedure_result_type;
@@ -755,6 +758,8 @@ pub use puzzle_agent_session_row_type::PuzzleAgentSessionRow;
pub use puzzle_agent_stage_type::PuzzleAgentStage;
pub use puzzle_draft_compile_input_type::PuzzleDraftCompileInput;
pub use puzzle_generated_images_save_input_type::PuzzleGeneratedImagesSaveInput;
pub use puzzle_leaderboard_entry_row_type::PuzzleLeaderboardEntryRow;
pub use puzzle_leaderboard_submit_input_type::PuzzleLeaderboardSubmitInput;
pub use puzzle_publication_status_type::PuzzlePublicationStatus;
pub use puzzle_publish_input_type::PuzzlePublishInput;
pub use puzzle_run_drag_input_type::PuzzleRunDragInput;
@@ -903,6 +908,7 @@ pub use submit_big_fish_input_procedure::submit_big_fish_input;
pub use submit_big_fish_message_procedure::submit_big_fish_message;
pub use submit_custom_world_agent_message_procedure::submit_custom_world_agent_message;
pub use submit_puzzle_agent_message_procedure::submit_puzzle_agent_message;
pub use submit_puzzle_leaderboard_entry_procedure::submit_puzzle_leaderboard_entry;
pub use swap_puzzle_pieces_procedure::swap_puzzle_pieces;
pub use treasure_interaction_action_type::TreasureInteractionAction;
pub use treasure_record_procedure_result_type::TreasureRecordProcedureResult;

View File

@@ -0,0 +1,70 @@
// THIS FILE IS AUTOMATICALLY GENERATED BY SPACETIMEDB. EDITS TO THIS FILE
// WILL NOT BE SAVED. MODIFY TABLES IN YOUR MODULE SOURCE CODE INSTEAD.
#![allow(unused, clippy::all)]
use spacetimedb_sdk::__codegen::{self as __sdk, __lib, __sats, __ws};
#[derive(__lib::ser::Serialize, __lib::de::Deserialize, Clone, PartialEq, Debug)]
#[sats(crate = __lib)]
pub struct PuzzleLeaderboardEntryRow {
pub entry_id: String,
pub profile_id: String,
pub grid_size: u32,
pub user_id: String,
pub nickname: String,
pub best_elapsed_ms: u64,
pub last_run_id: String,
pub updated_at: __sdk::Timestamp,
}
impl __sdk::InModule for PuzzleLeaderboardEntryRow {
type Module = super::RemoteModule;
}
/// Column accessor struct for the table `PuzzleLeaderboardEntryRow`.
///
/// Provides typed access to columns for query building.
pub struct PuzzleLeaderboardEntryRowCols {
pub entry_id: __sdk::__query_builder::Col<PuzzleLeaderboardEntryRow, String>,
pub profile_id: __sdk::__query_builder::Col<PuzzleLeaderboardEntryRow, String>,
pub grid_size: __sdk::__query_builder::Col<PuzzleLeaderboardEntryRow, u32>,
pub user_id: __sdk::__query_builder::Col<PuzzleLeaderboardEntryRow, String>,
pub nickname: __sdk::__query_builder::Col<PuzzleLeaderboardEntryRow, String>,
pub best_elapsed_ms: __sdk::__query_builder::Col<PuzzleLeaderboardEntryRow, u64>,
pub last_run_id: __sdk::__query_builder::Col<PuzzleLeaderboardEntryRow, String>,
pub updated_at: __sdk::__query_builder::Col<PuzzleLeaderboardEntryRow, __sdk::Timestamp>,
}
impl __sdk::__query_builder::HasCols for PuzzleLeaderboardEntryRow {
type Cols = PuzzleLeaderboardEntryRowCols;
fn cols(table_name: &'static str) -> Self::Cols {
PuzzleLeaderboardEntryRowCols {
entry_id: __sdk::__query_builder::Col::new(table_name, "entry_id"),
profile_id: __sdk::__query_builder::Col::new(table_name, "profile_id"),
grid_size: __sdk::__query_builder::Col::new(table_name, "grid_size"),
user_id: __sdk::__query_builder::Col::new(table_name, "user_id"),
nickname: __sdk::__query_builder::Col::new(table_name, "nickname"),
best_elapsed_ms: __sdk::__query_builder::Col::new(table_name, "best_elapsed_ms"),
last_run_id: __sdk::__query_builder::Col::new(table_name, "last_run_id"),
updated_at: __sdk::__query_builder::Col::new(table_name, "updated_at"),
}
}
}
/// Indexed column accessor struct for the table `PuzzleLeaderboardEntryRow`.
///
/// Provides typed access to indexed columns for query building.
pub struct PuzzleLeaderboardEntryRowIxCols {
pub entry_id: __sdk::__query_builder::IxCol<PuzzleLeaderboardEntryRow, String>,
}
impl __sdk::__query_builder::HasIxCols for PuzzleLeaderboardEntryRow {
type IxCols = PuzzleLeaderboardEntryRowIxCols;
fn ix_cols(table_name: &'static str) -> Self::IxCols {
PuzzleLeaderboardEntryRowIxCols {
entry_id: __sdk::__query_builder::IxCol::new(table_name, "entry_id"),
}
}
}
impl __sdk::__query_builder::CanBeLookupTable for PuzzleLeaderboardEntryRow {}

View File

@@ -0,0 +1,21 @@
// THIS FILE IS AUTOMATICALLY GENERATED BY SPACETIMEDB. EDITS TO THIS FILE
// WILL NOT BE SAVED. MODIFY TABLES IN YOUR MODULE SOURCE CODE INSTEAD.
#![allow(unused, clippy::all)]
use spacetimedb_sdk::__codegen::{self as __sdk, __lib, __sats, __ws};
#[derive(__lib::ser::Serialize, __lib::de::Deserialize, Clone, PartialEq, Debug)]
#[sats(crate = __lib)]
pub struct PuzzleLeaderboardSubmitInput {
pub run_id: String,
pub owner_user_id: String,
pub profile_id: String,
pub grid_size: u32,
pub elapsed_ms: u64,
pub nickname: String,
pub submitted_at_micros: i64,
}
impl __sdk::InModule for PuzzleLeaderboardSubmitInput {
type Module = super::RemoteModule;
}

View File

@@ -0,0 +1,59 @@
// THIS FILE IS AUTOMATICALLY GENERATED BY SPACETIMEDB. EDITS TO THIS FILE
// WILL NOT BE SAVED. MODIFY TABLES IN YOUR MODULE SOURCE CODE INSTEAD.
#![allow(unused, clippy::all)]
use spacetimedb_sdk::__codegen::{self as __sdk, __lib, __sats, __ws};
use super::puzzle_leaderboard_submit_input_type::PuzzleLeaderboardSubmitInput;
use super::puzzle_run_procedure_result_type::PuzzleRunProcedureResult;
#[derive(__lib::ser::Serialize, __lib::de::Deserialize, Clone, PartialEq, Debug)]
#[sats(crate = __lib)]
struct SubmitPuzzleLeaderboardEntryArgs {
pub input: PuzzleLeaderboardSubmitInput,
}
impl __sdk::InModule for SubmitPuzzleLeaderboardEntryArgs {
type Module = super::RemoteModule;
}
#[allow(non_camel_case_types)]
/// Extension trait for access to the procedure `submit_puzzle_leaderboard_entry`.
///
/// Implemented for [`super::RemoteProcedures`].
pub trait submit_puzzle_leaderboard_entry {
fn submit_puzzle_leaderboard_entry(&self, input: PuzzleLeaderboardSubmitInput) {
self.submit_puzzle_leaderboard_entry_then(input, |_, _| {});
}
fn submit_puzzle_leaderboard_entry_then(
&self,
input: PuzzleLeaderboardSubmitInput,
__callback: impl FnOnce(
&super::ProcedureEventContext,
Result<PuzzleRunProcedureResult, __sdk::InternalError>,
) + Send
+ 'static,
);
}
impl submit_puzzle_leaderboard_entry for super::RemoteProcedures {
fn submit_puzzle_leaderboard_entry_then(
&self,
input: PuzzleLeaderboardSubmitInput,
__callback: impl FnOnce(
&super::ProcedureEventContext,
Result<PuzzleRunProcedureResult, __sdk::InternalError>,
) + Send
+ 'static,
) {
self.imp
.invoke_procedure_with_callback::<_, PuzzleRunProcedureResult>(
"submit_puzzle_leaderboard_entry",
SubmitPuzzleLeaderboardEntryArgs { input },
__callback,
);
}
}