Example #1
0
 /// <summary>
 /// Do not call this constructor. Use SxLib.InitializeOffscreen instead.
 /// </summary>
 /// <param name="_Current"></param>
 /// <param name="_SynapseDir"></param>
 protected internal SxLibOffscreen(string _SynapseDir) : base(_SynapseDir)
 {
     LoadEventInternal   += delegate(SynLoadEvents LEvent, object Param) { LoadEvent?.Invoke(LEvent, Param); };
     AttachEventInternal += delegate(SynAttachEvents AEvent, object Param) { AttachEvent?.Invoke(AEvent, Param); };
     HubEventInternal    += delegate(List <SynHubEntry> Entries)
     {
         ScriptHubMarkAsClosedInternal();
         ScriptHubEvent?.Invoke(Entries);
     };
 }
        public void Load()
        {
            Task.Run(() =>
            {
                var platforms = _platformFactory.GetPlatforms();

                LoadEvent?.Invoke(this, new Information
                {
                    MachineName      = Environment.MachineName,
                    OperartiveSystem = Environment.OSVersion,
                    Platforms        = platforms.Where(x => x.Value.Available).Select(x => x.Value)
                });
            });
        }
Example #3
0
    public void LoadData(string json)
    {
        FullSave fullSave = JsonUtility.FromJson <FullSave>(json);

        // Singleton static
        // Reference
        JsonUtility.FromJsonOverwrite(fullSave.PlayerPart.Who, Player);
        StartHomeStats.Load(fullSave.HomePart);
        dorm.Load(fullSave.DormPart);
        voreChar.Load(fullSave.VoreSaves, Player);
        // Pure static
        DateSystem.Load(fullSave.DatePart);
        QuestsSystem.Load(fullSave.QuestSave);
        PlayerFlags.Load(fullSave.PlayerFlagsSave);
        MapEvents.GetMapEvents.Load(fullSave.PosPart, fullSave.TeleportSaves);
        GameManager.Load(fullSave.GameManagerSave);
        EventLog.ClearLog();
        LoadEvent?.Invoke();
    }
Example #4
0
 public void RaiseLoadEvent(object sender, System.Windows.RoutedEventArgs e)
 {
     LoadEvent?.Invoke();
 }
Example #5
0
 public void LoadEventOperation()
 {
     LoadEvent?.Invoke(this, EventArgs.Empty);
 }
Example #6
0
 internal void InitScript(UUIView _script)
 {
     Script = _script;
     LoadEvent?.Invoke(Script);
     LoadEvent = null;
 }
Example #7
0
 /// <summary>
 /// Do not call this constructor. Use SxLib.InitializeWinForms instead.
 /// </summary>
 /// <param name="_Current"></param>
 /// <param name="_SynapseDir"></param>
 protected internal SxLibWinForms(Form _Current, string _SynapseDir) : base(_SynapseDir)
 {
     Current              = _Current;
     LoadEventInternal   += delegate(SynLoadEvents LEvent, object Param) { Current.Invoke(new Action(() => { LoadEvent?.Invoke(LEvent, Param); })); };
     AttachEventInternal += delegate(SynAttachEvents AEvent, object Param) { Current.Invoke(new Action(() => { AttachEvent?.Invoke(AEvent, Param); })); };
     HubEventInternal    += delegate(List <SynHubEntry> Entries) { Current.Invoke(new Action(() => { ScriptHubEvent?.Invoke(Entries); })); };
 }
 protected virtual void OnLoadEvent(LoadEventArgs e)
 {
     LoadEvent?.Invoke(this, e);
 }
Example #9
0
 public virtual void Refresh()
 {
     LoadEvent?.Invoke();
 }
Example #10
0
 private void Loaded(VRTK_SDKManager sender, VRTK_SDKSetup setup)
 {
     OnLoaded.Invoke(sender, setup);
 }
Example #11
0
 /// <summary>
 /// Do not call this constructor. Use SxLib.InitializeWPF instead.
 /// </summary>
 /// <param name="_Current"></param>
 /// <param name="_SynapseDir"></param>
 protected internal SxLibWPF(Window _Current, string _SynapseDir) : base(_SynapseDir)
 {
     Current              = _Current;
     LoadEventInternal   += delegate(SynLoadEvents LEvent, object Param) { Current.Dispatcher.Invoke(() => { LoadEvent?.Invoke(LEvent, Param); }); };
     AttachEventInternal += delegate(SynAttachEvents AEvent, object Param) { Current.Dispatcher.Invoke(() => { AttachEvent?.Invoke(AEvent, Param); }); };
     HubEventInternal    += delegate(List <SynHubEntry> Entries) { Current.Dispatcher.Invoke(() => { ScriptHubEvent?.Invoke(Entries); }); };
 }