mirror of
https://github.com/Ellpeck/TinyLifeExampleMod.git
synced 2024-11-22 12:03:28 +01:00
improve the run configurations
This commit is contained in:
parent
78486b7f60
commit
18366975a1
3 changed files with 14 additions and 4 deletions
|
@ -18,7 +18,7 @@ Since Tiny Life uses early versions of some of my libraries, you will also have
|
||||||
dotnet nuget add source https://nuget.ellpeck.de/v3/index.json --name "Ellpeck"
|
dotnet nuget add source https://nuget.ellpeck.de/v3/index.json --name "Ellpeck"
|
||||||
```
|
```
|
||||||
|
|
||||||
This repository also contains a little script called `Run.sh` that you can use to automatically build your mod, copy it into the `Mods` directory of your Tiny Life instance and run the game. Just be sure to modify all of the paths first.
|
This repository also contains a little `Run` script for [windows](./Run.bat) and [linux and mac](./Run.sh) that automatically builds your mod, copies it into the `Mods` directory of your Tiny Life instance and runs the game. Note that the script will only work correctly if you've previously launched Tiny Life manually.
|
||||||
|
|
||||||
The game's API is **fully documented**. The documentation is easily accessible by opening any of the API's files in your IDE. The most updated version can be found on [the wiki](https://github.com/Ellpeck/TinyLifeExampleMod/wiki) as well.
|
The game's API is **fully documented**. The documentation is easily accessible by opening any of the API's files in your IDE. The most updated version can be found on [the wiki](https://github.com/Ellpeck/TinyLifeExampleMod/wiki) as well.
|
||||||
|
|
||||||
|
|
11
Run.bat
Normal file
11
Run.bat
Normal file
|
@ -0,0 +1,11 @@
|
||||||
|
@echo off
|
||||||
|
rem move to the script directory
|
||||||
|
cd /d "%~dp0"
|
||||||
|
rem build the mod
|
||||||
|
dotnet build
|
||||||
|
rem copy the mod to the mods folder
|
||||||
|
robocopy ./bin/Debug/netcoreapp3.0/ "%LOCALAPPDATA%/Tiny Life/Mods" /e
|
||||||
|
rem run the game
|
||||||
|
set /p dir=<"%LOCALAPPDATA%/Tiny Life/GameDir"
|
||||||
|
cd /d %dir%
|
||||||
|
"Tiny Life.exe"
|
5
Run.sh
5
Run.sh
|
@ -1,6 +1,4 @@
|
||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
GAME_DIR="path/to/Tiny Life"
|
|
||||||
|
|
||||||
# move to the script directory
|
# move to the script directory
|
||||||
cd "$(dirname "$0")"
|
cd "$(dirname "$0")"
|
||||||
# build the mod
|
# build the mod
|
||||||
|
@ -8,5 +6,6 @@ dotnet build
|
||||||
# copy the mod to the mods folder
|
# copy the mod to the mods folder
|
||||||
cp ./bin/Debug/netcoreapp3.0/* "$LOCALAPPDATA/Tiny Life/Mods" -r
|
cp ./bin/Debug/netcoreapp3.0/* "$LOCALAPPDATA/Tiny Life/Mods" -r
|
||||||
# run the game
|
# run the game
|
||||||
cd "$GAME_DIR"
|
dir=$(<"$LOCALAPPDATA/Tiny Life/GameDir")
|
||||||
|
cd $dir
|
||||||
"./Tiny Life.exe"
|
"./Tiny Life.exe"
|
Loading…
Reference in a new issue