View Full Version : Ending a SP-Level

07-08-2002, 10:37 PM
I want to let end my SP-Map after the player defeated the end-boss. How do I do this?????????

I tried to target the NPC to a target_level_change, but it didn't work...

PLZ, help if u can...!!!!!!!!!!!!!

07-09-2002, 12:54 AM
Any ideas???

PLZ help!!!!!!!!

07-09-2002, 03:56 AM
I wish I knew to help!!
I want to know too! , but I also want to know how to load the next level??


07-09-2002, 04:20 AM
Create a target_level_change. Give keyname map and your nextmap's name as value.

Create an area of trigger_once. Click its playeronly option. Then click that trigger_once entity first, and then the target_level_change. Press CTRL+K. Now they are connected.

When you trigger that your next map will be loaded.

Or you can do it by the boss defeat.
put your boss' NPC properties a key "NPC_target" and value "t_nextlevel"
then change your target_level_change entity's "targetname" as "t_nextlevel" too.

When you kill the boss you will advance to the next map.

Hmmm, i should give you an example of ending a level thou.

this zip has a map file and two script files(including txt files of the script files) . Unzip that into your gamedata/base directory.

You should have the pit4.map file in your gamedata/base/maps directory and the other files in your gamedata/base/scripts directory.

Open the script files (txt files) with Behaved to modify.

If you don't know how to use behaved then ask here.

07-09-2002, 07:43 AM
if u wanna end a level without moving to a new one use a s script like this

// Generated by DEvaheb v1.0

set ( "SET_PLAYER_LOCKED", "true" );
use ( "endcredit_music" );
wait ( 10000.000 );
set ( "SET_CLOSINGCREDITS", "true" );

the "endcredit_music" is just a target_playmusic entity that plays some dramatic music for when u kill the last guy in my level
if u just want credit to roll and the jk2 symbol to appear ignore it

if u want the credits to go shorter you'll have to make an edited version of the credits.sp to go woth your level

07-09-2002, 05:56 PM
THX a lot!!!!

I'll try it...!!!!!!!!!!!!

07-09-2002, 07:29 PM
There must be something to unload the map and go back to the main menu. I couldnt find yet. There is a menu changing thing but it doesnt work for now.

If you don't want to change the original ( leaving the original as original :D ), the only way to shorten Credits.sp is making a mod.
Take the credits.sp and modify it. Create a directory somewhere and under that create maps directory for your map files, scripts directory for your script files and strip directory for credits.sp.

Copy all your files to their corresponding directories ( modified credits.sp to the strip directory )

Then select all three directories and right click one of them. Select Add to zip and zip them in a file.

Change this zip file's extension to pk3 and put it in a directory in your gamedata directory. When you go to MODS section in the game you will see the directory's name which contains the pk3 file you made.

If it's only one in the list it has already been chosen. Click load button and then load your map. When you loaded the mod. All the original files like credits.sp are replaced by the files in the mod's pk3 file. Its not permanent. The game uses the mod's files until you quit the game.

I couldnt find how to unload a mod either :D