opx_infinityloading
Client
Last updated on
The loading contract on the client — whether a native load is up and whether OPX covers it.
local loading = OPX.Api.Get('loading')State
What the module last decided. To react to changes, listen to opx:on:loading:state instead of polling.
loading.State()Returns
Result— value:available:boolean—falseon a client without the reader (or after a refusal)mode:'state' | 'flag' | nil—loadingState,isLoadingonly, or not read yetactive:boolean— a native load is uphide:boolean— the HUD-like views are hiddencover:boolean— the OPX cover is drawnkind:'unknown' | 'splash' | 'initial' | 'fastTravel'progressKnown:booleanprogress?:number— 0..1
local now = loading.State()
if now.ok and now.value.active then return end -- do not open a menu during a load