From 54c6be05cd894d395499b8beafd72534d82ce433 Mon Sep 17 00:00:00 2001 From: Ellpeck Date: Mon, 14 Oct 2024 22:22:12 +0200 Subject: [PATCH] cleaned up docs, and added Yirggzmb's map tutorial --- docs/.htaccess | 1 + docs/articles/cheats.md | 4 ++-- ...nity_mod_tutorials.md => community_tutorials.md} | 11 +++++++---- docs/articles/creating_textures.md | 2 +- docs/articles/game_dir.md | 4 ++-- docs/articles/getting.md | 4 ++-- docs/articles/mod_basics.md | 13 ++++++++----- docs/articles/toc.yml | 12 ++++++------ 8 files changed, 29 insertions(+), 22 deletions(-) rename docs/articles/{community_mod_tutorials.md => community_tutorials.md} (75%) diff --git a/docs/.htaccess b/docs/.htaccess index 946c84e..0f05601 100644 --- a/docs/.htaccess +++ b/docs/.htaccess @@ -13,3 +13,4 @@ RewriteRule ^InGameNews(.html)?$ "https://tinylifegame.com/ingamenews" [R=301,L] RewriteRule ^articles/content_policy(.html)?$ "https://tinylifegame.com/content_policy" [R=301,L] RewriteRule ^articles/common_issues(.html)?$ "https://tinylifegame.com/common_issues" [R=301,L] RewriteRule ^articles/preview(.html)?$ "https://tinylifegame.com/preview" [R=301,L] +RewriteRule ^articles/community_mod_tutorials(.html)?$ "https://docs.tinylifegame.com/articles/community_tutorials.html" [R=301,L] diff --git a/docs/articles/cheats.md b/docs/articles/cheats.md index 0aa5206..2f8f048 100644 --- a/docs/articles/cheats.md +++ b/docs/articles/cheats.md @@ -1,7 +1,7 @@ # Cheats You can open up the game's cheat menu by pressing the `F1` key. Here is a list of some of the more useful cheats for mod development and testing. Keep in mind that `[arguments]` need to be replaced with your custom value, and the brackets `[]` need to be omitted. -## In-game cheats +## In-game Cheats - `ShowDebugActions` will enable a set of debug actions you can always select in-game, including teleporting to a certain location, adding people to your household, and more. - `ShowNonBuyable` allows you to buy plates, pots and the like. - `Need [name] [percentage between 0 and 1]` changes the current person's needs. @@ -35,7 +35,7 @@ You can open up the game's cheat menu by pressing the `F1` key. Here is a list o - `ResetLocation [name without spaces]` will clear the action queue of the given person and teleport them to their default location. For Tinies who live on a map, this is a location around their home. For lot staff or regular visitors, this is the closest exit road. This cheat is also available as a debug action (`ShowDebugActions`). - `Find [name without spaces]` causes the camera to focus on the person with the given name. -## Modding and debug cheats +## Modding and Debug Cheats - `EditWorld` allows you to place things outside of lots and adds the ability to add new lots to the world. You can find out more about editing the world in the [custom maps tutorial](custom_maps.md). - `Held [object name or null]` sets the current person's held object. You can find a list of all object names [in the API docs](xref:TinyLife.Objects.FurnitureType). - `EditCurrentActionSpot` turns on action spot edit mode, which allows you to easily edit the properties of the selected person's current action spot. diff --git a/docs/articles/community_mod_tutorials.md b/docs/articles/community_tutorials.md similarity index 75% rename from docs/articles/community_mod_tutorials.md rename to docs/articles/community_tutorials.md index 4a8fb1f..d2665cb 100644 --- a/docs/articles/community_mod_tutorials.md +++ b/docs/articles/community_tutorials.md @@ -1,12 +1,15 @@ -# Community Modding Tutorials -We want to use this section to showcase some of the tutorials and helpful bits of content that Tiny Life modders have created. +# Community Tutorials +We want to use this section to showcase some of the tutorials and helpful bits of content that Tiny Life custom content creators have created. Of course, please take care when using these resources, as their content may be incorrect or outdated. That being said, as far as we're aware, all of these resources abide by the [Tiny Life Content and Community Policy](https://docs.tinylifegame.com/articles/content_policy.html). -**If you're interested in having your content added to this page, please let us know on [the Discord server](https://link.tinylifegame.com/discordweb) or [submit a pull request](https://github.com/Ellpeck/TinyLifeWeb/blob/main/docs/articles/community_mod_tutorials.md).** +**If you're interested in having your content added to this page, please let us know on [the Discord server](https://link.tinylifegame.com/discordweb) or [submit a pull request](https://github.com/Ellpeck/TinyLifeWeb/blob/main/docs/articles/community_tutorials.md).** -## McChicky's Tutorials +## McChicky's Clothing Tutorials McChicky's tutorials have easy-to-follow descriptions and lots of screenshots, so they're especially recommended for people just starting out with Tiny Life modding. - [Creating a Basic Hair Mod from Scratch](https://docs.google.com/document/d/e/2PACX-1vShsxqDFy4TqvOG_eq5kpD5gnMvCJ4to0CdC_PnFHjfPTdVJIDMPbdsqVqI-hPHuMeYXMQitesvSbQ7/pub) - [Creating Multi-Colored Hair](https://docs.google.com/document/d/e/2PACX-1vRKkXlBlPozVQHQBdkihDJZLxwKQHyiHYJxXDjV05Q70ietByleY6DipTgfG0jaYftxSD92JeoPmDoj/pub) - [Understanding the Tiny Life Docs through Clothing Accessories](https://docs.google.com/document/d/e/2PACX-1vTQRMeR2eNb74xLGVZk_2JkFC_WhhchmopujRBUVHrU8GZCGYUltfML9-neQVnmaKuv4Co_souSH6Ve/pub) + +## Miscellaneous Tutorials +- Yirggzmb's guide for [creating custom maps](https://yirggzmb.github.io/tinylife/mapcreation.html), which goes much more in-depth than [ours](custom_maps.md) diff --git a/docs/articles/creating_textures.md b/docs/articles/creating_textures.md index c55b869..5aa343d 100644 --- a/docs/articles/creating_textures.md +++ b/docs/articles/creating_textures.md @@ -1,7 +1,7 @@ # Creating Textures When creating textures, either for custom mods or to change the game's default textures, there are several things that you will have to look out for. This article provides some guidelines and explanations. Note that this article is not exhaustive, so don't hesitate to [let us know](https://link.tinylifegame.com/discordweb) if there's anything you're confused by! -## General notes +## General Notes - Items that should be able to have color schemes applied to them in games should use a grayscale texture. The individual colors will then be applied to the grayscale texture when drawing. - When making a mod, the layout, size or positioning of custom texture regions generally doesn't matter. There are some exceptions to this, which will be noted in this article. - Items that should be able to have multiple distinct color schemes applied (like a table with a stone surface but wooden legs) need to be split up into multiple layers, with each layer being colored by its corresponding color scheme. These layers need to be laid out **horizontally**, with the `n`th layer of the item being placed `n * width` pixels to the right of the base layer's position. diff --git a/docs/articles/game_dir.md b/docs/articles/game_dir.md index df82b4b..ae9f2d5 100644 --- a/docs/articles/game_dir.md +++ b/docs/articles/game_dir.md @@ -8,10 +8,10 @@ Tiny Life's data folder contains several useful folders and files: There are several ways of locating this folder, and its location differs based on the operating system you're using. -## From within the game +## From Within the Game You can open the data folder easily from within the game by going to the options menu and opening the rightmost tab ("Custom Content"). The tab contains a button to quickly open the data folder. -## From your computer +## From Your Computer ### Windows On Windows, you can simply open a file explorer window and paste the following text into its location field: ``` diff --git a/docs/articles/getting.md b/docs/articles/getting.md index f12b414..91b982e 100644 --- a/docs/articles/getting.md +++ b/docs/articles/getting.md @@ -1,12 +1,12 @@ # Getting Custom Content You can get custom lots, households and mods from [the Steam workshop](https://steamcommunity.com/app/1651490/workshop/), [the Discord server](https://link.tinylifegame.com/discordweb) and more. -## Installing from Steam workshop +## Installing from Steam Workshop To install a mod or other custom content from the Steam workshop, all you have to do is select the item you want to install, and then press the big green "Subscribe" button! After a few seconds or after restarting the game, the item should appear in-game. If there are any errors or your items don't appear in-game, it'll be logged in the most recent file in the `Logs` folder in the [game folder](game_dir.md). -## Installing manually +## Installing Manually Installing a mod or other custom content is pretty simple: - Open the `Tiny Life` folder by following [this simple guide](game_dir.md#from-within-the-game). - Find the `Mods` (or `Custom Lots`, `Custom Households` or `Custom Maps`) folder. diff --git a/docs/articles/mod_basics.md b/docs/articles/mod_basics.md index 1245b7f..30baf55 100644 --- a/docs/articles/mod_basics.md +++ b/docs/articles/mod_basics.md @@ -1,7 +1,7 @@ # Modding Basics This page sums up a few of the basics that you'll need to know if you want to make a mod for Tiny Life. -## Creating mods +## Creating Mods Tiny Life mods are created using the .NET platform and the C# programming language, which means you need to have the [.NET SDK](https://dotnet.microsoft.com/en-us/download) installed. You can find the required version in the [dependency version history](#dependency-version-history) below. To create a mod, all you have to do is create a repository [from this template](https://github.com/Ellpeck/TinyLifeExampleMod) by pressing the green "Use this template" button. Then, you can open the project contained in it using Visual Studio, Rider or any other kind of C# IDE. The code that is already there contains some examples. Once you're done checking them out, you can just delete them and start fresh. @@ -14,20 +14,23 @@ The game's API is **fully documented**. The documentation is easily accessible b If you have any questions, don't hesitate to [ask on the Discord](https://link.tinylifegame.com/discordweb) or [start a discussion](https://github.com/Ellpeck/TinyLifeExampleMod/discussions) about it. -## Distributing mods +## Distributing Mods To distribute your mod to other people, you can simply run `dotnet cake --target Publish`. This task will automatically create a `zip` archive that you can share. If you want other players to try out your mod, you can also share it on [the Steam workshop](https://steamcommunity.com/app/1651490/workshop/). To do so, make sure you have Steam open in the background, and make sure that your mod's `zip` archive is in the game's mods folder. Then, go to the rightmost tab in the game's Options menu and select "Share Mod on Steam Workshop", and then follow the instructions there. It's recommended that, in addition to Steam workshop, you also publish your mod elsewhere, like on GitHub releases or [the itch community](https://itch.io/board/1032686/mods), as not every player has access to Steam workshop. -## Updating mods +## Updating Mods To change the version of Tiny Life that your mod is compiled against, simply go into [the project file](https://github.com/Ellpeck/TinyLifeExampleMod/blob/main/ExampleMod.csproj) and change the `TinyLifeApi` version. Note that some other dependencies might also have been updated, which needs to be [taken into account](#dependency-version-history). -## Where's the source code? +## Where's the Source Code? The NuGet package for the Tiny Life API just contains a [reference assembly](https://docs.microsoft.com/en-us/dotnet/standard/assembly/reference-assemblies) so that people can't just download the game from NuGet and play it. Since most of the public API is documented, you won't have to look at the source code in most cases, anyway. Technically, you can [download the game](https://tinylifegame.com/) and then decompile it to see the implementation's code, but due to its license, copying it is not allowed. -## Dependency version history +## Dependency Version History Since the mod is compiled against the same dependencies as Tiny Life, it also needs to have the same versions of those dependencies for mods to work correctly with the game. Each update to the template repository is [tagged](https://github.com/Ellpeck/TinyLifeExampleMod/tags) with the game's version number. If you want to develop for a certain version, just check that tag's [project file](https://github.com/Ellpeck/TinyLifeExampleMod/blob/main/ExampleMod.csproj) to see the required dependency versions, as well as the required .NET version. + +## What Next? +Go crazy with your ideas! If you're looking for inspiration, you can check out the [community tutorials](community_tutorials.md) article or play around with [other players' mods](getting.md). diff --git a/docs/articles/toc.yml b/docs/articles/toc.yml index d572ae7..fde3565 100644 --- a/docs/articles/toc.yml +++ b/docs/articles/toc.yml @@ -1,13 +1,9 @@ -- name: Advanced Playing +- name: Advanced Gameplay - name: Tiny Life's Data Folder href: game_dir.md - name: Cheats href: cheats.md -- name: Community -- name: Contributing Localizations - href: localization.md - - name: Custom Content - name: Getting Custom Content href: getting.md @@ -19,5 +15,9 @@ href: mod_basics.md - name: Creating Textures href: creating_textures.md + +- name: Community +- name: Contributing Localizations + href: localization.md - name: Community Tutorials - href: community_mod_tutorials.md + href: community_tutorials.md