Elin Decompiled Documentation EA 23.102 Nightly
Loading...
Searching...
No Matches
Core.cs
Go to the documentation of this file.
1using System;
2using System.Collections;
3using System.Collections.Generic;
4using System.IO;
5using System.Text;
6using DG.Tweening;
7using IniParser;
8using IniParser.Model;
9using ReflexCLI;
10using Steamworks;
11using UnityEngine;
12
13public class Core : BaseCore
14{
15 public new static Core Instance;
16
17 public static float delta;
18
19 public static float avgDelta;
20
21 public static float gameDelta;
22
23 public static float gameDeltaNoPause;
24
25 public static float fixedFrame;
26
27 public static bool spiked;
28
30
32
34
36
38
39 public ModManager mods = new ModManager();
40
41 public PCCManager pccs;
42
44
46
48
50
51 public CoreRef refs;
52
54
56
57 public Steam steam;
58
59 public bool useUImat;
60
61 public bool trial;
62
63 public UI ui;
64
65 public Scene scene;
66
68
69 [NonSerialized]
71
72 public Game game;
73
74 [NonSerialized]
75 public bool initialized;
76
77 private bool? lastFullScreen;
78
79 private float nextResolutionUpdate;
80
81 private float skinTimer;
82
83 public bool IsGameStarted
84 {
85 get
86 {
87 if (game != null)
88 {
89 return game.activeZone != null;
90 }
91 return false;
92 }
93 }
94
95 public override float uiScale => ui.canvasScaler.scaleFactor;
96
97 protected override void Awake()
98 {
99 base.Awake();
100 Debug.Log("Core Awake");
101 Debug.Log("Version:" + version.GetText());
102 QualitySettings.vSyncCount = 0;
103 Application.targetFrameRate = 60;
104 IO.CreateDirectory(CorePath.Temp);
105 SetCurrent();
106 Lang.langCode = "";
107 if (Application.isEditor && debug.langCode != 0)
108 {
109 forceLangCode = debug.langCode.ToString();
110 }
111 string[] array = (Application.isEditor ? debug.command.Split(',') : Environment.GetCommandLineArgs());
112 for (int i = 0; i < array.Length; i++)
113 {
114 string text = array[i];
115 text = text.Replace("-", "").ToUpper();
116 Debug.Log("Commandline args:" + text);
117 if (text.StartsWith("LANG_"))
118 {
119 forceLangCode = text.Replace("LANG_", "");
120 continue;
121 }
122 switch (text)
123 {
124 case "DEV":
125 releaseMode = ReleaseMode.Debug;
126 break;
127 case "UPDATE_LANG":
128 Lang.runUpdate = true;
129 break;
130 case "NOMOD":
131 ModManager.disableMod = true;
132 break;
133 }
134 }
135 NewsList.dict = null;
136 InvOwner.Trader = (InvOwner.Main = null);
137 SpriteSheet.dict.Clear();
138 SpriteSheet.loadedPath.Clear();
140 LayerDrama.haltPlaylist = false;
141 LayerDrama.keepBGM = false;
142 BaseModManager.isInitialized = false;
143 Net.isUploading = false;
144 MapPiece.initialized = false;
145 ActPlan.warning = false;
146 Game.isPaused = false;
147 if (Application.isEditor && BaseCore.resetRuntime)
148 {
149 ResetRuntime();
150 }
151 Window.dictData.Clear();
152 LayerInventory.listInv.Clear();
153 debug = Resources.Load<CoreDebug>("_Debug " + releaseMode);
154 debug.enable = releaseMode != ReleaseMode.Public;
155 if (useUImat)
156 {
157 Canvas.GetDefaultCanvasMaterial().CopyPropertiesFromMaterial(matUI);
158 Canvas.GetDefaultCanvasMaterial().shader = matUI.shader;
159 }
160 if (!ui)
161 {
162 ui = Util.Instantiate<UI>("UI/UI");
163 }
164 if (!scene)
165 {
166 scene = Util.Instantiate<Scene>("Scene/Scene");
167 }
169 ui.ShowCover();
170 canvas = ui.canvas;
171 ui.OnCoreStart();
172 BaseCore.BlockInput = () => ui.IsDragging;
173 CommandRegistry.assemblies.Add(typeof(Core).Assembly);
174 SoundData.EditorPlaySpatial = delegate(SoundData a)
175 {
176 game.player.chara.PlaySound(a.name);
177 };
178 SoundManager.funcCanPlayBGM = () => !LayerDrama.haltPlaylist && !LayerDrama.keepBGM;
180 MOD.langs.Clear();
181 MOD.OnAddPcc = pccs.Add;
182 MOD.listTalk = new TalkDataList();
183 MOD.tones = new ToneDataList();
184 MOD.listMaps.Clear();
185 MOD.listPartialMaps.Clear();
186 Portrait.modPortraitBGFs = new ModItemList<Sprite>();
187 Portrait.modPortraitBGs = new ModItemList<Sprite>();
188 Portrait.modPortraits = new ModItemList<Sprite>();
189 Portrait.modOverlays = new ModItemList<Sprite>();
190 Portrait.modFull = new ModItemList<Sprite>();
191 Portrait.dictList = new Dictionary<string, List<ModItem<Sprite>>>();
192 TileType.Init();
194 Debug.Log(steam.steamworks.settings.applicationId);
195 }
196
197 private void Start()
198 {
200 Debug.Log("Loading Config:" + CoreConfig.path + " - " + config);
201 if (config != null && config.other.disableMods)
202 {
203 ModManager.disableMod = true;
204 }
205 try
206 {
207 steam.Init();
208 }
209 catch
210 {
211 }
212 StartCase();
213 }
214
215 public void StartCase()
216 {
217 Debug.Log("StartCase:" + ModManager.IsInitialized);
219 {
221 StartCoroutine(mods.RefreshMods(delegate
222 {
223 MOD.actorSources.Initialize();
224 StartCase();
226 return;
227 }
228 Debug.Log("Plugins:" + ModManager.ListPluginObject.Count);
229 foreach (object item in ModManager.ListPluginObject)
230 {
231 Component component = item as Component;
232 if (!component)
233 {
234 Debug.Log("no go");
235 continue;
236 }
237 GameObject obj = component.gameObject;
238 obj.SendMessage("OnStartCore");
239 Component[] componentsInChildren = obj.GetComponentsInChildren<Component>();
240 foreach (Component component2 in componentsInChildren)
241 {
242 Debug.Log(component2.GetType().Assembly.GetName().Name);
243 ClassCache.assemblies.Add(component2.GetType().Assembly.GetName().Name);
244 }
245 break;
246 }
247 sources.Init();
248 if (!forceLangCode.IsEmpty())
249 {
251 }
252 else if (config == null)
253 {
254 Debug.Log("Config doesn't exist.");
255 try
256 {
257 if (debug.enable || !SteamAPI.IsSteamRunning())
258 {
259 BookList.dict = null;
260 ui.ShowLang();
261 return;
262 }
263 string currentGameLanguage = SteamApps.GetCurrentGameLanguage();
264 if (!(currentGameLanguage == "chinese"))
265 {
266 if (!(currentGameLanguage == "japanese"))
267 {
268 BookList.dict = null;
269 ui.ShowLang();
270 return;
271 }
272 langCode = "JP";
273 }
274 else
275 {
276 langCode = "CN";
277 }
278 }
279 catch (Exception message)
280 {
281 Debug.Log(message);
282 }
283 }
284 if (debug.showSceneSelector || (Input.GetKey(KeyCode.LeftShift) && debug.enable))
285 {
286 ui.ShowSceneSelector();
287 }
288 else
289 {
290 Init();
291 }
292 }
293
294 private void FixedUpdate()
295 {
296 fixedFrame += 1f;
297 }
298
299 public void Update()
300 {
301 frame++;
302 SoundManager.requestCount = 0;
304 EInput.uiMousePosition = Input.mousePosition / ui.canvasScaler.scaleFactor;
305 if (!initialized)
306 {
307 return;
308 }
309 ui.OnUpdate();
311 PoolManager.ignorePool = debug.ignorePool;
312 if ((bool)screen.tileMap && !screen.tileMap.passBlock.mat.mainTexture)
313 {
315 }
316 if (useUImat)
317 {
318 Canvas.GetDefaultCanvasMaterial().CopyPropertiesFromMaterial(matUI);
319 }
320 avgDelta += (Time.smoothDeltaTime - delta) * 0.1f;
321 delta = Time.smoothDeltaTime;
322 if (delta > 0.1f)
323 {
324 delta = 0.1f;
325 }
326 EInput.delta = (ButtonState.delta = delta);
327 if (lastFullScreen != Screen.fullScreen)
328 {
329 int width = Display.main.systemWidth;
330 int height = Display.main.systemHeight;
331 if (config != null && config.graphic.fixedResolution)
332 {
333 width = config.graphic.w;
334 height = config.graphic.h;
335 }
336 if (Screen.fullScreen)
337 {
338 Screen.SetResolution(width, height, fullscreen: true);
339 }
340 lastFullScreen = Screen.fullScreen;
342 }
343 if (nextResolutionUpdate <= 0f)
344 {
345 if (config != null && config.graphic.fixedResolution)
346 {
347 int w = config.graphic.w;
348 int h = config.graphic.h;
349 if (Screen.width != w || Screen.height != h)
350 {
351 Screen.SetResolution(w, h, Screen.fullScreen);
352 }
353 }
354 if (Screen.width != lastScreenWidth || Screen.height != lastScreenHeight)
355 {
357 }
359 }
360 else
361 {
363 }
364 if (IsGameStarted)
365 {
366 game.OnUpdate();
368 gameDelta = (FlockChild.delta = (ui.IsPauseGame ? 0f : gameDeltaNoPause));
369 }
370 else
371 {
372 gameDelta = 0f;
373 }
374 scene.OnUpdate();
375 if (actionsNextFrame.Count > 0)
376 {
377 for (int num = actionsNextFrame.Count - 1; num >= 0; num--)
378 {
379 actionsNextFrame[num]();
380 actionsNextFrame.RemoveAt(num);
381 }
382 }
383 }
384
385 private void LateUpdate()
386 {
387 if (!initialized)
388 {
389 return;
390 }
391 if (UIButton.actionTooltip != null)
392 {
394 UIButton.actionTooltip = null;
395 }
396 if (actionsLateUpdate.Count > 0)
397 {
398 for (int num = actionsLateUpdate.Count - 1; num >= 0; num--)
399 {
400 actionsLateUpdate[num]();
401 actionsLateUpdate.RemoveAt(num);
402 }
403 }
405 }
406
407 public void OnApplicationFocus(bool focus)
408 {
409 Resources.UnloadUnusedAssets();
410 GC.Collect();
411 if (config == null)
412 {
413 return;
414 }
415 if (focus)
416 {
417 AudioListener.volume = 1f;
418 }
419 else if (config.other.muteBackground)
420 {
421 AudioListener.volume = 0f;
422 }
423 if (!focus || !Instance)
424 {
425 return;
426 }
427 if (actionsNextFrame.Count == 0)
428 {
429 actionsNextFrame.Add(delegate
430 {
432 actionsNextFrame.Add(delegate
433 {
434 if (IsGameStarted)
435 {
436 if (Application.isEditor && (bool)WidgetMinimap.Instance)
437 {
438 WidgetMinimap.Instance.Reload();
439 }
440 foreach (CardRow row in sources.cards.rows)
441 {
442 if (row.replacer.hasChacked && row.replacer.data != null)
443 {
444 row.replacer.data.GetSprite();
445 }
446 }
447 }
448 });
449 });
450 }
452 {
453 foreach (PCC.Part value in pccs.allParts.Values)
454 {
455 foreach (ModItem<Texture2D> value2 in value.modTextures.Values)
456 {
457 value2.ClearCache();
458 }
459 }
460 CharaActorPCC[] array = UnityEngine.Object.FindObjectsOfType<CharaActorPCC>();
461 for (int i = 0; i < array.Length; i++)
462 {
463 array[i].provider.Rebuild();
464 }
465 }
466 EInput.Consume();
467 EInput.dragHack = 0f;
469 }
470
471 public void OnApplicationQuit()
472 {
473 try
474 {
475 Widget[] componentsInChildren = ui.widgets.GetComponentsInChildren<Widget>(includeInactive: true);
476 foreach (Widget widget in componentsInChildren)
477 {
478 if (widget.gameObject != null)
479 {
480 UnityEngine.Object.Destroy(widget.gameObject);
481 }
482 }
483 IO.PrintLog();
484 }
485 catch (Exception ex)
486 {
487 Debug.Log("Exception:" + ex);
488 }
489 try
490 {
491 if (SteamAPI.IsSteamRunning())
492 {
493 SteamAPI.Shutdown();
494 }
495 }
496 catch (Exception ex2)
497 {
498 Debug.Log("Exception:" + ex2);
499 }
500 try
501 {
502 IO.DeleteDirectory(CorePath.Temp);
504 }
505 catch (Exception ex3)
506 {
507 Debug.Log("Exception:" + ex3);
508 }
509 }
510
511 public void ResetRuntime()
512 {
513 BaseCore.resetRuntime = false;
514 BiomeProfile.forceInitialize = true;
515 WidgetHotbar.registering = false;
516 WidgetHotbar.registeringItem = null;
517 WordGen.initialized = false;
518 RecipeManager.rebuild = true;
519 BookList.dict = null;
520 SpawnList.allList.Clear();
521 }
522
523 public void Init()
524 {
525 Debug.Log("Initializing:" + langCode + "/" + forceLangCode);
526 StartCoroutine("OnEndOfFrame");
527 InvokeRepeating("Update100ms", 0.1f, 0.1f);
528 UnityEngine.Object.DestroyImmediate(ui.layoutLang.gameObject);
530 if (config.lang.IsEmpty())
531 {
532 config.lang = "EN";
533 }
534 SetLang(config.lang);
535 refs.Init();
536 debug.Init();
537 SpriteSheet.Add("Media/Graphics/Icon/icons_48");
538 Cal.Init();
539 Colors.Init();
540 gameSetting.Init();
541 mods.InitLang();
542 if (!Lang.isBuiltin)
543 {
544 sources.ImportSourceTexts();
545 }
546 PCCManager.current.Init();
547 SpriteVariationManager.current.Init();
548 scene.InitPass();
549 textures.Init();
550 textures.RefreshTextures();
551 SoundManager.current.Reset();
552 if (debug.validatePref)
553 {
555 }
556 if (debug.startScene == CoreDebug.StartScene.Title)
557 {
558 scene.Init(Scene.Mode.Title);
559 }
560 else
561 {
562 debug.QuickStart();
563 }
564 ui.HideCover(2f);
565 initialized = true;
566 }
567
568 public void Quit()
569 {
570 Application.Quit();
571 Debug.Log("Quit");
572 }
573
574 public override void ConsumeInput()
575 {
576 EInput.Consume();
577 }
578
579 public static Core SetCurrent(Core _current = null)
580 {
581 if ((bool)Instance)
582 {
583 return Instance;
584 }
585 Instance = _current ?? UnityEngine.Object.FindObjectOfType<Core>();
586 BaseCore.Instance = Instance;
587 if ((bool)Instance)
588 {
589 Instance.SetReferences();
590 }
591 return Instance;
592 }
593
594 public static Core GetCurrent()
595 {
596 return Instance ?? SetCurrent();
597 }
598
599 public void SetReferences()
600 {
601 CorePath.Init();
602 SourceData.dataPath = CorePath.packageCore + "/Data/Source/";
603 Instance = (EClass.core = (EMono.core = this));
604 SkinManager._Instance = skins;
605 PathManager.Instance = pathManager;
606 EffectManager.Instance = effects;
607 sources.InitLang();
608 }
609
611 {
612 if (releaseMode != m)
613 {
614 releaseMode = m;
615 debug = Resources.Load<CoreDebug>("_Debug " + releaseMode);
616 }
617 }
618
619 private IEnumerator OnEndOfFrame()
620 {
621 while (true)
622 {
623 yield return new WaitForEndOfFrame();
624 if ((bool)screen.guide)
625 {
626 screen.guide.OnEndOfFrame();
627 }
628 }
629 }
630
631 private void Update100ms()
632 {
633 if (IsGameStarted)
634 {
635 game.updater.Update100ms();
636 }
637 }
638
639 public void OnChangeResolution()
640 {
641 if (config != null)
642 {
643 config.OnChangeResolution();
644 }
645 screen.RefreshScreenSize();
646 lastScreenWidth = Screen.width;
647 lastScreenHeight = Screen.height;
648 IChangeResolution[] componentsInChildren = ui.GetComponentsInChildren<IChangeResolution>();
649 for (int i = 0; i < componentsInChildren.Length; i++)
650 {
651 componentsInChildren[i].OnChangeResolution();
652 }
654 }
655
656 public void Halt()
657 {
658 }
659
660 public override void FreezeScreen(float duration = 0.3f)
661 {
662 ui.FreezeScreen(duration);
663 }
664
665 public override void UnfreezeScreen()
666 {
667 ui.UnfreezeScreen();
668 }
669
670 public override void RebuildBGMList()
671 {
672 refs.RebuildBGMList();
673 }
674
675 public override void StopEventSystem(Component c, Action action, float duration = 0.12f)
676 {
677 eventSystem.enabled = false;
678 c.transform.DOScale(new Vector3(1f, 0f, 1f), duration).OnKill(delegate
679 {
680 eventSystem.enabled = true;
681 }).OnComplete(delegate
682 {
683 action();
684 })
685 .SetEase(Ease.Linear);
686 }
687
688 public override void StopEventSystem(float duration = 0.2f)
689 {
690 eventSystem.enabled = false;
691 TweenUtil.Tween(duration, null, delegate
692 {
693 eventSystem.enabled = true;
694 });
695 }
696
697 public void SetLang(string langCode, bool force = false)
698 {
699 if (!(Lang.langCode == langCode) || !sources || !sources.langGeneral)
700 {
701 Lang.Init(langCode);
702 AliasGen.list = null;
703 NameGen.list = null;
704 WordGen.initialized = false;
705 sources.OnChangeLang();
706 if (game != null && !IsGameStarted)
707 {
708 game.Kill();
709 }
710 config.OnSetLang();
711 }
712 }
713
714 public static int[] ParseElements(string str)
715 {
716 if (string.IsNullOrEmpty(str))
717 {
718 return new int[0];
719 }
720 string[] array = str.Replace("\n", "").Split(',');
721 int[] array2 = new int[array.Length * 2];
722 for (int i = 0; i < array.Length; i++)
723 {
724 string[] array3 = array[i].Split('/');
725 array2[i * 2] = GetElement(array3[0]);
726 array2[i * 2 + 1] = ((array3.Length == 1) ? 1 : int.Parse(array3[1]));
727 }
728 return array2;
729 }
730
731 public static int GetElement(string id)
732 {
733 SetCurrent();
734 if (sourceElement == null)
735 {
736 sourceElement = UnityEngine.Object.FindObjectOfType<SourceManager>().GetComponent<SourceManager>().elements;
737 }
738 if (!sourceElement.initialized)
739 {
740 sourceElement.Init();
741 }
742 if (!sourceElement.alias.TryGetValue(id ?? "_void", out var value))
743 {
744 Debug.LogError("exception:" + id);
745 value = sourceElement.rows[0];
746 }
747 return value.id;
748 }
749
750 public void ApplySkins()
751 {
752 IUISkin[] componentsInChildren = ui.GetComponentsInChildren<IUISkin>(includeInactive: true);
753 for (int i = 0; i < componentsInChildren.Length; i++)
754 {
755 componentsInChildren[i].ApplySkin();
756 }
757 }
758
759 public static IniData GetElinIni()
760 {
761 string pathIni = CorePath.PathIni;
762 string ie = "0123456789abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ";
763 try
764 {
765 FileIniDataParser fileIniDataParser = new FileIniDataParser();
766 if (!File.Exists(pathIni))
767 {
768 File.CreateText(pathIni).Close();
769 }
770 IniData iniData = fileIniDataParser.ReadFile(pathIni, Encoding.UTF8);
771 if (iniData.GetKey("pass").IsEmpty())
772 {
773 string text = "";
774 for (int i = 0; i < 4; i++)
775 {
776 text += ie.RandomItem();
777 }
778 iniData.Global["pass"] = text;
779 fileIniDataParser.WriteFile(pathIni, iniData);
780 }
781 return iniData;
782 }
783 catch (Exception message)
784 {
785 Debug.Log(message);
786 Debug.Log("exception: Failed to parse:" + pathIni);
787 IO.DeleteFile(pathIni);
788 File.CreateText(pathIni).Close();
789 return null;
790 }
791 }
792
793 public static void SaveElinIni(IniData ini)
794 {
795 new FileIniDataParser().WriteFile(CorePath.PathIni, ini);
796 }
797
798 public static void TryWarnMod(Action action, bool warn = true)
799 {
800 if (warn)
801 {
802 IniData ini = GetElinIni();
803 if (ini.Global["agreed_usercontens_usage_terms"] != "yes")
804 {
805 string[] items = new string[3] { "readTerms", "agree", "disagree" };
806 Dialog.List("dialogTermsOfUseUGC".lang(), items, (string j) => j, delegate(int c, string d)
807 {
808 switch (c)
809 {
810 case 0:
811 LayerHelp.Toggle("custom", "terms2");
812 return false;
813 case 1:
814 ini.Global["agreed_usercontens_usage_terms"] = "yes";
815 SaveElinIni(ini);
816 action();
817 break;
818 }
819 return true;
820 }, canCancel: true);
821 return;
822 }
823 }
824 action();
825 }
826
827 public static void TryWarnUpload(Action action)
828 {
829 IniData ini = GetElinIni();
830 if (ini.Global["agreed_usercontents_upload_terms"] != "yes")
831 {
832 string[] items = new string[3] { "readTerms", "agree", "disagree" };
833 Dialog.List("dialogTermsOfUse".lang(), items, (string j) => j, delegate(int c, string d)
834 {
835 switch (c)
836 {
837 case 0:
838 LayerHelp.Toggle("custom", "terms");
839 return false;
840 case 1:
841 ini.Global["agreed_usercontents_upload_terms"] = "yes";
842 SaveElinIni(ini);
843 action();
844 break;
845 }
846 return true;
847 }, canCancel: true);
848 }
849 else
850 {
851 action();
852 }
853 }
854}
ReleaseMode
Definition: ReleaseMode.cs:2
virtual float gameSpeed
Definition: ActionMode.cs:119
int lastScreenHeight
Definition: BaseCore.cs:44
string langCode
Definition: BaseCore.cs:25
static bool IsOffline
Definition: BaseCore.cs:9
List< Action > actionsNextFrame
Definition: BaseCore.cs:31
int frame
Definition: BaseCore.cs:40
string forceLangCode
Definition: BaseCore.cs:37
Canvas canvas
Definition: BaseCore.cs:34
Version version
Definition: BaseCore.cs:17
int lastScreenWidth
Definition: BaseCore.cs:42
static bool resetRuntime
Definition: BaseCore.cs:13
ReleaseMode releaseMode
Definition: BaseCore.cs:23
List< Action > actionsLateUpdate
Definition: BaseCore.cs:29
ScreenGuide guide
void RefreshScreenSize()
BaseTileMap tileMap
RenderDataObjDummy rendererObjDummy
Definition: BaseTileMap.cs:227
MeshPass passBlock
Definition: BaseTileMap.cs:147
void OnChangeResolution()
SoundSource PlaySound(string id, float v=1f, bool spatial=true)
Definition: Card.cs:5404
SpriteProvider provider
Definition: CharaActorPCC.cs:9
static HashSet< string > assemblies
Definition: ClassCache.cs:52
static CoreConfig TryLoadConfig()
Definition: CoreConfig.cs:649
GraphicSetting graphic
Definition: CoreConfig.cs:594
string lang
Definition: CoreConfig.cs:570
void OnChangeResolution()
Definition: CoreConfig.cs:819
static string path
Definition: CoreConfig.cs:623
OtherSetting other
Definition: CoreConfig.cs:606
void OnSetLang()
Definition: CoreConfig.cs:1002
static void Init()
Definition: CoreConfig.cs:691
void Init()
Definition: CoreDebug.cs:327
bool showSceneSelector
Definition: CoreDebug.cs:108
bool ignorePool
Definition: CoreDebug.cs:116
string command
Definition: CoreDebug.cs:135
bool validatePref
Definition: CoreDebug.cs:249
void QuickStart()
Definition: CoreDebug.cs:333
bool enable
Definition: CoreDebug.cs:285
bool skipModSync
Definition: CoreDebug.cs:111
void UpdateAlways()
Definition: CoreDebug.cs:781
Lang.LangCode langCode
Definition: CoreDebug.cs:113
StartScene startScene
Definition: CoreDebug.cs:95
static string PathIni
Definition: CorePath.cs:212
static string Temp
Definition: CorePath.cs:210
static string rootMod
Definition: CorePath.cs:169
static void Init()
Definition: CorePath.cs:220
static string RootSave
Definition: CorePath.cs:206
void RebuildBGMList()
Definition: CoreRef.cs:427
void Init()
Definition: CoreRef.cs:407
Definition: Core.cs:14
override void StopEventSystem(float duration=0.2f)
Definition: Core.cs:688
void StartCase()
Definition: Core.cs:215
override float uiScale
Definition: Core.cs:95
float nextResolutionUpdate
Definition: Core.cs:79
Material matUI
Definition: Core.cs:55
void LateUpdate()
Definition: Core.cs:385
CoreRef refs
Definition: Core.cs:51
ModManager mods
Definition: Core.cs:39
void Quit()
Definition: Core.cs:568
GameSetting gameSetting
Definition: Core.cs:47
IEnumerator OnEndOfFrame()
Definition: Core.cs:619
Game game
Definition: Core.cs:72
override void RebuildBGMList()
Definition: Core.cs:670
static SourceElement sourceElement
Definition: Core.cs:29
void OnApplicationFocus(bool focus)
Definition: Core.cs:407
void FixedUpdate()
Definition: Core.cs:294
override void StopEventSystem(Component c, Action action, float duration=0.12f)
Definition: Core.cs:675
EffectManager effects
Definition: Core.cs:37
static float avgDelta
Definition: Core.cs:19
static int GetElement(string id)
Definition: Core.cs:731
static void SaveElinIni(IniData ini)
Definition: Core.cs:793
override void FreezeScreen(float duration=0.3f)
Definition: Core.cs:660
void Init()
Definition: Core.cs:523
void Update()
Definition: Core.cs:299
void ResetRuntime()
Definition: Core.cs:511
SourceManager sources
Definition: Core.cs:33
static Core SetCurrent(Core _current=null)
Definition: Core.cs:579
float skinTimer
Definition: Core.cs:81
override void ConsumeInput()
Definition: Core.cs:574
static void TryWarnUpload(Action action)
Definition: Core.cs:827
CoreDebug debug
Definition: Core.cs:31
SkinManager skins
Definition: Core.cs:43
Steam steam
Definition: Core.cs:57
void Start()
Definition: Core.cs:197
TextureManager textures
Definition: Core.cs:45
void OnApplicationQuit()
Definition: Core.cs:471
void Halt()
Definition: Core.cs:656
static int[] ParseElements(string str)
Definition: Core.cs:714
static float gameDeltaNoPause
Definition: Core.cs:23
static float gameDelta
Definition: Core.cs:21
static new Core Instance
Definition: Core.cs:15
ColorProfile Colors
Definition: Core.cs:53
void OnChangeResolution()
Definition: Core.cs:639
bool initialized
Definition: Core.cs:75
override void Awake()
Definition: Core.cs:97
void SetReleaseMode(ReleaseMode m)
Definition: Core.cs:610
Scene scene
Definition: Core.cs:65
static IniData GetElinIni()
Definition: Core.cs:759
void ApplySkins()
Definition: Core.cs:750
BaseGameScreen screen
Definition: Core.cs:67
static float fixedFrame
Definition: Core.cs:25
static bool spiked
Definition: Core.cs:27
void Update100ms()
Definition: Core.cs:631
GameData gamedata
Definition: Core.cs:49
override void UnfreezeScreen()
Definition: Core.cs:665
bool IsGameStarted
Definition: Core.cs:84
void SetReferences()
Definition: Core.cs:599
PathManager pathManager
Definition: Core.cs:35
UI ui
Definition: Core.cs:63
PCCManager pccs
Definition: Core.cs:41
void SetLang(string langCode, bool force=false)
Definition: Core.cs:697
static void TryWarnMod(Action action, bool warn=true)
Definition: Core.cs:798
bool trial
Definition: Core.cs:61
static float delta
Definition: Core.cs:17
static Core GetCurrent()
Definition: Core.cs:594
CoreConfig config
Definition: Core.cs:70
bool useUImat
Definition: Core.cs:59
bool? lastFullScreen
Definition: Core.cs:77
Definition: Dialog.cs:7
Definition: EInput.cs:8
static void Consume(int _skipFrame)
Definition: EInput.cs:656
static void DisableIME()
Definition: EInput.cs:454
static Action< List< string > > onDrop
Definition: GameIO.cs:10
static void DeleteEmptyGameFolders(string path)
Definition: GameIO.cs:340
void Init()
Definition: GameSetting.cs:353
void Update100ms()
Definition: GameUpdater.cs:387
Definition: Game.cs:8
new Player player
Definition: Game.cs:176
void Kill()
Definition: Game.cs:1030
GameUpdater updater
Definition: Game.cs:243
void OnUpdate()
Definition: Game.cs:289
static void UpdateEventData()
Definition: Lang.cs:6
static string langCode
Definition: Lang.cs:28
static void Init(string lang)
Definition: Lang.cs:71
static bool isBuiltin
Definition: Lang.cs:42
static bool keepBGM
Definition: LayerDrama.cs:10
static bool haltPlaylist
Definition: LayerDrama.cs:12
static void Toggle(string idFile, string idTopic=null)
Definition: LayerHelp.cs:32
static List< LayerInventory > listInv
Definition: MOD.cs:7
static Dictionary< string, LangSetting > langs
Definition: MOD.cs:8
static List< FileInfo > listMaps
Definition: MOD.cs:20
static List< FileInfo > listPartialMaps
Definition: MOD.cs:22
Material mat
Definition: MeshPass.cs:21
void ClearCache()
Definition: ModItem.cs:65
static bool IsInitialized
Definition: ModManager.cs:33
override void Init(string path, string defaultPackage="_Elona")
Definition: ModManager.cs:35
IEnumerator RefreshMods(Action onComplete, bool syncMods)
Definition: ModManager.cs:95
static bool disableMod
Definition: ModManager.cs:25
static List< object > ListPluginObject
Definition: ModManager.cs:23
Chara chara
Definition: Player.cs:1004
void Init()
Definition: RenderData.cs:94
Definition: Scene.cs:8
void OnLateUpdate()
Definition: Scene.cs:733
CameraSupport camSupport
Definition: Scene.cs:41
ActionMode actionMode
Definition: Scene.cs:77
void OnUpdate()
Definition: Scene.cs:354
void InitPass()
Definition: Scene.cs:1025
GameScreenNoMap screenNoMap
Definition: Scene.cs:93
void Init(Mode newMode)
Definition: Scene.cs:172
Mode
Definition: Scene.cs:10
void OnEndOfFrame()
Definition: ScreenGuide.cs:37
List< CardRow > rows
Definition: SourceCard.cs:6
LangGeneral langGeneral
Definition: SourceManager.cs:6
SourceCard cards
void ImportSourceTexts()
SourceElement elements
void OnChangeLang()
static SourcePrefInspector Instance
static Dictionary< string, SpawnList > allList
Definition: SpawnList.cs:6
static Dictionary< string, SpriteData > dict
static void Add(Sprite sprite)
Definition: SpriteSheet.cs:10
static Dictionary< string, Sprite > dict
Definition: SpriteSheet.cs:6
static HashSet< string > loadedPath
Definition: SpriteSheet.cs:8
Definition: Steam.cs:8
SteamworksBehaviour steamworks
Definition: Steam.cs:11
void Init()
Definition: Steam.cs:24
void RefreshTextures()
void OnDropFile(List< string > paths)
static void Init()
Definition: TileType.cs:269
static Action actionTooltip
Definition: UIButton.cs:184
static WidgetMinimap Instance
Definition: Widget.cs:7
Definition: Window.cs:13
static Dictionary< string, SaveData > dictData
Definition: Window.cs:594
void OnChangeResolution()
void ApplySkin()
string GetText()
Definition: Version.cs:16