This topic was published by Jarret Buse and viewed 1048 times since "". The last page revision was "".
- Topics - 25
NOTE: SuperTux v0.4.0 now includes a "climbable" object in the Level Editor.
You may look at the title and think, "Tux can climb?" Yes he can. Now you may wonder, "How do you do it?".
The way to do it to use a Class called "Climbable". Where is this in the SuperTux Editor? It isn't in SuperTux Editor 0.3.4-GIT. You have to do this manually.
So, on a level, create your Sector. Add some blocks for Interaction. Add Vines from the "Forest (Foreground)" section, a Ladder from the "Misc" section, a pillar from the "Misc" section or any object you want Tux to climb. Be aware that the climbable object should be placed in the Background.
Once you have the item in place, go to the Objects section and select the Script (Scripttrigger) block. Place the block on the climbable object and elongate it to cover the whole climbable object. Select the Script Trigger Object and the "Edit Script". Add a simple text entry such as "climbable". Save your level and exit the Level Editor.
Edit the STL file you created with a text editor and search for "climbable" that you added to the "Edit Script" section. You will see this shown in Figure 1.
Change "scripttrigger" to "climbable". Remove the "script" and "button" lines as shown in Figure 2.
Save the STL file, close the text editor and open the STL in the Level Editor. You can see the Climbable Object in Figure 3 which is yellow.
When played, Tux can now climb the ladder. Almost any object can be climbed when set to climbable.
The trick is to set only one object to Climbable initially. To add more, simply select "Object" in the left-pane, right-click the "Climbable" object (the yellow rectangle) and select "Clone". Another Climbable object will be placed on the existing one. Left-click on it and move it to where you need it. Remember to resize it if needed to your new Climbable tiles.
It is even possible to have Tux climb any wall, no vines or ladder needed. Tux can even climb sideways along a wall if you make the whole thing climbable. Do not make the air climbable since this would not appear normal to a player.
I will include to download a file called "Up We Go.stl" (http://dcjtech.info/wp-content/uploads/2015/10/Up-We-Go.stl_.zip). In the Sector you can see how things are done. Alter the Sector and make it your own.
Have fun making Tux climb the wall.
- Supertux Level Editor Articles (List) - http://dcjtech.info/topic/gaming/#supertux
- SuperTux2 Update (Version 0.4.0) - http://dcjtech.info/topic/supertux2-update-version-0-4-0/
Attachments:You must be logged in to view attached files.