Modding:Content Tutorial Item Variants: Difference between revisions
mNo edit summary |
(Beginning tutorial) |
||
Line 3: | Line 3: | ||
{{GameVersion|1.19.5}} | {{GameVersion|1.19.5}} | ||
__FORCETOC__ | __FORCETOC__ | ||
== Introduction == | == Introduction == | ||
=== Objective === | === Objective === | ||
In this tutorial, you will | In this tutorial, you will create a set of items using variants, each with independent textures. Our items will not have any functionality, however this tutorial should give you a good understanding of what variants are and how to use them. | ||
=== Assets === | === Assets === | ||
Before starting, it is recommended you [https://github.com/Nateonus/vsmodexamples/releases/tag/ItemVariantsTutorial download the workspace and assets] for this tutorial. The completed files can also be found here. | |||
This tutorial starts with the following assets: | |||
This tutorial starts with the following assets: | |||
* Mod Setup & Folder Structure | * Mod Setup & Folder Structure | ||
* | * Template advanced wand file | ||
* | * Completed lang file | ||
* Item shape file | * Item shape file | ||
* Item texture | * Item texture files | ||
=== Prerequisites === | |||
This tutorial will assume you understand the following topics: | |||
* [[Modding:Developing a Content Mod|Setting up a content mod and using an IDE.]] | |||
* [[Modding:Content Tutorial Basics|The functions of shape, texture and lang files.]] | |||
It is recommended to have completed the following tutorial: | |||
* [[Modding:Content Tutorial Simple Item|2. Simple Item]] - The simple item made in this tutorial is the basis for this tutorial. | |||
It is recommended, but not necessary, to understand the following concept: | |||
* [[Modding:Variants|Variants]] | |||
== Navigating Assets == | |||
Using the downloaded workspace, have a look at the mod assets that currently exist. | |||
* ''itemtypes/advancedwand.json'' - The itemtype file from the [[Modding:Content Tutorial Simple Item|Simple Item]] tutorial. | |||
''' | * ''lang/en.json'' - This already contains the entries needed for the tutorial. | ||
* ''shapes/item/advancedwand.json'' - The shape file for the new wand. If you open this file in your IDE, you should notice that this new model takes in two textures - ''head'' and ''handle''. | |||
<syntaxhighlight lang="json"> | |||
"textures": { | |||
"head": "item/wand-blue", | |||
"handle": "item/wand-handle" | |||
}, | |||
</syntaxhighlight> | |||
* ''textures/item/wand-...'' - The four texture files for our wand. Notice that there exists 3 variants of colored texture, and 1 handle texture. | |||
== Adding an Item == | == Adding an Item == |
Revision as of 22:34, 30 March 2024
This page was last verified for Vintage Story version 1.19.5.
Introduction
Objective
In this tutorial, you will create a set of items using variants, each with independent textures. Our items will not have any functionality, however this tutorial should give you a good understanding of what variants are and how to use them.
Assets
Before starting, it is recommended you download the workspace and assets for this tutorial. The completed files can also be found here.
This tutorial starts with the following assets:
- Mod Setup & Folder Structure
- Template advanced wand file
- Completed lang file
- Item shape file
- Item texture files
Prerequisites
This tutorial will assume you understand the following topics:
It is recommended to have completed the following tutorial:
- 2. Simple Item - The simple item made in this tutorial is the basis for this tutorial.
It is recommended, but not necessary, to understand the following concept:
Using the downloaded workspace, have a look at the mod assets that currently exist.
- itemtypes/advancedwand.json - The itemtype file from the Simple Item tutorial.
- lang/en.json - This already contains the entries needed for the tutorial.
- shapes/item/advancedwand.json - The shape file for the new wand. If you open this file in your IDE, you should notice that this new model takes in two textures - head and handle.
"textures": {
"head": "item/wand-blue",
"handle": "item/wand-handle"
},
- textures/item/wand-... - The four texture files for our wand. Notice that there exists 3 variants of colored texture, and 1 handle texture.
Adding an Item
(The above heading is counted as a 'step'. I recommend following a method of 'do', 'analyse', 'experiment' for each step to improve modder's knowledge and understanding.)
Creating our Item
Testing our Item
Try it out...
Conclusion
Congratulations, you have now (created your first item...)! This tutorial should have given you some understanding of (blah blah blah).
Next Steps...
Try out the next tutorial, (link). This will show you how to create a (...)!
Content Modding | |||||||||
---|---|---|---|---|---|---|---|---|---|
Basics | Content Mods • Developing a Content Mod | ||||||||
Tutorials |
|
||||||||
Concepts | Modding Concepts • Variants • Domains • Patching • Remapping • World Properties | ||||||||
Uncategorized |
|
Wondering where some links have gone?
The modding navbox is going through some changes! Check out Navigation Box Updates for more info and help finding specific pages.
Modding | |
---|---|
Modding Introduction | Getting Started • Theme Pack |
Content Modding | Content Mods • Developing a Content Mod • Basic Tutorials • Intermediate Tutorials • Advanced Tutorials • Content Mod Concepts |
Code Modding | Code Mods • Setting up your Development Environment |
Property Overview | Item • Entity • Block • Block Behaviors • Block Classes • Block Entities • Block Entity Behaviors • World properties |
Workflows & Infrastructure | Modding Efficiency Tips • Mod-engine compatibility • Mod Extensibility • VS Engine |
Additional Resources | Community Resources • Modding API Updates • Programming Languages • List of server commands • List of client commands • Client startup parameters • Server startup parameters Example Mods • API Docs • GitHub Repository |