Home   Help Search Login Register  

Author Topic: JBOY Molotov Cocktail  (Read 9015 times)

0 Members and 2 Guests are viewing this topic.

Offline johnnyboy

  • OFPEC Patron
  • ****
  • Matan los Pantalones!!!
JBOY Molotov Cocktail
« on: 20 Dec 2008, 02:01:46 »
Tis the season for cocktails my friends...Molotov Cocktails!   :cool2:  My Xmas present to all the pyromaniacs in the community...

Demonstration video link:  http://www.youtube.com/watch?v=d0ReNnmPAnY

Addon required:   EditorUpdate_v102.pbo.

With this script, AI and players can throw Molotov Cocktails.

Features:
1.  Thrown grenade replaced by a bottle object.
2.  Bottle in-flight has flame and smoke trail.
3.  Bottle impact has glass breaking sound effect.
4.  Flame appears at point of impact (i.e., half-way up a wall, on the ground, side or roof of vehicle).  
5.  Flame attaches and moves with vehicles.
6.  Men hit with molotov cocktails will burn and die.
7.  Unarmored vehicles will take slow burn damage and eventually explode.
8.  Fires have burn sound effect.
9.  Men scream when burned.

Known Issues and Plans:
1. Death animations of men result in visual position of body not consistent with position returned by getpos.  This makes it impossible to keep the fire burning on the dead body.  To get around this I am forcing men down when burning, and re-setposing the body (so flame now on body).  The tradeoff is player may see abrupt anim change and body setposing.  I think this is better than flame appearing 1 or 2 meters away from dead soldier.

2. Performance issues may develop if you have many fires (many scripts playing fire anims and sounds).  Plan to only play a sound if there is not already another nearby fire playing a sound.  This will reduce sounds played.

3. Player will see Grenade as Selected Weapon.  I was hoping I could use a Ctrl Dialog to overlay the display of "Grenade" with "Molotov Cocktail", but there is no way to detect if Player has Grenade selected...

4. Cocktails will pass through window of cars, and through to other side.  This is because I am using a spawned bullet for collision detection, and bullets pass through windows.  

Plans for improvement:
A. Burn crew of vehicles if its an open vehicle.
B. Eject crew of vehicles if open vehicle.
C. Vehicle drive erratically if hit.
D. AI needs to react to incoming cocktails?
E. Add targeting function for AI to choose targets to throw at.
F. If player is burning, an evasive ROLL action may put out fire save him (if quick enough).

Will edit this post later with instructions on how to install and use...

Is it MP compatible?  Any other suggestions to make it perform better?

All feedback welcome.  

Changes:
- Dec. 20th:  Removed dependency on Editor addon.


Edit: images lost in crash of 2009, but demo mission re-upped, courtesy of fleepee - WEK
« Last Edit: 15 Jan 2011, 18:37:07 by Walter_E_Kurtz »
El Cojon: "Do you like to Tango?"
You: "Only in Bagango."
Download Last Tango in Bagango and discover how El Cojon earned his name...

Offline hoz

  • OFPEC Site
  • Administrator
  • *****
Re: JBOY Molotov Cocktail
« Reply #1 on: 20 Dec 2008, 02:09:52 »
Will AI throw them?
Xbox Rocks

Offline johnnyboy

  • OFPEC Patron
  • ****
  • Matan los Pantalones!!!
Re: JBOY Molotov Cocktail
« Reply #2 on: 20 Dec 2008, 02:12:46 »
If scripted via UseWeapon command, for sure. 

And also whenever the normal ARMA AI instructs them to throw a grenade.  It is a fired eventhandler, so whenever grenade "fired", the script takes over.
El Cojon: "Do you like to Tango?"
You: "Only in Bagango."
Download Last Tango in Bagango and discover how El Cojon earned his name...

Offline Odin

  • Members
  • *
Re: JBOY Molotov Cocktail
« Reply #3 on: 20 Dec 2008, 02:57:28 »
 :D I love it JB this is gonna be fun for urban Riots, Maybe you could attach fire to the victims aswell that would be cool, i have a snippit somewhere for that, well I am off to flame the city of Corazol  :cool2:

