EFMods Forum Archive
[Click here to go to EFMods.com]

Making a self destruct usable

EFMods Forum Archive - Mapping Help
JanMike34
Posted at 7:04 pm, 5th September 2004
hi im making a stargate map for ef2, (almost done) and it is of the alphasite. all i need now is:
a) press a button and everyone dies on base because of self destruct (after 30 seconds)
that is the only thing i need to know. but other things i would like to know are:
1) how do you make red team spawn on red base, and blue team spawn on blue base
2) how to make doors slowly open, then open at regular speed, then slowly stop (doors in lift1 for ef2)
3) make (like the event horizon for the gate) move

i really only need the first question answered (a) for the map to be complete, but the other questions are so that i know!
THANKS
Bicko
Lieutenant-Junior Grade

Posts: 149
Join Date: 08-10-2002
Posted at 9:25 pm, 5th September 2004
For Question A:
Cover the entire area with a func_hurt. Set it up to kill a player instantly. Give the func_hurt entity these properties:
key: targetname
value: selfdestructtriggger

Make a trigger_use for the button, and type in:
key: thread
value: selfdestruct

key: wait
value: 1
(Note: Value of 1 should be minimum)

Next, make a script file called YOUR_LEVELNAME.scr and make it like this;

[code:1:45547508bd]void main();
void init();
void selfdestruct();

void main()
{
thread init;
}

void init()
{
$selfdestructtrigger.nottriggerable();
}

//This turns the trigger hurt ON for 1 second, then turns it back off
void selfdestruct()
{
$selfdestructtrigger.triggerable();
wait(1);
$selfdestructtrigger.nottriggerable();
}[/code:1:45547508bd]

For Question 1:
I think to do this, you need to make all the info_player_deathmatch entities have this:
key: team
value: 1

That's what I think it is. If not, try the value of 2. If not... *shrug*

For Question 2:
I'll look into this for you.. I've been interested in it myself.

For Question 3:
Define move. You mean have a rippling texture on it? Talk to Simmo if it's a texture thing.

All of this should work.

edit: you know theres a "code" option for ths sort of stuff
JanMike34
Posted at 9:56 pm, 7th September 2004
Thanks. Did you get this information from a site, or from a previous post?
Oh and by the way, for the event horizon, i want it to move like water.
THANKS AGAIN
JanMike34
Posted at 10:21 pm, 7th September 2004
AHHHH!
I was about to put that into the game, then I load the map and "FATAL ERROR parsing map. Make sure that you are loading a map that is compatible with the current game (Elite Force 2)
Error parsing shader shaders/dm_char.shader: Mismatched braces." IT WONT START UP! AHHH! It is on the correct game, and everything should be how it is! NOOO! I CANT LOSE THIS NOW! HELP!
Scooter
Morale Officer

Posts: 2898
Join Date: 08-05-2002
Posted at 2:03 am, 8th September 2004
Sam's code snippet looks fine to me. You forgot a bracket somewhere while transcribing?

Captain of the USS Serenity
JanMike34
Posted at 10:05 am, 8th September 2004
It wasn't the scripting. When i was loading the game to input the trigger_hurt, it wouldn't load...
Bicko
Lieutenant-Junior Grade

Posts: 149
Join Date: 08-10-2002
Posted at 4:53 pm, 8th September 2004
JanMike34 said:
Thanks. Did you get this information from a site, or from a previous post?
Oh and by the way, for the event horizon, i want it to move like water.
THANKS AGAIN
I know from experience, I typed that up from memory.

As for water.. again, ask Simmo. He knows the shaders n junk better than myself.
Bicko
Lieutenant-Junior Grade

Posts: 149
Join Date: 08-10-2002
Posted at 12:06 pm, 13th September 2004
(Sorry for the double post)

How did this work out for you JanMike? Did you get around that error?