Jump to content

Recommended Posts

Description

This dialog is supposed to make the training of firing drills easier. It will show the current target, stats of the last shot and gives the opportunity to evaluate your firing discipline.

 

Features

  • Camera on the target
  • Stats from last shot
  • 3D model and hit position
  • Mini map with position of targets
  • Activate and deactivate selected target
  • MP compatible (tested on dedicated and hosted with 2 players, NOT TESTED WITH JIP)
  • Localized in German and English

 

Picture

fUhnVaE.jpg

 

Usage

To add a target to the list add this to the object init:

this setVariable ["TER_isTarget", true];

I recommend to only use objects of the type "Pop-Up Target X".

Open the dialog with

createDialog "TER_target";

Include the following files in your main mission folder (where the mission.sqm is):

  • Add these two lines to your description.ext (or create it): 
    • #include "TER_TargetGUI\defines_A3.hpp"
    • #include "TER_TargetGUI\TER_target.hpp"
  • Put this in the initPlayerLocal.sqf (or create it):
    • #include "TER_targetGUI\addEH.sqf"
  • Add the content of the stringtable.xml to your own or copy it as is
  • The TER_TargetGUI folder

 

Download

http://www.armaholic.com/page.php?id=33043 (RIP Armaholic)

https://drive.google.com/drive/folders/0B8-BL9HKQ_OXWjFnUDhEUGhqejA?usp=sharing (expired)

https://drive.google.com/drive/folders/0B8-BL9HKQ_OXWjFnUDhEUGhqejA?resourcekey=0-slVaBtuyLj5IjSDmkcW-2Q&usp=sharing

 

Credits

Dialog & scripts: Terra

Testing: Aasgeyer

 

 

Good hunting!

 

 

Changelog:

Spoiler

v1.1 (11.08.2017)
 -Added: Abillity to see the stats of the previous shooter
 -Added: Shot info can be retrieved with _target getVariable "TER_LastHitPos"; Format: [target (object), shooter (object), bullet (object), impact position (array, position AGL)]

v1.0 (21.07.2017)
 -Release

 

Feel free to report any bugs. I will try to fix them as soon as possible.

 

Edited by 7erra
expired download link
  • Like 7

Share this post


Link to post
Share on other sites

Great script, I'll be using it to train the designated marksmen in my community.

 

Any chance the info gets stored and is possible to use by one player alone? Right now if you shoot and open the dialog after, you can't see the shot info.

 

Also, how do you implement it? I used an object with addaction, since trigger is global (just curiosity).

 

Thanks!

 

PS. As far as I tested it, it works in JIP.

Share this post


Link to post
Share on other sites
15 hours ago, Andres97 said:

Any chance the info gets stored and is possible to use by one player alone? Right now if you shoot and open the dialog after, you can't see the shot info.

With the current script it is not possible and locality is a huge problem. I had to use a workaround for the EH "hitPart" to work correctly in MP. 

Some more information, not a solution:

Spoiler

The position of the last hit can be returned after the target was hit once at any time until someone opens the dialog and selects the same target. The variable is stored in the objects namespace as "TER_LastHitPos". To retrieve it you can use _object getVariable "TER_LastHitPos"; The other parameter are coming from the MPEH "MPHit". It is added to the target upon selecting a target and also removed once it is unselected or the dialog is closed.

 

Acutally it might be easier to make the MPHit EH persitent instead of adding and removing it everytime. Will take a look into this matter.

 

16 hours ago, Andres97 said:

Also, how do you implement it? I used an object with addaction, since trigger is global (just curio

Depends on what you want to implement (opening the dialog, adding targets, setting up the mission file). If you want to open the dialog with an addAction then you can use this:

_object addAction ["Open Target GUI",{createDialog "TER_target"}];

I'm not sure about the trigger but afaik they are local to everyone. I don't know whether the effects are global or not though. The createDialog command is local anyway.

Share this post


Link to post
Share on other sites
2 hours ago, 7erra said:

With the current script it is not possible and locality is a huge problem. I had to use a workaround for the EH "hitPart" to work correctly in MP. 

Some more information, not a solution:

  Hide contents

The position of the last hit can be returned after the target was hit once at any time until someone opens the dialog and selects the same target. The variable is stored in the objects namespace as "TER_LastHitPos". To retrieve it you can use _object getVariable "TER_LastHitPos"; The other parameter are coming from the MPEH "MPHit". It is added to the target upon selecting a target and also removed once it is unselected or the dialog is closed.

 

Acutally it might be easier to make the MPHit EH persitent instead of adding and removing it everytime. Will take a look into this matter.

 

Depends on what you want to implement (opening the dialog, adding targets, setting up the mission file). If you want to open the dialog with an addAction then you can use this:


_object addAction ["Open Target GUI",{createDialog "TER_target"}];

I'm not sure about the trigger but afaik they are local to everyone. I don't know whether the effects are global or not though. The createDialog command is local anyway.

 

If you use trigger, it opens the dialog for everyone present in the server, it executes the script in every machine. Ended up using addaction and worked fine.

Share this post


Link to post
Share on other sites

*** UPDATE ***

v1.1 (11.08.2017)

  • Added: Abillity to see the stats of the previous shooter
  • Added: Shot info can be retrieved with _target getVariable "TER_LastHitPos"; Format: [target (object), shooter (object), bullet (object), impact position (array, position AGL)]

@Andres97 

As requested you now can see the information of the last shooter. I am now working on a system with which you can retrieve the information about any shot that was fired at the target

Share this post


Link to post
Share on other sites

I got this working, kinda. When i shoot a target nothing comes up in the top left, like who shot etc. Also it does not show where i hit on the right either. Did i miss something?

 

965466c41f51079057a7ee62d0933952.jpg

Share this post


Link to post
Share on other sites
21 hours ago, MiffedLyric559 said:

I got this working, kinda. When i shoot a target nothing comes up in the top left, like who shot etc. Also it does not show where i hit on the right either. Did i miss something?

Oh boy it has been a year since I've create this. Let's see:

Where are you running the mission? SP, hoster MP, dedicated MP?

How are you creating the dialog? With createDialog "TER_target";?

 

I have to say I didn't work on this project anymore since I couldn't come up with anything new. Given my way better knowledge of A3 now I might do a remake. Though I'm still on some other projects.

 

 

Share this post


Link to post
Share on other sites
4 hours ago, 7erra said:

Oh boy it has been a year since I've create this. Let's see:

Where are you running the mission? SP, hoster MP, dedicated MP?

How are you creating the dialog? With createDialog "TER_target";?

 

I have to say I didn't work on this project anymore since I couldn't come up with anything new. Given my way better knowledge of A3 now I might do a remake. Though I'm still on some other projects.

 

 

 

I managed to get it working. The armaholic page is not updated with the newest version :D

Share this post


Link to post
Share on other sites

Does anyone have a working version of this and a MP compatible version? The link is outdated and no longer working .. Thank you in advance 

Share this post


Link to post
Share on other sites
12 hours ago, WarhammerActual said:

Does anyone have a working version of this and a MP compatible version? The link is outdated and no longer working .. Thank you in advance 

Man this is one old project of mine. Anyway, I updated the GDrive link so it should be accessible again. I didn't know that those can expire and also didn't get any notifcation...

Share this post


Link to post
Share on other sites
6 hours ago, WarhammerActual said:

I keep getting zip failed when I tried to download 1.1

?? no problem on my side. what browser are you using? also thinking about moving it to github

Share this post


Link to post
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now

×