Odin

Offline johnnyboy

  • OFPEC Patron
  • ****
  • Matan los Pantalones!!!
Re: JBOY Molotov Cocktail
« Reply #4 on: 20 Dec 2008, 03:05:13 »
Flame on Odin!  Flame does attach to victims.  Only I kill them quickly.

I wish there was a good panic anim or thrashing anim I could play on them, but there isn't.  So if I don't drop them to the ground right away, they calmly go about their business of walking or shooting while they are on fire (which looks really dumb).

I am loving this script though!
El Cojon: "Do you like to Tango?"
You: "Only in Bagango."
Download Last Tango in Bagango and discover how El Cojon earned his name...

Offline Odin

  • Members
  • *
Re: JBOY Molotov Cocktail
« Reply #5 on: 20 Dec 2008, 03:17:13 »
Cool played it again, I stand corrected :yes: Mwahahaha

Offline Knight Trane

  • Members
  • *
Re: JBOY Molotov Cocktail
« Reply #6 on: 20 Dec 2008, 18:28:18 »
I'm definately gonna try this.

Quote
I wish there was a good panic anim or thrashing anim I could play on them, but there isn't.

So do I.  I need civies to panic when the hordes come through.

Offline johnnyboy

  • OFPEC Patron
  • ****
  • Matan los Pantalones!!!
Re: JBOY Molotov Cocktail
« Reply #7 on: 20 Dec 2008, 20:12:49 »
Video link added to first post.
El Cojon: "Do you like to Tango?"
You: "Only in Bagango."
Download Last Tango in Bagango and discover how El Cojon earned his name...

Offline h-

  • OFPEC Site
  • Administrator
  • *****
  • Formerly HateR_Kint
    • OFPEC
Re: JBOY Molotov Cocktail
« Reply #8 on: 21 Dec 2008, 14:02:06 »
Seems to require something called "editorupdate_102", or something like that..

EDIT:
Removed the dependency from the mission.sqm and the molotov won't work, so I guess it is required for that.  :P
« Last Edit: 21 Dec 2008, 14:04:29 by h- »
Project MCAR   ---   Northern Fronts   ---   Emitter 3Ditor
INFORMATIVE THREAD TITLES PLEASE. "PLEASE HELP" IS NOT ONE..
Chuck Norris can divide by zero.

Offline johnnyboy

  • OFPEC Patron
  • ****
  • Matan los Pantalones!!!
Re: JBOY Molotov Cocktail
« Reply #9 on: 21 Dec 2008, 20:04:05 »
H, thanks for spotting that.

Its not really a dependency as the bottle objects are created via createVehicle.

I modified the mission file to remove the addon depencency, and re-uploaded the demo mission to the first post.  Should be fixed now. 

Edit:  Wrong!!!!  There is still a dependency on the addon.  Sorry about that.  I am working on it now... 
« Last Edit: 21 Dec 2008, 21:11:50 by johnnyboy »
El Cojon: "Do you like to Tango?"
You: "Only in Bagango."
Download Last Tango in Bagango and discover how El Cojon earned his name...

Offline snafu

  • Members
  • *
Re: JBOY Molotov Cocktail
« Reply #10 on: 22 Dec 2008, 13:06:40 »
Woah! I am very impressed! Reminds me of the fun I had with Gimbal's tosser addon back in OFP.

Offline h-

  • OFPEC Site
  • Administrator
  • *****
  • Formerly HateR_Kint
    • OFPEC
Re: JBOY Molotov Cocktail
« Reply #11 on: 31 Dec 2008, 23:13:42 »
Dunno if you have received any help on this, but I'll share something that might 'help' you.

ArmA is smart enough to include createVehicled stuff into the required addons in the mission.sqm which is why you get the editorupdate requirement:
If you have the editor addon installed, preview the test mission (and use the molotov) and save it the editor addon appears into the sqm because you use the bottle from that addon, and so it is required by the mission.

