diff --git a/crates/benilla-app/src/video.rs b/crates/benilla-app/src/video.rs index fdabc34f6..afbd56fab 100644 --- a/crates/benilla-app/src/video.rs +++ b/crates/benilla-app/src/video.rs @@ -15,7 +15,9 @@ //! //! Deviation: on Windows, NVIDIA's Vulkan driver (610.88 seen) crashes inside `vkQueuePresentKHR` //! on the first present after any swapchain resize while the present mode is `Fifo`, `FifoRelaxed` -//! or `AutoVsync` (a maximize is a resize). `Mailbox`, `AutoNoVsync` and DX12 survive, so there +//! or `AutoVsync` (a maximize is a resize). The fault is in the driver's own DXGI present +//! (`d3d11.dll`): it stays with `VK_LAYER_NV_present` disabled, and the validation layer reports +//! nothing before it. `Mailbox`, `AutoNoVsync` and DX12 survive, so there //! "vsync on" is `AutoNoVsync` paced to the monitor's refresh rate ([`present_choice`]), which //! keeps the synced look without the crash. `$WOW_PRESENT=fifo` restores plain `Fifo`. diff --git a/crates/benilla-formats/src/race_creature_type.rs b/crates/benilla-formats/src/race_creature_type.rs index 328ed7455..a6c1a88a1 100644 --- a/crates/benilla-formats/src/race_creature_type.rs +++ b/crates/benilla-formats/src/race_creature_type.rs @@ -1,7 +1,7 @@ //! `ChrRaces.dbc` column 9: the creature type a player's race reads as, the last stage of the //! creature-type resolver (`0x605570`: race byte → row `[0xc0dee0][race]`, offset `0x24`, at -//! `0x6055ca`). The runtime uses a frozen copy, `spell::unit_type::race_creature_type`; this -//! loader backs the test that pins it. +//! `0x6055ca`). The runtime uses a frozen copy, `creature_type::race_creature_type` in +//! `benilla-app`; this loader backs the test that pins it. use std::collections::HashMap; diff --git a/crates/benilla-protocol/src/messages/group.rs b/crates/benilla-protocol/src/messages/group.rs index e4e5b0687..ae5707d70 100644 --- a/crates/benilla-protocol/src/messages/group.rs +++ b/crates/benilla-protocol/src/messages/group.rs @@ -342,7 +342,7 @@ impl PartyMemberStatsInfo { / power_display_scale(u32::from(self.shown_power_type())) } - /// `UnitPowerType` from the pet block (`+0xd8`, `0x5179d2`'s pet leg), 0 when it has none. + /// `UnitPowerType` from the pet block (`+0xd8`, the pet leg `0x5179ff`), 0 when it has none. pub fn shown_pet_power_type(&self) -> u8 { self.pet_power_type.unwrap_or(0) } diff --git a/crates/benilla-ui/src/script/cursor/drag.rs b/crates/benilla-ui/src/script/cursor/drag.rs index 10036490e..06645bfb7 100644 --- a/crates/benilla-ui/src/script/cursor/drag.rs +++ b/crates/benilla-ui/src/script/cursor/drag.rs @@ -8,8 +8,9 @@ use crate::widget::FrameHandle; const DRAG_START_DISTANCE_SQ: f32 = 0.01 * 0.01; /// Whether `pos` is far enough from the press point `start` to start the drag (`0x76b34c`–`0x76b372`). -/// The reference measures in layout units, where the screen diagonal is 1 (`0x41ad80`, from the -/// press and move converters `0x425666`/`0x425766`), so the pointer, in root units, is divided by +/// The reference measures in layout units, where the screen diagonal is 1 (`0x41ad80`, called at +/// `0x766fb1` in the interface's mouse converter `0x766f70`, which the press and move handlers +/// `0x7662c0` and `0x7660d0` run), so the pointer, in root units, is divided by /// [`Model::layout_unit`]: 1% of the diagonal at every screen size and UI scale. The squared /// distance is taken in `f64` against the f32 threshold (x87 at 53 bits: `WinMain`'s /// `_controlfp(0x9001f)`, `D3DCREATE_FPU_PRESERVE`), and only a smaller one skips (`0x76b372` diff --git a/crates/benilla-ui/src/script/handler_prof.rs b/crates/benilla-ui/src/script/handler_prof.rs index e124a6d1e..5bc2ac455 100644 --- a/crates/benilla-ui/src/script/handler_prof.rs +++ b/crates/benilla-ui/src/script/handler_prof.rs @@ -307,8 +307,9 @@ fn print_report(rows: &[HandlerRow], window: f32, frames: u32, nested: u32) { } } -/// Install the profiler's `app_data` slot, armed from the environment. Unconditional: mlua refuses -/// to insert app data while any is borrowed, so the slot must exist before the VM runs. +/// Install the profiler's `app_data` slot, armed from the environment. Every VM gets one, where +/// its app data is made, because [`UiScript::profile_handlers`] and every reader do nothing on a +/// VM without it. pub(super) fn install(lua: &Lua) { let period = env_period(); lua.set_app_data(HandlerProf { diff --git a/crates/benilla-ui/src/script/macros.rs b/crates/benilla-ui/src/script/macros.rs index 6eeca6b57..b06cdcf17 100644 --- a/crates/benilla-ui/src/script/macros.rs +++ b/crates/benilla-ui/src/script/macros.rs @@ -55,7 +55,7 @@ pub struct MacroView { pub id: u32, pub name: String, /// The icon's texture path, kept by name because the reference saves the icon by name - /// (`MACRO %d "%s" %s`, `0x44cb60`). + /// (`MACRO %d "%s" %s`, `0x84cb60`). pub texture: Option, /// The macro's lines, `\n`-separated. pub body: String, diff --git a/crates/benilla-ui/src/script/mod.rs b/crates/benilla-ui/src/script/mod.rs index c9a6711d9..49130ba2a 100644 --- a/crates/benilla-ui/src/script/mod.rs +++ b/crates/benilla-ui/src/script/mod.rs @@ -633,8 +633,8 @@ fn open_state(vm: VmKind) -> mlua::Result { let mut model = Model::new(); model.vm = vm; lua.set_app_data(model); - // Before anything can fire a handler and while no app-data borrow is held, as the - // profiler's slot and the call host's require. + // Before anything can fire a handler: every VM carries the profiler's slot and the call + // host's. handler_prof::install(&lua); host::install(&lua); diff --git a/docs/DEVIATIONS.md b/docs/DEVIATIONS.md index 837b1eed1..b1c940eca 100644 --- a/docs/DEVIATIONS.md +++ b/docs/DEVIATIONS.md @@ -471,8 +471,8 @@ Each entry is the first sentence of a `Deviation:` comment, linking to where it #### video - `gxWindow "0"` is borderless fullscreen, not 1.12's exclusive mode-set at `gxResolution`, because Wayland has no client mode-setting (winit ignores `Fullscreen::Exclusive` there), X11's XRandR changes the desktop's mode and a crash leaves it changed, and macOS has no exclusive mode. ([`src/video.rs:4`](../crates/benilla-app/src/video.rs#L4)) -- On Windows, NVIDIA's Vulkan driver (610.88 seen) crashes inside `vkQueuePresentKHR` on the first present after any swapchain resize while the present mode is `Fifo`, `FifoRelaxed` or `AutoVsync` (a maximize is a resize). `Mailbox`, `AutoNoVsync` and DX12 survive, so there "vsync on" is `AutoNoVsync` paced to the monitor's refresh rate (`present_choice`), which keeps the synced look without the crash. `$WOW_PRESENT=fifo` restores plain `Fifo`. ([`src/video.rs:16`](../crates/benilla-app/src/video.rs#L16)) -- Sizes are logical px, because `gxResolution` is a logical inner size here. ([`src/video.rs:555`](../crates/benilla-app/src/video.rs#L555)) +- On Windows, NVIDIA's Vulkan driver (610.88 seen) crashes inside `vkQueuePresentKHR` on the first present after any swapchain resize while the present mode is `Fifo`, `FifoRelaxed` or `AutoVsync` (a maximize is a resize). ([`src/video.rs:16`](../crates/benilla-app/src/video.rs#L16)) +- Sizes are logical px, because `gxResolution` is a logical inner size here. ([`src/video.rs:557`](../crates/benilla-app/src/video.rs#L557)) #### vplates