PDA

View Full Version : Mission Objectives



fatso784
August 12th, 2007, 03:20 PM
I am making my own singleplayer level, and it is going well; however, as much as I understand scripts, I cannot find a tutorial on how to create and display mission objectives. I believe it has something to do with a .hud_message_text file. If anyone can be of assistance, I would greatly appreciate it.

CtrlAltDestroy
August 12th, 2007, 03:24 PM
Yes, you are correct, it has to do with .hud_message_texts.

Tutorial by kornman: http://gbxforums.gearboxsoftware.com/showthread.php?t=49991

To display them ingame:

(show_hud_help_text true) - Enables hud text.
(hud_set_help_text TEXTNAME) - Text to display on hud.
(hud_set_objective_text TEXTNAME) - Text to display on pause menu.
(show_hud_help_text false) - Disables hud text. (Initial setting)

fatso784
August 12th, 2007, 03:31 PM
Ah thanks thats exactly what I was looking for! +Rep

edit: That worked perfectly, thank you. While I have this topic up, though, I'd like to ask another question. How do you make background music work in an sp level? I am aware of sound_looping_start, that's what I'm using now. However, when the player dies and goes to the last checkpoint, the looping sound stops and does not play again. How do you fix this? (There was a tutorial for background music on TheGhost's tutorial page, but the only link was to the closed HaloWiki. )

Gamerkd16
August 13th, 2007, 02:08 PM
Well this was the only music tutorial I could find. Does this help:


Scripting music in Halo: CE maps.
Warning: Scripting syncing requires use of bipeds and vehicles (or other crushing objects.) in order to work over the netcode. These methods will work for single player maps, or multiplayer maps built for just one person. Syncing over Halo’s netcode will most likely not happen unless you work with the bipeds and vehicles. Remember - death’s sync, most else does not.
Warning 2: This method will use AI, and will check for the status of AI. AI ***DOES NOT SYNC*** over the netcode. Don’t try, you will fail.
Tutorial:
This tutorial will assume that you have basic scripting knowledge, basic AI knowledge, can type with a keyboard, and can read. If you do not qualify for any of these needed qualities, please, do not hesitate to smash your face into your keyboard until you can no longer see.
What you’ll need:
1. A compiled .scenario tag that you can edit in Sapien. 2. A .sound tag that you have compiled with tool. This should be the music you want to play in-game. 3. AI actors and actor varients. If you don’t have these, check over at the files.halomods.com forums. Search around there for “Aztec’s Actors” or something like that, and download his actor and actor varient tags.
open the desired .scenario file in Sapien. Place your AI encounters and squads, and give them appropriate names. For this tutorial, I’ll call my encounter “tutleets1², and the squad name will be “uber.” No reason for the names. :P
Anyways, place the AI, and under the encounters block and the information for it, check the box that says “Not created automatically”, or something to that effect. You can skip the checking of the box, but for this script, we will use commands that place this encounter on the map at a certain time, instead of right away as soon as the game loads. This can come in handy once you work with trigger volumes/loading zones/multiple BSPs, and that sort of thing. Make sure you give your AI spawn points, check the required boxes, and make sure they have respawn enabled, and have their max/min actors set to something other than zero.
Now, load up *gasp* Notepad, and type the following (Note: DO NOT ADD *’s.) :
(script startup musicnai
(ai_place tutleets1) * (sleep_until (= (ai_strength tutleets1/uber) 0)) ** (sound_impulse_predict sound\music\madrigal true) *** (sound_impulse_start sound\music\madrigal none 1)) **** * This will place the AI that we decided to not create automatically. ** This will pause execution of the rest of the script until the give condition is true, or in other words, until your AI are all dead. *** This script will bring your sound or music file into the sound cache for your map. This has to be done before actually playing the sound, as far as I know. I’m assuming your file is found at sound\music\madrigal.sound for this. If you were to name your .sound file anything else, change “madrigal” accordingly in the script. **** This will start playing your music.
I believe that after the last command in the script, you can do a (sound_impulse_predict [sound location] false) command, to remove the song from the cache. But, I’m not sure if you’d have to run a sleep command first, or if you could just run it right after running the sound to begin with. That could stop the sound abruptly, but I’m not sure. Go ahead and experiment with this on your own.
After typing that, save the file as scripts.hsc in your levels\[your level]\scripts directory, or something like that. Go into Sapien, and go to File > Compile scripts. If it gives you any errors… well, try and fix them. I’m not a damn troubleshooting guide. :P
Of course, to play music, you don’t need AI or anything. You can use trigger volumes and things like that, but that gets just a tad more complicated. This is just basic scripting using an AI command or two.
Final note: This is a very basic way to play music in Halo: CE. I’m sure there are better, more elaborate ways, but this will get the job done.
Pkmnrulz240/Dark Cloud

Ki11a_FTW
August 13th, 2007, 02:37 PM
whats the script to put the little check mark next to the objective

fatso784
August 13th, 2007, 02:41 PM
You found the lost music tutorial from the halowiki! +Cookie lol

CtrlAltDestroy
August 13th, 2007, 03:22 PM
whats the script to put the little check mark next to the objective

It puts a check by the previous objective once you set a new objective IIRC.

Ki11a_FTW
August 15th, 2007, 09:40 PM
Yes, you are correct, it has to do with .hud_message_texts.

Tutorial by kornman: http://gbxforums.gearboxsoftware.com/showthread.php?t=49991

To display them ingame:

(show_hud_help_text true) - Enables hud text.
(hud_set_help_text TEXTNAME) - Text to display on hud.
(hud_set_objective_text TEXTNAME) - Text to display on pause menu.
(show_hud_help_text false) - Disables hud text. (Initial setting)

sorry for the little bump but what is TEXTNAME, were is the source

CtrlAltDestroy
August 15th, 2007, 10:00 PM
The name of your hud message text in the tag of the same type.