mirror of
https://github.com/coop-deluxe/sm64coopdx.git
synced 2025-10-30 08:01:01 +00:00
add documentation to some missing manual functions
This commit is contained in:
parent
aa21b4feea
commit
f98571c458
3 changed files with 105 additions and 1 deletions
|
|
@ -212,6 +212,8 @@ manual_index_documentation = """
|
|||
- [add_scroll_target](#add_scroll_target)
|
||||
- [collision_find_surface_on_ray](#collision_find_surface_on_ray)
|
||||
- [cast_graph_node](#cast_graph_node)
|
||||
- [get_uncolored_string](#get_uncolored_string)
|
||||
- [gfx_set_command](#gfx_set_command)
|
||||
|
||||
<br />
|
||||
|
||||
|
|
@ -726,6 +728,56 @@ N/A
|
|||
|
||||
<br />
|
||||
|
||||
## [get_uncolored_string](#get_uncolored_string)
|
||||
|
||||
Removes color codes from a string.
|
||||
|
||||
### Lua Example
|
||||
```lua
|
||||
print(get_uncolored_string("\#210059\Colored \#FF086F\String")) -- "Colored String"
|
||||
```
|
||||
|
||||
### Parameters
|
||||
| Field | Type |
|
||||
| ----- | ---- |
|
||||
| str | 'string' |
|
||||
|
||||
### Returns
|
||||
- `string`
|
||||
|
||||
### C Prototype
|
||||
N/A
|
||||
|
||||
[:arrow_up_small:](#)
|
||||
|
||||
<br />
|
||||
|
||||
## [gfx_set_command](#gfx_set_command)
|
||||
|
||||
Sets the specified display list command on the display list given.
|
||||
|
||||
### Lua Example
|
||||
```lua
|
||||
gfx_set_command(gfx, "gsDPSetEnvColor", 0x00, 0xFF, 0x00, 0xFF)
|
||||
```
|
||||
|
||||
### Parameters
|
||||
| Field | Type |
|
||||
| ----- | ---- |
|
||||
| gfx | [Gfx](structs.md#Gfx) |
|
||||
| command | `string` |
|
||||
| (Any number of arguments) | `integer` |
|
||||
|
||||
### Returns
|
||||
- None
|
||||
|
||||
### C Prototype
|
||||
N/A
|
||||
|
||||
[:arrow_up_small:](#)
|
||||
|
||||
<br />
|
||||
|
||||
"""
|
||||
|
||||
############################################################################
|
||||
|
|
|
|||
|
|
@ -27,6 +27,8 @@
|
|||
- [add_scroll_target](#add_scroll_target)
|
||||
- [collision_find_surface_on_ray](#collision_find_surface_on_ray)
|
||||
- [cast_graph_node](#cast_graph_node)
|
||||
- [get_uncolored_string](#get_uncolored_string)
|
||||
- [gfx_set_command](#gfx_set_command)
|
||||
|
||||
<br />
|
||||
|
||||
|
|
@ -2457,6 +2459,56 @@ N/A
|
|||
|
||||
<br />
|
||||
|
||||
## [get_uncolored_string](#get_uncolored_string)
|
||||
|
||||
Removes color codes from a string.
|
||||
|
||||
### Lua Example
|
||||
```lua
|
||||
print(get_uncolored_string("\#210059\Colored \#FF086F\String")) -- "Colored String"
|
||||
```
|
||||
|
||||
### Parameters
|
||||
| Field | Type |
|
||||
| ----- | ---- |
|
||||
| str | 'string' |
|
||||
|
||||
### Returns
|
||||
- `string`
|
||||
|
||||
### C Prototype
|
||||
N/A
|
||||
|
||||
[:arrow_up_small:](#)
|
||||
|
||||
<br />
|
||||
|
||||
## [gfx_set_command](#gfx_set_command)
|
||||
|
||||
Sets the specified display list command on the display list given.
|
||||
|
||||
### Lua Example
|
||||
```lua
|
||||
gfx_set_command(gfx, "gsDPSetEnvColor", 0x00, 0xFF, 0x00, 0xFF)
|
||||
```
|
||||
|
||||
### Parameters
|
||||
| Field | Type |
|
||||
| ----- | ---- |
|
||||
| gfx | [Gfx](structs.md#Gfx) |
|
||||
| command | `string` |
|
||||
| (Any number of arguments) | `integer` |
|
||||
|
||||
### Returns
|
||||
- None
|
||||
|
||||
### C Prototype
|
||||
N/A
|
||||
|
||||
[:arrow_up_small:](#)
|
||||
|
||||
<br />
|
||||
|
||||
|
||||
---
|
||||
# functions from area.h
|
||||
|
|
|
|||
|
|
@ -1083,7 +1083,7 @@ if (strcmp(command, #symb) == 0) { \
|
|||
if (paramCount != params) { LOG_LUA("gfx_set_command: '" #symb "' received incorrect number of parameters. Received %u, expected %u", paramCount, params); return 0; } \
|
||||
UNUSED const char symbolName[] = #symb; \
|
||||
REPEAT(HANDLE_PARAM, params); \
|
||||
Gfx _Gfx[] = { CALL_SYMB(symb, LIST_ARGS(GET_ARG, params)) }; \
|
||||
const Gfx _Gfx[] = { CALL_SYMB(symb, LIST_ARGS(GET_ARG, params)); } \
|
||||
memcpy(gfx, _Gfx, sizeof(_Gfx)); \
|
||||
return 1; \
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue