Star Trek Voyager: Elite Force

Note: this document assumes that you are familiar with using EFRadiant (or the Quake equivalent) and have BehavED and have read the ICARUS Manual.

“How Do I…”

Modify game content:

Create all the stuff you want to replace in the proper subdirectories in the baseEF directory.

(for instance: models/players/munro/munro_face.jpg)

Now, zip all this up and be sure to recurse subdirectories.

Now you should have a .zip file in your baseEF directory that contains all the files you made. Simply rename the .zip to .pk3. Now Elite Force will load your new stuff over the stuff in the pak0.pk3. This is because EF will only override the pak0.pk3 data with data it finds in other .pk3's.

However, if you're playing online, you may not want extra pak files in your baseEF (because EF will always load these extra modded pk3's and if these .pk3 files overwrite any data in the pak0.pk3, this will potentially render your game "impure" and you wouldn't be able to join any servers that didn't have the same exact pk3 files you did). So, in this case, you want to make another directory in your Elite Force directory- call it, for example, "mymod". Now in your Elite Force directory, you should have a baseEF directory containing the game's original pak0.pk3 and a separate directory called "mymod" containing your new, modified pk3 file. See

Start the game using a mod:

Ideally, a modder should provide proper installation instructions or an installation program/batch file. If they didn’t (or if you’re a modder and want to know how to make a good installation readme or program/batch file), read this section.

Where do mods go?

Any mod you’ve downloaded should be a .pk3 file. Every mod should have its own directory in the directory in which you installed Elite Force. In your Elite Force directory, you should have a baseEF directory containing the game's original pak0.pk3 and separate directories containing your modified pk3 files. (The only possible exception to this are .pk3 files that don’t replace anything in the original game, just add things- like new maps. These .pk3 files can just be dropped in the baseEF directory, but it’s hard to know if a .pk3 file replaces something in the original game- it may be safer to keep all your extra downloaded maps in their own directory.)

There are two ways to use these mods:

From in the game:

Go to the “mods” menu and select the directory name of the mod you want to load. The game will quit and restart with the selected mod loaded. (NOTE: the initial release of Elite Force single player did not have a “mods” menu, that has been fixed in the patch- if you don’t have a “mods” menu in your single player game, use the next method below to load a mod.)

From a shortcut or batch file or command line:

To start the game using your pk3 file to override what the game uses by default, start the game with the command line parameter +set fs_game modname (“modname” should be the directory the modded .pk3 file is in).

So the command to start the game would look like:

Stvoy.exe +set fs_game modname

You can put this in a shortcut or batch file or whatever you want. This way, when you run the single player game, you can use whatever mods you want, but when you start the multiplayer game, your game will be pure (unmodified) and you will be able to join any server.

Note that you can only load one mod at a time. If you want to combine multiple mods/.pk3 files, put the multiple .pk3 files in one directory. For example, say you downloaded three new maps and want to be able to have them all loaded at once. Say they’re named “ctf_lava.pk3”, “ctf_arugula.pk3” and “ctf_skippy.pk3”. Instead of having a separate directory for each of these, just make a directory called “newmaps” and put all three .pk3 files in there. Then just load the “newmaps” mod and all three maps will be available. Note, though, that if any of these maps overwrite some data that the other is using, it might look a bit weird.

See all the console commands in Elite Force

Type cmdlist at the console to see all the console commands.

Make a brush entity move:

Anything that rotates or moves through scripting has to have an origin. To give a brush entity an origin, make a brush with the origin texture on it and make that part of the brush entity. The center of that origin brush will be the origin of the brush entity.

Defeat the final boss:

The trick is to keep moving and hit him with everything you’ve got. If that just isn’t working for you, use the invincibility cheat.

Be invincible:

Bring down the console.

Type “sv_cheats 1”

Then type “god”.

You’re now invincible.

Replace a skin that is in the game:

The best way is to extract what you want to replace from the pak0.pk3 file, modify it, then zip it back up (using WinZip) and rename the .zip as a .pk3 file. Then the game will automatically read it from the .pk3 file and replace the skin that was in the pak0.pk3. However, since you are replacing data that came in the pak0.pk3 file, your game is now "impure" and you won't be able to join any servers that aren't using the same exact set of .pk3 files as you (to prevent cheating).

Make it so the player can go back and forth between levels:

Well... kind of, but not really. All or our previous games had this kind of "hub" system where you could go back and forth between levels, but for Elite Force it was decided that we would never need this capability. It can be done, however- if, when the player leaves a level, you save the game, then, when returning to the level, you load the savegame... that's what we do with the holodeck. Problem is, the player is reset to however he was when he saved the game. So, the short answer is: no, not really.

Script it so that I can disable all the Borg in an area:

The Borg deactivation is done a lot on Borg1. Basically, all we did is this:

Target the disnode at a target_scriptrunner. When the disnode is destroyed, it will use the scriptrunner. The scriptrunner will affect each borg in the area (by NPC_targetname) and run the "borg1/disable" script on it (we released all our scripts- take a look at this one in BehavEd to see what it did to the borg). That's all!

Convert a 3ds MAX environment to an Elite Force map in EFRadiant

i think i have seen some plugins for MAX to export in a quake style .map file.

that is the only way to get max geometry into the game, convert it to the map format and then use our normal map editing and compiling.

What’s the purpose of the caulk texture?

It's basically a wall that is not only invisible, but stops anything behind it from being drawn. You'll get the HOMM effect if you look at it. I think its purpose was to be put behind curves (which don't block visibility).

How do you do the tracking camera shot?

Did you read the ICARUS Manual? If not, I strongly recommend it.

Essentially, to set up a scene, you have to first script your NPCs to do what you want. If it's walk down a hallway and talk, then do that. Give them navgoals and lines to say and run it a few times until you've got what you like.

Next, you place ref_tags in the world where you want the cameras to be.

In your script, you enable the camera and set it's origin at whatever ref_tag you want it to be at. Set the angle to whatever you want (or use the FOLLOW command to make the camera stay pointed at a specific group of NPCs- those NPCs all have to have the same "cameraGroup" value).

Now, to make it track, you set up a linked path of path_corners in the map and issue a TRACK command to the camera, specifying the first path_corner. Then, to make it follow at a fixed distance, you set a DISTANCE command- this will make the camera stay on that TRACK at a given DISTANCE from the group of entities you told it to FOLLOW.

It may sound complicated, but that's because you're trying to take it all in at once. Start simple, just get the NPCs to do stuff first. Then play around with just placing cameras and enabling and disabling the camera, etc. Take it one step at a time and you should be able to pick it up pretty well.

Make an NPC respond to me when I use him:

First, of course, I suggest reading the ICARUS Manual.

Okay, place the NPC in the map. Set his spawnscript to something like "neelix_spawn".

In his (Neelix's) spawnscript ("neelix_spawn") you need to do two things:

1) set SET_PLAYER_USABLE to true. This means that when the player hits his use button while looking at this NPC, the NPC will run his "usescript".

2) set SET_USESCRIPT to whatever the name of the script is that Neelix has to run when you use him (for example, name it "neelix_use").

Then, create another script called "neelix_use" and have it do this:

1) sound( CHAN_VOICE, "sound/voice/neelix/misc/intro.wav" ) - This will tell neelix to play the specified sound on his voice channel (which means he'll move his lips, etc, to match the sound).

That's essentially it. To make him wait for the sound to complete before continuing with the script, just put the sound command in a task and dowait for the task to complete before continuing. You can also, at this point, change Neelix's usescript to some other script so that the next time you use him, he does something different (tells you to bug off, for instance).

Make an NPC say something without using a sound file:

You can't. The only way to get an NPC to say something is to use the sound command in a script. The sound command must use the CHAN_VOICE or CHAN_VOICE_ATTEN (meaning it attenuates much faster) and it must point at a valid .wav or .mp3 file.

NPCs will also use generic responses that are coded into the game itself when you use them or sometimes when you block or shoot them. But these are still sound files (you will find them in each character's "misc" sound directory.

Use MD3View to see how I’m changing a model/skin?

Simply make a copy of all the data in the directory of the model you want to use. Replace the .tga/.jpg files. You can modify the .skin files to point to whatever new directories you want (some of the .skin files will pull .tga/.jpg files from several different directories since we reuse textures often). Then just open the lower.mdr in MD3View. It will automatically open and attach the torso and head models. You can then use the mouse to rotate and move the model. I believe there is some documentation with MD3View that indicates how to use it?

Make an NPC walk back and forth between two points

First, read the ICARUS Manual.

Now: to get an NPC to run a specific script- set his usescript to the name of the script you want him to run (for example: "common/backandforth"). Then, have something use the NPC (either have a trigger whose target value is the same as the NPC's NPC_targetname, or set the NPC to be directly usable by the player and just walk up to him and hit use or even just use the NPC from another script). When an NPC is used, it will run whatever script it's usescript is set to.

Place and point a camera:

First, read the ICARUS Manual.

Now:

Place a ref_tag in the map where you want the camera to be and give it a targetname (say, for example, "cam1").

Then put a info_null in the map where you want the camera to point. Target the ref_tag at the info_null.

Now, in a script that gets run (either off a trigger or by a target_scriptrunner that gets use by some event), do this:

Enable the camera with this command:

camera ( DISABLE )

Move the camera to the ref_tag like so:

camera ( MOVE, tag( "cam1", ORIGIN) )

You need to know how to use BehavEd to do these things- for example, in the above:

Double-click on the "camera" command to put it in the script window

Double-click on in in the script window to change which camera command you want to use (in this case, choose "MOVE")

Then hit the re-evaluate button- two new boxes will appear (for a total of 3), the first is where the camera goes and the second is how many milliseconds it takes to get there.

Click on the second box's "Helper" button and you get more choices

By the "Tag" box, make sure "ORIGIN" is selected and click on "Tag". It will fill in the proper command format for using a ref_tag to place a camera.

Now, in the that second box (where it now says "tag( "targetname", ORIGIN)", replace "targetname" with the targetname of your ref_tag (in our example, this is "cam1").

There you go! You've now moved the camera to a ref_tag.

NOW. To point it at the right angle, the proceedure is similar. Use this command:

camera ( PAN, tag( "cam1", ANGLE) )

Just make sure that when you hit the "Tag" button in the second box that the "ANGLE" option is chosen (otherwise, it will try to use the origin as an angle and that would be bad).

Now you can do whatever you want- zoom in/out, pan, fade, shake, etc. When you're done with the camera, turn it off by using this command:

camera ( DISABLE )

what can cause a character NOT to turn? its purly random and disrupts the whole cinematic

If the character has an enemy, he will face the enemy and ignore turn commands. Safest bet: set ignoreenemies to true for him.

.)is it possible to assign textures with different or user made "step-sounds" ? for example: snow,grass,fabric,......
yes I believe it's one through the shader files

.)is it possible to assign different areas/nodes with different looped environment sounds(atten.-1 but looped) ? for example: indoor-machinehall & indoor-office & outdoor-streetsound & ......
yes you can do this with trigger_multiples that have a soundSet on them (and are player only triggers), then place them to transition sounds as you move from one area to the next

.)textures/faces where players dont get fallingdamage, no matter from how high he jumps at? (avaliable on "SIN")
it's called "cushion", just place it as an invisible brush a couple of pixels above the floor

.)is it possible to assign different areas/nodes with different gravity-values in one map ?
again trigger multiples targeting gravity entities (forget what they're called right now), this is what I did in External Stimuli

.)snow and rain in multiplayermaps no matter of gfx system ?
no

.)real,movable dynamic light´s & spots ?
nope, not in this engine (except for misc_dlight)

.)is it possible to limitate the distance how far the engine can see (like "distcull" in one of raven´s masterpieces SoF)
no?

Make the NPC run the script I wrote?

Right, the script will not magically run itself. It has to run from an NPC or a target_scriptrunner. Make the script Tuvok's usescript then use him or make it a target_scriptrunner's usescript and use that script (from, say a trigger the player walks through)

Otherwise, the script looks fine (though I wouldn't pack more than one command into a task- it should still work)

Also, obviously, make sure you have waypoint_navgoals in your map with the correct names.

Jesus! Okay, here we go...

First of all, I'm going to expect that you have read the ICARUS Manual and a tutorial on using EFRadiant (go to www.q3radiant.com for some very good ones).

Secondly, I recommend looking at some of the uncompiled maps and scripts we released to see how we did some of this stuff.

Now, that said, I'll give a brief response to each question on how to do what you want- assuming you've got some basis of knowledge from the steps above:

1 - How can i make elevators that start when you press a console
Most of our elevators are simply func_doors with the toggle spawnflag turned on. That means, each time the func_door is used/triggered, it will go to it's other position. So, here's what you do:

Make a func_door.
Make a console.
Make a trigger_multiple in front of the console. Target the trigger_multiple at the func_door. Turn on the "usebutton" spawnflag on the trigger (this means that the playe rmust not only be standing in the trigger to fire it, but also holding down the "use" button). That's it, basically. Every time you hit the use button while in the trigger, it will use the func_door and make it move. When you get more into this kind of thing, you can start to add sound effects, delays, waits, console screen changes, etc.

2 - How do i make a console that makes sound when you push it or...activate a elevator
Easy, same as above, just target the trigger at a target_speaker as well (or instead). The target_speaker simply has to have a sound key that points to the desired sound.

3 - How can i let the character say something (in text an/or speech) when you walk on a certain spot ?
Put an NPC where you want them to be.
Give them an NPC_targetname (for this example, it's "Neelix").
Give them a usescript (for this example, it's "test/neelix_talk").
Now, Make a trigger_once at the spot where you want the player to trigger the NPC to talk. Set the target of the trigger to the NPC's NPC_targetname (again, "Neelix")
Now, make the neelix_talk script in the "test" subdirectory of the real_scripts directory (under baseEF).
In that script, simply use the sound command like so:

sound ( CHAN_VOICE, "sound/voice/neelix/intro.wav" )

That's it. If you want to wait for him to finish the sound before continuing with the script, just put the sound in a task and dowait the task.

4 - How can i make npc's say something when you talk to them, or maybe walk away or something

Same as above. When the player hits the "use" button on someone, he'll say their name (if he knows it- that's all hardcoded into the game itself). If you set the NPC to be usable by the player, the NPC will run it's usescript when the player "uses" him. You can then run the same "talking" script I described above, except append at the end a couple commands to make the NPC walk away. This would be something like this:

task("walktoconsole")
{
set ( SET_NAVGOAL, "console" )
}
set ( SET_BSTATE, BS_WALK )
dowait ( "walktoconsole" )

That's it!

5 - How do i make a npc walk to random directions

"Random" is not really random. You can Have 4 or 5 different navgoals and use the "if" and "else" and "random" features of the ICARUS command set to do this... or you could lay down a waypoint network and put the NPC into a BSTATE of BS_WANDER (this actually works very well).

6 - How can it be that i was planning to ask 3 questions and ask 6 ?

Standard rule of programming- every estimate should be doubled.

Map your own face into the game?

Yes, this is doable. First, open up the pak0.pk3 and extract the files (keeping directory info) you need to replace- say, for instance, munro's head and face .jpg's.

Now, scan in your picture, and cut and paste it into the .jpg's you extracted according to your artistic ability.

Now, just .zip the files back up (retaining the directory structure), then rename the .zip as a .pk3 (pk3's are really just .zip files).

Now you can distribute your .pk3 with your face on Munro as a "mod

Make an NPC appear/disappear?

When you want to get rid of an NPC, use the remove( "<name>" ) script command. The <name> part is the NPC_targetname of the NPC you want to get rid of (or "self" if you want to get rid of the NPC running the script).

Now, for a cinematic Munro, do this:

give the NPC_munro a spawnscript that makes him invisible and nonsolid (the script common/invis_cinematic does this- look at it). Note that the NPC_munro can't have an NPC_targetname of "Munro"- that is *always* the player- name him "MunroCin" or something like that.

Then, when you want to start the cinematic (say, when the player hits a trigger), just affect the NPC_munro and make him visible (and solid, if you want) and do your cinematic as normal.

When you're done with the cinematic, just use the remove command on him.
eg:
remove( "MunroCin" )

That's it, he's gone for good!

I tried what you said and got my scripts set up, character in Radient set up etc but as soon as the map loads the NPC just dies.

Okay, step by step:

Place the info_player_start somewhere else.

Place a ref_tag 24 units above the ground (3 lines in the z-checker bar). Give it a targetname of, for example, "playerhere". This is where you want to place the player once your cinematic is done.

Now, in your script, at the end of the cinematic, affect "Munro" (the player) and do this command:

set ( SET_ORIGIN, tag( VECTOR, "playerhere" ) )

To access a tag, hit the helper button next to the edit box in the set_origin window. Then hit the tag button.

Another, (maybe easier) way to do this is this:

Set the cinematic munro (say his name is "MunroCin") to invisible and not solid, then affect "Munro" and do this:

set ( SET_COPY_ORIGIN, "MunroCin" )

This will move the player to where the Munro NPC is, now you can remove the Munro NPC.

once i have a npc in a map, and a script build, how do i get the npc to read the script? what should i put in the entry info box?

Depends when you want him to run it. If you want him to runit when he spawns (which, btw, is before the player spawns), you make it his spawn script, like so:

key:
spawnscript

value:
test/myscript

(assuming your script is called "myscript" and is in a subdirectory of real_scripts called "test")

If you want him to run it when he's "used" (triggered), make it his usescript. If you want him to run it when he gets shot, make it his painscript, etc.

be sure to read the ICARUS Manual

ok, i have a nice script made all up, but how do i get nav points set up so the person will walk them? I saw way points in there

First, create a system of waypoints, linked to each other. It's important to remember that no two waypoints can have the same targetname and that you can have a waypoint point to up to 4 other waypoints (target, target2, etc.) and have up to 4 other waypoints point at one waypoint- but 8 total links is the max.

They should be set up so that you don't use a whole lot of them, but each one has a clear path to the next one (with certain exceptions, like through doors that open automatically, etc.)

Now, place waypoint_navgoal's where you want your NPC to get to. Give them distinct targetnames (like "nav_console" for a navgoal by a console).

In your script, set the NPC into a BSTATE of BS_WALK (or whatever you prefer) and set the NAVGOAL to "nav_console". Putting that in a task and dowaiting it will make the NPC use the waypoint network to find the navgoal then head straight for it. Having it in a task means that the NPC will not continue with the rest of his script until he reaches the navgoal.

save stuff as a prefab?

just save it into your prefab directory, that's really all it is.

Make my own .pre? The set_precache command is disabled!

Just make a behaved.pre in a directory under real_scripts that has the same name as your map.

For example, if your map is called "argyle", put a behaved.pre in the directory baseEF/real_scripts/argyle. The game will load it automatically.

Make Md3view work? I get an error about GL when I start it!

make sure you have the newest version from:

http://www.3ddownloads.com/index.php3?directory=/eliteforce/

obviously, you need good OpenGL drivers, just like the game does.

I have a script that makes an NPC walk around to navgoals- how do I set up the map to make it do this?

I replied to this one already, didn't I?

Read the ICARUS Manual first.

In that case of that script, do as I said:

place waypoints in the map- as many as you need, but don't be excessive.

*each* waypoint can only have a max of 8 waypoints connected to it (you'll never need that many).

The waypoints are used internally by the nav system completely automatically - you cannot refer to them by name via a script or anything.

The waypoint_navgoals are the objects that you can tell someone to go to with a set( NAVGOAL, "navpoint1" ) command. They key is "targetname" (did you read the entity's comments?) and the value would be "navpoint1"- that's its name.

Just place the waypoints and navgoals as directed, then set up a trigger or whatever that fires off a target_scriptrunner. That scriptrunner should have a (key) usescript of (value) whatever the path to that script is (for example, walktest/walkies).

Note that the NPC must have a (key) NPC_targetname of (value) Tuvok for that script since it "affects" an NPC named Tuvok.

Also, you should make a subdir in baseEF/real_scripts that is the same as the name of your map (for my example, it's walktest). All your .pre's and scripts should go in there.

I would like to replace some of the wav. files in windows with those form elite force. I was looking on disc and folders but I could not locate them, can you help find them?

Use winzip to open the pak0.pk3 in your baseEF directory. However, almost all of our voice and music sounds are mp3's, so if you plan on using those (not just sound effects), you'll need an mp3->wav converter.

But as the prechache command seems to be disabled, I wasn't able to (or was to stupid to) do such a simple thing as to have my own script print a text on the screen. Please, Raven guys, there has to be a way, help me!

Just make a behaved.pre in a directory under real_scripts that has the same name as your map.

For example, if your map is called "argyle", put a behaved.pre in the directory baseEF/real_scripts/argyle. The game will load it automatically

I tried what you said and got my scripts set up, character in Radient set up etc but as soon as the map loads the NPC just dies.

Did you put him on the player start? That may not be a good idea. Better to start the player somewhere else then move him to where he has to be at the end of the cin. You can move the player with the set_origin command. Use a ref_tag.

I want the team I'm assembling to wear helmets and pattern enhancers on their backs. I can get my NPCs to wear these boltOns, but how do you do stuff to the player?

I tried using AFFECT, but I don't know who to affect nor who to assign a spawnscript to. Please help?

use affect on munro (default player name) but run it off something that is triggered AFTER the player is spawned (which is fairly late in the process), otherwise it is trying to affect someone who does not exist yet. I recommend putting a player-only trigger just around the spawnspot and have it target a scriptrunner which runs the script that affects the player (that burned down the house that Jack built )

MRJ

1) When I ran my map with stvoyhm.exe, my NPCs were no where to be found, therefore their spawn scripts didn't happen. Does ICARUS work in HM and can I have NPCs in HM?

ICARUS and NPCs are not in multiplayer.

2) I've been able to do lots of stuff to OTHER characters. I can get stuff to happen by either specifying a spawnscript setting to their entity or using the AFFECT command. How do I do stuff to ME, the current player? I tried setting a spawn script to the info_player_start entity and that didn't work the way I wanted it to. My only other idea is to specify a scripttarget (or what ever that setting is), but I wouldn't know who/what to set the entity on.

The player's name is Munro- to do something to them- affect "munro" (make sure you don't make an NPC with an NPC_targetname of "munro").

Note also that in cinematics, the player becomes invisible and nonsolid. In all the cinematics in which you see "the player", it's really an NPC_Munro

once you have the JPG that you want to use for a level shot, and put it in your levelshots folder, how do you get it to show up? is it in the worldspown entite?

And does anyone know where i can get a program to edit or somehow convert MP3s to Wavs... i got a program to do wav to MP3, just not the other way around.

That's correct, just take a screenshot, resize it to an appropriate size (I usually use a 512x512 JPG), then name it mapname.jpg and put it in the levelshots folder.

If your problem is getting the map to show up in the 'create server' listing, that's another problem. For that you need to create a .arena file and put it in the scripts directory. For an example of this take a look in the pk3 file for CTF_Geothermal, or for the Raven level pack released today. They're just text files so upen one up in Notepad and take a look.

Could someone send me an example of the force fields avaible like one that you have to shoot down(and regenerate after cos it's for MP), one that you press button to deactivate and activate, one that you shoot a disnode to deactivate(regenerate as well) and one that only certain people can walk through and some mixed ones in .map format PLEASE. Or can you tell me how to do it cos it just doesn't work for me. THAnkz

Basically you can specify different types of 'clipping' in the shader files. If you look at the shader entries for some of the forcefields you'll see listings like 'shotclip' 'playerclip' 'NPCclip' etc. This tells it what will and won't collide with a forcefield.

In the case of some of the fields in the borg maps and Forge3, etc, they're set to playerclip (so the player collides) and shotclip (so gunfire collides). This leaves NPCs free to walk through them.

The problem is if you have teammates along, well, they're NPCs and can walk through it too. Usually you have to mess with how far ahead/behond you they try to walk to make sure that doesn't happen.

Ok, I'm making map in EFRadiant, and whenever I test it, the room is almost WHITE because it's so bright, but the thing is, I haven't even put one light in the room!... ANybody know why?

If you don't have any lights in the map it'll default to fullbright, I believe. This will also happen if you don't run the light stage when compiling the map, the BSP menu should tell you which of those don't light though.

I made a script (it should work) and compiled it, putted it in the star trek elite force\GDK\Tools\sourchsomething\mygame
dir.
But i need to know how i can make a npc do the script.
I made a script that will first go to cam mode and then there is a converstaion between you and chakotay and then it returns to normal mode.
I want it to be ativated when you press the use button at chakotay.
And i need to know how to make it run only once too.

So this are the questions:

1 - How to make the script run when u use chakotay
2 - How to make it run only once

Thanx already !

First, read the ICARUS Manual. That will help explain a lot.

Now, assuming you read that, here's a step-by step example:

For this example, we assume your mapname is chaktest. This means your scripts for this map should be in in the folder: baseEF\real_scripts\chaktest\.

Put an NPC_Chakotay in your map. Set his (key) spawnscript to (value) chakotay_spawn.

Now make a script in chaktest called chakotay_spawn (you can use any name you want, but descriptive ones like this make it easier to remember what a script was for). As his spawnscript, it will be run when Chakotay spawns into the map.

In that script, set SET_PLAYER_USABLE to true. Now, set SET_USESCRIPT to "chaktest/chakotay_use". (Again, name it whatever you want).

Now, make a script named "chakotay_use" in the chaktest directory- this is whatever you want chakotay to do when you use him (sounds like you already have this written). The first command in this script should be to set SET_PLAYER_USABLE to false so that you can't use chakotay again. Would also be a good idea to set SET_USESCRIPT to NULL just to be sure.

There you go.

And be sure to read the ICARUS Manual!

lets say i wanted to make a SP "movie" that needs to have the npcs jump around a lot. Can this be done? I dont mean jump up and down with joy. I am going to ask the makker of the CTF map "forge debre" (spelling?) if i can use that map to make a 'movie' with a very long script.

So can this be done? i have yet to see npcs jump in SP, i have seen them fall down long stairs a such, but jumping...

you can set them to behavior_state BS_JUMP and give them navgoals to jump to, switch them back to a walk or run behavior_state long enough to get the next jump point, then back to BS_JUMP etc. etc.. almost forgot- make sure it's an NPC that has jump animations, or it may not work right!

make transporters

You should be able to use a trigger_teleport for this. Simply target it at a target_location, and it'll send anyone who runs into the trigger to that point.

I just bought the game and was wondering where to go for skin tools and help. I would love to make my own skins. I have photoshop and photopaint already. Would appreciate the help.

Open the pak0.pk3 file with winzip.

In that pakfile, you'll find some tga or jpg's in the directory models/player/model_name/...

Those are the skin files. You need to unzip all the files from one model (the one you are making the skin for) to a directory on your harddisk.

After that, you can modify the jpg's or tga's

If that is done, zip them again in a new zipfile, and make sure that the directory info remains the same : for instance models/player/seven
should stay seven.

After that, rename the zipfile .zip to .pk3,
so you'll get something like skins.pk3, and copy that pk3 into your baseEF directory. After that, launch it, and choose your model.

[LC]Shadow

Hi! I have tried to alter existing NPCs (e.g. give someone a different uniform). Therefor I extracted the NPCs.cfg into the BASEEF\ext_data folder and changed some vaiables. Should have worked, but didn't. What did I make wrong/forget?

Put it in a new directory and use fs_game.

How can I use NPCs that are not in the list in EFradiant. I added an NPC to the SP_Entities, so I could use him in EFradiant. Then I added the NPC to the NPCs.cfg. But what then?

Use an NPC_spawner and set the NPC_type to the new NPCs.cfg entry you made. All the other NPC's in the entity list are just NPC_spawners with a hard-coded NPC_type.

Ok, I made a basic map, compiled it in the bsp format and when I went to run it from HM it boots back to the start up screen half way through loading! ahh!

it sounds as though you need to drop the console by pressing the ` key
then type sv_pure 0 then load your map. This lets the game load non-standard maps (this is for the purpose of avoiding multiplayer cheating).

how do you add 'decals' such as the No Escape scrawl or the Beta Station sign

There are a couple different ways you can do it. You can create a rectangular brush with common/caulk on all sides, put the decal on one side, then sink the brush into the wall so that the decal side shares the same plane as the wall's surface. Or, you can use a rectangular patch mesh, put the decal texture on it, and move it so the mesh shares the same plane as the wall's surface.

Now, it's that "sharing the same plane" that gets me, because if I try that with any other two brushes, they... erm... fuzzify

Won't this happen with a brush setup like that?

Nope, because the decal textures are entirely transparent except for the design part. Decals basically just tint whatever's behind them with whatever's on the decal. Place them on a patch mesh ('fit' them to the mesh) right flush with the surface and there you go.

Using EFRadient, how does one place a different texture one face of a brush? I made a small brush that is supposed to be a light. This brush is connected to a ceiling of a room. On the side facing down, I have a light texture, but on the four other sides perpendicular to the ceiling, I want a different texture, like a grey texture. How is this done? Can I just select a surface, like in the UnrealED editor?

The only alternative I know is to make special thin brushes that acts as "texture" brushes.

The middle mouse button has functions specifically for texturing in the camera view. Middle-clicking on a face will select the texture currently on that case. Ctrl-middle will assign the selected texture to the brush you click on, and ctrl-shift-middle will assign the texture to the face you click on.

Using these will let you very quickly texture an object once the initial brushwork is done. Selecting a texture by middle clicking will also maintain any offsets, scales, etc so you can align one part of a multi-brush object, then use this function to apply that to the rest of the surfaces.

after compiling my map I lunch holomatch load a level then posh ~ on my key board and type in /map test and it says could not find maps/test.bsp what does this mean? I have it in my baseef folder if you could help it would be nice thanks :)

It has to be in baseEF/maps/. Make a "maps" dir, drop the bsp in there and try loading it exactly as you did before. Note that if you're trying to load your own map, you will need to set "sv_pure" to "0" on the console. The game should remember that setting after the first time and keep it.

Firstly, what programs will I need to model? Secondly, teaching me how to fit a box on someone head will do. Anything, just as long as it applies to offer modelling things.

I don't know how to model, myself... the process for creating new models (from the program to use, how to skin it, how to convert it to an md3) can best be explained by James Monroe (gone till Monday) and Les Dorscheid.

But the boltOn I can explain. Look at the file in the pak0.pk3 (use WinZip) for the file boltOns.cfg (in the ext_data dir). Therein is listed every boltOn available to ICARUS. The setup of the boltOn in here is the most crucial aspect of the process. For sunglasses you'd want something like this:

sunglasses

{

modelName models/boltOns/sunglasses.md3

targetModel 2

targetTag tag_head

}

Here's the explanation:

"sunglasses" is the name of this boltOn, it's the name you use in a script to tell an NPC which boltOn to turn on.

The modelName is simply the path (under baseEF) to the model to use.

The targetModel tells the NPC which part of the body to try to bolt the model on to. NPC are split into 3 models, 0 = legs, 1 = torso, 2 = head.

The targetTag tells the NPC which "tag" to look for in the targetModel- this is simply an invisible poly named tag_(whatever). This is where the game will position the origin of your boltOn model. In this case, the only tag you're guaranteed to find in every head model is tag_head- but this is at the base of the neck, so you'll have to tweak the offset of your sunglasses from it's origin until it looks right.

Now, in a script you simply tell an NPC to set SET_BOLTON_ON to "sunglasses".

That should do it!

That didn`t work, it just keeps putting me at the info_player_start point in the map.

Is there something I`m doing wrong?

I`ve got a Ref Tag called "munrostart" in EFRadient, and in BahavEd I have the line SET_ORIGIN, tag("munrostart", ORIGIN) and It still won`t put me at the RefTag called munrostart.

When are you running the script? The player will not be in the map at the very beginning- it is the last thing to spawn in.

Best way to make sure a script that has to do something to the player at the beginning of the map is this:

target the info_player_start at a target_scriptrunner. That target_scriptrunner will run its usescript as soon as the player spawns.

That script should look something like this:

affect ( "Munro", FLUSH )
{
set ( SET_ORIGIN, $tag( "munrohere", ORIGIN )$ )
}

That's it. Make sure you have a ref_tag in map with a targetname of "munrohere" (for this example) and that it is 24 off the ground (25 to be safe).

Make sure that you don't just type in the $tag( "munrohere", ORIGIN )$ part- you have to do it through the buttons on the SET_ORIGIN box. Hit the "helper" button, then the "tag" button and you'll see $tag( "targetname", ORIGIN )$ appear in the box- just replace "targetname" with "munrohere".

Can somebody please give me a step by step tutorial on how to make chakotay do a script (that i allready programmed).

Did you read the Radiant tutorials and the ICARUS Manual? it's really very easy. If you know how to give something a targetname, you know how to make something run a script. If you haven't read these, I can't help you, you have to know the basics of creating entities, setting key values, etc.

For this example, we assume your map is called "test" and you're trying to get an NPC named "Chakotay" to run a script.

Set an entity's (key) "spawnscript" to
(value) "test/chakotay_spawn". "test" is the subdirectory under baseEF/real_scripts in which the game will look for scripts for a map named "test". "chakotay_spawn" is the name I chose for this script for this example because it just makes sense and makes it easy to tell what a script is used for by looking at its name.

Now write the script- have it do whatever chakotay should do when he spawns (keep in mind that he spawns into the map before the player does).

There are several kinds of scripts you can assign, for example:
spawnscripts - run when the NPC spawns
painscript - run when the NPC takes pain
usescript - run when the NPC is used (by a trigger or player or whatever)
deathscript - run when the NPC dies.

etc.

To make an NPC be usable by something- just set that something's (for example, a trigger_once) target to the NPC's NPC_targetname. When you hit the trigger, it makes the NPC run its usescript. If you want the player to go up to an NPC and use it (with the use key), the NPC has to be set up to be player-usable. In a spawnscript, set the NPC's SET_USABLE to true and give the NPC a usescript. Now the NPC will run that script when used by the player.

Make sure you don't give and NPC a targetname- that will make the NPC not spawn until it's used- give it an NPC_targetname if you want to use it from a trigger or affect it in a script.

Also keep in mind that when an NPC (or any entity) runs a script, it is essentially affecting itself- so if an NPC called "Chakotay" runs a script, you don't want to put an "affect ( Chakotay )" command at the beginning of the script- that is inferred.

Does this help?

convert Quake 3 multiplayer models into Elite Force multiplayer models?

1) drop the quake models, skins and .tgas in a directory in our players2 directory

2) convert all the icon .tga's to .jpg's since ours won't load tga icons.

3) move all the .skin files to a directory with the same name in our players directory

As you know, the script file Guard.ibi controls spawned characters in the single player game. If I wanted spawned members of different teams to act differently (e.g. starfleet officers don't act like drones and vise versa), how would I do this?

Give them separate spawn scripts and write them.

So you could have a guard_rom.ibi, a guard_klg.ibi, etc.

put Subtitles on screen?

In each real_script directory, you will find a behaved.pre. In that, every line of dialogue has a path to a sound file and it's associated text. That text will appear when an NPC plays that sound on their CHAN_VOICE via a script (assuming you have subtitles turned on in the menu).

I have been trying to create an effect so an NPC appears to change into

another NPC type, however I have had absolutely no success. First of all is this possible and if it is how would I go about it I have already tried moving unspawned NPC's around using the SET_COPY_ORIGIN command and targeting them at other NPC's but this never works. Any help would be very much appreciated.

First, if you haven't already, read the ICARUS Manual.

Now, what you probably want to do is have a ref_tag in the map where you want the NPCs to be (eventually). Put the first NPC at that ref_tag- either via a script with a

set( SET_ORIGIN, tag( "targetname", ORIGIN ) )

or just put them there in the map.

Now, when you want to swap them out, move the first NPC somewhere - or just remove him like so:

remove( "NPC_targetname" )

Then, immediately afterwards, move the other NPC to the first spot:

set( SET_ORIGIN, tag( "targetname", ORIGIN ) )

It may be possibly that you have written your commands correctly and you just haven't set up the NPCs correctly. Make sure that the NPCs have an NPC_targetname or else you won't be able to "affect" them in a script.

Make sure in your script that you "affect" the proper NPC when moving them.

If that doesn't help at all, send me your script (and perhaps the .map file) and I'll take a look at it and see what's wrong.

I have made an awesome map but I dont know how to play it in my voyager game what do I have to do to load up my map?

Put the map in a directory called "maps" in your "BaseEF" subdirectory of your game. If there isn't a "maps" directory, make one. Then, when you run the game, bring down the console with the "~" key and type "map mymap" (assuming your map's filename is "mymap.bsp"). That's it!

I have a major problem with the scripting. The screen is to big so I cant see the whole thing I can only see up to the treehouse options.I cant reduce the size, so how do I fix this problem?

Unfortunately, the only solution is to up your resolution. Multiple resolution support was not built in to BehavEd.

display NPC dialogue with the head and mouth sync at the top?

Just have them play the sound on their voice channel. As long as that sound is in one of that level's .pre files, the dialogue will show up. Look at the other level's .pre files as an example, it's pretty simple to set up. Just remember that a .pre file must be called behaved.pre or extra.pre and must be in a script directory that is the same as the map's name (this is also where all scripts for that map should be). So if the map is called "mymap.bsp", the .pre's and scripts should be in real_scripts/mymap.

I was wondering if it is possible to use your own lines of text for mission objectives. I know how to make them appear, dissappear and appear completed, but the objectives that you can choose from in BehavED are all from the normal game and don`t apply to my MOD, can I make my own?

Not without changing code. However, you can replace the already existing ones by simply editing the file baseEF/ext_data/objectives.dat.

Question #1: .dat, .cfg, and .bat files; for objectives.dat what dir do you have to use to have a mod recognize objective paths? What are npcs.cfg files and what dir do they need to be in to be recognized by a mod. How do you make .bat files (in baseEF dir) that launch mods from a folder in baseEF and then load the map right away?

That was actually more like 5 questions :)...

1: "for objectives.dat what dir do you have to use to have a mod recognize objective paths?"

Objectives.dat has to be in the ext_data directory. Remember that all this stuff has to be zipped up into a .pak file and that .pak file has to either be in baseEF or be loaded as a mod (see below).

2: "What are npcs.cfg files?"

The NPCs.cfg file contains all the settings for every possible NPC in the game. There is an explanation of the fields in the comments at the top of the file. Essentially, when an NPC spawns, it reads its entry in here that corresponds to it's NPC_type (for certain preset NPC's, these are hardcoded in, for example, the NPC_tuvok automatically sets his NPC_type to "tuvok"). This entry will set all the unique properties of the NPC, what team it's on (which determines a lot of AI behavior), what head, torso and legs models and skins it uses, which sounds it will use, how big its bounding box is, etc. If you want to add a new NPC, just make a new entry at the bottom of the file and put an NPC_spawner on your map with an NPC_type that matches the name of your new entry.

3: "and what dir do they need to be in to be recognized by a mod."

Same thing, in ext_data, but in a .pak file.

4: "How do you make .bat files (in baseEF dir) that launch mods from a folder in baseEF"

The .bat file should read "../stvoy.exe -game mymod". "mymod" is the name of the directory you put your .pak file in. This directory should be in your root Elite Force directory, at the same level as baseEF. Note that the "../" is necessary because you said this .bat file would be in baseEF. If the .bat file is one level up, in the same dir as the stvoy.exe, you can leave that bit off.

5: "and then load the map right away?"

Add this to the command: "-map mymap" where "mymap" is the name of the map you want it to load. So your complete command would look like this:

"../stvoy.exe -game mymod -map mymap"

Question#2: How do you add a title to a levelshot, do you edit it in a graphics app. or use a script?
The text actually is read from a file and displayed on the screen as you're loading, regardless of the level shot. There is a file called infostrings.dat in ext_data. This file was made so that our maps could have text messages in them that were properly translated for whatever country they're in. So the map will use the name of an infostring (like II_DECK_04) and the game will look that up in the appropriate infostrings.dat file for the current language and use the text in there. Unfortunately, you cannot add more infostrings without changing game code and recompiling. But you can replace other infostrings and use them. Just set the worldspawn's "message" field to II_DECK_04 (or whatever you want to use).

Question#3: How do you "un-spawn" NPC's as if their beaming out to somewhere else?

Affect them (unlesss they're the ones running the script), set the event "beam down" and they'll do the teleport effect and sound and remove themselves.

affect( "bob", FLUSH )

{

set( SET_EVENT, "EV_BEAM_DOWN" );

}

Question#4: Can NPC's fight hand to hand (melee combat) and do damage to each other?

Only the Klingons and Imperials have this ability. Set their weapon to one of the blades.

affect( "klingon", INSERT )

{

set( SET_WEAPON, WP_IMPERIAL_BLADE )

or:

set( SET_WEAPON, WP_KLINGON_BLADE )

}

Question#5: How do use triggers in scripts, for example when an NPC enters a certain trigger it loads a new map, etc? Or for example (like in the actual game) when you come close enough to a pair of NPC's then they start talking.

That's easy, just set up a trigger, target it at the target_scriptrunner whose usescript is the script you want to run. If it's a trigger you only want the player to be able to trip, be sure to set the "playeronly" flag on the trigger. You can also target the trigger at NPC's themselves by setting the trigger's target to the NPC's NPC_targetname. This will make that NPC run its usescript when you hit the trigger.

Question#6: How do you get the dialogue and the animated head of the player to appear at the top when an NPC is talking?

If you look in the directory in real_scripts that corresponds with the mapname (for example, voy3.bsp has a script directory of real_scripts/voy3), you'll find a behaved.pre. This file is loaded when the map loads and lets the game know what dialogue sounds to load, what the subtitle text is and whether or not to show the dialogue at the top of the screen. An example:

sound/voice/chakotay/voy3/intruderalert.mp3 "Intruder alert- all Security and Hazard Team personnel to the Loading Dock!" CHAKOTAY

The first part is the path to the sound file you're planning on using in a script. The second part is the corresponding text of the line of dialogue. The last part is a keyword- if present, it will make the head of the specified NPC appear at the top of the screen with the text.

Note that you cannot add more of these without modifying cgame code and recompiling.

Question#7: At the beginning of a map if a spawnscript is loaded in the worldspawn, how do you create a black background, use pics, etc...while showing scrolling text?

Make a small room somewhere that has the background you want. Put a camera in there and point it at the wall. Start the map, turn on the camera and start the scrolling text.

Here is an example of borg1's intro... note that any script with camerawork in it should be run from a target_scriptrunner that is fired off by the info_player_start- this ensures that the player will be spawned and in the game when the camera scene begins.

camera ( /*@CAMERA_COMMANDS*/ ENABLE );
camera ( /*@CAMERA_COMMANDS*/ FADE, < 0.000 0.000 0.000 >, 0, < 0.000 0.000 0.000 >, 1, 0 );
camera ( /*@CAMERA_COMMANDS*/ MOVE, $TAG("stars", ORIGIN)$, 0 );
camera ( /*@CAMERA_COMMANDS*/ PAN, $TAG("stars", ANGLES)$, < 0.000 0.000 0.000 >, 0 );
camera ( /*@CAMERA_COMMANDS*/ ZOOM, 60.000, 0 );
camera ( /*@CAMERA_COMMANDS*/ FADE, < 0.000 0.000 0.000 >, 1, < 0.000 0.000 0.000 >, 0, 1000 );
set ( /*@SET_TYPES*/ "SET_SCROLLTEXTCOLOR", "WHITE" );
set ( /*@SET_TYPES*/ "SET_SCROLLTEXT", "@scrolling1" );

The "@scrolling1" is, again, a reference to a text field in an external file that needs to be translated for different countries. In this case, you'll find the text in the extra.pre in the same dir as the behaved.pre. In that file, you just make a "@scrolling#" (where "#" is any number) and refer to that in your script and it will display the appropriate text.

In the actual game, for example, when you watch the briefing, the screen changes textures to correspond with what Tuvok is saying, or when you press a control panel and the texture changes to show it, can anyone tell me how this done?

Is it through scripts or through some Radient feature?

It's done through func_usables. A func_useable is a brush entity (like, say, a door or func_breakable) that will turn itself on and off when used. So, in the briefings, there are several func_usables in the same spot on the viewscreen, each with a different texture. The script in which Tuvok talks, it uses the proper brusher at the proper time which turns off one func_usable and turns on another. This gives the illusion that the screen graphic is changing.

How do I make enemies shoot me and friendlies follow me? I'm pretty sure it has something to do with the "playerteam & enemyteam" values ... but I tried all sorts of key's and values, just not the right one I think.

Making enemies shoot you is easy. The enemy NPCs (scavengers, hirogen, borg, etc.) are already automatically set up to get angry at the player when they see him. You should be able to just drop them in a map and they'll attack you when they see you.

Getting allies to follow you is a bit more complex. The friendly NPCs are already set up to not consider you an enemy. They do not have an enemy team assigned by default though, so they won't attack unless attacked first. You can set their enemy_team to the enemies you have on the map and they'll shoot on sight.

There are two ways to get them to follow you:

1) Put them in behavior state BS_FOLLOW_LEADER and set their leader to "Munro" (the player) or the NPC_targetname of another NPC if you want to chain them along (but at least one of them must be following the player).

2) Make squadpaths. As an example of this, open up any of our .map files we released that has teammates following you on it. Basically what you do is this:

Make a squadpath for each NPC. It must start with a squadpoint that has an "ownername" that matches the NPC's NPC_targetname. Target that squadpoint at the next one, etc, along a path throughout the map along the route the player is likely to take (you can branch using target2, target3, etc.) This is the path the NPC will stick to while following the player.

When the map starts, you must make sure to set the NPC's squadname to "Munro" (the player). Once everyone is assigned the proper squadname, you call SET_MAKEFORMATION. This will grab everyone in Munro's squad and make them find their squadpath and they'll stick to it. As you move through the map, they stay as close as they can to you while staying on their path- they'll also do the random chatter and shoot enemies. You can override how far ahead/behind the player they follow by setting a leadDist on each squadPoint. Positive numbers make them walk ahead of the player, negative numbers make them trail him.

Once in formation, they will stay in formation until you change their behavior state. If you change it (to, say, BS_WAIT), they return to normal AI and will not follow you. You can easily put them *back* in formation by setting their behavior state back to BS_FORMATION. Once you do this, they remember their squadpath and get back on it.

First of all I'd like to tell you that my NPC's are following me through my level. Thanx for the help. But now, how do I get the enemies to run through my level chasing me instead of staying in one place to shoot me.? With Scavengers this is not much of a problem, but the BORG or Species 8472 will only run at me when the can see me. But once they encounter a small object they won't even walk around it.

It sounds like you don't have a waypoint network in your map? This is needed to make the enemies get around obstacles and chase you around corners. Look at one of our released maps for an example. It's simply a network of waypoint entities, all with a unique targetname and all targeted by or at another waypoint. Each one must be in line of sight of the waypoint(s) it's connected to. You can refer to one of our maps and/or read the entity comments in Radiant for more. Also, you can load up one of our maps and bring down the console and type "nav show all" to turn on debug-drawing of the waypoint network.

Also, How do I get an NPC to be dead en stay dead in my level... It's for the storyline, I want to encounter a dead member of Starfleet.

To make someone "dead", it depends on if you want to do anything with them after their dead. NPCs will not respond to scripts once dead. If this isn't a problem, just place them in a map with an NPC_targetname (for this example, we'll use "Fred") and, in a script, use the "kill" command like so:

kill( "Fred" )

If you don't want them to *actually* be dead, you can just set their upper and lower anims to one of the death anims and set theit anim_holdtime_both to -1 to make sure they keep this anim. Then set them to be invincible and not react to pain. The script would look something like this:

set( SET_ANIM_BOTH, BOTH_DEATH1 )

set( SET_ANIM_HOLDTIME_BOTH, -1 )

set( SET_IGNORE_PAIN, true )

set( SET_INVINCIBLE, true )

Also, there are other anims we used for people leaning up against walls- these are called BOTH_INJURED1, 2, etc. Use Md3view to browse through a model's animations (you need to extract them from the .pk3 file to do this)

Hi, I've just read through the icarus manual and am eager to design my own one player mission, however I do have two questions for you if you don't mind:

1. It says the commands in grey are not yet implemented, however in another question on the site you told someone to use one of these. Are they implemented now?

Some of the commands are and some aren't... we don't have a totally up to date version of the scripting manual... I haven't had time to write one. If something is questionable, you can ask me.

2. I want to use some holographic characters, particularly the Docter (EMH). However, I don't believe he's authentic enough. For example (I can't be sure of this, maybe you did it), when Munro is about to have the firefight in the cargo bay with the Klingons the Doctor is out side and offers help. Was he wearing his mobile emitter? Is there another skin for the Doctor with the Mobile Emitter somewhere? Also, the forcefeild sounds will probably do for the sound effect, but I need a more proper hologram activate/deactivate animation. Is this possible? The way he shrinks an inch and goes transparent leaving only an outine that shimmers into thin air. Also, personally I think the transporter animation is WAY off. Can this be fixed/has it been fixed in the add-on pack?

2. The Doctor has his mobile emitter on. All it is is a bolt on and you can turn it on in ICARUS - set ( SET_BOLTON_ON, "holoemitter" ). Making an effect for him to appear and disappear will require programming.

3. Can you make the NPC's react when the player character draws a weapon?

3. Yes, do a loop that contains a wait (of, say, 500ms) that constantly checks the player's weapon. Something like this:

declare ( STRING, "playerWeap" )

loop(-1)

{

affect ( "Munro", INSERT )

{

set ( "playerWeap", get( STRING, "SET_WEAPON") )

}

wait ( 100 )

if ( get( STRING, "playerWeap") = "WP_COMPRESSION_RIFLE" )

{

run ( "mymap/getangry" )

}

wait ( 500 )

}

So... you affect the player, get him to store his weapon name in a variable, wait 100ms (so that the player has a chance to execute that command before you check it). Check the name of the playerWeap and run the script. Remember that running a script is basically like including it, so unless the script you run has a "flush" command in it, it will just insert that script into your loop here. Also, if you have the player run it, *he* will be executing the commands, not the NPC. This is fine if the script you run affects another entity because then, essentially, they would run the commands. So you could do this:

(for this example, let's say the NPC running this script has an NPC_targetname of "smitty" )

declare ( STRING, "playerWeap" )

loop(-1)

{

affect ( "Munro", INSERT )

{

if ( get( STRING, "playerWeap") = "WP_COMPRESSION_RIFLE" )

{

run ( "mymap/getangry" )

}

}

wait ( 500 )

}

And the "mymap/getangry" script would look like this (remember, this will be run by the player in the above version of the script)

affect ( "smitty", FLUSH )

{

set ( SET_ENEMY, "Munro" )

set ( SET_BSTATE, BS_RUN_AND_SHOOT )

<etc...>

}

The "FLUSH" will break smitty out of his loop and make him run these new commands. You want to make sure this FLUSH happens right away or else smitty could go on looping that script and making Munro run that "getangry" script over and over and that would be very bad.

So, yes, it's possible, but a bit tricky.

Is it possible to beam the player and\or AI units 'out' of one area of the

map and into another part of the map? If this is not possible, then how

would I trigger the loading of a new map from within a script?

Well, you can just do this:

set ( SET_EVENT, EV_BEAM_DOWN )

On an NPC, but this removes them from the world when the effect finishes. You'd have to have a second NPC to beam in to the new spot (which isn't a horrible thing, really).

But, if you don't want to go through the hassle of deleting one NPC and spawning in another, you can try this: place an fx_crew_beam_in in the map and have it target the NPC you want to move. fx_crew_beam_in's "target" should match the NPC's "NPC_targetname". When you use the fx_crew_beam_in, it will play the beaming effect on that NPC (though it doesn't look exactly like the other beaming effect, I think). After 2000 ms, you can do a SET_ORIGIN on the NPC to move it where you want ... use a tag, most likely... like so:

set ( SET_ORIGIN, tag( "newspot", ORIGIN ) )

and play that effect again (use the fx_crew_beam_in). This will apply to the player as well.

The only way to change a map from a script is with a "use" command targeted at a target_level_change on the map, like so:

use ( "exitlevel" )

Or whatever you call that entity when you make it.

I was wondering how I would go about spawning an NPC onto the map while

the level is running. Would I be using an NPC_spawner entity? How would I get the entity to transport onto the map?

Use an NPC_spawner with a targetname. When you use that targetname, the NPC_spawner will spawn its NPC.

Is there a way to detect whether the player chose Munro to be male or female? How can it be done?

You need to do a get and compare it to a string. Like so:

if ( get( STRING, "SET_SEX") = "male" )

for the male Munro and:

if ( get( STRING, "SET_SEX") = "female" )

for the female Munro.

That's all!

Is it possible to just display text on the screen without any accompanying audio? I looked at that doc that you sent, but I'm not sure if I'm using the right format. What format does the .PRE file have to be in? Also, when I call the print function in the script, what do I reference?

If you want to put scrolling text on the screen like at the beginning of the game, you need to have a line like this (this is from real_scripts/borg1/extra.pre):

"@scrolling1" "On Stardate 48315.6, the U.S.S. Voyager was transported beyond our control, 70,000 lightyears across the Galaxy to the Delta Quadrant. There, without aid from Starfleet, we began our 70-year journey home.\nIn our numerous encounters we came into contact with many dangerous and violent species. Having a limited crew with no chance of reinforcements, we determined that we needed a specialized team to handle the more dangerous situations. Tuvok, Voyager's Chief of Security, assembled an elite force of security personnel named the Hazard Team.\n\nEnsign Munro is second in command of this uniquely trained team. Equipped with Seven of Nine's experimental anti-Borg weapon, the Infinity Modulator, the Hazard Team has beamed to a Borg cube on a dangerous mission.\nHowever, the team was quickly overwhelmed and the I-Mod is now in the hands of the Borg.\n\nSeparated from the rest, Munro is attempting to rescue the team."

Then, in your script, do this:

set ( SET_SCROLLTEXTCOLOR, WHITE ) //(or whatever color you want)

set ( SET_SCROLLTEXT, "@scrolling1" ) //This is the identifier - the keyname in the extra.pre that corresponds to the text you want to show

If you want normal text, use an entry like this in the extra.pre:

"@endlevel" "Entering New Area."

And put it on the screen from a script, like so:

set ( SET_CENTERTEXTCOLOR, "WHITE" ) //(or whatever color you want)

print( "@endlevel" )

I think that will print it to the middle of the screen. If you want it kind of framed, use this:

set ( SET_LCARSTEXT, "@endlevel" )

If you want a dialogue print with no sound, you can just use an mp3 that's silent and give it subtitle text, like so (again, in the extra.pre):

sound/voice/tuvok/borg1/empty.mp3 "Ensign, I've uploaded your mission objectives and tactical information." TUVOK

Note that the "TUVOK" on the end not only specifies that it the text should appear in the comm box at the top of the screen, but it also indicates to the game *whose* head should show up. Also, when you do this (assuming you're using a silent sound for some reason) - make sure the sound is long enough so that the comm message stays up long enough to be read (I believe the comm box stays up as long as it takes to play the sound?)

Good luck!

I'm trying to have Munro (the player) say something and have it appear with the head and text on the screen. I have it working fine for the AI teammates, but can't get it to work for the player. Here is the chunk of code I am calling in the script:

affect ( "Munro", /*@AFFECT_TYPE*/ FLUSH )

{

task ( "Play_Munro_CargoBay2" )

{

sound ( /*@CHANNELS*/ CHAN_VOICE, "sound/voice/Munro_CargoBay2.mp3" );

}

dowait ( "Play_Munro_CargoBay2" );

}

In the map, I have the NPC_targetname property on AI's to identify them, do I need something similar for the player? I looked at some of the existing maps and scripts to see if there was something I was mission, but nothing jumped out at me. Strangely, if I just play the sound without the using the 'affect' call I can see the head and banner appear at the top of the screen for a brief second.

Well, there's a couple things that may be wrong...

Did you put text after the .mp3 in the extra.pre? That's how it knows what text to put up. It also should have the "MUNRO" identifier after it, like so:

"sound/voice/Munro_CargoBay2.mp3" "Munro to Cargo Bay 2." MUNRO

You might want to put the mp3 in the sound/voice/munro directory, but I don't think that's why it's not appearing (not putting it in that dir will probably just mean it won't work right if you play as Alexandria).

The script you sent is fine, "Munro" is the player's targetname.

The reason you get that pop up on the top of the screen for a split second if you don't affect Munro is that only NPCs and the player can wait for sounds to complete. Not using the affect means it's probably not running on an NPC (unless another NPC is calling that affect?) and so the sound finishes instantly.

All this being said, I don't think we ever had Munro's head appear up in that comm window because that was meant for people talking to him, not for him talking. I'm not quite sure what you'd have to do to get it to work. If you're set up the way I described above, let me know and I'll mess around with it here to see if I can figure out a way to make that work.

The only hack I could imagine working right now is to have an NPC_Munro somewhere on the map and play the sound on him at the same time...? If you are willing to mess around in code, there may be a better solution I can suggest.

Another issue I'm having is that I've given an AI the order to follow me in formation (which he does fine), but then I have a trigger area I enter which instructs the AI to go to another waypoint, but the AI doesn't go to the other waypoint. He still keeps following me.

When you tell him to go to another waypoint, you're also going to have to change his Behavior State- try BS_RUN or BS_WALK. Putting him back in BS_FORMATION will make him follow you again (you do not have to do a CREATEFORMATION again- that is only needed once and should be called only by the leader of the formation- the player (not once for each member of the formation)).

Is it possible to record demos in Elite Force?

Only in multiplayer, sorry...

I'm trying to use a global variable and can't get it to work. Basically, I

want it so the player has to go into a specific room (where a script will be

run) in order to use the transporter. I'm declaring the variable in the

worldspawn script:

//(BHVD)

declare ( /*@DECLARE_TYPE*/ FLOAT, "Transporter_Active" );

set ( "Transporter_Active", $0$ );

then setting it in the script when the player enters the correct room

//(BHVD)

set ( "Transporter_Active", $1$ );

and then checking the variable when the player enters the transporter pad

//(BHVD)

if ( $get (FLOAT, "Transporter_Active") = 1$ )

{

use ( "exitlevel" );

}

But it doesn't seem to work. Any idea what I'm doing wrong?

Hmm, this looks right.. and it seems as though everything is in the right order... one thing to keep in mind is that these global variables do not carry over level transitions... is that what you're trying to do?

how do i terminate a endless loop?

I have something like

loop ( -1 )

{

use ( "redalert" );

wait ( 4000.000 );

use ( "redalert" );

}

I want to terminate this with another script when the user presses some button or something.

I tried to set a float variable “redalert” and was always checking if it’s set to 1.. But EF didn’t like this and it crashed. It doesn’t like

It on endless loops. On defined loops it’d work.

I read on the doc about the flush command

I also tried this:

affect ( "munro", /*@AFFECT_TYPE*/ FLUSH )

{

loop ( -1 )

{

use ( "redalert" );

wait ( 4000.000 );

use ( "redalert" );

}

}

in another script that is called I have this:

affect ( "munro", /*@AFFECT_TYPE*/ FLUSH )

{

flush ( );

}

But for some reason, it doesn’t work. I read that flush should overwrite the commands and terminate the loop. I also experimented with INSERT in the affect() but it didn’t work too.

Please help!

The flush should definitely work. Are you sure that flushing script is running? (turn on the icarus debug info - "Icarus log munro"). As a matter of fact, the loop will be broken as soon as you do an affect( "Munro", FLUSH ), the "flush" command itself is redundant (aside from the fact that you may need at least *one* command inside the affect for it to do anything). Verify that that second script is running (try putting a print command in it), then let me know if you still have the problem.

How can I enable shields for the player, and make them adapt just like regular borg? Also, is it possible to make the player start out with assimilation tubules, the taser, or the borg weapon?

I'm assuming you're talking about single-player...

Without actually changing the code, there's no way I can think of to make the player adapt to shots like a Borg. The problem is adaption requires that the person hit has a team of Borg (which you can set in scripting) and a race of RACE_BORG (which is only settable on NPCs). So I don't think that could be done in SP (MP already has this- in the game mode "Assimilation"), sorry.

You can give the player the Borg weapons if you like. Have the info_player_start target a target_scriptrunner that runs a script like this:

affect( "Munro", INSERT )

{

set( SET_WEAPON, WP_BORG_ASSIMILATOR )

set( SET_WEAPON, WP_BORG_TASER )

set( SET_WEAPON, WP_BORG_WEAPON )

}

Now the player will have all three of these, and will start off with whatever weapon you set on him/her last.