bump deps & rust edition

This commit is contained in:
yulian 2025-02-26 21:37:34 +07:00
parent c6eaffdb29
commit 4b3b768723
9 changed files with 21 additions and 21 deletions

View File

@ -1,6 +1,6 @@
[workspace] [workspace]
members = ["gameserver", "proto", "sdkserver"] members = ["gameserver", "proto", "sdkserver"]
resolver = "2" resolver = "3"
[workspace.package] [workspace.package]
version = "0.1.0" version = "0.1.0"
@ -11,13 +11,13 @@ ansi_term = "0.12.1"
atomic_refcell = "0.1.13" atomic_refcell = "0.1.13"
lazy_static = "1.4.0" lazy_static = "1.4.0"
axum = "0.7.4" axum = "0.8.1"
axum-server = "0.6.0" axum-server = "0.7.1"
env_logger = "0.11.3" env_logger = "0.11.3"
rbase64 = "2.0.3" rbase64 = "2.0.3"
rand = "0.8.5" rand = "0.9.0"
rsa = { version = "0.9.6", features = [ rsa = { version = "0.9.6", features = [
"sha1", "sha1",
"nightly", "nightly",
@ -26,12 +26,12 @@ rsa = { version = "0.9.6", features = [
"sha2", "sha2",
] } ] }
prost = "0.12.3" prost = "0.13.5"
prost-types = "0.12.3" prost-types = "0.13.5"
prost-build = "0.12.3" prost-build = "0.13.5"
paste = "1.0.14" paste = "1.0.14"
sysinfo = "0.30.7" sysinfo = "0.33.1"
hex = "0.4.3" hex = "0.4.3"

View File

@ -1,6 +1,6 @@
[package] [package]
name = "gameserver" name = "gameserver"
edition = "2021" edition = "2024"
version.workspace = true version.workspace = true
[dependencies] [dependencies]
@ -31,4 +31,4 @@ proto.workspace = true
proto-derive.workspace = true proto-derive.workspace = true
rand.workspace = true rand.workspace = true
mhy-kcp.workspace = true mhy-kcp.workspace = true

View File

@ -144,7 +144,7 @@ impl Gateway {
fn next_conv_pair(&mut self) -> (u32, u32) { fn next_conv_pair(&mut self) -> (u32, u32) {
( (
self.id_counter.fetch_add(1, Ordering::SeqCst) + 1, self.id_counter.fetch_add(1, Ordering::SeqCst) + 1,
rand::thread_rng().next_u32(), rand::rng().next_u32(),
) )
} }
} }

View File

@ -72,7 +72,7 @@ async fn create_battle_info(caster_id: u32, skill_index: u32) -> SceneBattleInfo
let mut battle_info = SceneBattleInfo { let mut battle_info = SceneBattleInfo {
stage_id: player.battle_config.stage_id, stage_id: player.battle_config.stage_id,
logic_random_seed: rand::thread_rng().gen::<u32>(), logic_random_seed: rand::rng().random::<u32>(),
battle_id: 1, battle_id: 1,
rounds_limit: player.battle_config.cycle_count, rounds_limit: player.battle_config.cycle_count,
world_level: 6, world_level: 6,

View File

@ -1,7 +1,7 @@
[package] [package]
name = "mhy-kcp" name = "mhy-kcp"
version.workspace = true version.workspace = true
edition = "2021" edition = "2024"
[features] [features]
fastack-conserve = [] fastack-conserve = []
@ -10,11 +10,11 @@ tokio = ["dep:tokio"]
[dependencies] [dependencies]
bytes = "1.6.0" bytes = "1.6.0"
log = "0.4.21" log = "0.4.21"
thiserror = "1.0.58" thiserror = "2.0.11"
tokio = { version = "1.37.0", optional = true, features = ["io-util"] } tokio = { version = "1.37.0", optional = true, features = ["io-util"] }
[dev-dependencies] [dev-dependencies]
time = "0.3.34" time = "0.3.34"
rand = "0.8.5" rand = "0.9.0"
env_logger = "0.11.3" env_logger = "0.11.3"

View File

@ -1,6 +1,6 @@
[package] [package]
name = "proto" name = "proto"
edition = "2021" edition = "2024"
version.workspace = true version.workspace = true
[dependencies] [dependencies]

View File

@ -1,7 +1,7 @@
[package] [package]
name = "proto-derive" name = "proto-derive"
version = "0.1.0" version = "0.1.0"
edition = "2021" edition = "2024"
[dependencies] [dependencies]
syn = "2.0.53" syn = "2.0.53"

View File

@ -1,7 +1,7 @@
[package] [package]
name = "sdkserver" name = "sdkserver"
version = "0.1.0" version = "0.1.0"
edition = "2021" edition = "2024"
[dependencies] [dependencies]
anyhow.workspace = true anyhow.workspace = true

View File

@ -1,9 +1,9 @@
use axum::Json; use axum::Json;
use serde_json::json; use serde_json::json;
pub const LOGIN_WITH_PASSWORD_ENDPOINT: &str = "/:product_name/mdk/shield/api/login"; pub const LOGIN_WITH_PASSWORD_ENDPOINT: &str = "/{product_name}/mdk/shield/api/login";
pub const LOGIN_WITH_SESSION_TOKEN_ENDPOINT: &str = "/:product_name/mdk/shield/api/verify"; pub const LOGIN_WITH_SESSION_TOKEN_ENDPOINT: &str = "/{product_name}/mdk/shield/api/verify";
pub const GRANTER_LOGIN_VERIFICATION_ENDPOINT: &str = "/:product_name/combo/granter/login/v2/login"; pub const GRANTER_LOGIN_VERIFICATION_ENDPOINT: &str = "/{product_name}/combo/granter/login/v2/login";
pub const RISKY_API_CHECK_ENDPOINT: &str = "/account/risky/api/check"; pub const RISKY_API_CHECK_ENDPOINT: &str = "/account/risky/api/check";
#[tracing::instrument] #[tracing::instrument]