protologic_core 11.0.0

Rust bindings for Protologic
Documentation
1
2
3
4
5
6
7
8
9
10
11
use crate::lowlevel::quickstate;

/// Get the current amount of "fuel" available for CPU operations within this tick.
pub fn cpu_get_fuel() -> i64
{
    // Note: this does _not_ read from quickstate. We want to get a "live" value every time this is called!
    unsafe
    {
        return quickstate::cpu_get_fuel();
    }
}