Jump to content

Home

Falling Func_Breakable Destroys a 2nd func_breakable


Obsidian-Jovani

Recommended Posts

*Note: I tried the search, but in all the results it didn't answer my question.

**************************************************

Ok. Func_breakable #1 drops from the ceiling on top of a Func_breakable #2. I need both of them to destroy themselves when they hit each other. How do I do this?

 

Here is the code to drop func_breakable #1:

//Generated by BehavEd

 

rem ( "stalagmite01 Script" );

rem ( "Script by: Obsidian-Jovani" );

 

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

{

rem ( "Move stalagmite01 to ref_tag stalagmite01_stop" );

move ( $tag("stalagmite01_stop", ORIGIN)$, $< 0 0 0 >$, 1000.000 );

 

}

 

I tried placing a Trigger_once & then a trigger_hurt on top of fun_breakable #2 and targeted both brushes to destroy, but it didin't work. Is there something I can add in the script? Ideas?

Link to comment
Share on other sites

Bah.

 

I tried to SET_HEALTH to a negative, but it just made the func_breakable invincible.

 

An idea: after move put in the following:

wait ( 1000 );

use ( "stalagmite01" );

use ( "stalagmite02" );

 

Then I tried your idea Leslie, but it still didn't work. :(

 

Any more ideas?

Link to comment
Share on other sites

Originally posted by Leslie Judge

Put those 3 lines after the whole affect.

 

Well I did that, but it still failed to blow up.

 

rem ( "stalagmite01 Script" );

rem ( "Script by: Obsidian-Jovani" );

 

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

{

rem ( "Move stalagmite01 to ref_tag stalagmite01_stop" );

move ( $tag("stalagmite01_stop", ORIGIN)$, $< 0 0 0 >$, 1000.000 );

}

 

wait ( 1000.000 );

use ( "stalagmite01" );

use ( "jumpblock01" );

 

 

Could my ref tag be in the wrong place? I ask this because right now stalagmite01 kinda sinks into jumpblock01 a few units.

 

I also tried using: kill ( "stalagmite01") but that failed too.

Link to comment
Share on other sites

Grrr.

 

It seems like the USE command would work. I wonder if something is wrong in my func_breakable properties. Here is what I have on them:

 

Stalagmite

Key: script_targetname

Value: stalagmite01

 

Key: splashDamage

Value: 25

 

Checkboxes IMPACT & NO_EXPLOSION

 

*************

 

jumpblock

Key: script_targetname

Value: jumpblock01

 

Key: material

Value: 4

 

Key: radius

Value: 2

 

Key: delay

Value: 1

 

Checkboxes IMPACT

 

Should I be using paintarget too? Ideas?

Link to comment
Share on other sites

Ok, MP-Mapping idea, but anyway: When triggering the first stalagnite- stop the time it takes for it to drop to the second one. Then make the first trigger trigger the second one (just include the wait-command) you should get it to time pretty good- given the wait are 100th of a second....

 

Just my 2 cents...

Link to comment
Share on other sites

Originally posted by Leslie Judge

Nah, OK, I get it.

 

To affect something in a script you need a script_targetname. And you have it right.

 

BUT to use something, even from a script, you need a targetname.

 

L.J. you are a God send. Thanks so much. It works great now.

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...