The problem is that even though the game files include several bottle models (that's where the editor update got it) they seem to not be available with the actual vanilla Arma :(, at least I couldn't find any entry for those in any config (well, Planck will correct this statement if they do have one ;) )..

So, to get rid off the addon requirement you either have to use some item already available in the game; closest one to a bottle would sadly be the OPFOR handgrenade model, or you just state that this editor update is required. :dunno:
Project MCAR   ---   Northern Fronts   ---   Emitter 3Ditor
INFORMATIVE THREAD TITLES PLEASE. "PLEASE HELP" IS NOT ONE..
Chuck Norris can divide by zero.

Offline Mandoble

  • Former Staff
  • ****
    • Grunt ONE and MandoMissile suite
Re: JBOY Molotov Cocktail
« Reply #12 on: 31 Dec 2008, 23:48:21 »
Or you may just use a global initialized before using the script to define the class of object to be used. So, for an addon free demo you may just use the standard road cone.

Offline johnnyboy

  • OFPEC Patron
  • ****
  • Matan los Pantalones!!!
Re: JBOY Molotov Cocktail
« Reply #13 on: 01 Jan 2009, 01:19:31 »
Thanks guys.  Since only the bottle looks good for this, I think I will just require the addon.

What is holding me up on this resource is making it MP compatible.  I asked some MP questions about this on this thread:

http://www.ofpec.com/forum/index.php?topic=32690.0

And Ionos gave me some advice on how to make it work.   I'm going to give it a try, but it sounds like a major re-write. 
« Last Edit: 01 Jan 2009, 01:24:30 by johnnyboy »
El Cojon: "Do you like to Tango?"
You: "Only in Bagango."
Download Last Tango in Bagango and discover how El Cojon earned his name...

Offline hoz

  • OFPEC Site
  • Administrator
  • *****
Re: JBOY Molotov Cocktail
« Reply #14 on: 01 Jan 2009, 02:26:32 »
If you can find a solution without the addon, that is better for everyone. Its worth the extra effort :)
Xbox Rocks

Offline Planck

  • Honoured
  • Former Staff
  • ****
  • I'm never wrong ....I'm just not always right !
Re: JBOY Molotov Cocktail
« Reply #15 on: 01 Jan 2009, 13:38:06 »
I see no solution to the bottle (addon) problem.

Either you go with the Editor102 requirement for the mission, or ...

You make your own little config.cpp that configs the bottle (or several different bottles), then PBO it as a custom config addon which you can package with the mission, with instructions to throw it in Addons.


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

Offline johnnyboy

  • OFPEC Patron
  • ****
  • Matan los Pantalones!!!
Re: JBOY Molotov Cocktail
« Reply #16 on: 01 Jan 2009, 19:55:03 »
Planck,

I've never made a config.cpp addon.  Can you (or anyone) recommend a dead-simple single object addon somewhere that I could use as an example?
El Cojon: "Do you like to Tango?"
You: "Only in Bagango."
Download Last Tango in Bagango and discover how El Cojon earned his name...

Offline Planck

  • Honoured
  • Former Staff
  • ****
  • I'm never wrong ....I'm just not always right !
Re: JBOY Molotov Cocktail
« Reply #17 on: 02 Jan 2009, 00:43:04 »
Here you go, this one works, I tried it in your mission after I edited the bottle class in your files.

Planck


Edit: Attachment (JBOY_Molotov.rar) lost in crash of 2009 - WEK
« Last Edit: 15 Jan 2011, 18:34:12 by Walter_E_Kurtz »
I know a little about a lot, and a lot about a little.

Offline johnnyboy

  • OFPEC Patron
  • ****
  • Matan los Pantalones!!!
Re: JBOY Molotov Cocktail
« Reply #18 on: 02 Jan 2009, 01:25:06 »
Wow Planck, thanks a million!

It works beautifully.  My addon learning curve would have been very steep...so you really saved me tons of work.  Much appreciated.

