mirror of
https://github.com/coop-deluxe/sm64coopdx.git
synced 2025-10-30 08:01:01 +00:00
Document lag_compensation.h (54.31%)
This commit is contained in:
parent
66e23c0cbf
commit
c790115c24
3 changed files with 20 additions and 0 deletions
|
|
@ -4469,20 +4469,24 @@ end
|
||||||
|
|
||||||
--- @param otherNp NetworkPlayer
|
--- @param otherNp NetworkPlayer
|
||||||
--- @return MarioState
|
--- @return MarioState
|
||||||
|
--- Gets the local Mario's state stored in lag compensation history
|
||||||
function lag_compensation_get_local_state(otherNp)
|
function lag_compensation_get_local_state(otherNp)
|
||||||
-- ...
|
-- ...
|
||||||
end
|
end
|
||||||
|
|
||||||
--- @return integer
|
--- @return integer
|
||||||
|
--- Gets the local Mario's state index
|
||||||
function lag_compensation_get_local_state_index()
|
function lag_compensation_get_local_state_index()
|
||||||
-- ...
|
-- ...
|
||||||
end
|
end
|
||||||
|
|
||||||
--- @return boolean
|
--- @return boolean
|
||||||
|
--- Checks if lag compensation history is ready
|
||||||
function lag_compensation_get_local_state_ready()
|
function lag_compensation_get_local_state_ready()
|
||||||
-- ...
|
-- ...
|
||||||
end
|
end
|
||||||
|
|
||||||
|
--- Stores the local Mario's current state in lag compensation history
|
||||||
function lag_compensation_store()
|
function lag_compensation_store()
|
||||||
-- ...
|
-- ...
|
||||||
end
|
end
|
||||||
|
|
|
||||||
|
|
@ -5126,6 +5126,9 @@ Sets if first person is enabled
|
||||||
|
|
||||||
## [lag_compensation_get_local_state](#lag_compensation_get_local_state)
|
## [lag_compensation_get_local_state](#lag_compensation_get_local_state)
|
||||||
|
|
||||||
|
### Description
|
||||||
|
Gets the local Mario's state stored in lag compensation history
|
||||||
|
|
||||||
### Lua Example
|
### Lua Example
|
||||||
`local MarioStateValue = lag_compensation_get_local_state(otherNp)`
|
`local MarioStateValue = lag_compensation_get_local_state(otherNp)`
|
||||||
|
|
||||||
|
|
@ -5146,6 +5149,9 @@ Sets if first person is enabled
|
||||||
|
|
||||||
## [lag_compensation_get_local_state_index](#lag_compensation_get_local_state_index)
|
## [lag_compensation_get_local_state_index](#lag_compensation_get_local_state_index)
|
||||||
|
|
||||||
|
### Description
|
||||||
|
Gets the local Mario's state index
|
||||||
|
|
||||||
### Lua Example
|
### Lua Example
|
||||||
`local integerValue = lag_compensation_get_local_state_index()`
|
`local integerValue = lag_compensation_get_local_state_index()`
|
||||||
|
|
||||||
|
|
@ -5164,6 +5170,9 @@ Sets if first person is enabled
|
||||||
|
|
||||||
## [lag_compensation_get_local_state_ready](#lag_compensation_get_local_state_ready)
|
## [lag_compensation_get_local_state_ready](#lag_compensation_get_local_state_ready)
|
||||||
|
|
||||||
|
### Description
|
||||||
|
Checks if lag compensation history is ready
|
||||||
|
|
||||||
### Lua Example
|
### Lua Example
|
||||||
`local booleanValue = lag_compensation_get_local_state_ready()`
|
`local booleanValue = lag_compensation_get_local_state_ready()`
|
||||||
|
|
||||||
|
|
@ -5182,6 +5191,9 @@ Sets if first person is enabled
|
||||||
|
|
||||||
## [lag_compensation_store](#lag_compensation_store)
|
## [lag_compensation_store](#lag_compensation_store)
|
||||||
|
|
||||||
|
### Description
|
||||||
|
Stores the local Mario's current state in lag compensation history
|
||||||
|
|
||||||
### Lua Example
|
### Lua Example
|
||||||
`lag_compensation_store()`
|
`lag_compensation_store()`
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -4,9 +4,13 @@
|
||||||
#define MAX_LOCAL_STATE_HISTORY 30
|
#define MAX_LOCAL_STATE_HISTORY 30
|
||||||
|
|
||||||
void lag_compensation_clear(void);
|
void lag_compensation_clear(void);
|
||||||
|
/* |description|Stores the local Mario's current state in lag compensation history|descriptionEnd| */
|
||||||
void lag_compensation_store(void);
|
void lag_compensation_store(void);
|
||||||
|
/* |description|Gets the local Mario's state stored in lag compensation history|descriptionEnd| */
|
||||||
struct MarioState* lag_compensation_get_local_state(struct NetworkPlayer* otherNp);
|
struct MarioState* lag_compensation_get_local_state(struct NetworkPlayer* otherNp);
|
||||||
|
/* |description|Checks if lag compensation history is ready|descriptionEnd| */
|
||||||
bool lag_compensation_get_local_state_ready(void);
|
bool lag_compensation_get_local_state_ready(void);
|
||||||
|
/* |description|Gets the local Mario's state index|descriptionEnd| */
|
||||||
u32 lag_compensation_get_local_state_index(void);
|
u32 lag_compensation_get_local_state_index(void);
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
Loading…
Add table
Reference in a new issue