I've added exploding barrels to my Venice map and I would like to respawn them after a given time but only when the one at that specific location has been destroyed.
Tltrude's Thread for spawning explosive crates in stock maps has convinced me to try and use that setup... but I have no idea how to let the script determine wheter or not the barrel at that spot is destroyed.
Exploding barrels instead of Tltrude's popup boomcrates ?
Moderator: Moderators
this should work
isalive is really meaning, in existance.
Code: Select all
if($barrel isalive)
{
// dadadadadadadada
}Moderator
۞
Abyssus pro sapientia
Olympus pro Ignarus
۞
AND STUFF™ © 2006
۞
Abyssus pro sapientia
Olympus pro Ignarus
۞
AND STUFF™ © 2006
func_barrel
Far as I know, you can't move a func_barrel--not sure if you can even spawn one. My exploding crate thread uses the indicrate model, and there is no model for barrels.
So, your barrels will have to be script_objects that are already in the map. You can use "hide" and "show" to make them vanish and come back. But, the rest of the crate thread should work for the explosions and stuff.
So, your barrels will have to be script_objects that are already in the map. You can use "hide" and "show" to make them vanish and come back. But, the rest of the crate thread should work for the explosions and stuff.
it seems easy to me, make your barrel, make it a script_object, open your .mp file with Notepad, find the barrel, copy it's sizes, and spawn it at xyz with setsize ... ... ... .. ... ..not sure if you can even spawn one
i thought all entities could move as well :S jsut not brushes.Far as I know, you can't move a func_barrel
Moderator
۞
Abyssus pro sapientia
Olympus pro Ignarus
۞
AND STUFF™ © 2006
۞
Abyssus pro sapientia
Olympus pro Ignarus
۞
AND STUFF™ © 2006
Yeah probably you could just do:
Code: Select all
local.barrel_pos = $mybarrel.origin
local.barrel_bmodel = $mybarrel.brushmodel // bsp brush ref
local.barrel =$mybarrel
while(1)
{
local.barrel waittill death
wait 5.0
// make new barrel
local.barrel = spawn BarrelObject origin local.barrel_pos model local.barrel_bmodel
}
wow!
That is cool, jv_map! That means there only has to be one real barrel, somewhere in the map, and more barrels can be spawned using it.
Of course, they are not exploding barrels--just the brushes.
Of course, they are not exploding barrels--just the brushes.
-
Master-Of-Fungus-Foo-D
- Muffin Man
- Posts: 1544
- Joined: Tue Jan 27, 2004 12:33 am
- Location: cali, United States
Re: Exploding barrels instead of Tltrude's popup boomcrates
hes not script spawning guys a func_barrel outta nowhere.. he'll map it.Kalti wrote:I've added exploding barrels to my Venice map...



