Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

FPSC Classic Scripts / spawning an entity when i destroy another

Author
Message
EGG HEAD OF DOOM
16
Years of Service
User Offline
Joined: 21st Sep 2008
Location: The Hacked Hospital Lobby
Posted: 22nd Nov 2010 22:46
how would i go about doing this, i'v tried a few different ways with scripts i already have and tweaking them, but to no avail.

basically what i want to do is:
if one entity is shot: spawn another in the same location and activate another entity (e.g. a door)

i'm sure this is simple, but cant seem to do it

any help is much appreciated

Sandante
16
Years of Service
User Offline
Joined: 9th Sep 2008
Location: Dark World
Posted: 23rd Nov 2010 16:19
i dont know how to script, but maybe this will help.

Use the Destroyandactivate script. for the entity that you want to shoot

give the both things you want to spawn the same name. i know this will work to open the door, so maybe it will also spawn the other entity you wanted.

again this is just an idea.

EGG HEAD OF DOOM
16
Years of Service
User Offline
Joined: 21st Sep 2008
Location: The Hacked Hospital Lobby
Posted: 23rd Nov 2010 19:15
Thanks, I figured i'd have to use that for the entity I'm destroying, but the problem is what script am I suppose to give the entity that I'm spawning.

does anyone know what script I should use or any tips on how I should go about making this script?

EGG HEAD OF DOOM
16
Years of Service
User Offline
Joined: 21st Sep 2008
Location: The Hacked Hospital Lobby
Posted: 24th Nov 2010 04:36
sorry to double post, but this is something thats rather important to my project so if someone with a good knowledge of scripting could give me advice, it would be VERY much appreciated

Delusional Games
14
Years of Service
User Offline
Joined: 2nd Oct 2010
Location: Serbia, Sometimes Finland
Posted: 25th Nov 2010 09:53 Edited at: 25th Nov 2010 10:01
Becouse there is activateifused line in destroyandactivate.fpi.
You edit the entity you want to appear on double click and change its name to for example apen1. And set spawn at start to NO, then edit the enity you want to destroy and in its IFUSED field write the name of appearing-when-other-is-destroyed entity wich is in this case apen1.
And you give other entity script whatever you want, like shootwhensee.fpi if its character.

That is not dead which can eternal lie. And with strange aeons even death may die.
H.P.L
EGG HEAD OF DOOM
16
Years of Service
User Offline
Joined: 21st Sep 2008
Location: The Hacked Hospital Lobby
Posted: 25th Nov 2010 19:22
Sandante
16
Years of Service
User Offline
Joined: 9th Sep 2008
Location: Dark World
Posted: 26th Nov 2010 19:29
EGG HEAD OF DOOM@

i made 2 rooms for you so you can see by yourself how it works with the destroyandactivate sript.

the idea is to shoot the black terminal in the room, and see what is happening in that room.

i used only things from the stockengine. you only have to bright up your ambience maybe.

good luck!!

Attachments

Login to view attachments

Login to post a reply

Server time is: 2024-11-24 16:28:29
Your offset time is: 2024-11-24 16:28:29