Skip to content

Commit

Permalink
Update docs.
Browse files Browse the repository at this point in the history
  • Loading branch information
eugeneko committed Dec 3, 2023
1 parent 9bd0e73 commit 56a4eb2
Show file tree
Hide file tree
Showing 3 changed files with 32 additions and 4 deletions.
15 changes: 14 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,19 @@ Run Editor:

Run Player:

Launch `Player.exe --pp path/to/sample-project/Project`
Launch `Player.exe`

## Portability of Resource Access

The engine needs to somehow locate project resources on launch.

By default, the engine attempts to find `Data`, `Cache` and `CoreData` folders next to the executable.
However, this behavior may be inconvenient during development:
* `Data` and `Cache` folders are located in `Project` folder,
* `CoreData` is located in `bin` folder of `rbfx` repository,
* The executable is located somewhere in CMake build folder.

This issue can be mitigated by having `ResourceRoot.ini` file.
See the comments in `ResourceRoot.ini` file in this repository for details.

![](/screenshot.png)
18 changes: 18 additions & 0 deletions ResourceRoot.ini
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
# ResourceRoot.ini should be located either in the same directory as the executable file
# or in any of the parent directories.

# Format of the file:
# alias1=relative/path/1
# alias2=relative/path/2
# ...

# When the engine is looking for a file, it will check these paths from last to first.

# It is recommended to use standard aliases in default order and only customize the paths:
# - CoreData: files from `rbfx/bin/CoreData` that should always be updated with the engine.
# - Data: project-specific files that are created and updated by a person.
# - Cache: project-specific files that are generated by the editor.

CoreData=../rbfx/bin/CoreData
Data=Project/Data
Cache=Project/Cache
3 changes: 0 additions & 3 deletions ResourceRoot.txt

This file was deleted.

0 comments on commit 56a4eb2

Please sign in to comment.