feat: samples default to local project reference, and can optionally use the nuget package
This commit is contained in:
parent
8739e3b347
commit
28179a995e
2 changed files with 22 additions and 2 deletions
|
|
@ -52,10 +52,14 @@
|
||||||
<Using Include="System.Numerics"/>
|
<Using Include="System.Numerics"/>
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
|
|
||||||
<ItemGroup>
|
<ItemGroup Condition="'$(UseRaylibCsPackage)' != 'true'">
|
||||||
<ProjectReference Include="..\Raylib-cs\Raylib-cs.csproj"/>
|
<ProjectReference Include="..\Raylib-cs\Raylib-cs.csproj"/>
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
<Import Project="..\Raylib-cs\Raylib-cs.targets"/>
|
<Import Project="..\Raylib-cs\Raylib-cs.targets" Condition="'$(UseRaylibCsPackage)' != 'true'"/>
|
||||||
|
|
||||||
|
<ItemGroup Condition="'$(UseRaylibCsPackage)' == 'true'">
|
||||||
|
<PackageReference Include="Raylib-cs" Version="$(RaylibCsVersion)"/>
|
||||||
|
</ItemGroup>
|
||||||
|
|
||||||
<ItemGroup Condition="'$(RuntimeIdentifier)' == 'browser-wasm'">
|
<ItemGroup Condition="'$(RuntimeIdentifier)' == 'browser-wasm'">
|
||||||
<WasmExtraFilesToDeploy Include="Web/index.html" TargetPath="index.html"/>
|
<WasmExtraFilesToDeploy Include="Web/index.html" TargetPath="index.html"/>
|
||||||
|
|
|
||||||
16
README.md
16
README.md
|
|
@ -96,6 +96,22 @@ internal static class Program
|
||||||
}
|
}
|
||||||
```
|
```
|
||||||
|
|
||||||
|
## Building the examples locally
|
||||||
|
|
||||||
|
The `Examples` project references the sibling `Raylib-cs` project by default, so local changes to the
|
||||||
|
bindings are picked up directly:
|
||||||
|
|
||||||
|
```
|
||||||
|
dotnet run --project Examples
|
||||||
|
```
|
||||||
|
|
||||||
|
To build the examples against the Raylib-cs NuGet package instead (the version set by
|
||||||
|
`RaylibCsVersion` in [Directory.Build.props](Directory.Build.props)), set `UseRaylibCsPackage`:
|
||||||
|
|
||||||
|
```
|
||||||
|
dotnet run --project Examples -p:UseRaylibCsPackage=true
|
||||||
|
```
|
||||||
|
|
||||||
## Contributing
|
## Contributing
|
||||||
|
|
||||||
Feel free to open an issue. If you'd like to contribute, please fork the repository and make
|
Feel free to open an issue. If you'd like to contribute, please fork the repository and make
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue