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 Models and Media / Make debris spawn when CP_factions parts are destroyed/set an object to spawn when another is destroyed

Author
Message
Sparrowhawk
15
Years of Service
User Offline
Joined: 12th Apr 2011
Location: Planet Magrathea
Posted: 13th Aug 2011 12:34
Ok, so with some forum help I found how to use destroy and activate script. However on the tutorial jpg is says "on the debris use whatever debris you like and set it to spawn when an entity is destroyed"
So how do I set an object to spawn when another is destroyed?
starmind 001
FPSC Reloaded Backer
18
Years of Service
User Offline
Joined: 23rd Sep 2007
Location:
Posted: 13th Aug 2011 18:50 Edited at: 13th Aug 2011 18:51
You need to read your guide in your docs file. Spawning thing when something if activated is the same as the pillers. If you want to activate something like debris when one of the pillers is damaged, you have to give it the same name as the piller being activated.

So if you look in your guide it says on page 154 how to spawn an entity with a trigger. apply it to this and you are golden. very simple.

But perhaps you are like alot of people on here and you don't want to thumb thru the guide, so here you go:

Spawning enemies with a trigger zone: By Brian Lizotte

How a game plays is just as important as how it looks. Spawning enemies at just the right time in unexpected places can make your game exciting and fun to play as well as great looking.

1. In the editor, place your enemy or enemies where
you want them to appear when they spawn. Right
click on the enemy and enter the following in the
properties section:

 Give the enemy a unique "Name". If more than
one, all must have the same name.

 Set "Spawn At Start" to No.

 Set "Maximum Spawn" to 1 (see image below)



Changing the "Maximum Spawn" number will change the number of times that the enemy spawns after he is killed.
See the FPSC Manual for other values and their meanings.

2. In the editor, place a new Trigger Zone where you
want the enemy's appearance to be triggered. Right
click on the Trigger Zone and enter the following in
the properties section:

 Enter the enemy's name in the "If Used" box.

 Set the AI Main script to

"plrinzoneactivatifused.fpi”.

See the FPSC Manual for other values and their meanings.
The enemy will now spawn when the player walks into the Trigger Zone. Be sure to place the Trigger zone where the player will have to walk into it, unless randomness is part of the plan. Giving the player multiple routes to travel with different results can add a longer play life to your game.

Sparrowhawk
15
Years of Service
User Offline
Joined: 12th Apr 2011
Location: Planet Magrathea
Posted: 13th Aug 2011 19:09
Oh ok I thought it was more complicated than that - thanks. Yeah sorry i had to uninstall adobe reader so at the moment I can't open pdfs.. which is what the guide is, though I'm going to rectify that asap.

Cheers for the info.
One more thing though. I have set spawn velocity to 100 for the debris, however it just appears flat on the ground... does it need to be 1 to have a velocity or is 100 too low?
starmind 001
FPSC Reloaded Backer
18
Years of Service
User Offline
Joined: 23rd Sep 2007
Location:
Posted: 13th Aug 2011 19:31
Here is your guide.
http://forum.thegamecreators.com/?m=forum_view&t=131868&b=21

I am going to use a quote from Thraxas for the velocity:

Quote: "If you open up the volcanospawn.fpm in the mapbank/tutorial folder you can see it in action. The rocks which spawn from the volacno fly upwards and depending on what you set their velocity to they will move at different speeds
"


Sparrowhawk
15
Years of Service
User Offline
Joined: 12th Apr 2011
Location: Planet Magrathea
Posted: 13th Aug 2011 22:15
Thanks that helped, though i have also found my main problem - the entities I was trying to use had no collision, or something... Hence they didn't seem to fit the rules. Or maybe they were just bugged themselves.

Login to post a reply

Server time is: 2026-07-05 14:20:42
Your offset time is: 2026-07-05 14:20:42