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 Product Chat / Self Destroy?

Author
Message
Monkey Mja
16
Years of Service
User Offline
Joined: 8th Apr 2010
Location:
Posted: 11th Aug 2010 03:48 Edited at: 11th Aug 2010 03:48
Is there any way to make a object destroy (exploding works too) itself as soon as the game starts, or as soon as the player walks on/through a certain trigger zone?

- Monkey
Nbt
16
Years of Service
User Offline
Joined: 11th Oct 2009
Location: Behind you!!
Posted: 11th Aug 2010 03:54 Edited at: 11th Aug 2010 03:56
Easy way is set your entities to 1 strength and set them to explode, then have them not spawn at level start and place them up high.
That way when you spawn them by a trigger etc they spawn in the air hit the ground and explode Plus if you set their explosion power high they blow up other stuff about them.

You can of course use invisible textures for the exploding entities if you do not want the player to see them. I used to make some cool chain reactions, setting each entity in turn to spawn after the one before blew up.

Otherwise just script them with "destroy" in their main AI script.

Monkey Mja
16
Years of Service
User Offline
Joined: 8th Apr 2010
Location:
Posted: 11th Aug 2010 03:57 Edited at: 11th Aug 2010 03:58
Did not think of that. Thanks NBT. A related question:

Is there any way to make a object destroy (exploding works too) itself as soon as the player walks on/through a certain trigger zone?


Quote: "Examples:

- Lets say you don't want the player accessing Floor B untill he reaches the end of Floor A. You could place an invisible wall, and right when he finishes the floor, the invisible wall is destroyed.

- Lets say you want it so your teammates all die before the final fight. If your teammates are not already dead, they would drop dead, leaving only the player to fight the final boss.

- Detailed scenes. If your making a war game and you want a friendly helicopter to explode, then a few gas tanks go boom chakalaka."


- Monkey
Nbt
16
Years of Service
User Offline
Joined: 11th Oct 2009
Location: Behind you!!
Posted: 11th Aug 2010 04:10
yes exactly as I told you above monkey with an exploding entity with a enough damage on death and enough to blow up the wall. Place another invisible wall in front of this wall with strength set to 0 (immortal) so the player cannot shoot the real wall.

Then set a trigger (or objective item) to spawn the bomb and set the bomb to activate if used the invisible wall to have coloff

Monkey Mja
16
Years of Service
User Offline
Joined: 8th Apr 2010
Location:
Posted: 11th Aug 2010 04:23 Edited at: 11th Aug 2010 04:23
Sorry. A bit confuzzled here.


Set a trigger to spawn the bomb? How do you spawn an entity?

(I have been working with FPSC for six months and still feel like a noob )


But then you set the bomb/exploding entity's "if used" to the invisible wall and it all works out.

PS: If it explodes, wouldn't it make a bit of noise? How do you make the explosion invisible?

- Monkey
Nbt
16
Years of Service
User Offline
Joined: 11th Oct 2009
Location: Behind you!!
Posted: 11th Aug 2010 04:30
Monkey mate, I have been a constant noob all my life ^_^ and as to FPSC I'm even worse and class myself as an undernoob

You spawn an entity, by setting the entity to not spawn at start in it's properties. Then set a trigger or another entities Main AI script to spawn the entity via it's "IfUsed" property.

As to the noise I thought you wanted the wall to blow up ?? so does it not want a noise? As to making an explosion invisible, use a transparent decal for it's explosion I guess?

Monkey Mja
16
Years of Service
User Offline
Joined: 8th Apr 2010
Location:
Posted: 11th Aug 2010 04:40
I want it to destroy, so if I set it to explode=1, it would go down to no health, and blow up just as if I would of shot it. It would take damage and go through it's normal destroy routine.

- Monkey
mindragon
16
Years of Service
User Offline
Joined: 3rd Jan 2010
Location: Sweden
Posted: 11th Aug 2010 10:25
Hi,

I often use a script such as this:



Put this as the main script in the (dynamic) entity you want to destroy. Then you can place a trigger zone with main script plrinzoneactivateused, and in the if used field of the trigger zone you put the name of the entity you wish to destroy.
In this case the strenth of the entity could be zero if you don“t want the player to be able to break it manually (i e shoot it). It will still get destroyed by the trigger.

Hope this makes sense!
JRH
19
Years of Service
User Offline
Joined: 8th Jul 2006
Location: Stirling, UK
Posted: 11th Aug 2010 14:50 Edited at: 11th Aug 2010 14:50
For an explosion I use these settings, this is the simplest way to achieve this:


Login to post a reply

Server time is: 2026-07-05 00:42:45
Your offset time is: 2026-07-05 00:42:45