TSC
Text Scripts

TSC stands for Text SCripts. It is the scripting language of Cave Story. It allows cutscenes to work and many NPCs to have their behavior.

In TSC, numbers are always 4 digits long. Remember that. If you want to write 41, you need to write 0041.

We are going to make a door that directly connects Mimiga Village and Grasstown. To do this, open the Mimiga Village map then Map Menu > Edit Script.

You will see a bunch of TSC code. Insert this code snippet at the end of the file:
#0700
<KEY<SOU0011<DNP0700<FAO0004<TRA0006:0092:0011:0012
What does this TSC code do? Well first, <KEY locks out player controls, <SOU0011 plays sound #11, which is the open door sound. <DNP0700 deletes NPC 700, <FAO fades out the screen, and finally <TRA transports you to grasstown or any other map.

To make this code actually work, create a door entity (which is NPC 18) somewhere in Mimiga Village, preferably on the ground, and give it event number 700. You should also add some tiles around the door to make it look nice. Most importantly, make sure you set flag option 0x2000 - PC presses down to run script on the door so that it can run TSC event 700.

Door

And that is TSC. To see the full list of commands, go see the TSC Notes. Also, you may want to look at the detailed TSC Command Info.

Navigation
Previous Lesson: Tiles and Entities
Next Lesson: Flags
Table of Contents