From 219bee0410156ee4c27f7a29b171146a597efb74 Mon Sep 17 00:00:00 2001 From: entar Date: Tue, 10 Jun 2025 16:59:17 +0700 Subject: [PATCH] Add Stages --- Stages.md | 54 ++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 54 insertions(+) create mode 100644 Stages.md diff --git a/Stages.md b/Stages.md new file mode 100644 index 0000000..9fa0001 --- /dev/null +++ b/Stages.md @@ -0,0 +1,54 @@ +Stages are the backgrounds of songs. Every week has at least one stage. + +# How to make stages + +First of all you need a name for the stage. Here i will just use "something" + +## Start + +Then you need the sprites / images for backgrounds and background characters. Usually they are put into sprites/something folder or images/something folder. + +Dont forget that for sprites you need to convert the XML to a JSON file. + +## Middle + +You place something.json into the stages folder and add this stuff into it. It contains basic variables you will have to change for your stage. +``` +{ + "boyfriend": [0, 0], + "girlfriend": [0, 0], + "opponent": [0, 0], + + "camera_boyfriend": [0, 0], + "camera_opponent": [0, 0], + "camera_girlfriend": [0, 0], +} + +``` + +Then, you will have to script your images and sprites into the game yourself. I made a good API for this with image / sprite types so it isn't too hard. You can check some [existing stages](https://git.squog.ru/TaggedEngine/TaggedEngine/src/branch/main/stages/stageErect.lua) and the [type documentation](https://git.squog.ru/TaggedEngine/TaggedEngine/wiki/Types) for help. + +Also for more stage script manipulation you need to check the [Scripting Functions](https://git.squog.ru/TaggedEngine/TaggedEngine/wiki/Scripting) page. + +### Small example stage script: +``` +local myTypes = require("modules.types") + +local module = {} +function module.onCreate(song) + local back = myTypes.Image("images/stage/stageback.png") + back.layer = -10 + back.position = myTypes.Vector2(-800, 50) + + local front = myTypes.Image("images/stage/stagefront.png") + front.layer = -1 + front.position = myTypes.Vector2(-900, 1000) + + local curtains = myTypes.Image("images/stage/stagecurtains.png") + curtains.position = myTypes.Vector2(-1150, 50) + curtains.modifier = 1.3 + curtains.layer = 5 +end + +return module +``` \ No newline at end of file