58 UnityEngine.Object.DestroyImmediate(
box.gameObject);
60 boxBk.transform.SetParent(base.transform, worldPositionStays:
false);
61 boxBk.GetComponentInChildren<
UIDragPanel>(includeInactive:
true).SetTarget(this.Rect());
70 if (base.config.skin.bgColor.Equals(
new Color(0f, 0f, 0f, 0f)))
100 if (s.IsEmpty() || s ==
" ")
111 if (s.StartsWith(
"*"))
120 s = s.TrimStart(
' ');
123 else if (s.EndsWith(
"*"))
130 if (lastBlock.
txt !=
null)
134 string text = txt.text;
135 if (text.EndsWith(
") ") && text.Contains(
"(x"))
137 text = text.Substring(0, text.IndexOf(
"(x"));
139 txt.text = text +
"(x" + (lastBlock.repeat + 1) +
") ";
140 if (lastBlock.
repeat == 1)
143 box.RebuildLayout(recursive:
true);
170 EMono.
ui.widgets.Activate(
"MainText");
186 box.RebuildLayout(recursive:
true);
209 box.RebuildLayout(recursive:
true);
218 uIContextMenu.
AddSlider(
"msgLines", (
float n) => n.ToString() ??
"",
box.
maxBlock, delegate(
float a)
220 box.maxBlock = (int)a;
221 extra.maxLine = (int)a;
222 }, 2f, 10f, isInt:
true, hideOther:
false);
223 uIContextMenu.
AddSlider(
"width", (
float a) => a.ToString() ??
"",
extra.
width, delegate(
float a)
225 extra.width = (int)a;
227 }, 30f, 100f, isInt:
true);
231 extra.fadeLines = (box.fadeLines = a);
234 uIContextMenu2.
AddSlider(
"changeBG", (
float n) => n +
"/" + (EMono.core.refs.bg_msg.Count - 1),
extra.
bg, delegate(
float a)
239 }, 0f, EMono.core.refs.bg_msg.Count - 1, isInt:
true);
240 uIContextMenu2.
AddButton(
"colorBG", delegate
253 base.OnChangeResolution();
254 RectTransform rectTransform = this.Rect();
255 rectTransform.sizeDelta =
new Vector2(0.01f * (
float)Screen.width * (
float)
extra.
width, rectTransform.sizeDelta.y);
List< SpriteAsset > bg_msg
static BaseGameScreen screen
static LangSetting setting
static MsgBlock lastBlock
void SetBG(SpriteAsset s, Color c)
void Append(string s, Color col)
void KillAll(bool instant=false)
void Append(Sprite sprite)
static WidgetMainText Instance
void Append(string s, Color col, Point pos=null)
override void OnSetContextMenu(UIContextMenu m)
override void OnActivate()
override void OnChangeResolution()
void Append(string s, Point pos=null)
override bool ShowStyleMenu
override object CreateExtra()