Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Ability to see currently selected signal strength in DB #45

Closed
Hazerre opened this issue Apr 25, 2023 · 14 comments · Fixed by #128
Closed

Ability to see currently selected signal strength in DB #45

Hazerre opened this issue Apr 25, 2023 · 14 comments · Fixed by #128
Labels
enhancement New feature or request

Comments

@Hazerre
Copy link

Hazerre commented Apr 25, 2023

Hello. If it is possible, can you please add a UI element or similar that shows us the signal strength of the signal within our cursor on the spectrum device? Having to guess where it is peaking on a graph with only marks every 20db is pretty tough. Having an actual number would allow us to more accurately track line of bearing. Thanks in advance.

@Crowdedlight
Copy link
Owner

Due to limited spare time and making custom GUIs in arma being a pain, it's unlikely I will have time to add something like that. Pull-requests are more than welcome!

The current spectrum device GUI uses a built-in basegame API that does not show the specific db. I might be able to just draw something on top of it... hmmm. Will think about it.

@Crowdedlight Crowdedlight added the enhancement New feature or request label Oct 1, 2023
@Hazerre
Copy link
Author

Hazerre commented Jan 14, 2025

Any word on this improvement? A number drawn crudely on the screen without UI elements would be better than nothing. Adding a noise that changes pitch as the signal gets stronger would be another option. At the end of the day being able to get an accurate peak via any method would be ideal.

Also, if you'd be willing to spin me up I'd be willing to help contribute to this improvement.

@Crowdedlight
Copy link
Owner

I have not had time for a while. IRL being taking my time.
I had a quick look and might have some possible ideas. Might have a moment this weekend to have a look, but no promises.

Otherwise I am always up for helping people get started if they want to contribute. Just let me know what you need of details you need to start poking around.

@Hazerre
Copy link
Author

Hazerre commented Jan 16, 2025

To be honest I'm not very familiar with how addons are made for ARMA in general. I tried looking for guides but most of the search engine results I find seem to be not functional anymore or very old. A good start would be I guess understanding how this addon works currently so I can think of ways to add to it without reinventing the wheel.

My plan is to start looking at the code in this repo pretty much file by file and trying to map out how things interact. There's almost certainly a better way to RE this but I wouldn't know what that better method is so I'll do what I can in the mean time.

I'm available on Discord if you use that. If not I also run a Matrix server that's federated if you'd be available to chat/collab on something like that. Let me know. Thanks in advance.

@Crowdedlight
Copy link
Owner

I had a look at reusing the icons from the Contact campaign and recreate the functionality. I currently have this.

spectrum_icon_test.mp4

There is still some issues where if you change display, or just suddenly it fails to keep updating the icon positions. I have not been able to figure out what happens there yet.

Also needs a cleanup and figure out if I need to run it in its own PFH, or I can add it to the signal strength calculations to also avoid some calculations. But it is not a bad current state.

@b-mayr-1984 I remember you saying you wanted CBA options to enable/disable if it got too far from irl/simulation standpoint. Is this something you want for this feature?
It is kept in the "simulation" space as it just shows icons on peaks with the peaks strength and frequency. But you might see a benefit of having it toggable anyway?

@Hazerre
In terms of figuring out how stuff works and get started with hemtt, I will try and see if I can make a quick "get started" guide or video this weekend to help you along on how to build and launch it, and use filepatching to not have to restart the game between script changes.

@b-mayr-1984
Copy link
Collaborator

b-mayr-1984 commented Jan 17, 2025

@b-mayr-1984 I remember you saying you wanted CBA options to enable/disable if it got too far from irl/simulation standpoint. Is this something you want for this feature? It is kept in the "simulation" space as it just shows icons on peaks with the peaks strength and frequency. But you might see a benefit of having it toggable anyway?

I don't remember it in the context you mention here. 🤔
There was a discussion on how realisticly jammers should behave in terms of the range they have an effect on. But I don't see how this should have an effect on spectrum markers.

Love what you have shown in the video. 👏 🙂

What would happen if there are multiple peaks in the selected blue area?

@Hazerre another way of getting started is to see what has been done in recent pull requests. Those are smaller chunks of changes that often have quite a bit of discussion/review added for context. Here are a few that might help:

