Home   Help Search Login Register  

Author Topic: Detailed explosion script  (Read 3127 times)

0 Members and 1 Guest are viewing this topic.

Offline Triggerhappy

  • Contributing Member
  • **
  • Llama, it's what's for dinner.
Detailed explosion script
« on: 05 Nov 2004, 01:29:35 »
New version (see later post)
Parameters for script:

UnitName = name of unit, vehicle, object, to create the explosion at
AmmoType = Explosive that will explode on impact (ex. "shell120") (!must be a string!)
Height = height above the unit (the shell will fall to the ground)
delay = time before the explosive
drop/explode (solution to question 2) = 1 or 0,  1 = explodes in air, 0 = falls to ground
see new version post for how to execute

Things i would like to know:
1) which versions of OFP will this work with? (I have v. 1.96) #SOLVED#

2) should i make the explosion happen in the air or let it fall? (i could make it selectable also) #SOLVED#

3) what explosives are there, so far i know of:
Shell73
Heat73
Gun73
Shell105
Heat105
Gun105
Shell120
Heat120
Gun120
Shell125
Heat125
Gun125
LaserGuidedBomb
Timebomb
Flare
FlareGreen
FlareRed
FlareYellow
HandGrenade
SmokeShell
SmokeShellRed
SmokeShellGreen
Please add to this list or correct anything so i can include these with my script

Thanks!  :D
« Last Edit: 12 Nov 2004, 00:14:31 by Triggerhappy »

Offline Triggerhappy

  • Contributing Member
  • **
  • Llama, it's what's for dinner.
Re:Detailed explosion script
« Reply #1 on: 07 Nov 2004, 23:40:59 »
won't nobody test it?  :'(
or even just answer questions 2 and 3 based on preferance/knowledge (respectively) if you don't want to bother checking out the script?

Dubieman

  • Guest
Re:Detailed explosion script
« Reply #2 on: 08 Nov 2004, 05:04:13 »
Will test soonish, its bed time u know. ;)

Sounds good, but err, I kinda made one too, but only for in the air, no falling shells in my script. If you wanna get ideas from it, its in the ed depot. But its rather simple. :P

Try this list at the bottom, it has many names. Satchels are weird, but timebombs are fun. Make it and 30secs later, boom. ;D

1.) Not sure of version, when was camcreate put in? :-\

2.) Either, I encourage both, it'd have more features than mine. :'( *sniff sniff*

In air is good for well, anything and falling is good for, well whatever situation warrants... :P

3.)Above, may not be complete... :P


Offline Triggerhappy

  • Contributing Member
  • **
  • Llama, it's what's for dinner.
Re:Detailed explosion script
« Reply #3 on: 08 Nov 2004, 11:05:43 »
I've seen your script, and i did get some ideas from your description (but didn't copy any of the script)

already have that list actually... and i don't know how i would make satchels work for this script ???

1) yeah it uses camcreate

2)ok I'll make that selectable  :P

3)didn't think so... what is the name for a laser guided bomb?
just laserguidedbomb or i think i've seen laserguided before...

Dubieman

  • Guest
Re:Detailed explosion script
« Reply #4 on: 08 Nov 2004, 20:20:14 »
I don't mind if you copy parts of my script, just as long as yours has good features in the end. ;)

1.) camcreate in V1.75? I've heard something about using the wierd setpos an exploding vehicle at different parts of the map for arty, in 1.46 I think. So maybe it was resistance...

2.) yeah

3.) its "LaserGuidedBomb"

And satchels, I dunno how to make them activate without some dude hitting the trigger. Maybe you can command it or something like a Blackops guy, but just like if there was no guy.... :P  

Giving orders to inanimate objects... lol ;D

 

Offline Planck

  • Honoured
  • Former Staff
  • ****
  • I'm never wrong ....I'm just not always right !
Re:Detailed explosion script
« Reply #5 on: 08 Nov 2004, 20:29:33 »
I think camCreate was always there. createUnit and createVehicle however were introduced in 1.34.


Planck
I know a little about a lot, and a lot about a little.

Offline Triggerhappy

  • Contributing Member
  • **
  • Llama, it's what's for dinner.