Now back to my MP conversion hell on this...
El Cojon: "Do you like to Tango?"
You: "Only in Bagango."
Download Last Tango in Bagango and discover how El Cojon earned his name...

Offline DeanosBeano

  • Addons Depot Staff
  • *****
  • SirDeanosbeano bstowed on me by sui ;)
    • Fraghaus
Re: JBOY Molotov Cocktail
« Reply #19 on: 02 Jan 2009, 18:55:27 »
 
 If  you cant select the bottle because it is protected or not even configed ,you could drop the shape of the bottle simply by pathing the p3d correctly, this will give you a random turning effect also i believe . not looked at your scripts but this maybe a way for you to achieve this without the need for an addon.

as for your Now back to my MP conversion hell on this.
 my own snowballers maybe similar to this and  they work in mp , look in addons and mods beta. feel free to abuse anything ya like in there regarding this.



« Last Edit: 02 Jan 2009, 18:57:48 by DeanosBeano »
I love ofp

Offline h-

  • OFPEC Site
  • Administrator
  • *****
  • Formerly HateR_Kint
    • OFPEC
Re: JBOY Molotov Cocktail
« Reply #20 on: 04 Jan 2009, 13:51:59 »
Completely and utterly forgot you could always use it as a particle.

Would be ideal because then there would be no addon requirements..
Project MCAR   ---   Northern Fronts   ---   Emitter 3Ditor
INFORMATIVE THREAD TITLES PLEASE. "PLEASE HELP" IS NOT ONE..
Chuck Norris can divide by zero.

Offline Curatalo

  • Members
  • *
Re: JBOY Molotov Cocktail
« Reply #21 on: 09 Feb 2009, 05:42:01 »
This is a very good script, and very fun to use, EXCEPT
- Its not MP compatible!

i tryed to use it in one of my Afghan misions, and when one of us would throw a Molotov, only we could se our own molotov.
If you make it MP compatible itle be great!

Offline johnnyboy

  • OFPEC Patron
  • ****
  • Matan los Pantalones!!!
Re: JBOY Molotov Cocktail
« Reply #22 on: 09 Feb 2009, 07:40:28 »
Curatalo:  Glad you like the script.  I think its fun too!  I put many hours into trying to make it MP compatible, but failed.  I plan to post an improved SP version soon.

And maybe I will post my attempt at MP compatible version, but it has real problems still.  Very complex problem...for me anyway.
El Cojon: "Do you like to Tango?"
You: "Only in Bagango."
Download Last Tango in Bagango and discover how El Cojon earned his name...

Offline johnnyboy

  • OFPEC Patron
  • ****
  • Matan los Pantalones!!!
Re: JBOY Molotov Cocktail
« Reply #23 on: 10 May 2010, 03:58:43 »
Hello.  Does anybody have my sample mission that was linked to the first post on this thread?

I lost my hard drive a while back, and lost these scripts.  And OFPEC lost it it too...  :weeping:

Please post it here or PM me if you have this script.  Thanks!
El Cojon: "Do you like to Tango?"
You: "Only in Bagango."
Download Last Tango in Bagango and discover how El Cojon earned his name...

Offline fleepee

  • Members
  • *
  • Enter the Matrix!
Re: JBOY Molotov Cocktail
« Reply #24 on: 10 May 2010, 07:36:35 »
Here it is!! :good:


Edit: re-attached to first post -WEK :good:
« Last Edit: 15 Jan 2011, 18:38:16 by Walter_E_Kurtz »

Offline johnnyboy

  • OFPEC Patron
  • ****
  • Matan los Pantalones!!!
Re: JBOY Molotov Cocktail
« Reply #25 on: 11 May 2010, 04:34:53 »
You the man Feepee!  Muchas gracias!    :clap:

Why should I ever back up my HD when all you guys have all my scripts?   ;)
El Cojon: "Do you like to Tango?"
You: "Only in Bagango."
Download Last Tango in Bagango and discover how El Cojon earned his name...