mirror of
https://gitlab.com/veloren/veloren.git
synced 2024-08-30 18:12:32 +00:00
fix client without singleplayer feature
This commit is contained in:
parent
3e19c847f1
commit
68857d5af7
@ -21,6 +21,7 @@ use common::comp;
|
|||||||
use common_base::span;
|
use common_base::span;
|
||||||
use i18n::LocalizationHandle;
|
use i18n::LocalizationHandle;
|
||||||
use scene::Scene;
|
use scene::Scene;
|
||||||
|
#[cfg(feature = "singleplayer")]
|
||||||
use server::ServerInitStage;
|
use server::ServerInitStage;
|
||||||
use std::sync::Arc;
|
use std::sync::Arc;
|
||||||
use tokio::runtime;
|
use tokio::runtime;
|
||||||
@ -29,7 +30,9 @@ use ui::{Event as MainMenuEvent, MainMenuUi};
|
|||||||
|
|
||||||
#[derive(Debug)]
|
#[derive(Debug)]
|
||||||
pub enum DetailedInitializationStage {
|
pub enum DetailedInitializationStage {
|
||||||
|
#[cfg(feature = "singleplayer")]
|
||||||
Singleplayer,
|
Singleplayer,
|
||||||
|
#[cfg(feature = "singleplayer")]
|
||||||
SingleplayerServer(ServerInitStage),
|
SingleplayerServer(ServerInitStage),
|
||||||
StartingMultiplayer,
|
StartingMultiplayer,
|
||||||
Client(ClientInitStage),
|
Client(ClientInitStage),
|
||||||
|
@ -16,6 +16,7 @@ use i18n::Localization;
|
|||||||
use iced::{button, Align, Column, Container, Length, Row, Space, Text};
|
use iced::{button, Align, Column, Container, Length, Row, Space, Text};
|
||||||
use keyboard_keynames::key_layout::KeyLayout;
|
use keyboard_keynames::key_layout::KeyLayout;
|
||||||
use serde::{Deserialize, Serialize};
|
use serde::{Deserialize, Serialize};
|
||||||
|
#[cfg(feature = "singleplayer")]
|
||||||
use server::{ServerInitStage, WorldCivStage, WorldGenerateStage, WorldSimStage};
|
use server::{ServerInitStage, WorldCivStage, WorldGenerateStage, WorldSimStage};
|
||||||
|
|
||||||
struct LoadingAnimation {
|
struct LoadingAnimation {
|
||||||
@ -139,9 +140,11 @@ impl Screen {
|
|||||||
|
|
||||||
let stage = {
|
let stage = {
|
||||||
let stage_message = match init_stage {
|
let stage_message = match init_stage {
|
||||||
|
#[cfg(feature = "singleplayer")]
|
||||||
DetailedInitializationStage::Singleplayer => {
|
DetailedInitializationStage::Singleplayer => {
|
||||||
i18n.get_msg("hud-init-stage-singleplayer")
|
i18n.get_msg("hud-init-stage-singleplayer")
|
||||||
},
|
},
|
||||||
|
#[cfg(feature = "singleplayer")]
|
||||||
DetailedInitializationStage::SingleplayerServer(server_stage) => {
|
DetailedInitializationStage::SingleplayerServer(server_stage) => {
|
||||||
match server_stage {
|
match server_stage {
|
||||||
ServerInitStage::DbMigrations => {
|
ServerInitStage::DbMigrations => {
|
||||||
|
Loading…
Reference in New Issue
Block a user