@Crowdedlight
Copy link
Owner

I don't remember it in the context you mention here. 🤔 There was a discussion on how realisticly jammers should behave in terms of the range they have an effect on. But I don't see how this should have an effect on spectrum markers.

It was #51
But I think it was mostly if whatever unit was sending the signal was named, not the frequency/signal strength

What would happen if there are multiple peaks in the selected blue area?

It will only show the one with the best signal strength. The basegame gui only have a single element setup to be the text control from what I could see, so could not see easy ways to highlight multiple selections.

@Hazerre
Copy link
Author

Hazerre commented Jan 18, 2025

@Crowdedlight It will only show the one with the best signal strength. The basegame gui only have a single element setup to be the text control from what I could see, so could not see easy ways to highlight multiple selections.

I think this is fine and also adds to the realism. If you're getting one signal that's peaking above another you'd never see the weaker signal unless it's transmitting on a wider band or one is upper sideband while the other is lower sideband. Even still you'd need more specialized software for that and I don't know of anything in ACRE that does modulation like that.

In terms of figuring out how stuff works and get started with hemtt, I will try and see if I can make a quick "get started" guide or video this weekend to help you along on how to build and launch it, and use filepatching to not have to restart the game between script changes.

Thank you for the suggestion. HEMTT seems pretty sweet so far. I definitely didn't expect to see any form of automated building let alone CD for ARMA but here we are. I ran the branch you made for this change through HEMTT and it came out with a single error for me. Not sure if that's because I set things up wrong or not so please let me know. The error I saw was

warning[BBE5]: /addons/spectrum/data/c_track/c_track.p3d is missing 1 material:
  /a3/data_f/penetration/metal.rvmat

@b-mayr-1984 another way of getting started is to see what has been done in recent pull requests. Those are smaller chunks of changes that often have quite a bit of discussion/review added for context. Here are a few that might help:

That's more or less how I've been doing it so far. I've been looking at both this repo and ACRE2's repo. I'm having a difficult time understanding how certain things get pulled from the game as not everything is defined within the mods. An example in this commit being stuff like this:

  • addons/spectrum/functions/fnc_spectrumHudStrength.sqf
private _sigsArray = missionNamespace getVariable ["#EM_Values", []];

I understand that you need to get the array of signal values to be able to paint them on the analyzer gui. That part makes perfect sense. I'm just unsure where in the game you would be pulling EM_Values from and how the game knows what those values are. Or maybe I'm missing something and falsely assuming that sqf files interact with the game at all.

Are there any discord/slack/element/etc groups that talk about ARMA 3 mod development that would be accepting of a new face?

@b-mayr-1984
Copy link
Collaborator

I ran the branch you made for this change through HEMTT and it came out with a single error for me. Not sure if that's because I set things up wrong or not so please let me know. The error I saw was

warning[BBE5]: /addons/spectrum/data/c_track/c_track.p3d is missing 1 material:
  /a3/data_f/penetration/metal.rvmat

Since it is a warning I suppose HEMTT did build the mod anyways.

You probably didn't do anything wrong. It appears that parts of #54 are on the branch that you build and that some configs for damage behaviour are missing for this device.

@Landric are you aware of this warning?

private _sigsArray = missionNamespace getVariable ["#EM_Values", []];

I understand that you need to get the array of signal values to be able to paint them on the analyzer gui. That part makes perfect sense. I'm just unsure where in the game you would be pulling EM_Values from and how the game knows what those values are. Or maybe I'm missing something and falsely assuming that sqf files interact with the game at all.

That specific variable is explained at https://community.bistudio.com/wiki/Arma_3:_Spectrum_Device
You can find a lot of such information if you just google for the thing you don't understand and put arma3 or arma3 sqf in front of it. This is how I do it. Without those extra search terms you often don't find what you need.

Are there any discord/slack/element/etc groups that talk about ARMA 3 mod development that would be accepting of a new face?

Yes, definately.

The most important one IMHO is the ACE discord.
Here #dev-arma3 is like THE central hub for Arma3 devs helping each other out.
(but better google for your problem/variables/functions first, otherwise you might make contact with an angry bear 😆)

Another good source, especially for 3D model and terrain building (and how to configure the properties of them) are the various channels of the official Arma discord.

