6 [
Attribute(
"{70E828A2F6EBE7D0}UI/Textures/Nametags/nametagicons.imageset", UIWidgets.ResourceNamePicker,
desc:
"Imageset selection",
params:
"imageset")]
7 ResourceName m_sImageset;
9 [
Attribute(
"64", UIWidgets.CheckBox,
"Scaled icon size at the beginning of the zone \n pix*pix")]
10 protected float m_iImageSizeMax;
12 [
Attribute(
"64", UIWidgets.CheckBox,
"Scaled icon size at the end of the zone \n pix*pix")]
13 protected float m_iImageSizeMin;
18 ImageWidget widget = ImageWidget.Cast(
data.m_aNametagElements[
index] );
27 float diff = m_iImageSizeMax - m_iImageSizeMin;
30 int zoneStart = zone.GetZoneStart();
34 float lerp = Math.InverseLerp(zoneStart, zone.m_iZoneEnd,
data.m_fDistance);
37 diff = ( m_iImageSizeMax - diff );
39 widget.SetSize(diff, diff);
45 ImageWidget iWidget = ImageWidget.Cast(
data.m_aNametagElements[
index] );
53 if (!m_sImageset.IsEmpty() && !stateConf.m_sImagesetQuad.IsEmpty())
54 iWidget.LoadImageFromSet(0, m_sImageset, stateConf.m_sImagesetQuad);
57 FrameSlot.SetSize(iWidget, m_iImageSizeMin, m_iImageSizeMin);
59 iWidget.SetColor(stateConf.m_vColor);
61 data.SetVisibility(iWidget, stateConf.m_fOpacityDefault != 0, stateConf.m_fOpacityDefault, stateConf.m_bAnimateTransition);
70 [
Attribute(
"0", UIWidgets.CheckBox,
"Whether this element should use defined faction rank icons in default state")]
71 protected bool m_bUseRanks;
82 ImageWidget iWidget = ImageWidget.Cast(
data.m_aNametagElements[
index] );
92 iWidget.LoadImageTexture(0, rankIcon);