Bohemia Interactive Forums  

Go Back   Bohemia Interactive Forums > BI MILITARY GAMES FORUMS > ARMA 2 & Operation Arrowhead > ArmA 2 & OA - ADDONS & MODS: COMPLETE

ArmA 2 & OA - ADDONS & MODS: COMPLETE This forum is for the release and subsequent discussion of addons/mods.

Only addons/mods which have content freely available for download should have threads in here.

Addons that are released in alpha/beta/final state are covered by this "Complete" forum.

Reply
 
Thread Tools Display Modes
Old 08-08-2009, 07:15 AM   #1
Jonescrusher
Private First Class
 
Join Date: May 2009
Posts: 31
Jones's Mortar and artillery script

Updated from 1.2 to 1.4

1.4 changes
Added ammo handling and saftey checks for the M119 and D30 artillery.

Demo mission folder for the editor.
http://www.yourfilehost.com/media.ph....Chernarus.zip


Rounds are actually fired, no cam created rounds. I designed it around the real artillery mod I did for Arma. If you like that mod then you will love this script.

WP and HE ammo available.

Tube data is in US military standard Mils. 6400 mils. If you haven't used mils might want to do a bit of research on it.

Registration fire mode shows impact coordinate. The pos2grid function wokrs for chenarus and utes beyond that I will have to update the function for other islands at a later time.

Settings that can be adjusted: (listed setting can be adjusted in the mortarinit.sqf file)

Safety checker script. This ensures an the specific mortar faction's ammo truck does not get any closer than 15 meters. If the ammo truck is with in 15 meters, it ejects the player from mortar. This is used as a way to restrict ammo. When this is used you have to reload ammo via the action menu and an ammo truck has to be 15 to 40 meters from the firing position. on by default

Ammo reload time: can adjust the time it takes to reload a magazine for further ammo restriction. to prevent a 30 minute spam fest. 15 seconds default.

Registration fire mode. Can adjust the time for the registration fire mode to be used. Default is 1 minute wait after impact.

Strictly player controlled, no ability to have Ai use the mortars.

Scripts are portable to any vanilla mortar ( or artillery system Version 1.4) just add the following code to the mortar init line
Code:
this addEventHandler ["GETIN", { [_this select 0] execVM "scripts\mortarUI\mortarinit.sqf"}];
Tips: Turn mouse sensitivity down for more precise aiming.
Once you have the desired tangent and elevation hold down free look (default left alt) to lock tube postion in place.
For aiming pull up compass turn mortar in desired direction and open map, place corner of compass edge, notched side by compass face. The notched side of compass will be the line you are aiming down. see image 2.

I didn't make a transoprt system for the mortar yet. There are enough scripts floating around now. I might implement a way to transport and deploy the mortars later. But for now I would suggest using Norrins attachto examples to move them around.

image 1: user interface


Image 2: Map is fully accessible with UI open


Saftey check to prevent ammo truck being parked ontop of fire position as a ammo restriction option
__________________
Can't spell peanut butter with out "nut" or "butt". Do you really want to eat it?

Last edited by Jonescrusher; 08-12-2009 at 11:36 PM.
Jonescrusher is offline   Reply With Quote
Old 08-08-2009, 09:48 AM   #2
CrazyAce
Staff Sergeant
 
Join Date: Jul 2008
Posts: 372
Quote:
Originally Posted by Jonescrusher View Post
Tube data is in US military standard Mils. 6400 mils. If you haven't used mils might want to do a bit of research on it.
Yeap never used it before, where is a good place to start besides random to unrelated searches on the Internet?
CrazyAce is offline   Reply With Quote
Old 08-08-2009, 09:58 AM   #3
Mark XIII
Master Sergeant
 
Mark XIII's Avatar
 
Join Date: Oct 2007
Location: Coventry, UK
Posts: 673
great work mate, is that jonescrusher AKA 'Death' ?
__________________
Quote:
Nu school ???
Old school ???
S**t I never even went to school...
Mark XIII is offline   Reply With Quote
Old 08-08-2009, 10:54 AM   #4
Fintroll
Suspended Member
 
Join Date: Jul 2009
Posts: 46
Nice work man, but that safety violation must go before i download. Imagine in a heat of battle when your guys are getting slaughtered, you get a damn safety violation.... In real war if there is a damn elderly lady sitting on top of that mortar you will shoot it if you have to.
Fintroll is offline   Reply With Quote
Old 08-08-2009, 11:03 AM   #5
*Alex72*
Moderator
 
Alex72's Avatar
 
Join Date: Feb 2008
Location: -STHLM-
Posts: 4,676
Both folders to be used with init line if i dont use the demo mission? Description file needed?

Yeah im green with these things. But im getting there. Slowly.

Thanks for the scripts!

Alex
__________________

+Has a bug or suggestion already been ticketed? Search the A2CIT!


+Check out the Operation Arrowhead FAQ
Alex72 is offline   Reply With Quote
Old 08-08-2009, 11:09 AM   #6
the_shadow
Warrant Officer
 
Join Date: Sep 2002
Location: Lidköping, Sweden
Posts: 2,109
Quote:
Originally Posted by CrazyAce View Post
Yeap never used it before, where is a good place to start besides random to unrelated searches on the Internet?
short explanation.

1 MIL = 1 milliradian
the compass is divided in 360 degrees or 6400 MILS.

6400/0 is north, 1600 = East, 3200 = south, 4800 = west
the scale goes clockwise.
and ofcourse the angel of aim is measured in a quarter cirkle = 1600 MILS where 0 is horisontal and 1600 is vertical (straight up)


also.
1 MIL = 1/1000 of the distance.

so if you have a object that you know is 1m wide and you measure it to 1 MIL (with the cope on a sniper rifle for example) you know it´s 1000m away. if it´s 2 MILs its 500m away.
and so on.
(a human body is usually around 0.5m at the shoulders if im correct, so if it´s 1 MIL wide in the scope it´s about 500m away)

as you can se, MIL´s is a much more accurate way of calculating direction, angle and even distance then using degrees.
__________________
there should be some kind of sig here but i cant be arsed to make one..
the_shadow is offline   Reply With Quote
Old 08-08-2009, 11:40 AM   #7
*Alex72*
Moderator
 
Alex72's Avatar
 
Join Date: Feb 2008
Location: -STHLM-
Posts: 4,676
That "monitor" seems to be out of my screen (1024x768). I can see it's frame out to the right.

Anyway of moving it for me or is a new version needed for smaller res?

EDIT: Also had a CTD when aiming straight up. 1.03.

Alex
__________________

+Has a bug or suggestion already been ticketed? Search the A2CIT!


+Check out the Operation Arrowhead FAQ
Alex72 is offline   Reply With Quote
Old 08-08-2009, 03:41 PM   #8
Jonescrusher
Private First Class
 
Join Date: May 2009
Posts: 31
Quote:
That "monitor" seems to be out of my screen (1024x768). I can see it's frame out to the right.
I will make an alternate .Hpp file for lower res monitors.
not sure about the CTD being related first I have heard of that. I will look the the script for possible conflicts

Quote:
Nice work man, but that safety violation must go before i download. Imagine in a heat of battle when your guys are getting slaughtered, you get a damn safety violation.... In real war if there is a damn elderly lady sitting on top of that mortar you will shoot it if you have to.
It can be disabled via the mortarinit.sqf file. set this variable to false
Code:
MortSafety = true;

Quote:
great work mate, is that jonescrusher AKA 'Death' ?
yep one and the same

Quote:
Both folders to be used with init line if i dont use the demo mission? Description file needed?
Just transfer the folders to your mission folder and add this line to your description.ext
Code:
#include "dialogs\mortarUI\JonesMortDialg.hpp"
__________________
Can't spell peanut butter with out "nut" or "butt". Do you really want to eat it?
Jonescrusher is offline   Reply With Quote
Old 08-08-2009, 04:30 PM   #9
dkraver
Master Sergeant
 
Join Date: Nov 2001
Location: Denmark
Posts: 655
Dont really get the mils in the elevation part. Can any one explain how to calculate the distance??
__________________

Click here to see tag details
dkraver is offline   Reply With Quote
Old 08-08-2009, 05:19 PM   #10
Cionara
Staff Sergeant
 
Cionara's Avatar
 
Join Date: May 2009
Posts: 206
Yea need it too, I shot a little bit and it was like:

500 meters = elevation 1485
700 meters = elevation 1450
1000 meters = elevation 1400

And is there some kind of cluster-ammo ?
When I try to hit T1 I never hit the bus because it's so small, only the big house next to it.
__________________
Watercooled
i7 920 @ 4,3GHz @ 1,36V
GTX280- 700/1188
6144 MB-DDR3 1333Mhz 7-7-7-18
21.686-3dMark06 (Win7)

Last edited by Cionara; 08-08-2009 at 05:22 PM.
Cionara is offline   Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT. The time now is 04:46 AM.


Powered by vBulletin® Version 3.8.2
Copyright ©2000 - 2010, Jelsoft Enterprises Ltd.