OFPEC Forum

Editors Depot - Mission Editing and Scripting => Arma2 - Editing/Scripting Resources Beta Testing & Submission => Topic started by: jones on 08 Aug 2009, 08:07:45

Title: Jones's Mortar scripts / UI
Post by: jones on 08 Aug 2009, 08:07:45
Demo mission folder for the editor.

Rounds are actually fired, no cam created rounds.
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 with in 15 meters ejects 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. The 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 mortar system. just add the following code to the mortar init line
Code: [Select]
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.

image 1: user interface
(http://img37.imageshack.us/img37/3995/jonesmortarui.jpg)

Image 2: Map is fully accessible with UI open
(http://img9.imageshack.us/img9/4686/mortarmap.jpg)

Saftey check to prevent ammo truck being parked ontop of fire position as a ammo restriction option
(http://img14.imageshack.us/img14/2050/safetycheck.jpg)
Title: Jones's Mortar scripts
Post by: jones on 08 Aug 2009, 08:10:32
Merged topics. Edit as you please :) ~Wolfrug

Thank you