puff of smoke and falling beams
Moderator: Moderators
puff of smoke and falling beams
I can't seem to find what I want, what is the easiest way to create a cloud of dust with a couple beams falling and block the player's retreat after triggering a bomb?? Thanks.
-
Bjarne BZR
- Site Admin
- Posts: 3298
- Joined: Wed Feb 05, 2003 2:04 pm
- Location: Sweden
- Contact:
ok say I have a beam called beam1 and a script origin where I want it to go called beam1loc, so should I have this:
then I should insert a script model with model/fx/dummy.tik called dustemitter then:
or what?
Code: Select all
$beam1 moveto $beam1loc
Code: Select all
$dustemitter model emitters/tankdust.tik
yes
So far so good. But the dust emitter does not have to be a script_model. In the script you can stop/start the animation for it with this.
$dustemitter anim stop
$dustemitter anim start
$beam1 time 1.2 // travel time in seconds
$beam1 moveto $beam1loc
$beam1 move
If you want beam1 to bounce when it hits the ground, make it a "func_fallingrock". Then you would just need "$beam1 start" in the script to make it fall.
$dustemitter anim stop
$dustemitter anim start
$beam1 time 1.2 // travel time in seconds
$beam1 moveto $beam1loc
$beam1 move
If you want beam1 to bounce when it hits the ground, make it a "func_fallingrock". Then you would just need "$beam1 start" in the script to make it fall.
Code: Select all
/*QUAKED func_fallingrock (0.75 0.75 0.75) ?
Scorpios comments/information:
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Description:
------------
A volume of falling rock.
Spawnflags:
===========
None !
Values:
=======
None !
Functions:
==========
"bounce" sent to entity when touched.
"dmg" ( Integer dmg ) Set the damage from the rock.
"doActivate" ( Entity activatingEntity ) General trigger event for all entities
"doTouch" ( Entity touchingEntity ) sent to entity when touched.
"noise" ( String sound ) Set the sound to play when the rock bounces
"rotate" rotates the falling rock.
"speed" ( Float speed ) Set the speed that the rock moves at.
"start" Starts rock falling.
"wait"( Float wait ) How long to wait before rock starts falling.
Internal Engine Use:
====================
None !
Not sure ?:
===========
None !
*/
Last edited by tltrude on Sun Apr 04, 2004 9:41 am, edited 1 time in total.
ok sweet! thanks tom! I have the beam working but I'm still trying to get the dust. Actually what should I use for an explosion, I want an explosion then I'll have a couple beams fall and a wall fall over and lean up against the wall on the other side of the hallway. Also what are the other move commands? like rotatex 90 and so on?
well,u could make a test map like i did and test all the effects in it .place all the effects u want then script them 2 turn on and off at different times while a visual indicator helps u understand when one is activated or not.i used a box to indicate when an effect is starting and stopping (move up move down).
after that choose the effect u like then place it in ur map
after that choose the effect u like then place it in ur map
func_fallingrock
If you want that func_fallingrock to be in the editor, copy the code from above (ends with "*/") to Notepad. and save it as "anyname.ccp" (rock.cpp maybe). Then place the file in main/code (make a code folder). The entdefs.pk3 has the same type files, but this one was not included. I'm still learning how to use the func_fallingrock. It will not bounce at an angle as far as I can tell. But, it does damage players, if that is set.
Here is a thread I used to test it falling into water. The thread just starts when the game does, and "$rock hide" is in prespawn.
"$water _hit" is an "animate/fx_mortar_water.tik" entity.
Here is a thread I used to test it falling into water. The thread just starts when the game does, and "$rock hide" is in prespawn.
Code: Select all
rock_hit:
wait 20
$rock show
$rock start
while !($rock istouching $water_hit_trigger) // waits until the rock touches the trigger.
waitframe
$water_hit_trigger playsound grenade_exp_water
$water_hit anim start
end


