8 [
Attribute(
"#AR-Editor_Attribute_Randomize_Name")]
11 [
Attribute(
"{0C6A9655C33FB75D}UI/layouts/Editor/Attributes/Base/ButtonImageUnderlined.layout")]
14 [
Attribute(
"{B98EA1D6487A6F45}UI/layouts/Editor/Attributes/Base/AttributeEmptyButton.layout")]
17 [
Attribute(
"0",
desc:
"At which int the randomizer starts. This is when you want the first few buttons to be ignored by the randomize button")]
20 [
Attribute(
"true",
desc:
"Shows border when hovering over button.")]
59 array<ref SCR_BaseEditorAttributeEntry> entries =
new array<ref SCR_BaseEditorAttributeEntry>;
62 bool hasIcon, hasButtonDescription;
68 foreach (SCR_BaseEditorAttributeEntry entry: entries)
74 string buttonDescription;
77 if (hasButtonDescription)
88 if (buttonHeight != -1)
104 for (
int i = 0; i < count; i++)
109 Widget buttonRow = w.FindAnyWidget(
"ButtonRow");
114 while (count < buttonsOnRow)
127 if (hasIcon || hasButtonDescription)
128 GetGame().GetCallqueue().CallLater(
DelayedInit, 1,
false, hasIcon, hasButtonDescription);
150 if (hasIcon && !iconOfRandomizeButton.IsEmpty())
152 array<SCR_ButtonBaseComponent> elements =
new array<SCR_ButtonBaseComponent>;
162 imageWidget.LoadImageTexture(0, iconOfRandomizeButton);
184 super.Init(w, attribute);
190 array<SCR_ButtonBaseComponent> elements =
new array<SCR_ButtonBaseComponent>;
196 for (
int i = 0; i < count; i++)
214 imageWidget.LoadImageTexture(0, icon);
216 imageWidget.LoadImageFromSet(0, icon, value.
GetIconName());
220 imageWidget.SetVisible(
false);
221 Widget textWidget = elements[i].GetRootWidget().FindAnyWidget(
"Text");
223 textWidget.SetVisible(
true);
234 elements[i].GetRootWidget().AddHandler(button);
322 for(
int i = 0; i < count; ++i)
332 for(
int i = 0; i < count; ++i)
376 array<SCR_ButtonBaseComponent> elements =
new array<SCR_ButtonBaseComponent>;
380 for(
int i = 0; i < count; i++)
383 if (i == selectedIndex)
384 elements[i].ShowBorder(
true);
387 elements[i].ShowBorder(
false);
402 for(
int i = 0; i < count; ++i)
412 if (!attribute)
return false;
416 super.OnChangeInternal(w, x, y, finished);
425 int index = currentIndex;
427 while (
index == currentIndex && overflow > 0)
ArmaReforgerScripted GetGame()
void SCR_BaseEditorAttributeFloatStringValues(array< ref SCR_EditorAttributeFloatStringValueHolder > values)
SCR_DestructionSynchronizationComponentClass ScriptComponentClass int index
Get all prefabs that have the spawner data
UI Textures DeployMenu Briefing conflict_HintBanner_1_UI desc
Base Attribute Script for other attributes to inherent from to get and set varriables in Editor Attri...
sealed SCR_BaseEditorAttributeVar GetVariable(bool createWhenNull=false)
sealed SCR_BaseEditorAttributeVar GetVariableOrCopy()
int GetEntries(notnull array< ref SCR_BaseEditorAttributeEntry > outEntries)
Get attribute this component represents return Editor attribute *SCR_BaseEditorAttribute GetAttribute()
void SetFromVarOrDefault()
ref SCR_EditorAttributeUIInfo m_ButtonDescriptionUIInfo
string m_sUiComponentName
void GetPresetValues(out int buttonsOnRow, out bool hasRandomizeButton, out ResourceName iconOfRandomizeButton, out bool hasIcon, out bool hasButtonDescription, out string buttonDescription, out int buttonHeight)
UIInfo used by editor attribute system.
void CopyFromEditorAttributeUIInfo(notnull SCR_EditorAttributeUIInfo source, LocalizedString overwriteDescription=string.Empty, Color overwriteColor=null)
SCR_FieldOfViewSettings Attribute