find_unity {unifir} | R Documentation |
Find the Unity executable on a machine.
Description
If the path to Unity is not provided to a function, this function is invoked to attempt to find it. To do so, it goes through the following steps:
Attempt to load the "unifir_unity_path" environment variable.
Attempt to load the "unifir_unity_path" option.
Assuming that neither points to an actual file, this function will then check the default installation paths for Unity on the user's operating system. If not found, this function will error.
Usage
find_unity(unity = NULL, check_path = TRUE)
Arguments
unity |
Character: If provided, this function will quote the provided string (if necessary) and return it. |
check_path |
Logical: If |
Value
The path to the Unity executable on the user's machine, as a length-1 character vector.
See Also
Other utilities:
add_default_player()
,
add_prop()
,
create_unity_project()
,
get_asset()
,
load_png()
,
load_scene()
,
new_scene()
,
read_raw()
,
save_scene()
,
set_active_scene()
,
validate_path()
,
waiver()
Examples
if (interactive()) {
try(find_unity())
}