#enfusion_gui
1 messages Β· Page 6 of 1
You need to relaunch your Workbench
code seems to be great
I right click on the original config and i press "override"
just right click and "override"
Maybe just create an other config file
Don't duplicate
Or override
in Config/System
We keep trying, thanks for the help guys!
On my side the override work, my menu has been register
Yes, me too with the modded enum
that's a mistake right here
you should have this :
modded enum ChimeraMenuPreset : ScriptMenuPresetEnum {
VehicleSpawnerMenu
}
expect from the comma
I mean yes you can do it but its not needed
At least that's how it worked in DayZ but who knows..Everything is different.
We got it!
yeah override config was issue
you dont need to inherit on modded classes
ty dolores!
β€οΈ
thanks you all my menu is open !!! goood β€οΈ
Hi all, does anyone have a barebone example of creating a custom menu/UI? Not finding much docs and no samples either.
So from my understanding to make a simple menu
You use the layoutTool, To make your .layout #enfusion_gui message
Then Override chimeraMenus.conf from ArmaReforger
"Open" it and press the + Here add your .layout and a class
To open the menu: GetGame().GetMenuManager().OpenMenu(ChimeraMenuPreset.TestMenu);
Where should this code be ran?
I put this code in my ScriptedUserAction, just before the class definition
Because I use it in my ScriptedUserAction
modded enum ChimeraMenuPreset : ScriptMenuPresetEnum {
TestMenu
}
class GRM_OpenTestMenu : ScriptedUserAction
{
override void PerformAction(IEntity pOwnerEntity, IEntity pUserEntity)
{
Print("Hello Please open my function!");
GetGame().GetMenuManager().OpenMenu(ChimeraMenuPreset.TestMenu);
}
override bool CanBePerformedScript(IEntity user)
{
return true;
}
}```
Something like that?
But, I think the best should be in scripts/Game/UI/
yes
Still cant get it working....
and you still open with GetGame().GetMenuManager().OpenMenu(ChimeraMenuPreset.TestMenu); ??
Yes
weirdjet just released a nice basic compass gui mod, like a quarter of the way towards functioning sthud π
i created a layout, and opened it via CreateWidgets, but the dialog does not have focus, anyone know a workaround? I looked into it more, and i found that there is the menupreset stuff, is it actually the only way?
Maybe I'll have a little more luck here, can anyone help me understand how to properly use the string table editor for localization? #reforger_workbench message
any idea of how to add label type for EditableEntityCore.conf? cuz atm i use FACTION_NONE and it works but i would like to add my own 'tag'
Could layouts be used as texture? Like GUI on surface.
Asking becuase PIP scope uses that
I heard thats doable but don't know how
also i would like to know how to create gui
to create a bank system for an rp server
but i don t know how to create
Yes PIP is using that. You can take a look a the layout with RTRenderWidget or something like that, and then inside script you can do SetGUIWidget, which should render your layout in the texture. This is just to point out where to search. But if you find something shares it here. It can even maybe added to the official documentation at some point if people want to do some display or something.
And you can check inside {0091FAECFC169506}Assets/Weapons/Attachments/Optics/ARTII/Data/Optic_ARTII_PIPMaterial.emat they are using $rendertarget to be able to display the layouts onto the texture itself
This is a really dumb question, but is there a better way to make a rangefinder reticle than to manually test character heights & bullet/projectile drops ingame?
theres a mod by weirdjet that lets you put a marker on the map and it creates an on-screen in-game objective marker with distance value
This is what i was using, i was wondering if you could math this out somehow but guess not
no one know how to create a gui?
In my GUI How do i check if a button has been pressed? via ActionListener(s) ?
you should attach components to buttons
ScriptedWidgetEventHandler
sorry, ScriptedWidgetComponent
...or, you can attach some component which exposes those events via an event handler, to which you can subscribe
The Button already has the BasicbuttonComponent this has a function OnClick would i somehow just be able to override this?
does this mean my chimera config is not overriden?
Restart your workbench once overriding the config otherwise it does not work
yeah worked by restarting
is there a guide for making a UI and banking system or something similar?
Not in the official wikis but maybe this can come in handy ^^
What's chimera? Been browsing the scrips and discords for a while can't figure it out
My guess is internal codename for the Reforger. It's everywhere in the scripts, so don't focus on that wordπ
Self describing code -,-
It's in my eyes the new word for player
Like ChimeraCharacter is the player character
What about ChimeraGame, ChimeraWorld, ChimeraAIAgent, ChimeraMenuBase, ChimeraSunAndMoon π
Chimera is just the working title of reforger
You have to be carefully with the name player. Had alot of frustration yesterday not understanding the definition.
From what I got out of the code the term player means a human controlled a character while ChimeraCharacter is basically just the raw charackter and depending if it is AI or not a ChimeraCharacter has an AiController or a PlayerController.
For example getPlayer(int Id) would not work on AI because they don't have a playerId. So you have to find another way to access ai.
Kinda annoying because alot of components work on playerlvl instead of ChimeraCharacter so you have to implement stuff differently if you want it to work also for AI.
I have a basic idea about it but yes you are 100% right.
I see that the engine has a VideoWidget component, what video format does the engine accepts?
Ogg (.ogv) was the video format they used in previous titles. Not sure how it is now
when i overwrite a ui layout in mod. nothing seems to change?
i disable the image from the left of the headers in the menus>inventory .layout files as overrides but still shows them.
Hi, How can I spawn my GUI (myGuiLayout.layout) using script?
anyone know how to add new font to the game ?!!
Hi. Where i can find help page about formatting tags?
GUI (E): RichTextWidget: unknown tag 't'.
theres any way to make radial progress bar? or i need to make a bunch of images of a progress bar with different progresses and change the spray each time the value changes?
probably making an image set and just changing the index
Check the capture and hold example. The score on top is like that π
but unfortunately not radial π¦
can you send me image so i dont have to open the game? xD
no example around sry xD
somehing like that but the bars are progressing π
i know how to do that
just want it radial
ok than its no help xD
Thats for unity but it may help you https://sharpcoderblog.com/blog/unity-3d-radial-circular-progress-bar-tutorial
This has more math so its maybe easier convertable https://forum.unity.com/threads/how-to-best-to-do-a-radial-progress-circle.1164800/
theres a Radial Progressbar component
i did put it to my progressbar but doesnt converts into radial
oh i just found that actually exists a .layout that has what i want on reforger addons
im gonna duplicate it and modify to look how i want
it doesnt uses progressbar
uses overlaywidget
https://imgur.com/GniUKGA any idea for the stamina icon?
Typical lighting bolt? β‘
i just did this, i will check how it looks, and how a bolt looks
which is better?
Second one imo
2nd 100% it's simpler and everybody should know what it means
instead of a fork for hunger, I would go with a chicken drumstick, seems to be pretty standard for hunger imo
like this
i need to design it
and not all people eat meat
a fork is more generic
the truth is that im lazy xD
maybe later i will design a chicken drumstick or a beef
if you plan on adding a medical mod with limbs, scum would be a great option - otherwise i agree the second UI is better
TextListBox crash for anyone else?
Anyone figure out how to do custom map icons?
Yep, me. I have already report3d it in feedback tracker
Some DayZ players would likely at first think the second one is about shock and not stamina π€ that's why I'd say the first one but those triangles should likely be just squares because it looks quite jagged.
Until that is fixed you could create your own list with a wrapper or vertical widget and create your own layout for the entries that then go into this widget as childs
Once I wake up, I will test that
you can try scripted listbox,
{94CAAE4A601195D3}UI/layouts/ListBox/ListBox.layout
It does exactly that:
create your own list with a wrapper or vertical widget and create your own layout for the entries that then go into this widget as childs
TextListboxWidget is not even used in the game
Regarding this config, is there a way to change this for a specific game mode? I do not want to completly override this in my mod and break other peoples menus they want to add :/ I was unable to find any component yet where this config file is setup? Is it a magic file that is fixed in the engine?
it's referenced somewhere in gproj file (in workbench -> options -> game project -> menu manager settings)
(I didn't try to change it myself π )
but you are not going to break anything with your override π
I think that if two mods override this .conf file and add new entries, it's fine, or is it not?
And if two mods change some value like - what layout to use for inventory menu, then it will get broken.
Well I want to modify the inventory basically, but preferably only in my own game mode. And so far the only option to change it is to either make a new one seperate from Inventory20Menu and mod the scripts to open that menu only when in my game mode or ... I don't know yet. Trying to figure out the best ways.
So, only in your specific world. I don't think engine has a tech like that, as menu manager is one per whole project. So you'd have to hack/script it somehow.
I want to add an inventory action button at the bottom to do stack mangement. e.g. move whole magazine stack. But those buttons seem to be defined in some prefab or something, and I am going up the traces I can find to see where the inventory is put together, and where the buttons are setup.
Sometimes these buttons are added through code upon menu initialization. SuperMenu has methods to add buttons to the bottom row via code.
So also check script class of that menu.
Yeah you a probably right. Override does indeed only appear to add. If the enum does not clash when given a unique (prefixed) name then i guess adding custom menus that way would be the way to go
So far I traced down the inventory buttions like G to drop to SCR_NavigationBarUI::m_aEntries. Where those are coming from I have no clue yet
I don't think so :/
Maybe creating a "custom" ScriptMenuPresetEnum with another config file like chimeraMenus.conf ?
Found it btw. InventoryMain.layout > InventoryRoot > MenuBase1 > SizeBase > VerticalLayout0 > SizeFooter > Footer There is the SCR_NavigationMenuBarUI with the NavigationButtonEntry list. Thought it appears for a simple mod it might be easier to add them via script in SCR_NavigationMenuBarUI.c > HandlerAttached .
I also realised that some components are integrated to widgets and you cant rly modify them when they are related to other layout prefabs. You can add things but not rename/delete until you create your own prefab layout (so same behaviour like for all prefabs).
Anyone know why the text widget and image widget don't resize correctly when the rootframe is sized in code?
What do you expect to happen and what does the code do?
When I resize the root element, it should resize the inner circle accordingly.
And not shift or more the circle.
anyone know why when assigned to an image widget, my image is desaturated?
the edds looks fine in editor though
Maybe because of the color being applied in the image widget is white, but I don't think I can choose to turn that off
You will need to resize the image widget and also the image loaded to the widget depending on the properties of the image widget in code also.
No idea about that one, i use only blank white icons for stuff like that and apply the colour in the GUI editor
Yeah, that's what I had to move to. Sucks because it makes doing anything more complicated impossible.
Probably a color space thing, but not sure.
Na not rly
You may can try working with a SizeWidget
And put everything in there
And modify maybe only the size widget then instead
but i haven't tested that yet
Check slot properties of image and text.
They are inside frame, this they use frame slot. You must set min and max anchors to 0 and 1.
Or just change root to overlay and set width and height rules of image to fill instead of center.
Yeah there is a color space option in image importing rules, check those and reimport
How can I change text values in a layout from a script outside of the layout?
Find that widget in the layout, and call SetText on it
how does FindWiget() work exactly? do i just put in the Widget name?
There are two kinds of this, FindWidget and FindAnyWidget
You always start search from some widget in the hierarchy though!
So it's typically root widget of your menu, root widget of your hud, root widget of some other element (like root widget of a button which has some other widgets inside)
For example i want to select this Widget: https://imgur.com/a/QuJUxdZ
So i would be doing FindWidget("HRearEyePiece.VerticalLayout.SizeRear.Overlay.Rangefinder")?
Yes! Or just FindAnyWidget("Rangefinder") (if Rangefinder is unique widget name starting from that place in the hierarchy)
Alright, got it, thank you π
I want to open a menu via the ActionsManagerComponent but my class is not displayed. I have already tried different things from the channel. My current code looks like this:
ATM
}
class NE_ATMUI : ScriptedUserAction
{
GetGame().GetMenuManager().OpenMenu(ChimeraMenuPreset.ATM);
}```
Did you override chimeraMenus/conf in your mod?
{C747AFB6B750CE9A}Configs/System/chimeraMenus.conf
class NE_ATMUI : ScriptedUserAction
{
GetGame().GetMenuManager().OpenMenu(ChimeraMenuPreset.ATM);
}
But you must put the actual code statements into some method of a class. Not to a class itself. I am not sure how it even compiles.
In ChimeraMenus you must specify a class which is MenuBase and it will be handling life cycle of your menu.
like that?
{
override void PerformAction(IEntity pOwnerEntity, IEntity pUserEntity)
{
GetGame().GetMenuManager().OpenMenu(ChimeraMenuPreset.ATM);
}
}```
Yeah seems to make sense! Check other classes inherited from ScriptedUserAction, I never worked with scripted user actions.
@left sorrel I have explained how to create an ScriptedUserAction here:
#enfusion_scripting message
Hope it helps π
Oh this is how layouts are opened?
GetGame().GetMenuManager().OpenMenu(ChimeraMenuPreset.ATM);
oh I'm going to test it, thx
Thanks for the guide. After a lot of trying I finally got it to work
Does anyone got any experience with SCR_InfoDisplay or SCR_InfoDisplayExtended? I cannot get it to work.
Whats the best method of tracking which buttons in a widget are which
basically I made my UI and I got it loaded
im programatically populating it with information
but I am lost as to how to track each button
for example onclick requires an (int button) which leads me to assume its some sort of unique ID but whenever I check the value is always 0 :/
You can define all widgets in script like this:
ButtonWidget button1 = ButtonWidget.Cast(m_Root.FindAnyWidget("buttonWidgetName"));
The root is the main widget of your layout from that you can get all his children widgets and define them by getting them with there widget name from the main root widget.
Idk if this is still a thing in reforger but in DayZ SA we could skip the definition part when we just used the same name as the widget in the layout also in script.
The main thing is the onclick event because as far as I can see I have no ability to pass the widget to the function thats called with the event
you can with different methods
There is different ways depending on the class you are using and you always can hook up on the existing script invokes to add your certain trigger event types.
you can use a very basic OnClick event
Hey there. By doing this will it automaticaly override the vanilla one, or do i have to make a script to tell the game to replace the vanilla one by the modded one. This is my first mod on the arma series so im kinda lost
Or you use the ButtonComponets in the game apply that to your button widget and use its events
ignore my shitty placeholders
so each row is basically the same layout loaded again and again
yeah i get that
Add a SCR_EventHandlerComponent to your button on the layout
look into that class
I think you will get the drill
Look how they use it for the Tiles in the load-out manager in the respawn selection menu for example
It has all the events you will need i think
Can any of you guys add a textListboxWidget to a rootFrame without workbench crashing on you ?
No problem for me
Want me to send that layout? XD
Mine crashes when i try click around properties and stuff and if i save it i cant load that layout again
Oh
yes ok
i see
same
f
Hm there is a default ListBoxWidget layout
try to use that by dragging the layout into your root of your layout
I will check it out thank you
Funny none of the listbox layouts use the listbox widget but i will dig around maybe another layout will have it
Gives you more variety options for the list box elements
How can i close a menu GetGame().GetMenuManager().CloseMenu(ChimeraMenuPreset.ATM) didn't work
try CloseAllMenus instead
looks amazing!! πͺ
Yep I have already reported it on Feedback tracker: https://feedback.bistudio.com/T165213
This unfortunately closes all open menus (obviously) but this way you can close single menus again GetGame().GetMenuManager().CloseMenuByPreset(ChimeraMenuPreset.ATMUI);
@tropic drift are you using the ItemPreviewWidget for rendering the AKs on your list and do you load up the model trough a script ?
There should be only one menu opened all the time, no?!
ItemPreviewComponent prob
I must admit I tried to get the preview widget working but im kinda new to programming and totally new to modding arma so I instead loaded images until I can figure out the preview widget
could never get the sizing, angling and backgrounds working properly
I would say look into the SCR_LoadoutPreviewComponent
That is what they use to create the loadout preview in the loadout selection
yea im just a little overwhelmed doing all of this so ill just slowly go through everything until it make sense
You can get all the info/data needed to display a preview from the prefab btw
even a image (if there is one)
Hey, i'm trying to get all child widgets from code.
now there is a Widget::GetChildren() but this returns a widget and not a array.
Is there an other function I missed ?
Hi, I have overwritten the chimerasMenu.Conf And I have added an entry called SPK_myTestGui .
But if I try to open it in some script
GetGame().GetMenuManager().OpenMenu(ChimeraMenuPreset.SPK_myTestGui);
```an error is shown saying that `SPK_myTestGui` doesn't exist. What I'm missing here?
did u defined your SPK_myTestGui class as a ChimeraMenuBase or sub class like class SPK_myTestGui : ChimeraMenuBase{ }
I did but with another name
they must be the same?
class SPK_myMenuUI : ChimeraMenuBase{
}
oh must be it, I will try
and restart wb after you add it there
does anyone knows how i add a custom button action like GetGame().GetMenuManager().CloseAllMenus()
it is already defined correctrly (I did nothing) and pointing to the correctConf
can u send your'r code an error message
Check definition of ChimeraMenuPreset, find it via symbol finder in script editor.
It's an enum with values corresponding to those entires in conf file.
You must make a modded enum and add your value there.
Ok, this right?https://gyazo.com/e7e2610b124dac63b28d960a9c49ef82
yes, just make a modded enum somewhere in your script
actually even like this works
modded enum ChimeraMenuPreset
{
AddonPresetDialog
}
without the : ScriptMenuPresetEnum part
ah okay nice to know
so how and where should someone start in modding the ui?
like adding a button to an existing ui or creating a new one
You can create a new one I will try to explain how
GUI Setup
- Create the following folders in your project: UI/layouts/Modded
- Create some layout inside the created Modded folder:
myNewLayout.layout - Create the following folders: Scripts/Game/UI/Modded
- Create a .c file inside the created Modded folder:
myScriptedUI.c - Go to ArmaReforge/Configs/System/chimeraMenus.conf and rightclick/override in yourAddon
- Go to your automatically created path Configs/System/chimeraMenus.conf and add your new GUI at the end with some ID name (
myTestGui_ID). - Assign the Layout (
myNewLayout.layout) - Assign the Class (
myNewLayoutClass) - Return to the previously created: myScriptedUI.c
- Add this:
modded enum ChimeraMenuPreset {
myTestGui_ID
}
- In the same file you can add your class to (I will put the code later to make it more clear):
class myNewLayoutClass: ChimeraMenuBase
{
//your GUI code ...
}
- With this done you will be able to Open the GUI using this code somewhere:
GetGame().GetMenuManager().OpenMenu(ChimeraMenuPreset.myTestGui_ID);
Adding functionality to your new created GUI (Hint on Button Click)
13. Go to your layout: myNewLayout.layout
14. Add one ButtonWidget and rename it to: SendHint
15. In SendHint/Script add one component called: SCR_ButtonTextComponent (and leave it with his default values for now)
16. Return to your previously created class: myNewLayoutClass and do the following code magic:
class SPK_myMenuUI: ChimeraMenuBase
{
protected Widget m_wRoot;
protected SCR_ButtonTextComponent comp;
IEntity myCallerEntity; // (Added) this variable will be used only to show how to transfer parameters to the GUI.
//------------------------------------------------------------------------------------------------
override void OnMenuOpen()
{
m_wRoot = GetRootWidget();
// SendHint
comp = SCR_ButtonTextComponent.GetButtonText("SendHint", m_wRoot);
if (comp)
{
GetGame().GetWorkspace().SetFocusedWidget(comp.GetRootWidget());
comp.m_OnClicked.Insert(myCustomFunction);
}
}
// myCustomFunction called when SendHint Button is pressed
void myCustomFunction()
{
SCR_HintManagerComponent.GetInstance().ShowCustomHint("This executes when pressing SendHint Button (Using OnClick)", "MY GUI", 3.0);
}
};
- (Added) You will need to change the code in step 12 if you want to be able to pass some variables to the GUI:
MenuBase myMenu = GetGame().GetMenuManager().OpenMenu(ChimeraMenuPreset.SPK_myTestGui);
SPK_myMenuUI myMenuUI = SPK_myMenuUI.Cast(myMenu);
myMenuUI.myCallerEntity = pOwnerEntity; // pOwnerEntity is the variable we want to be able to use in the GUI on this example.
This is the basic GUI that I managed to learn with some people in this channel, hope it helps.
should create a tutorial or something on github for it
like it was done for mission making
I don't know how to do that hehehhe
I hope that all the GUI stuff will be in the wiki some day
create a project on github, add examples to it, switch to wiki tab, write up wiki or I can do it on the run as I learn it from you and others π
Of course feel free to use my description to do whatever you want with it. Community doc are always good
If someone is interested I did an explanation on how to use the new "AddActions" here: #enfusion_scripting message
It's a good combo with this GUI stuff in order to Open It
can someone please help me
I'm trying to load a menu layout i've created
i've added an action to chimeraInputCommon.conf in project
and i've added a menu entry to chimeraMenus.conf
with the relevant layout field filled, but it doesn't work π¦
Any ideas why i am getting : GUI (E): Menu preset 'myTestGui_66' not found! I followed the tutorial above and it feels that the chimeraMenus.conf does not get loaded
did you also mod the menu preset enum with the new value?
#enfusion_gui message
yeah
I think that is what is throwing the error
Ok so i changed the value to some random value and it threw error that it can not find variable so both the ENUM and the chimeraMenus.conf seem to be loaded
@sage current it started working when i removed the confing setting from the project file and loaded it again
how can i add my own markers on the map? i havent had any luck with tasks with map descriptor components
Restart the workbench
how would i go about showing my UI layouts straight from the start? ie: making health/stamina bar etc show up always.
Not sure if this is correct place, but I am looking for help on an inventory issue. Made a helmet mod and it will put on if selected from the ground, but inside the inventory it will show as applying to the helmet slot, but it ends up disappearing. Anyone know of a fix to get it to enable inside the inventory onto your character?
Hello I am looking for a tutorial how to create a physic as well as how to operate my car get into it etc.
If anyone is struggling how to use SCR_InfoDisplay and let it show up, I created a Steam Guide for it. You can check it out and check if you are missing something.
https://steamcommunity.com/sharedfiles/filedetails/?id=2814814735
how would i get a widget thats 2 or more deep in the root widget? m_wRoot.FindWidget only seems to get the child thats 1 below root. ?
search FindWidget through whole reforger code, you will see how to specify a path
or you can use FindAnyWidget
w.FindAnyWidget()
No.
how i get the players health or blood?
nm worked it out π
Do you guys know how to position HUD relative to the resolution the player is running the game in ?
What are you trying to achieve? Where should the element be positioned?
Here the FrameWidget is set to 1920x1080 so when i load it in 4k it is sort of off the middle
You should have your root a Frame widget.
Ok show the slot properties of the panel please
most likely anchors and sizes are wrong
Ok I see. You should add a VerticalLayout into root of the frame. Then put those horiz. layouts into the vert. layout:
Frame(root)
VerticalLayout
HorizLayout0
HorizLayout1
...
Then click on vert. layout, set its anchor to xmin, xmax = 1, ymin, ymax = 1
Play with pivot and offset values, set width and height.
I think you will get what you want π€
Ok got it thank you
Make sure you know how to use all values in frame widget, it's very powerful for positioning.
Second is overlay widget. It's simpler but OK for most common cases like centered, aligned to left/right
Why do you need to mod ChimeraMenuPreset and can not create a subclass like this?
enum MyMenuPreset : ChimeraMenuPreset
{
myTestGUI_ID
};
If I try the above, I get an exception
I think it is because the chimeraMenu.conf has all its guis defined there. But I dont know the tecnical reason.
The Problem is still the lag of information. Hopeful BI is giving us more Input in the next days.
Most we do now is try and error as well back engineering
The problem is that the game looks to be hardcoded on the engine side to only look for ChimeraMenuPreset.
how can i access to character or charactercontroller from OnStartDraw (orUpdateValues) from a subclass of SCR_InfoDisplay?
@terse lily do you mean like this?
||class whatever: SCR_InfoDisplay
{
private SCR_CharacterControllerComponent CController = null;override event void OnStartDraw(IEntity owner) { CController = SCR_CharacterControllerComponent.Cast(player.FindComponent(SCR_CharacterControllerComponent)); if (CController) Print("Found character controllerc omponent") }}||
yeah
i think i found a way
SCR_ChimeraCharacter character = null;
if(owner.Type() == SCR_PlayerController){
SCR_PlayerController player = SCR_PlayerController.Cast(owner);
character = SCR_ChimeraCharacter.Cast(player.GetLocalControlledEntity());
}
but not sure if it works correctly
What exactly are you trying to achieve?
player health
with that i can do
float health = character.GetDamageManager().GetHealth();
Ah, I see. Yesterday someone asked if there is a "getHealth" Variable or something like Stamina has. He found a workaround, might as well contact him if you are not able to manage to get it.
This guy.
i just pulled getHealthScaled from the damagemanger dont rely on what i do tho. am newb lol
thats similar to what i do
gethealth from damagemanager
which gives health as float from 0 to 1
yeah should work then i guess?
Honestly. We are all new to this right now. But things that might work, just work. π
yeah friend told me if it works it works. and not to worry if its correct or not lol
doesnt say. just says returns it from 0 to 1
but its a bool xD
ahah has sense now
where can i pull blood from?
doesnt seem to be on DamageManager like health is
mm blood says it is on damagemanager. cant seem to pull it must be tired lol
I'm really confused how the blood system works. I found all kind of blood stuff in the actual Hitzones there are like more than 10 of them.
Is blood the actual health? So if you would set it to zero the character dies or is it more like a health modifier?
no idea. i guess if u run out of blood u die like with health?
so lets say you have 100 blood and 100 health are they completly unrelated?
So you can play with 1 health and 1 blood?
And when one of them reaches 0 you die? hmmmm
no idea tbh. cant find anywhere that explains it lol
Yea same. I found some blood modifier on each hitzone and set it to 0 so now characters don't bleed out at least I survived >5 minutes while having the bleeding UI which also is weird because why is the bleed ui shown when you don't bleed.
But thinking of it as two seperate systems makes sense I think.
They're somewhat separate. Though not 100% sure how it goes in AR. Likely that you lose both health and blood when something hits you, it also causes a wound, so you lose blood over the time. If you don't patch up and blood goes low you lose health again. If you patch up, blood loss stops and blood probably regains back to full. Health likely remains low. Not sure does AR have health regen yet.
You can get a grip if you look for how those work in DayZ.
In dayz SA every hit zone of the player character has its own blood/health
Not sure but this could be the same case in Reforger
This is how it looks like in the code but how does this work?
What happens if you would partially damage every hitzone? somehow the damage needs to be subtracted from some main health pool no?
It was possible to get the overall health by not adding the hit zone index as param. There should be a similar method
π€
But thats all theory
I haven't looked into the way they do it now. It just sounds very similar
someone knows how to import fonts?
why would equip show as unavailable but on a grenade it allows u to put in hand?
Conditioning. There has to be a method that checks if the action is usable by going thru conditions. If the method returns false. This is the result.
Hi, do you know how to get ref to text widget ?
You know of any tutorials for the UI?
@floral root How did you manage to access the damage component from your script ?
No, this is the main issue ^^'
how would i go about creating a ui widget by script?
Well it depends
do you want to simply render it
or have the focus on the widget
Without having the focus you can't interact with buttons and stuff
For simply rendering it's as easy as GetGame().GetWorkspace().CreateWidgets("Widget Resourece Name");
For making it a menu, it's requires little bit more effort but still extremely easy
You need mod ChimeraMenuPreset enum and add your own menu
Same with chimeraMenus.conf, you need to override and add your menu there as well
Creating a class that inherits from ChimeraMenuBase can be helpful as well
After all the setup is done, GetGame().GetMenuManager().OpenMenu(Your Modified ChimeraMenuPreset Enum goes here);
It will return a MenuBase. You can get top parent widget within that by doing newlyCreatedMenu.GetRootWidget();
After that you are ready to rock'n roll
You have a refrence to the menu and a reference to the widget. Everything you are mostly going to need to interact with an UI is going to be within those 2
Much like entities, widgets follow a parent child relationship. So if you want to modify a text or an image within a widget you can utilize that hierarchy to get that text or image and modify it via code
And that hierarchy is going to based on your .layout
ta π
@floral root Thank you for the screenshots from above.
is there an easy way to fade UI in and out or point me in the direction if so?
Is it possible to only show part of an image as imageWidget?
I want to display the US flag image that already exists in the game but the lower 50% of the image is black. Is it somehow possible to only show the upper 50% of the image?
Went through all the options but could not find it.
https://imgur.com/a/Sp12rF6
I also tried wrap and none but then I can't scale the image only the widget.
You can edit your own images in photoshop/gimp/whatever you want, put them in your addon folder in explorer and then import them, which converts them from jpg/png to edds. Which you can then use
so what does deployment points relate to? as it cant be spawn points as i have some in the map. Anyone know?
Those should be the spawn points
Maybe you don't have them linked with faction?
its linked as far as i know. it shows up on map on the spawn screen. and can select it on map and spawn at it if ur the faction. not sure if thers anything special i need todo it to "link" it to a faction.
factioncontrol component on the spawn point is set to the faction
So this menu is in GM?
Check if there are spawn points in editablePrefabs folder
yeah shows up in GM mode aswell
it works fine. apart from just doesnt show on deployment points screen lol
shows up fine on end selection screen
dam just tested with peer tool. seems my ui doesnt update on other players either lol
argh
void OVT_MainMenu(OVT_MainMenuWidgets widgets, Widget root)
{
m_TownManager = OVT_TownManagerComponent.GetInstance();
m_Widgets = widgets;
SCR_ButtonTextComponent comp;
// Map Info
comp = SCR_ButtonTextComponent.GetButtonText("Map Info", root);
if (comp)
{
GetGame().GetWorkspace().SetFocusedWidget(comp.GetRootWidget());
comp.m_OnClicked.Insert(MapInfo);
}
}
protected void MapInfo()
{
Print("Map Info button was clicked");
}
Any clue why this m_OnClicked handler isnt being called? All the other events are working fine (hover, click sound is played)
the handler is definitely being inserted, but "MapInfo()" is never called
I think my class was getting GC'd, storing it as a ref fixed it
does anyone even know how "Priority" is even supposed to work in ActonContexts? If I set anything higher than 1 it will override everything else that is 1. Selecting "Cursor visible" shows the cursor all the time, even if my context isnt active.
and if i set 1 then obviously all the other contexts are active, so you can still move around and esc shows the pause menu
i thought it just puts them in the order of priority in the menu list
has to be more than that, because of what I said
setting anything but priority 1 makes the flags active even when the context isnt
not sure then sorry π
How would i get a component on a character from a script based on SCR_InfoDisplay?? everyway ive tried to get the character didnt work on a peer client.
higher priority means the context is activated sooner, if your context has prio 2 and has no overlay flag (aka overlaying other contexts), it means no contexts with priority below it (1 or less) will be active, which seems to be your case
non-overlayed contexts are used when you do actually want to ignore all other inputs (lets say when you open a map, you dont want to be able to move around and shoot)
That doesn't explain why the flags are active when the context is not
I do want to ignore all other inputs as it's a menu but I'm not using the menu manager as I feel adding it to the enum of menus is silly
So I don't choose overlay and set flags to show cursor, with priority > 1 but as soon as game starts the cursor is shown and can't control the character even though ActivateContext hasn't been called
that doesnt sound possible π€
you could check how it looks with debug in WB
dbg menu (WIN+ L ALT), -> GameCode-> ShowInputManager will show you which contexts are currently active/suppressed
Ok I'll have a look thanks
Hi,
how to get a list of child widgets from a parent?
I have a GridLayoutWidget and I want to get an array of rows and columns but the GridLayoutWidget itself has no such functions.
The Widget class has a GetChildern() which returns for some reason only one widget instead of a list.
proto external Widget GetChildren();
I want to access the cells by row column numbers, but I can't find any method that allows to do that.
so the CharacterGeneralContext isnt active at all when my contexts have priority > 1
which seems weird
my contexts arent active
which is correct
but no idea why character general would not be
I guess I can just force it active
but shouldnt have to
yes
this is once I set my priorities back to 1
so all the character contexts disappear
action menu, weapon, movement, general
afaik those contexts are activated by gamecode, they shouldnt just disappear
interesting
well this at least sheds some more light, Ill have a dig
thanks for the help
I wonder if you're doing anything which could suppress active flag or frame mask for the player entity, which would stop it from activating the ctx π€
so in the case of the ActionMenuContext this is whats suppressing it:
thats always null
so it doesnt activate context further down
this is SCR_InteractionHandlerComponent.OnPostFrame line 403
removing the SetEventMask(owner, EntityEvent.FRAME); from my component didnt change anything
worth a shot
Would probably have to ask someone who knows how those contexts are activated, possibly @fossil sorrel ?
I just noticed that when my priority is > 1 the GadgetContext is active
so whatever is happening is also activating that (shouldnt be afaik)
UserActionContext != input action context
UserActionContext is the actual context on an item in the world
I know
but if you scroll up, none of the character specific contexts are being activated
the gadget ones are
all im doing is adding custom contexts with priority > 1 nothing else
well that I know of
Maybe some of the context has the exclusive flag set? 
that would suppress them and show them as yellow in dbg (if not overlayed)
this looks like something straight up deactivates them
Maybe the priority and the fact that these 5 prio ones are not overlay? I am not the input master though, so I am just guessing here :\
oh ok
they shouldnt be overlay though
they are inactive
only activated later
ill keep digging unless you can point me in the direction of an input master hehe
I was wondering if you knew what activates the contexts, maybe somethin wrong is being overridden, turning them off? (Character_XXX_Contexts)
ok so it seems to think I have a gadget raised
if (m_InputManager && m_HeldGadgetComponent)
maybe
no thats not breakpointing
but i have no idea why gadgetcontext is being activated lol
shouldnt be relevant in grand scheme of things because gadgetcontext isnt suppressing things either
good question, you could try overriding instead π€
looking into that now
for a ui for the player am i best putting it on the SCR_HUDmanagerComponent thats on the player controller or the SCR_BaseHUDComponent thats on the character??
Btw you will need to reset entire WB when doing that cause WB loads that cfg differently I think
ok
it depends on usage, most of such UI is on controller because it just exists once and you only need to refresh it when your entity dies/changes etc
when its on entity directly its created/destroyed along with the entity which add slight overhead but there are cases when that is preferable
so like a health bar? better on controller or character? ive got it on controller but trying to think if its better off on the player.
it will work with both, neither is 'incorrect'
k kl π
BINGO
this did it
thanks man
theres one for the docs
and for future reference @fossil sorrel, inheriting from chimeraInputCommon.conf is bad, overriding good
well sort of.. now I get no CharacterMovementContext but everything else works
but its an improvement, might be something else im doing
yeh just need to restart WB any time the conf is changed or weird stuff happens
all working good now
Why is this ALWAYS saying no deployment points? cant it find the spawn points or bugged? Ive added editble spawn points in with faction key etc. but nothing.
do you have Faction field filled in your spawn point entity?
Yeah. thing looks identical to us/ussr etc apart from with own faction.
deployment points show up on the map to select for each faction on last screen. but yeah never show on the faction tiles.
trying to view the properties of a TextListboxWidget instantly crashes Workbench
help π¦
do you inherit your spawn points from SpawnPoint_Base.et prefab?
@rough yoke ive tried it with PrefabEditable/ spawn points, also with the Prefabs/MP/Spawning/ faction ones edited to say my faction key instead on any component/section that has the faction key part. Is there somewhere else other than on the spawn points prefabs/components that it needs to be told ?
Idk where to ask this but... Does Enfusion have vector support for something like a crosshair in a scope? I would have no idea how to even search for this. Basically, can I use an SVG within Enfusion somehow?
I mean you can just use a CanvasWidget and draw it
pretty sure, although im only just starting on canvas widgets myself
Can it be used to make something like this?
Know the math..? Yep I think I'll stick with a texture then lmao. Very much appreciate your help though, I'm just not technical enough to make something like that.
Legend
I should add this now:
class SPK_myMenuUI: ChimeraMenuBase
{
...
IEntity myCallerEntity;
...
MenuBase myMenu = GetGame().GetMenuManager().OpenMenu(ChimeraMenuPreset.SPK_myTestGui);
SPK_myMenuUI myMenuUI = SPK_myMenuUI.Cast(myMenu);
myMenuUI.myCallerEntity = pOwnerEntity;
Just filed a bug report for SCR_EditBoxComponent throwing a NULL-pointer error when attached to EditBoxWidget, maybe someone has figured out some workaround for it at the moment?
anyway to make list with selection in the mean time that you can add/remove elements to
until the listboxwidget is broke
you could write one yourself
just add textwidgets to a layout container
Ive been using the gamemaster asset selection screen which is just a grid of repeated elements with image etc
fill them with info and turn off the ones I dont need
https://github.com/ArmaOverthrow/Overthrow.Arma4/blob/main/Scripts/Game/UI/Context/OVT_ShopContext.c
around line 53
Yes, you should take a look into the serverBrowser layout.
Finally I got a decent GUI XD (with some receiver typo π )
https://gyazo.com/7c853b3c71288199bdc08ec30c9b085a
You need to use a prefab called WLib_PooledList.layout and create a new layout that will be displayed as a list.
I don't know how to populate it by script yet. But hope this images help you
There is a ListView prefab to but I don't know the diference
thanks ill take a look :)
Anyone knows the difference between SCR_PooledListComponent and SCR_ListViewComponent. For example let's say I want to make a list in which all the players appear and that I can select one, which should I use? And how I must clear, add items? I think that the workflow is to create a new class inheriting form one of these and override the FillEntry() method, am I right?
I keep trying to generate a very basic list using SCR_ListViewComponent. I have come up with the following:
class SCR_HintListComponent : SCR_ListViewComponent
{
protected ref array<SCR_HintEntryComponent> m_aObjectsEntries = new array<SCR_HintEntryComponent>;
//------------------------------------------------------------------------------------------------
//! Empty functions for setting up widget entry beavhior actions, callbacks, etc.
override protected void SetupEntryBehavior(Widget entry) { }
//------------------------------------------------------------------------------------------------
//! Empty function for filling entries with data
override protected void FillEntry(Widget w)
{
Print("FillEntry - In");
int id = m_aEntryWidgets.Find(w);
Print(id);
SCR_HintEntryComponent objectEntry = m_aObjectsEntries[id];
if (!objectEntry)
return;
ARU_ObjectEntry myEntry = new ARU_ObjectEntry();
myEntry.SetId(id);
myEntry.SetName("myEntryDefaultName");
objectEntry.SetObjectInfo(myEntry);
w.SetVisible(objectEntry != null);
Print("FillEntry - Out");
}
};
This component is placed in the "FrameWidget" prefab WLib_ListView.layout. When I'm in the workbench it shows something, but ingame the list is not filled. I have seen that SCR_ListViewComponent has some lines comented but not cleary why.
Tring to override the OnUpdate method to call FillEntry results in errors ... so I'm stuck here XD
@deft zenith hi, sorry for mentioning you . It seems like nobody know about this and Im blocked. Do you know someone that can help with this? π
I am no expert in this, here are answers from our UI devs
Simply pooled list is iteration of list view, so there is this old SCR_ListViewComponent left over. Its purpose is to reuse minimal amount of widget and just to change data inside widgets.
If anyone would want to do just small list there is no need to use it. Only thing needed is to put list items into ScrollLayoutWidgetin layout editor
Or SCR_ListBoxComponent
Ok will try this afternoon/night. Thx
I got it π₯³ Thx
I made this little tutorial it will be useful fore someone else π
How to create a ListBox in GUI - Layout
0. Place an OverlayWidget and resize it as you wish.
- Search the ArmaReforger Prefab:
ArmaReforger:UI/layouts/ListBox/ListBox.layout - Place the prefab inside the OverlayWidget created at Step 0 and change the Horizontal and Vertical Align to the 4th option.
- Get sure that the new created ListBox0 (by default) has the component
SCR_ListBoxComponent. - Get sure that the new created ListBox0 has a ScrollLayoutWidget ("ScrollLayout0" doesn't mater) and a VerticalLayoutWidget ("List" as name, required) created.
- Steps 3 and 4 should be fine by default if you have used the ListBox Prefab.
How to create a ListBox in GUI - Fill and GetIndex
6. Create a menu class script with the following:
class SPK_myMenuUI: ChimeraMenuBase
{
protected Widget m_wRoot;
//...
OverlayWidget m_ListBoxOverlay;
SCR_ListBoxComponent m_ListBoxComponent;
//...
//------------------------------------------------------------------------------------------------
override void OnMenuOpen()
{
m_wRoot = GetRootWidget();
//...
// MyList
m_ListBoxOverlay = OverlayWidget.Cast(m_wRoot.FindAnyWidget("ListBox0"));
m_ListBoxComponent = SCR_ListBoxComponent.Cast(m_ListBoxOverlay.FindHandler(SCR_ListBoxComponent));
if (m_ListBoxComponent)
{
m_ListBoxComponent.AddItem("MyItem0");
m_ListBoxComponent.AddItem("MyItem1");
m_ListBoxComponent.AddItem("MyItem2");
}
//...
}
//...
};
- In order to get the ListBox Index you can use this:
m_ListBoxComponent.GetSelectedItem();
Ok, so here's a difficult one:
We have overriden the chat layout to display it in another position on screen and resized it.
It shows and works just fine if playing from camera position in editor and then possessing the character.
It does NOT work when creating a spawn point and spawning in. It just doesn't show up π
It works on characters I place down via GM, but not when I use a spawn point to spawn.
If you don't override the chat it works?
(to get sure that isn't some configuration missing)
yep
Interestingly it works for regular players who spawn in on a server via a created spawn point
It does not work in spawn menu, nor while in GM mode
You can type and hit enter and it gets sent to chat but you don't see it π€
At the current moment my best guess is that it has to do something with a renamed/deleted/changed (formatting) widget.
I tried to post this in other channels but I want to try to get the people here to take a peek, since some of the GUI plays with the string table.
I have edited my string table to include some of my custom additions. my problem is in workbench and in game, The id (#AR-FieldManual_Page_Intel_Title) shows up instead of the Target translation.
omg. The layout editor has been crashing like crazy for me today. It even has reverted files I've saved TWICE. I'm done
Anybody else have problems or am I screwing it up?
Most of the time it has has the "send debug" window but the last few times it just went straight to desktop
Are you using a list view component
Nope, just lots of FrameWidgets, VerticalLayout/horizontalLayout, Overlays, RichText and a couple of ImageWidgets
This is what it has reverted back to after crash. I've had to make a header for the item/cost header three times now. It usually crashes soon after adding a few more elements
Oh look! It just did it again
It happends to me to. The revertrd files especially
I'm going to have to put it aside for now. It doesn't crash nearly as much in other parts of the editor.
Going to install latest GPU drivers and report back
Nope. Still an issue
So here's what happened this time. I went in and fixed up that one that kept reverting and saved it a million times and even grabbed a snap shot here.
I then switched to another layout and it crashed right after. Messing up this one, which now looks like this.
So it isn't exactly reverted. There's just some elements that got corrupt
all those items are placed inside a verticalLayoutWidget? (Item and cost to?)
Or they are placed manually?
@fossil sorrel question, do you know any samples/tips for setting up simple radial menus like you have in your reloading mod? I'm just trying to setup one with some static actions in it right now
Each line is a HorizontalLayout and they are all nested inside one VerticalLayout. I think my problem may even be that another layout file is corrupted. I'll have to start my whole mod from scratch
Not really, it was new to me as well. I suggest checking out how I did it in the mod for reference
Thoughts?
There isn't a Cancel button. Its intentionaly?
Looks great π
Nothing to cancel. Maybe the purchase buttons should have a confirmation
Cancel/Exit Menu
Ok serves same purpose
How do you exit if you dont want to purchase?
By the way i was testing with layouts prefabs they are quiete useful.
Yeah, I found them. At first was using dialogs and working them manually but the prefabs cut that workload down a lot
The background and all the visible widgets are another layout an then I can use this on all layouts
There's great prefabs for most buttons and other elements. Works best if you have a container like a horizontal or vertical layout to put them in. Then duplicate after getting them to fit just right
Yes but this is a self made prefab. Its like a dialog base template for my addon
Then I can add the content and foter on another layout
I'll need to make one of those too. There'll be a few menus for my mod
I will share the layout herarchy this afternoon maybe it is more clear
Coding for it might take a week for me to figure out thought. I wanted to have the menu layouts done before tackling too much of the rest of the mod so that I can also do custom debugging and playtesting.
It's off to other UI elements after this.
Your tagging game is on point.
yep I like how it ended
As you can see here I just dragged my standard DialogBackground and then I added stuff on Content (manually) and Footer (another buttons standard layout)
I'm having some problems with localization, this is why the # is missing on those texts, to avoid engine to search for it
There's still a few bugs in the system. I think the reason I was crashing before was the dialog I was using as a base.
Every time I went back to start a fresh one it would crash eventually
I started fresh with some other base layout and haven't crashed since
Ye there is a lot of bugs with the layouts π©. But i cant replicate it consistently to make a ticket on feedback tracker.
@worn marten I haven't messed with GUI stuff yet, but how difficult would it be to create some GUI menu with multiple sub menus, and have back option where it'll go to the previous menu? π€
Not so much i think
++++++
Has anyone managed to get EditBoxes to work properly with SCR_EditBoxComponent? The component has a bug at the time, so I don't think it's usable, but may there be some other way to attach a "text changed" handler to an EditBox?
What bug does it have? i have been using it without problem. I haven't tested with UI eventHandlers yet
EditBox itself works fine, but when I attach a SCR_EditBoxComponent it keeps spamming null-reference errors to debug log, so I don't think it's usable at the moment
The bug I filed in the feedback tracker was moved to "Assigned" status today so I hope the issue is resolved soon
Oh no, so list boxes don't work yet?
They work. And in the meantime your can do you oun method for cler and setCurrentItem. but i hope they finish this soon because I would like to use it to
First time messing around with GUI stuff, probably messed up big time 
You can implement a very simple stack data structure. Push & pop references to the UI that's being opened/closed or resource names of the UI layouts, at that point it's an implementation detail of how you want to proceed. That would give you the behavior you want to achieve ^^
Made some more progress, thanks for the guides @worn marten they're super helpful 
Looks great. you have changed the default ListBoxElement_Text.layout by another custom, right?
I did manually edit ListBox.layout and ListBoxElement_ImageText.layout to get it how I needed.
where should I start with learning gui creation? any tutorials or other stuff?
I just started tinkering with it yesterday so I'm still trying to get my head around it. But the best thing to do is just open layouts from the game and inspect how they work, a few posts in here are very useful too. Such as #enfusion_gui message #enfusion_gui message https://steamcommunity.com/sharedfiles/filedetails/?id=2814814735
thx
So after messing around more trying to get my own radial menu working from scratch, I tried seeing what I could do with some modifications of your reload menu entries, and it literally works perfectly for what I need. Are you allowing modified versions like that to be published or you want me to carry on trying to get something else to work?
Of course it's endorsed even, that is the whole point of the mods I made, to help you get stuff up and running :)
Is there a way to use the button widgets that are already created by BI? Like if I wanted to use this
Using this:
string m_sActionName = "MenuBack";
m_wActionRichText.SetText(string.Format("<action name='%1' scale='1.25'/>", m_sActionName));
So that would be placed on a richtext?
in like a initialization script for the layout
Thanks!
How am I able to close a menu? I tried with a Cancel Button which executes the following but I get an error:
{
GetGame().GetMenuManager().CloseMenu( ChimeraMenuPreset.SARO_MHQMenuGUI_ID );
}```
error:
```only NULL assignment is allowed```
```can not convert 'int' to 'MenuBase' for argument '0' to method 'CloseMenu'```
CloseMenu needs a BaseMenu class object. I guess the question is how do I get this?
searching Discord helped^^
this works:
GetGame().GetMenuManager().CloseAllMenus();
but would be better to have a solution for one menu in case you have multiple menus open at the same time...
well you need to pass it the actual menu as argument, not enum ID
there are so many ways to get it, MenuManager has FindMenuByPreset() / GetOwnerMenu(), you can also just cache it or use "this" if you are calling the cancel from within the menu
thx a lot, this worked
GetGame().GetMenuManager().CloseMenu(teleportMenu);```
I've got a different issue with closing a particular menu. I've modded the map and using it to launch other menus, closing it however leaves your character with the map item still in hand. It's a minor issue since you can just switch to a weapon but the UI will then display the fadeout animation that closing some menus does. I have no idea where to start looking for what code is being run here.
Map when used as a character is opened using the GadgetMap action, when it is opened all lower priority inputs (character stuff) is disabled, so map has a special context with reference to the GadgetMap action so it can still be used to close it "from" the map
My guess is that you close the map in a way that skips the closing logic from triggering on the character level, which is fine for things like respawn map, but not for this case
I guess I'll have to take a look at the map gadget. Everything I've done so far was strictly in the UI scripts.
There's probably a way to force close a gadget quietly
If you need to do a proper map close from a player, you can just grab GadgetManager and do SetGadgetMode(mapItem, EGadgetMode.IN_STORAGE)
If you do something like CloseMap() only UI will close, but wont get propagated to character logic
That's awesome. Will be doing that. Thanks
yo can anyone point me at what I need to do to have a dialog for an editable entity with some properties
if you want to know how to create a dialog, this may help you: #enfusion_gui message
what do you refer exactly with "editable entity"?
ie. when you double click a car in game master to change its fuel
I want exactly that, but with my own variables for my own entities
ok, I don't know how it works
no worries
yep I'm searching to, the only thig I found by now is that component
I've found the health bar on: {5AA8B62B2B33CD49}UI/layouts/Editor/Attributes/Entity/AttributePrefab_HealthWithWarning.layout
for example you have SCR_AiSkillEditorAttribute
but I don't know how it is plugged in to the actual dialog
getting closer
I did it 
What type of properties can you add to those menus ?
there is a dropdown ui element, but I don't remember what kind of values it stores
can you resume how it is done?
I will need it some time XD
yeah hit me up when you need it or just download the mod and open it
Is there a way to assign a UI to a mesh face like a monitor screen?
i think you can add the action on a object but on screen i dont know maybe with layout ?
Yooo you the π bro. Canβt wait to use your mods in multiplayer some day. Do you know why the parachute flares and artillery barrages canβt be accessed? I can spawn the smokes, fire, and explosions, but ever since the parachute flares got added I couldnβt find them to spawn in. Iβm on xbox btw if that makes a difference
Hm they should be in the same category, maybe mod needs to he updated in game?
Yeah I just updated to the version that includes the artillery barrages, but I still only have access to smoke, fire, and explosions. Stuff added since the flares still ainβt tho.
I tried scrolling through the whole entity list, searching artillery, sorting by system etc, they just arenβt in the list lol
there's a separate category now called game master fx in the sidebar, but I have no clue if there's anything special to do for xbox
Oh shittttttt Iβm a fucking idiot. So yeah even though I was updated none of that stuff was visible, but after deleting the mod and reinstalling its all there π
whew
Thanks dawg π
sure, have fun blowing things up
not that destruction is implemented yet but someday hopefully it will
Yep, now time to spawn in 50 AI, and blow them up while fantasizing about being able to use mods in multiplayer on Xbox.

Hi, I am trying to make scope two color. Using vanilla way with HDR scope map, but I cant make my scope reticle two color, like red/black.
In the script I found that widget uses SetColor to set color of the reticle. How could I make it so widget is two tone?
Edit. Solved it by overriding PIP Sights component and adding second Camera Effect with different reticle
Is there a list of all of the action names somewhere?
as far as i know, there isn't
Damn
Has anyone used WidgetAnimator.PlayAnimation to do a fade in? I'm trying it OnMenuInit but that doesn't seem to be the right spot
OnMenuOpen I'm assuming is too late. After the menu has been drawn
I haven't used it yet.
A la
WidgetAnimator.PlayAnimation(GetRootWidget(), WidgetAnimationType.Opacity, 1, m_fAnimationRate);
I slowed the animation rate down to a crawl just to see if I wasn't seeing it but no, it fades out very slowly but doesn't do a fade in.
does the localization system not fall back to english when a runtime file isnt available in the selected language? or is that something I need to select somewhere?
its normal you are in first person π
Anyone know when they will finish this in the SCR_ListBoxComponent?
Ticket opened: https://feedback.bistudio.com/T166364
@worn marten any clue how do I add something to display text on hover in inventory?
A tooltip?
I have seen an option to add tooltips y will take a look this afternoon/night
yes
or an action that happens when it's clicked, could be launching a dialog
SCR_InventoryMenuUI
//------------------------------------------------------------------------------------------------
//! when clicked on item / storage slot using controller or mouse
protected void Action_SelectItem()
{
// Ignore if we cannot interact
if (!GetCanInteract())
return;
SimpleFSM( EMenuAction.ACTION_SELECT );
}
whats this
no clue how to connect this to my entity tho
do editor attributes support strings?
any clue how to hide action menu or put my layout in front?
tried all sorts of Z order values
Well, it seems to be created and handled with SCR_ActionMenuInteractionDisplay (if I understand the code correctly), so you should be able to hide/destroy it
I have the same problem π¦
or maybe with the ScriptedUserAction::CanBeShownScript, with some variable detecting GUI opened/closed
override bool CanBeShownScript(IEntity user)
{
return true;
}
There are two SCR_Tooltip components but I don't know how to use them. I'm thinking to that haven't seen tooltips in the Arma Referger menus so ... π€
thanks, tbh I kinda backed out of the idea because game master attributes editor doesnt support strings so I can't really have GMs be able to edit items
I am so mad about that lol
Custom Intelligence folder says goodbye
you can still make them in your custom missions via workbench, just no editing in GM
true, but i wanted to be able to change the message on the Fly
you can if it's made out of numbers
Maybe i'll have to work around by sending a global Textmessage when openeing the GUI
ahh good old Intelligence encription lol
yea I'm not implementing strings in GM so imma just wait for official support
Any idea to get all the items in a players inventory and show them to another grid?
Folks, were there any docs regarding the RichTextWidget? What can be put there and what is the syntax?
there isn't any GUI doc yet π¦
You will have to look for examples in the code
I'm looking for a way to add shadow for the text. Like <t shadow='2'>...</t> in ArmA.
mmm I haven't seen shadow on text in referger (on their own menus) so maybe there isn't. If you place a TextWidget or RichTextWidget and there isn't any option in the propertis windows ...
Hm.. found something:
TextWidget tWidget = TextWidget.Cast( data.m_aNametagElements[index] );
tWidget.SetColor(stateConf.m_vColor);
tWidget.SetShadow( stateConf.m_fShadowSize, stateConf.m_vShadowColor.PackToInt(), stateConf.m_fShadowOpacity, 0, 0);
Hi, this worked for me. All my UserActions Inherit from ARU_ScriptedUserAction
class ARU_ScriptedUserAction: ScriptedUserAction
{
//------------------------------------------------------------------------------------------------
override bool CanBeShownScript(IEntity user)
{
MenuManager manager = GetGame().GetMenuManager();
if(manager.IsAnyMenuOpen() || manager.IsAnyDialogOpen())
return false;
else
return true;
}
//------------------------------------------------------------------------------------------------
override bool CanBePerformedScript(IEntity user)
{
return true;
}
//------------------------------------------------------------------------------------------------
override bool HasLocalEffectOnlyScript()
{
return true;
}
};
Sorry for the delayed response heheh I haven't had time to test it
oh and @wicked zinc FYI
Actually, I don't get it π€
He added more storages to the chimeraCharacter, right? I don't know if they are functional thou
@worn marten top image has a dogtag in that dogtag slot
Thank you Spyke! That's very not trivial π
Should probably get a page in biki
you are welcome π
which tools do you need to setup and script a custom GUI ?
Wanted to do something similar to what Tarkov does with mags and being able to check your mag after shooting.
The modding tools on Steam@agile jungle
As Zelik has said, you have the arma reforger workbench tools on steam. If your question is more about how to setup a GUI look at pined messages.
I know about the tools I'm using the Map tools atm π
I used the A3 tools.
wanted to test something.
where it says: UI/layouts/Modded do i create it this way UI>kayout>Modded> ? or each folder ?
iv'e never made a UI beofore.
No need for the modded folder, you can name it as you want. The UI/layout path isnt compulsory but its recomended
what I mean is do they need to be inside each other for the UI to function properly ?
Nope
which file is the .c file ?
when I typed in the .c file name and then hit enter it brings up some other menu. Not sure which one to choose.
thanks






