OFPEC Forum

Editors Depot - Mission Editing and Scripting => OFP - Editing/Scripting General => Topic started by: Shove It on 21 Jun 2004, 10:34:07

Title: Heavy bombing
Post by: Shove It on 21 Jun 2004, 10:34:07
You know those a-10 Thunderbolts (LGB) that have very powerful bombs (GBU-24) that can blow up loads of stuff at once, well I need a command to put in a trigger in the On Activation bit so that I can have AIs fire them whenever I want. I really need it cause I'm working on the biggest bombing raid in history!!!!!!!!! ;D ;D
Title: Re:Heavy bombing
Post by: CrashnBurn on 21 Jun 2004, 18:06:31
I tried to do that once using the fire command, but could'nt get it to work. You can fake it using the camcreate, setdir, getdir, and setvelocity commands. Here's an example-

bomb1 = "LaserGuidedBomb" camcreate getpos hog1; bomb1 setdir getdir hog1; bomb1 setvelocity [50,0,-10]

The setvelocity command has to be tweaked depending on the speed and direction of the plane. The above example was for an A10 flying east at limited speed.
Title: Re:Heavy bombing
Post by: Shove It on 22 Jun 2004, 06:22:07
Thanks but I don't like faking stuff, unless, (sorry I can't go on OFP now because I lent it to someone) unless you would actually see the bombs drop. You see, I don't like using pages of script that you have to download and refer to on OFP and I don't like faking stuff at all. There has to be some other solution.
Title: Re:Heavy bombing
Post by: CrashnBurn on 22 Jun 2004, 08:23:15
Yes you can see the bombs drop and it looks very realistic and only requires a few triggers. No scripting is necessary.
Title: Re:Heavy bombing
Post by: Shove It on 22 Jun 2004, 16:05:33
Ok, then it should be perfect. I'm very desperate so I'm running over my principles (yes, I'm a nerd). I'll test it as soon as I get OFP back.
Title: Re:Heavy bombing
Post by: Shove It on 22 Jun 2004, 16:07:27
What is hog1?
Title: Re:Heavy bombing
Post by: Shove It on 22 Jun 2004, 16:50:47
Ok I just got OFP back and I worked it out. It's great, but how do I change the formula if the hog1 (a-10) is flying west?
Title: Re:Heavy bombing
Post by: Iceholey on 22 Jun 2004, 17:59:58
If you don't like simulated LGBs, you can use the command

planename fire "LaserGuidedBomblauncher"

But I think its fair to warn you that it will be very inaccurate.

If you are after a really really heavy duty and indiscriminate bombing run, then you could try a simple script like this:


_plane= _this select 0
_Bombs= _this select 1
_interval = _this select 2

_Counter1= 0

#Bomb
? (_Counter1 == _Bombs ): exit
_plane fire "LaserGuidedBomblauncher"
~(_interval)
_Counter1 = _Counter1 + 1
Goto "Bomb"

Give your script a name and use a command line like
[planename, 5, 2] exec "thisscriptname.sqs"
Title: Re:Heavy bombing
Post by: Iceholey on 22 Jun 2004, 18:11:59
Sorry, in answer to your previous question, you could try tweaking the velocity speed i.e. bomb1 setvelocity [-50,0,-10]

You could take it a bit further with:

bombdirx = getdir bomb1 select 0; bombdiry = getdir bomb1 select 1; bomb1 setvelocity [(bombdirx)*0.5, (bombdiry)*0.5, -10]
Title: Re:Heavy bombing
Post by: Dubieman on 23 Jun 2004, 04:27:45
Err did you guys miss the laser designator? :o :P

That's its purpose in the game, I think its one of those

man dofire LaserDesignator

things coupled with a looping dotarget such and such. The bombs actually come out of the plane so its a plus for realism.

Also there is a invisible targets addon around somewhere, try lookin in ofp sites for it, like opflashpoint.org or ofp.info and they might have it.

There's a invisible laser target. Set it to east and let the A10s at it, they will bomb the crap out of everything near that laser until they are out of ammo. ;D
Title: Re:Heavy bombing
Post by: Dubieman on 23 Jun 2004, 04:31:37
Here it is, just download it, unzip it and put it in the addon folder. Sorry but the readme is in dutch but the addon is self explanatory. ;)

 
Title: Re:Heavy bombing
Post by: Shove It on 25 Jun 2004, 06:24:20
I'm not going to use the type of script that you put in the addons folder because it doesn't work with me, but thanks anyway, thanks for all the help, this bombing raid is going to be a lot more eventfull. Oh by the way, does anyone know what I should call the bomb with the fire command for the camel planes cause I might make a slightly different bombing raid with those.
Title: Re:Heavy bombing
Post by: Dubieman on 25 Jun 2004, 14:36:54
Its not a script, its an invisbile unit. Like a Game logic, but it s targeted by the opposing side depending on what kind you put there. It really helps in makin bombing or cover fire those sort things. The download itself is like only 2 kb.

OR

Try and get my laser designator to work. There has to be a thing in the ed depot on it or a search of the forums would reveal how to do this. :P

Otherwise your camcreating stuff.
Title: Re:Heavy bombing
Post by: Shove It on 26 Jun 2004, 08:40:22
As long as I have to download it and it does not have an installer, I can't use whatever it is. Thanks anyway.
Title: Re:Heavy bombing
Post by: Planck on 26 Jun 2004, 12:43:39
Hmmmm.......How difficult can it be, putting a PBO file in your Addons folder.

I think switching the computer on is only slightly less complex.



Planck
Title: Re:Heavy bombing
Post by: Shove It on 26 Jun 2004, 13:33:05
If you were calling me retarded, think again dcikweed. I didn't say I couldn't do it, I said it doesn't work with me because my computer is so messed up. And before you try to say something else stupid, yes, my computer is plugged in, no, I'm not looking at the washing machine while typing, and yes, I did set up the computer before attempting to use it.
Title: Re:Heavy bombing
Post by: Planck on 26 Jun 2004, 14:52:03
So, am I to understand then, that you have absolutely no addons in your Addons folder, apart from the original addons that came with the game?

btw......There is no need to resort to abusive language.  All you needed to do was to specify in a little more detail why putting addons into your Addons folder does not work.  What method do you use to copy them there, what exactly do you mean by 'it doesn't work'?

However on reflection, I would say you should go to the Official Forums for help with this sort of problem.


Planck
Title: Re:Heavy bombing
Post by: KTottE on 26 Jun 2004, 18:15:04
Be nice now kids.
Title: Re:Heavy bombing
Post by: DBR_ONIX on 27 Jun 2004, 12:04:23
But wheres the fun in that :P
Nah, j/king
Anyway, this will set the bombs velocity to the same as the plane :
bomb1 = "LaserGuidedBomb" camcreate getpos hog1; bomb1 setdir getdir hog1; bomb1 setvelocity [velocity hot1 select 0,velocity hog1 1,velocity hog1 -10]

So if the plane is flying that way, at 150km/h to the right, the same to the left (It's flying it 45* I guess), and down at 10km/h.. The bomb goes left 150kmh, forwards 150kmh, and down at 20kmh (If it gives some error, remove the "velocity hog1" bit, it should still work fine)

Hope this helps,
And yeah, don't swear etc

- Ben
BTW, if your having trouble with the addons stuff, try adding -nomap to the shortcut for OFP on the desktop (Right click > properties, and change the link to flashpoint.. The end should look like this : Flashpoint.exe" -nomap)
Thats all I can't think off
Title: Re:Heavy bombing
Post by: Shove It on 28 Jun 2004, 06:37:47
Sorry about my last message, I was a bit annoyed that day but never mind. About the addon problem. I mentioned it on a different site and nobody could solve the problem. There was one guy though who had the same problem. And he had an unofficcial upgrade disc called Between the Lines which had a really amateur made campaign by the way but the editor extras are good. Anyway, I also have that upgrade, so maybe its that, but it could also be the way I'm copying the files so I'll tell you how I do that. What I do is simply find the .pbo file and right click, copy it, go to RESISTANCE (D)/FlashpointResistance/Res/AddOns and I put the copied .pbo file in that addons folder. Am I doing it right?
Title: Re:Heavy bombing
Post by: DBR_ONIX on 28 Jun 2004, 19:34:57
If you use Ctrl+C after selecting the file
And go the OFP Folder > Addons, and Ctrl+V in there
Thats what I do
They might not work in the Res/Addons folder
Hmm.. Hold on.. Do you have an Operation Flashpoint/ folder?
I only have the GOTY edetion, it's different

So I'm not sure.. But try putting it in the non-resistance addon folder
Dunno
- Ben
Title: Re:Heavy bombing
Post by: Planck on 28 Jun 2004, 19:39:43
Basically your method seems sound.

However, I never put any addons into Res\Addons unless it is stated by the maker that it NEEDS to be there.

I always put third party addons in the standard Addons folder.

My method is a little quicker than yours.

I highlight the PBO file.....press Ctrl-C......go into the standard Addons folder.......press Ctrl-V.


Planck
Title: Re:Heavy bombing
Post by: Shove It on 29 Jun 2004, 06:24:59
The problem is, I can't get into my addons folder without going to res. If I inserted the original disc for OFP then would it work, if no, somebody tell me what res is cause I can't find another way to get to the addons folder. If you don't know then just tell me how you get into your addons folder.
Title: Re:Heavy bombing
Post by: Planck on 29 Jun 2004, 21:25:20
I installed the original Flashpoint, patched to version 1.46.

This installation has an Addons folder.

The folder structure inside the OperationFlashpoint folder is:

Addons
Bin
Campaigns
DTA
Missions
MPMissions
SPTemplates
Templates
Users
Worlds

When I installed OFP Resistance, this added the Res folder to the above list.

Inside the Res folder I have the following folder structure:

Addons
Bin
Campaigns
Dta

I never put any addons into the Res\Addons folder unless it has to be put in there, as specified by the addon maker.

I normally put all addons into the first Addons folder.

If you do not have an Addons folder, apart from the one inside the Res folder, you could always create one in the same location as the original should be and put third party addons in there.

Let us know if this works for you


Planck
Title: Re:Heavy bombing
Post by: Shove It on 30 Jun 2004, 08:53:36
I don't know where the original one is supposed to be. According to me, I never had an original or any other addon folder plus how do I create this folder. I know how to create a folder but if I put an addon in it would it still work, or do I hav eto change something with the things that that folder does, cause I don't know how to do that.

Also could someone tell me what to call those bombs that the WW1 camels use.

planename fire "?????"
Title: Re:Heavy bombing
Post by: Shove It on 06 Jul 2004, 08:26:12
Doesn't anyone know the script?