Compare commits

..

No commits in common. "672007ac7b04cf2ca231c35dd6019cc4679cc9a7" and "225cecf1fad35da4328900d4a92d09968f5c1824" have entirely different histories.

5 changed files with 8 additions and 24 deletions

View file

@ -32,9 +32,7 @@ jobs:
- name: Build
run: cargo build
--release
--package kubi
--bin kubi
--package kubi-server
--bin kubi-server
- name: Create artifact
shell: bash

View file

@ -87,8 +87,6 @@ cargo apk run -p kubi --lib --no-default-features
<h2>touch controls</h2>
warn: multitouch got broken after switching to `android-activity`, I'm still looking for a fix.
<img src=".readme/touch_controls.png" alt="touch control scheme" width="300">
- Left side: **Movement**
@ -120,16 +118,4 @@ seed = 0xfeb_face_dead_cafe # worldgen seed to use
name = "Kubi Server" # server name
```
<h2>"In-house" libraries</h2>
- [`kubi-ui`](kubi-ui): semi-imm.mode backend-agnostic ui system\
mostly ready to use, it has already replaced the Kubi legacy ui
- [`kubi-pool`](kubi-pool): very early work-in-progress work-stealing threadpool system\
aiming to replace `rayon` threadpool that's currently used inside the kubi client (for more control over task priority)
- [`kubi-logging`](kubi-logging) fancy-ass custom formatter for `env-logger`
deprecated:
~~`kubi-udp`~~ was a huge pita to work with and eventually got replaced by `uflow` (https://github.com/lowquark/uflow) in #5
<h6 align="right"><i>~ uwu</i></h6>

View file

@ -4,7 +4,7 @@ use crate::rendering::{Renderer, RenderTarget, WindowSize};
#[derive(Unique)]
pub struct UiState {
pub kui: KubiUi,
pub ui: KubiUi,
pub renderer: GliumUiRenderer,
}
@ -13,7 +13,7 @@ pub fn kubi_ui_init(
) {
let renderer = storages.borrow::<NonSendSync<UniqueView<Renderer>>>().unwrap();
storages.add_unique_non_send_sync(UiState {
kui: KubiUi::new(),
ui: KubiUi::new(),
renderer: GliumUiRenderer::new(&renderer.display)
});
}
@ -21,16 +21,16 @@ pub fn kubi_ui_init(
pub fn kubi_ui_begin(
mut ui: NonSendSync<UniqueViewMut<UiState>>
) {
ui.kui.begin();
ui.ui.begin();
}
pub fn kubi_ui_end(
mut ui: NonSendSync<UniqueViewMut<UiState>>
) {
let ui: &mut UiState = &mut ui;
let UiState { kui, renderer } = ui;
kui.end();
let (upload_needed, plan) = kui.draw_plan();
let UiState { ui, renderer } = ui;
ui.end();
let (upload_needed, plan) = ui.draw_plan();
if upload_needed {
renderer.update(plan);
}

View file

@ -21,7 +21,7 @@ fn render_progressbar(
let total = world.chunks.len();
loaded as f32 / total as f32
};
ui.kui.add(
ui.ui.add(
ProgressBar { value, ..Default::default() },
size.0.as_vec2()
);

View file

@ -30,7 +30,7 @@ impl Default for GameSettings {
render_distance: match true {
cfg!(debug_assertions) => 5,
cfg!(target_os = "android") => 6,
#[allow(unreachable_patterns)] _ => 7,
#[allow(unreachable_patterns)] _ => 8,
},
mouse_sensitivity: 1.,
debug_draw_current_chunk_border: false, //cfg!(not(target_os = "android")) && cfg!(debug_assertions),