how to use the setmission command?

Talk about your new mod or map here

Moderators: jelco, bert_the_turtle

User avatar
cro5point
level1
level1
Posts: 15
Joined: Sun May 14, 2006 6:31 am

how to use the setmission command?

Postby cro5point » Thu May 18, 2006 2:30 pm

i want to make a level open when a player take over the trunk port in the first level

i have looked at a few other mods but im still not sure how it works

please help
User avatar
trickfred
level5
level5
Posts: 1691
Joined: Sat Jul 24, 2004 5:01 am
Location: The Great White North, Eh?
Contact:

Postby trickfred » Thu May 18, 2006 2:36 pm

...It's not that hard, really.

From game.txt:

Code: Select all

Locations_StartDefinition
   # Id  Avail                   mapFile                    missionFile
   # ==================================================================
      0    0                   map_test.txt                         mission_test.txt
      1    1                  map_maint.txt                  mission_maint_intro.txt
      2    1                 map_mp1138.txt                                     null


Maps 1 and 2 will be visible on the world map, map 0 will not. But, notice the mission file for map 2 is set to 'null' - so only map 1 will actually be available for selection on the world map. Map 2 will be greyed out, and inaccessible.

To make map 2 available for selection (and thus entrance), either call a script that has this line:

Code: Select all

SetMission mp1138 mission_mp1138_whatever.txt


Or, add this line to an event in game.txt:

Code: Select all

Action SetMission mp1138 mission_mp1138_whatever.txt


You can use this command to re-visit levels with different scenarios, or to create 'save points' partway through a level.

Return to “Mod Projects”

Who is online

Users browsing this forum: No registered users and 17 guests