Game Development Community

Load Mission Code

by Andrew Van Orden · in Technical Issues · 04/11/2007 (2:24 pm) · 2 replies

I have been researching this but I cannot find what code to use to load a mission. I have a title screen that loads with a start button. What I need is to be able to load my mission from this button. Thanks for any help you can give me.

#1
04/12/2007 (10:11 am)
For the button command, put "loadMyMission();". If you open up your YourGameFolder/Main.cs file, there should be a function in there called "loadMyMission(). In that function there is a command, "createServer("SinglePlayer", expandFilename("./data/missions/gameonemission.mis"));" change it to "createServer("SinglePlayer", expandFilename("./data/missions/yourGameMission.mis"));", where "yourGameMission" is the name of your .mis file.

Also, in your example folder, there should be a "GettingStarted" tutorial that covers all that good stuff.
#2
11/07/2007 (6:44 am)
Hi people!

Supose I have a mission already loaded , and I would like to clean up this mission and than load another mission . ( As if the player had completed the level and goes to te next.) .

How can I do that ??