Long-range visual triggers?
5 posters
Operation Flashpoint Dragon Rising OFDR Forums :: OPERATION FLASHPOINT: DRAGON RISING :: OFDR EDITING :: EDITING Q+A
Page 1 of 1
Long-range visual triggers?
Hi, guys.
Would it be possible to create a module, or is there existing code that allows the player to visually trigger an objective?
I'd like to try to put a 2-man Scout Sniper team on the map. Recon is a lot of their job, and 90% of recon is visual. They're a team of only 2: to reduce risk, they'd be engaging high priority targets only (example, AT gunners) and then from a distance. The whole point would be to have a recon team go in first and grab solid intel for a future assault.
So goal is: enable player to visually trigger objective, *through binoculars*. Or perhaps, reaching the (definitely UNMARKED) objective will have to involve stepping into a small trigger zone in the perfect spot to observe encampments/installations? Then remaining in that position for a certain length of time to simulate time taken to observe?
Thanks for any help.
Would it be possible to create a module, or is there existing code that allows the player to visually trigger an objective?
I'd like to try to put a 2-man Scout Sniper team on the map. Recon is a lot of their job, and 90% of recon is visual. They're a team of only 2: to reduce risk, they'd be engaging high priority targets only (example, AT gunners) and then from a distance. The whole point would be to have a recon team go in first and grab solid intel for a future assault.
So goal is: enable player to visually trigger objective, *through binoculars*. Or perhaps, reaching the (definitely UNMARKED) objective will have to involve stepping into a small trigger zone in the perfect spot to observe encampments/installations? Then remaining in that position for a certain length of time to simulate time taken to observe?
Thanks for any help.
Badger75- Location : Third World Country
Points : 19
Reputation : 2
Join date : 2013-07-15
Re: Long-range visual triggers?
There is a function called onReconRegister, which use a visual cone. This you can set to spread out as small or as far as you like. I'll try and dig up an old mssn I found trying to do something pretty similar myself but using the cobras.
You could try the onIdentified function too and use that to call a specific function once the correct units/vehicles have been seen. I'd place the targets in a set and then use a variable to call those specific units in the code.
something like.
Something like that maybe??? thats not tested obviously, just trying to show the concept of it.
Also this sighting concept would be pretty nice to see in the yet to be made stealth module.
There is something similar used in the mission Operation Nighthawk, which uses a canSee debug function with the onIdentified function but I'm not too up on how that works tbh. TJ is the man to help out with that.
You could try the onIdentified function too and use that to call a specific function once the correct units/vehicles have been seen. I'd place the targets in a set and then use a variable to call those specific units in the code.
something like.
- Code:
targets = "atguy"
function onIdentified(identifiedID,IdentifierID)
if identifiedID == "atguy" then
OFP:callAnAirstrike("to","blow","****","outtatheirass") --lol!
end
end
Something like that maybe??? thats not tested obviously, just trying to show the concept of it.
Also this sighting concept would be pretty nice to see in the yet to be made stealth module.
There is something similar used in the mission Operation Nighthawk, which uses a canSee debug function with the onIdentified function but I'm not too up on how that works tbh. TJ is the man to help out with that.
Re: Long-range visual triggers?
Cool! Thanks, mdog. So my line would read--
OFP:setObjectiveState( "objective" , "COMPLETED" )
...but that airstrike idea is giving me extra ideas *grin*
Re: the stealth mod-- I will endeavor to be patient.
I'm still working through your EDX manual. Thanks for all that hard work, guy.
OFP:setObjectiveState( "objective" , "COMPLETED" )
...but that airstrike idea is giving me extra ideas *grin*
Re: the stealth mod-- I will endeavor to be patient.
I'm still working through your EDX manual. Thanks for all that hard work, guy.
Badger75- Location : Third World Country
Points : 19
Reputation : 2
Join date : 2013-07-15
Re: Long-range visual triggers?
try...
If your using EDX, this would still have to be in the level.script. OFP:registerOnReconFunction is one of the pain in the ass functions that will only work in the level script and not secondary scripts. However they are called a "reconPoint" for good reason, and work very well at that.
reconPoint are registered to unit, echelons or groupNames.
You can register multiple reconPoints to the same unit/s, however once a reconpoint is sighted, all reconPoints registered to the unit/s will become unregistered. In same way that the OFP:unregisterOnReconFunction("unitEchelonGroupName") unregisters all reconPoints registered to the unit/s.
reconPoints do not take line of sight into consideration. A reconPoint behind a rock, building, shipping container etc. will be visible within the distance value set.
- Code:
function onMissionStart()
OFP:registerOnReconFunction("sawit","reconpoint","echelon",5000,30,300)
end
function sawit()
OFP:displaySystemMessage("Saw it!")
end
If your using EDX, this would still have to be in the level.script. OFP:registerOnReconFunction is one of the pain in the ass functions that will only work in the level script and not secondary scripts. However they are called a "reconPoint" for good reason, and work very well at that.
reconPoint are registered to unit, echelons or groupNames.
You can register multiple reconPoints to the same unit/s, however once a reconpoint is sighted, all reconPoints registered to the unit/s will become unregistered. In same way that the OFP:unregisterOnReconFunction("unitEchelonGroupName") unregisters all reconPoints registered to the unit/s.
reconPoints do not take line of sight into consideration. A reconPoint behind a rock, building, shipping container etc. will be visible within the distance value set.
tjdagger- Admin
- Location : Silverdale, Queensland, Australia
Points : 107
Reputation : 7
Join date : 2012-12-17
Age : 48
Re: Long-range visual triggers?
Good morning. Actually, no it's not, it's too damn early. I'm just being polite
What is good is all this info. Thanks.
TJ, I dunno so much that " registerOnRecon " is precisely what I want for 2, maybe 3 objectives; I think the " function onIdentified " will work because the player(s) should be looking at the objective (radar, officer, etc). There are a string of secondaries that " registerOnRecon " definitely will work for, though, and make my life easier. Thanks, TJ.
...and I'm starting to see how this code generally makes things easier, not harder. I've had this game since 2010, and until now the mission ed has been something I've deliberately ignored, because !Code Monster Inside! But the idea of making missions that really mirror various realities, is a temptation that beats the !Code Monster!
What is good is all this info. Thanks.
TJ, I dunno so much that " registerOnRecon " is precisely what I want for 2, maybe 3 objectives; I think the " function onIdentified " will work because the player(s) should be looking at the objective (radar, officer, etc). There are a string of secondaries that " registerOnRecon " definitely will work for, though, and make my life easier. Thanks, TJ.
...and I'm starting to see how this code generally makes things easier, not harder. I've had this game since 2010, and until now the mission ed has been something I've deliberately ignored, because !Code Monster Inside! But the idea of making missions that really mirror various realities, is a temptation that beats the !Code Monster!
Badger75- Location : Third World Country
Points : 19
Reputation : 2
Join date : 2013-07-15
Re: Long-range visual triggers?
TJ, I dunno so much that " registerOnRecon " is precisely what I want for 2, maybe 3 objectives; I think the " function onIdentified " will work because the player(s) should be looking at the objective (radar, officer, etc).
Ok, so? Things to know...
- Code:
function onIdentified(identifiedID, identifierID)
-- "onIdentified" will only fire when one "unit" has detected another "unit", that is not on the same "army side". AND has not already been Identified previously.
-- the "onIdentified" firing is triggered as a result of the "onSuspected" function.
-- the "onSuspected" is a timer that firers away in the background.
-- the "onSuspected" function fires several times per second. And it maintains data of what "units" are where on the map, what "army side" they are on etc. This data is compared by it's own set of logic taking "line of sight" into consideration, distances and so on.
-- the "onSuspected" logic is based around parameraters set in config.xml I beleive, however, evertime you hear "Rifflemen 500m" it's a result of a successful "onSuspected" resulting in an "onIdentified" being firerd, at which point we can analyse the identifiedID and identifierID.
--the "onSuspected" only tracks "units".
So, what is a Unit?
-- a unit can be a "soldier" or a "vehicle"
-- a "soldier" can be in a "group", "echelon", has a "Broad Category Name" and a more specific "templateName".
-- a "vehicle" can be in a "group" has a "Broad Category Name" and a more specific "templateName".
-- a unit's "army side" can be 0, 1, 2 or "US", "PLA" , "Neutral" respectively.
-- the "onSuspected" function sorts out who can see who and gives feedback to systems like the visual map icons and more.
-- "Vehicles that are "unMounted" will appear "Neutral". Once "Mounted" they reflect the side of the "vehicle leader".
-- the "onSuspected" will record "onIdentified" results and if line of sight is broken for to long the "Identified unit" will no longer be classed as "Identified".
...the objective (radar, officer, etc).
As for "registerOnRecon" vs "onIdentified" the objective will determine which you'll need.
tjdagger- Admin
- Location : Silverdale, Queensland, Australia
Points : 107
Reputation : 7
Join date : 2012-12-17
Age : 48
Re: Long-range visual triggers?
Honestly, you guys are awesome. A while back, I gave up trying to mod another (will-not-be-named) game, because asking for help returned unfriendly responses.
So as you say, it's going to depend on the objective. And thanks, your explanation definitely helps make more sense of why the onRecon option is better. I just have to make the viewCone value as small as you did. What's the mechanics there? I'm presuming that "30" is the base radius of the cone, but there was mention that line-of-sight could be ignored, so "30" could also be its height...
Thanks again.
So as you say, it's going to depend on the objective. And thanks, your explanation definitely helps make more sense of why the onRecon option is better. I just have to make the viewCone value as small as you did. What's the mechanics there? I'm presuming that "30" is the base radius of the cone, but there was mention that line-of-sight could be ignored, so "30" could also be its height...
Thanks again.
Badger75- Location : Third World Country
Points : 19
Reputation : 2
Join date : 2013-07-15
Re: Long-range visual triggers?
I believe the "30" refers to a circular vision cone, a "15" degree radius, based off of "line of sight", as opposed to a "30" degree wedge with a height stretching from max to min environment height.What's the mechanics there? I'm presuming that "30" is the base radius of the cone, but there was mention that line-of-sight could be ignored, so "30" could also be its height...
... but, "line of sight" between "unitName" and a "reconPoint" isn't calculated in the same way that debug:canSee(), which is used for "units" to "units" exclusively. Instead I believe that "onSuspected" tracks reconPoints locations. I'd assume that ""onSuspected" is more the wedge shape and things like "units" are subject to "line of sight" analysis while inside the wedge, and "reconPoints" are subject to being compared to the values set in "registerOnReconFunction" only against for the "unit/s" specified.
Effectively a "reconPoint" on the other side of the mountain will be spotted if the "reconPoint" exists inside of the "30" circular vision cone based off of where the unit is directly looking, within the specified distance regardless of whether a great big mountain is in the way or not.
...that, at least, is what all my experience indicates.
Cheers, happy to help. Documentation doesn't (and to my knowledge, never has) exist for most of this. Been at this a good while now, and I know a lot of the answers... I just don't know what the questions are. if that makes any sense?
tjdagger- Admin
- Location : Silverdale, Queensland, Australia
Points : 107
Reputation : 7
Join date : 2012-12-17
Age : 48
Re: Long-range visual triggers?
Badger75 wrote:Honestly, you guys are awesome. A while back, I gave up trying to mod another (will-not-be-named) game, because asking for help returned unfriendly responses.
ARMA
there you go said it for ya! I don't care. I've had the same response as you from them sometimes. It hasn't put me off playing it though. I do like playing that.
BTW, naming other games isn't an issue here just so you know. We welcome all kinds here as long as people respect the core values of the forum and respect each other.
Re: Long-range visual triggers?
Actually, it might've been waaaaay worse than the Arma crowd: CoD2, possibly teenage *ANY* age CoD fanboys who mod are *vicious*. But I've heard enough about the Arma boys to steer clear. Don't have/want to get Arma, anyway.
...and seeing as you're around, I can't get the Edx to work. I dunno if I downloaded the wrong kit, but there was no Mission Editor exe (or any of the numerous files and apps) in that EDx Mission Editor folder. So, replacing the old folder with the new one... One certainly loses a lot. I've tried swapping out only the matching files from the download, and when I try to load the Quickstart module via File>Markers Collection, I get an error message: "Invalid mission file version 0.60. This version of MissionEditor does not support it, and no XSL sheets were found that could transform it to supported version."
Might my game version have something to do with it? I have out-the-box v1.0, and the MissEd is v1.0.2.0.
I'd like to get the EDx to work, because it certainly seems to save time and effort, but if I can't, I'm not afraid of time and effort. I've been having fun making sh*t blow up and whatnot with the vanilla ed, so... *shrug*
...and seeing as you're around, I can't get the Edx to work. I dunno if I downloaded the wrong kit, but there was no Mission Editor exe (or any of the numerous files and apps) in that EDx Mission Editor folder. So, replacing the old folder with the new one... One certainly loses a lot. I've tried swapping out only the matching files from the download, and when I try to load the Quickstart module via File>Markers Collection, I get an error message: "Invalid mission file version 0.60. This version of MissionEditor does not support it, and no XSL sheets were found that could transform it to supported version."
Might my game version have something to do with it? I have out-the-box v1.0, and the MissEd is v1.0.2.0.
I'd like to get the EDx to work, because it certainly seems to save time and effort, but if I can't, I'm not afraid of time and effort. I've been having fun making sh*t blow up and whatnot with the vanilla ed, so... *shrug*
Badger75- Location : Third World Country
Points : 19
Reputation : 2
Join date : 2013-07-15
Re: Long-range visual triggers?
In reply to TJ:
(and when is the PHP crowd gonna come up with a simple damn "Reply to this post" button?)
Oh brother, re: being able to 'recon' something right through a mountain/hill. What sort of vision might that be? It's much better than boring old x-ray
I'll figure something out, even if I go back to my original Plan B of getting the player to find the best place to get eyes on the BGs. Finding a good vantage point is straight out of fieldcraft manuals anyhow, so it works.
It does make sense. A lot of sense. And thanks.
(and when is the PHP crowd gonna come up with a simple damn "Reply to this post" button?)
Oh brother, re: being able to 'recon' something right through a mountain/hill. What sort of vision might that be? It's much better than boring old x-ray
I'll figure something out, even if I go back to my original Plan B of getting the player to find the best place to get eyes on the BGs. Finding a good vantage point is straight out of fieldcraft manuals anyhow, so it works.
Been at this a good while now, and I know a lot of the answers... I just don't know what the questions are. if that makes any sense?
It does make sense. A lot of sense. And thanks.
Badger75- Location : Third World Country
Points : 19
Reputation : 2
Join date : 2013-07-15
Re: Long-range visual triggers?
... you could direct the player towards one or more "best vantage points"... these locations could have a small triggerzone, which upon entering, calls the "OFP:registerOnReconFunction". Restricting the possibility of a confirmed sighting until they are in position, eh?
Last edited by tjdagger on Thu 18 Jul 2013, 01:14; edited 1 time in total
tjdagger- Admin
- Location : Silverdale, Queensland, Australia
Points : 107
Reputation : 7
Join date : 2012-12-17
Age : 48
Re: Long-range visual triggers?
Good morning to you, sir.
And yup, small trigger zone, irritatingly small *grin*. But it'll also be fun to find that perfect spot-- nothing for it but to park myself in the map and take a hike/drive/flight. Might as well dot a few PLA here and there for target practice while I'm at it...
And yup, small trigger zone, irritatingly small *grin*. But it'll also be fun to find that perfect spot-- nothing for it but to park myself in the map and take a hike/drive/flight. Might as well dot a few PLA here and there for target practice while I'm at it...
Badger75- Location : Third World Country
Points : 19
Reputation : 2
Join date : 2013-07-15
Re: Long-range visual triggers?
Might my game version have something to do with it? I have out-the-box v1.0, and the MissEd is v1.0.2.0.
...to get the EDX to work you will need to download and install CM's official 1.02 patch, below is a download link with a good overview of version changes.
http://www.shacknews.com/file/16095/operation-flashpoint-dragon-rising-patch-102-and-overwatch-dlc-p
You will also want the "acid mod" for v1.02. below is a link to the authors page with an explanation and download link for the mod itself.
http://forums.steampowered.com/forums/showthread.php?t=1943271
cheers,
tjdagger- Admin
- Location : Silverdale, Queensland, Australia
Points : 107
Reputation : 7
Join date : 2012-12-17
Age : 48
Re: Long-range visual triggers?
Ta, TJ.
(my internet is super-speedy this before-sparrow-fart a.m-- a whole 80kbps! [see: Third World Country])
(my internet is super-speedy this before-sparrow-fart a.m-- a whole 80kbps! [see: Third World Country])
Badger75- Location : Third World Country
Points : 19
Reputation : 2
Join date : 2013-07-15
Re: Long-range visual triggers?
TJ and Mdog-- it now works!
Awesome sauce, dudes. Thanks!
Awesome sauce, dudes. Thanks!
Badger75- Location : Third World Country
Points : 19
Reputation : 2
Join date : 2013-07-15
Re: Long-range visual triggers?
good to hear it's all working.
tjdagger- Admin
- Location : Silverdale, Queensland, Australia
Points : 107
Reputation : 7
Join date : 2012-12-17
Age : 48
Re: Long-range visual triggers?
pre-designated vantage points would provide a nice secondary trigger for verification objectives and enforce that the player(s) are staying on mission.
as for the mission design, pre-designated locations (like waypoint markers) allow for the designer to provide some anticipated travel corridors for ambush potential - add a low probability spawn ratio to keep players on their toes.
OFF TOPIC: TJ nice sigline!
as for the mission design, pre-designated locations (like waypoint markers) allow for the designer to provide some anticipated travel corridors for ambush potential - add a low probability spawn ratio to keep players on their toes.
OFF TOPIC: TJ nice sigline!
John J. Stevens- Admin
- Location : WV/PA
Points : 285
Reputation : 22
Join date : 2012-12-19
Re: Long-range visual triggers?
John J. Stevens wrote: OFF TOPIC: TJ nice sigline!
I know, right? It's Sharp!
Similar topics
» Code for Laser Range Finder?
» [SP/COOP] Long Road Home
» Operation Flashpoint: Dragon Rising - Long Overdue
» [SP/COOP] Long Road Home
» Operation Flashpoint: Dragon Rising - Long Overdue
Operation Flashpoint Dragon Rising OFDR Forums :: OPERATION FLASHPOINT: DRAGON RISING :: OFDR EDITING :: EDITING Q+A
Page 1 of 1
Permissions in this forum:
You cannot reply to topics in this forum
|
|