uce/site/doc/pages/2_DValue_to_s64.txt
2026-06-15 21:42:50 +00:00

18 lines
450 B
Plaintext

:sig
s64 DValue::to_s64(s64 default_value = 0) const
:params
s64 : fallback returned when conversion is not possible
return value : converted value or the fallback
:see
0_DValue
2_DValue_get_by_path
:content
Converts strings, f64, bool, pointer, and single-value maps to a signed integer. Invalid or empty strings return the default. Values outside the signed range are clamped.
```cpp
s64 count = cfg.get_by_path("limits/count").to_s64(10);
```