Re:Detailed explosion script
« Reply #6 on: 08 Nov 2004, 22:18:36 »
1) maybe someone knows of an old comref i can look at?

3)I'll look around for the satchels, maybe its got a script in one of the pbos that come with the game

new version soon

Dubieman

  • Guest
Re:Detailed explosion script
« Reply #7 on: 08 Nov 2004, 23:10:06 »
Couldn't get your script to work. I looked at it and couldn't figure out the objects for the array.

Couldn't remember your post so I'm still wonderin how to call. Simple example mission please.

Ahh crap. I was so close, got numbers mixed up. But an example mission would still help.  :P


Offline Triggerhappy

  • Contributing Member
  • **
  • Llama, it's what's for dinner.
Re:Detailed explosion script
« Reply #8 on: 09 Nov 2004, 01:48:44 »
wish granted, its attached, also a new verison of the script is in there, which allows you to select whether to explode in air or drop if you give it a height or its hitting a flying unit etc., also got rid of the need for the extra brackets.

Code: [Select]
[[unit,ammo,height,delay,Drop/explode],[etc.]] exec explode.sqsdrop/explode is either 1 or 0, 1 will make it explode as soon as it is made, 0 will let it fall if it has a height.
« Last Edit: 12 Nov 2004, 00:26:15 by Triggerhappy »

Dubieman

  • Guest
Re:Detailed explosion script
« Reply #9 on: 09 Nov 2004, 20:33:13 »
Ok will get around to it tonight.




« Last Edit: 09 Nov 2004, 20:34:14 by GuiltyRoachKillar »

Offline Triggerhappy

  • Contributing Member
  • **
  • Llama, it's what's for dinner.
Re:Detailed explosion script
« Reply #10 on: 11 Nov 2004, 01:11:21 »
according to the official comref (v.1.85) camcreate doesn't have a required version...
could someone test it who has v. 1?
« Last Edit: 11 Nov 2004, 01:11:56 by Triggerhappy »

Offline Planck

  • Honoured
  • Former Staff
  • ****
  • I'm never wrong ....I'm just not always right !
Re:Detailed explosion script
« Reply #11 on: 11 Nov 2004, 02:41:45 »
camCreate AFAIK came with the game when it first came out.


Planck
I know a little about a lot, and a lot about a little.

Dubieman

  • Guest
Re:Detailed explosion script
« Reply #12 on: 11 Nov 2004, 19:26:29 »
Ok, sorry for delay.  :P

Did your test mission. It looks good for chains of explosions. That's what I see it as. Good for chains or something like your ambush mission. It seemed a bit odd atbfirst cause it needs an array in an array. But it is okay for a single explosion, sometimes hard to remember what number does what. :)

I like its features and everything seemed to work. The delay, the in the air or not. The height and all. Worked seemless.

Although it may be complicated for beginners, but good job. Maybe someway to make it not like guessing:
[[target1,"LaserGuidedBomb",15,1,1,5]] exec "explode.sqs" to find out which of the last numbers does what.

But good script. Looks almost finished. One last thing, maybe make a singular trigger for your ex. mission. Just to keep it simple maybe. :P



Offline Triggerhappy

  • Contributing Member
  • **
  • Llama, it's what's for dinner.
Re:Detailed explosion script
« Reply #13 on: 11 Nov 2004, 21:52:11 »
hmm.. perhaps if i changed their order so that the the 3 numbers were seperated by the object and the ammo string, then i could check for whether it is the right thing in each spot, and hint if it is wrong... I think i could make it so it would require a true/false setting for the dropping thing

about the array in an array, i had to make it that way so that each explosion's attributes can be individually specefied

Offline Triggerhappy

  • Contributing Member
  • **
  • Llama, it's what's for dinner.
Re:Detailed explosion script
« Reply #14 on: 12 Nov 2004, 00:30:37 »
new version:
less confusing
called like so:
Code: [Select]
[[delay,unitname,ammotype,height, drop/explode(optional, left blank will cause it to fall)],[repeat as necessary]] exec "explode.sqs"
drop/explode is now "air" to explode in air, anything else, including nothing, will cause it to fall

EDIT: see the readme for refence or whatever when using the script
« Last Edit: 12 Nov 2004, 00:32:12 by Triggerhappy »