diff --git a/README.md b/README.md index c77a2fa..cf5b2d3 100644 --- a/README.md +++ b/README.md @@ -1,7 +1,11 @@ # VinTest — in-game testing framework for Vintage Story mods -| ![Demo](/docs/img/demo.png) | Make a mod for your mod that will test your mod while you mod it. | +| ![Demo: code](/docs/img/demo.png) | [Demo: CLI](/docs/img/demo-cli.png) | | --- | --- | +|Make a mod for your mod that will test your mod while you mod it.|| + +[![NuGet](https://img.shields.io/nuget/v/VinTest.svg)](https://www.nuget.org/packages/VinTest) +[![NuGet](https://img.shields.io/nuget/v/VinTest.Cake.svg)](https://www.nuget.org/packages/VinTest.Cake) **Documentation: https://artalus.github.io/vintest/** diff --git a/VinTest.Cake/README.md b/VinTest.Cake/README.md new file mode 100644 index 0000000..cc6657e --- /dev/null +++ b/VinTest.Cake/README.md @@ -0,0 +1,7 @@ +# [Cake](https://cakebuild.net/) integration for [`VinTest`](https://github.com/Artalus/vintest/) + +| ![Demo: code](https://github.com/Artalus/vintest/blob/main/docs/img/demo.png?raw=true) | [Demo: CLI](https://github.com/Artalus/vintest/blob/main/docs/img/demo-cli.png) | +| -------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------- | +| Make a mod for your mod that will test your mod while you mod it. | | + +**Documentation: https://artalus.github.io/vintest/** diff --git a/VinTest.Cake/VinTest.Cake.csproj b/VinTest.Cake/VinTest.Cake.csproj index c71b092..7a54519 100644 --- a/VinTest.Cake/VinTest.Cake.csproj +++ b/VinTest.Cake/VinTest.Cake.csproj @@ -15,7 +15,7 @@ - + diff --git a/VinTest/README.md b/VinTest/README.md new file mode 100644 index 0000000..f5a5984 --- /dev/null +++ b/VinTest/README.md @@ -0,0 +1,7 @@ +# Core package of [`VinTest`](https://github.com/Artalus/vintest/) + +| ![Demo: code](https://github.com/Artalus/vintest/blob/main/docs/img/demo.png?raw=true) | [Demo: CLI](https://github.com/Artalus/vintest/blob/main/docs/img/demo-cli.png) | +| -------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------- | +| Make a mod for your mod that will test your mod while you mod it. | | + +**Documentation: https://artalus.github.io/vintest/** diff --git a/VinTest/VinTest.csproj b/VinTest/VinTest.csproj index 8fe83b2..0827caa 100644 --- a/VinTest/VinTest.csproj +++ b/VinTest/VinTest.csproj @@ -15,7 +15,7 @@ - + diff --git a/docs/img/demo-cli.png b/docs/img/demo-cli.png new file mode 100644 index 0000000..e62b91a Binary files /dev/null and b/docs/img/demo-cli.png differ diff --git a/docs/index.md b/docs/index.md index bf47a06..f294cbc 100644 --- a/docs/index.md +++ b/docs/index.md @@ -5,7 +5,8 @@ hide: title: Home --- -![](/vintest/img/demo.png){ align=right width=400 } +
+
# VinTest @@ -32,3 +33,13 @@ VinTest is split into three "layers": ______________________________________________________________________ → [Quickstart](quickstart/getting-started.md) — add VinTest to an existing mod project step by step. + +
+
+ +![](/vintest/img/demo.png) + +![](/vintest/img/demo-cli.png) + +
+
diff --git a/docs/stylesheets/extra.css b/docs/stylesheets/extra.css new file mode 100644 index 0000000..2860dc6 --- /dev/null +++ b/docs/stylesheets/extra.css @@ -0,0 +1,48 @@ +/* Wide: text left (2/3), images stacked on right (1/3) */ +.home-columns { + display: flex; + flex-direction: row; + gap: 2rem; + align-items: flex-start; +} + +.home-columns .left { + flex: 2; +} + +.home-columns .right { + flex: 1; +} + +.home-columns .right img { + width: 100%; + display: block; +} + +/* Narrow: images side-by-side on top, then text below */ +@media (max-width: 960px) { + .home-columns { + flex-direction: column; + } + + .home-columns .right { + order: -1; + display: flex; + flex-direction: row; + gap: 1rem; + } + + .home-columns .right p { + flex: 1; + margin: 0; + } + + .home-columns .right img { + width: 100%; + } +} + +/* hide tag/release icon from site header as it makes no sense for now */ +.md-source__fact--version { + display: none; +} diff --git a/example/MyMod/Mod.cs b/example/MyMod/MyMod.cs similarity index 88% rename from example/MyMod/Mod.cs rename to example/MyMod/MyMod.cs index 32b03a7..0535164 100644 --- a/example/MyMod/Mod.cs +++ b/example/MyMod/MyMod.cs @@ -12,7 +12,7 @@ public void TurnIntoDrifter(IServerPlayer player) { try { - if (PositionIsNearbyEnough(player.Entity.Pos.AsBlockPos, new BlockPos(0, 0, 0))) + if (!PositionIsNearbyEnough(player.Entity.Pos.AsBlockPos, new BlockPos(0, 0, 0))) DoMagic(); } catch (Exception ex) diff --git a/zensical.toml b/zensical.toml index 7983e68..39a6d8b 100644 --- a/zensical.toml +++ b/zensical.toml @@ -36,6 +36,9 @@ nav = [ ] }, ] }, ] + +extra_css = ["stylesheets/extra.css"] + [project.theme] variant = "classic"