There are other specialized discords e.g. for TFAR and other popular mods, but those 2 above are the ones that I visit, and which help, me the most.

@Crowdedlight
Copy link
Owner

Thank you for the suggestion. HEMTT seems pretty sweet so far. I definitely didn't expect to see any form of automated building let alone CD for ARMA but here we are.

Yes, we are very lucky that Brett have spent his time making Hemtt the amazing tool it is. It have sped up the testing speed and ease of development for me, and honestly is probably why I am still making mods ;-)
Does remind me I should consider setting up the CI/CD with hemtt for this repo.... whenever I got time to mess about with it 😅

You probably didn't do anything wrong. It appears that parts of #54 are on the branch that you build and that some configs for damage behaviour are missing for this device.

c-track is part of the tracker I made that is released. I did not use the latest hemtt last time I built, so probably why I did not see that error. Seems to be me missing something when making the .p3d file, I will investigate if I can figure out what that error is 😅

I'm just unsure where in the game you would be pulling EM_Values from and how the game knows what those values are. Or maybe I'm missing something and falsely assuming that sqf files interact with the game at all.

so any getVariable or setVariable is saving a variable on a specific namespace or object. Optionally you can get it to syncronize that across all clients too, but as default it is locally for the single client it was called on. It can be very useful to set variables on a specific object, unit, or in general for missionNamespace to save some data connected to the mission, and not a specific client.
(See more namespaces here: https://community.bistudio.com/wiki/Category:Command_Group:_Namespaces)

In this specific instance I am using the variable names on missionNamespace as the basic Spectrum-device api requires. But the actual data in that variable is something I set myself in: https://github.com/Crowdedlight/Crows-Electronic-Warfare/blob/spectrum_icons/addons/spectrum/functions/fnc_spectrumTrackingLocal.sqf#L66
Where I calculate the strength for all signals based on the players current direction and range, and then update the variable so it shows on the spectrum device.

Yes, agreed with Bernhard. ACE discord and Arma3 discord is the usual suspects. ACE discord kinda assumes you know the basics and somewhat what you are doing, but when asked about specific stuff or what would be a good approach, I have always gotten good help or advice.
I do not have a discord for my mods, because I don't think it needs it and I got too many discords already xD
But I am around on ACEs and Arma3s and have dm's open.

@Crowdedlight
Copy link
Owner

Updated the icon branch. Cleaned it up from my testing, renamed a bunch of things, and moved the text for a focused signal to be on the side, instead of top. I felt like on the side fitted better than on top, as if you are closer the signal lines would occlude the text.

Image

Also merged into main a PR that fixes the warnings hemtt gives. So using hemtt now on this branch should not give any extra warnings.

@Crowdedlight
Copy link
Owner

@Hazerre Added a page to the wiki with some basic info about the mod and how its structured etc.
tried to add whatever information I also wish I had when I first ran into the same concepts. Or at least some basic info for it.

You can see it here: https://crowdedlight.github.io/Crows-Electronic-Warfare/contribute/get-started.html

@Hazerre
Copy link
Author

Hazerre commented Jan 22, 2025

@Crowdedlight I do not have a discord for my mods, because I don't think it needs it and I got too many discords already xD
But I am around on ACEs and Arma3s and have dm's open.

It would seem that you're only accepting DMs from friends. I have sent you a friend request. I have a neat little idea that I'd like to get your thoughts on as a way for me to attempt to contribute to this mod. Eager to hear your response.

@Crowdedlight
Copy link
Owner

@Crowdedlight I do not have a discord for my mods, because I don't think it needs it and I got too many discords already xD
But I am around on ACEs and Arma3s and have dm's open.

It would seem that you're only accepting DMs from friends. I have sent you a friend request. I have a neat little idea that I'd like to get your thoughts on as a way for me to attempt to contribute to this mod. Eager to hear your response.

My discord dm is open for "message requests", as long as we have a shared server. So you can just send a message request and I can accept. Does not have to be friends to dm me. (I don't usually accept discord friends before I get to know people ;-) )

I tried to send you an DM, but you don't accept from non-friends, or discord might be broken, as I don't get a message request option as you usually do -_-'

Image

I accepted the friend-request for now to see if that works then 😅

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants