I have been banging my head all night. I am new to mapping and scripting. I have learned alot through forums,tuts and trial and error. I have a plane that is set up to drop multiple bombs. The splinepaths are connected and the set numbers are correct. The problem is it drops the first bomb and that explodes and does exactly what it is suppose to do. The second bomb how ever i can see deploy and hit target but no explosion. Also the bombs can only be triggered 1 time but my planes i have scripted the triggers to reset and they work fine. So why would the bombs not repeat if they are on the same spline path?
Any help would be graetful in this matter.
thanks
Spc. Debord
U.S. ARMY
Camp Kalsu Iraq
Bomber plane multiple bombs help!
Moderator: Moderators
-
Annihillator
- Private
- Posts: 2
- Joined: Sun Jul 10, 2005 3:44 am
- Contact:
Assumeing you are useing the global/bomber.scr this thread from that script may help
for (local.i=1;local.i<level.bombers+1;local.i++)
{
if (local.name == level.bomber[local.i].set)
{
if (level.bomber[local.i].loop == 0)
{
level.bomber[local.i].loop = -1
level.bomber[local.i] thread bombdrop local.name local.i
}
else
if (level.bomber[local.i].loop == 1))
level.bomber[local.i] thread bombdrop local.name local.i
}
}
-
Annihillator
- Private
- Posts: 2
- Joined: Sun Jul 10, 2005 3:44 am
- Contact:
Very hot the weather that is and tahnks for the welcome. I am running the global exploder scr.. I did get part of my problem solved with the bombs exploding. I am going to try the loop you recommended and i will post the results as soon as I possibly can. thanks for your help in advance I really appreciate it.
I see but the global/exploder.scr is a one shot script there isn't anything in the script to reset the explosion . I wrote something called the global/strafe.scr to make strafeing planes that can also bomb . It is at my site if you want to take a look at it . You can shut off the guns if you don't want them
No that is not true if you look at these two threads from the global/bomber.scr
So targetname bomber give it a set number and the Key: loop Value: 1 then you will be able to use it again .
bombdrop local.name local.num:
local.range = vector_length (self.origin - $("bomberplane" + local.name).origin) + 100
local.oldrange = local.range
// println local.range
local.time = level.time + 1
// while ((local.range < local.oldrange) || (local.range > 500))
while (level.time < local.time)
{
wait 0.1
}
while (local.range > 200)
{
local.oldrange = local.range
local.range = vector_length (self.origin - $("bomberplane" + local.name).origin)
wait 0.1
}
spawn script_model "targetname" ("bombdrop" + local.num)
$("bombdrop" + local.num) playsound drop_bomb
$("bombdrop" + local.num).origin = self.origin
$("bombdrop" + local.num) playsound drop_bomb
$("bombdrop" + local.num) model "ammo/us_bomb.tik"
$("bombdrop" + local.num) notsolid
$("bombdrop" + local.num) scale 1
$("bombdrop" + local.num) flypath self 2500 2000 256
// speed accell lookahead
$("bombdrop" + local.num) waitmove
thread spawntankshot $("bombdrop" + local.num).origin
if (self.setthread)
{
println ("Bomb from set " + local.name + " threading " + self.setthread)
$("bombdrop" + local.num) thread level.script::self.setthread
}
$("bombdrop" + local.num) delete
end
If you do it as the script say then the bomb is not useing the global/exploder.scr it uses the models/emitters/explosion_mine.tik to do the explosion . If you want me to spell it outspawntankshot local.vec:
exec global/model.scr local.vec "models/emitters/explosion_mine.tik"
thread killwithboom local.vec
radiusdamage local.vec 500 500
end
Use the loop key on the first spline of the bomb path the one with the targetname $bomber the spline path next to one of the splines that the plane flys that is the first spline of the path the bomb takes when it falls .if (level.bomber[local.i].loop == 1)
So targetname bomber give it a set number and the Key: loop Value: 1 then you will be able to use it again .
- small_sumo
- Lieutenant General
- Posts: 953
- Joined: Mon Jul 01, 2002 4:17 pm
- Contact:



