Skip to content

Runtime Helpers B

Codex edited this page Oct 12, 2026 · 1 revision

uk · ru · en · de · fr · it · es · zh-tw · ja · ko

Допоміжні функції B

Внутрішній код реалізації, не самостійний скрипт.

ClassicUO.CSharp.CSharpCallbacks.CommandWords

Перевіряє умови нижче й повертає показаний результат.

Параметри: command

Джерело: Project_Full/src/ClassicUO.CSharp/CSharpCallbacks.cs:449.

private static string[] CommandWords(string command)

Результат: string[].

Результат: words.ToArray().

Виклики: word.Append, char.IsWhiteSpace, words.Add, word.ToString, word.Clear, words.ToArray.

Умови: quote != '\0'; letter == quote; letter is '\'' or '"'; char.IsWhiteSpace(letter).

Внутрішній код реалізації, не самостійний скрипт.

private static string[] CommandWords(string command)
    {
        var words = new List<string>(); var word = new System.Text.StringBuilder(); char quote = '\0'; bool started = false;
        foreach (char letter in command)
        {
            if (quote != '\0') { if (letter == quote) quote = '\0'; else word.Append(letter); started = true; }
            else if (letter is '\'' or '"') { quote = letter; started = true; }
            else if (char.IsWhiteSpace(letter)) { if (started) { words.Add(word.ToString()); word.Clear(); started = false; } }
            else { word.Append(letter); started = true; }
        }
        if (quote != '\0') throw new ArgumentException("Unclosed quote in callback command.");
        if (started) words.Add(word.ToString());
        return words.ToArray();
    }

ClassicUO.CSharp.CSharpCallbacks.IsRunning

Повертає значення виразу нижче.

Параметри: name

Джерело: Project_Full/src/ClassicUO.CSharp/CSharpCallbacks.cs:168.

public bool IsRunning(string name)

Результат: bool.

Виклики: Verify, active.Any.

Виклики:

Внутрішній код реалізації, не самостійний скрипт.

public bool IsRunning(string name)
    {
        Verify();
        lock (sync) return active.Any(call => call.Name.Equals((name ?? "").Trim(), StringComparison.OrdinalIgnoreCase)
            && !call.Cancellation.IsCancellationRequested);
    }

ClassicUO.Game.GameActions.Attack

Виконує показані виклики та оновлення стану.

Параметри: world, serial

Джерело: Project_Full/src/ClassicUO.Client/Game/GameActions.cs:265.

public static void Attack(World world, uint serial)

Результат: void.

Виклики: world.Mobiles.Get, UIManager.Add, Socket.Send_AttackRequest.

Умови: ProfileManager.CurrentProfile.EnabledCriminalActionQuery; m != null && (world.Player.NotorietyFlag == NotorietyFlag.Innocent || world.Player.NotorietyFlag == NotorietyFlag.Ally) && m.NotorietyFlag == NotorietyFlag.Innocent && m != world.Player.

Внутрішній код реалізації, не самостійний скрипт.

public static void Attack(World world, uint serial)
        {
            if (ProfileManager.CurrentProfile.EnabledCriminalActionQuery)
            {
                Mobile m = world.Mobiles.Get(serial);

                if (m != null && (world.Player.NotorietyFlag == NotorietyFlag.Innocent || world.Player.NotorietyFlag == NotorietyFlag.Ally) && m.NotorietyFlag == NotorietyFlag.Innocent && m != world.Player)
                {
                    QuestionGump messageBox = new QuestionGump
                    (
                        world,
                        ResGeneral.ThisMayFlagYouCriminal,
                        s =>
                        {
                            if (s)
                            {
                                Socket.Send_AttackRequest(serial);
                            }
                        }
                    );

                    UIManager.Add(messageBox);

                    return;
                }
            }

            world.TargetManager.NewTargetSystemSerial = serial;
            world.TargetManager.LastAttack = serial;
            Socket.Send_AttackRequest(serial);
        }

ClassicUO.Game.GameActions.RequestPartyQuit

Виконує показані виклики та оновлення стану.

Параметри: player

Джерело: Project_Full/src/ClassicUO.Client/Game/GameActions.cs:559.

public static void RequestPartyQuit(PlayerMobile player)

Результат: void.

Виклики: Socket.Send_PartyRemoveRequest.

Внутрішній код реалізації, не самостійний скрипт.

public static void RequestPartyQuit(PlayerMobile player)
        {
            Socket.Send_PartyRemoveRequest(player.Serial);
        }

ClassicUO.Game.GameActions.RequestPartyRemoveMember

Виконує показані виклики та оновлення стану.

Параметри: serial

Джерело: Project_Full/src/ClassicUO.Client/Game/GameActions.cs:554.

public static void RequestPartyRemoveMember(uint serial)

Результат: void.

Виклики: Socket.Send_PartyRemoveRequest.

Внутрішній код реалізації, не самостійний скрипт.

public static void RequestPartyRemoveMember(uint serial)
        {
            Socket.Send_PartyRemoveRequest(serial);
        }

ClassicUO.Game.GameActions.UseSecondaryAbility

Виконує показані виклики та оновлення стану.

Параметри: world

Джерело: Project_Full/src/ClassicUO.Client/Game/GameActions.cs:957.

public static void UseSecondaryAbility(World world)

Результат: void.

Виклики: SendAbility.

Умови: world?.Player == null; ((byte) ability & 0x80) == 0.

Виклики:

Внутрішній код реалізації, не самостійний скрипт.

public static void UseSecondaryAbility(World world)
        {
            if (world?.Player == null)
                return;

            ref Ability ability = ref world.Player.Abilities[1];

            if (((byte) ability & 0x80) == 0)
            {
                for (int i = 0; i < 2; i++)
                {
                    world.Player.Abilities[i] &= (Ability) 0x7F;
                }

                SendAbility(world, (byte)ability, false);
            }
            else
            {
                SendAbility(world, 0, false);
            }

            ability ^= (Ability) 0x80;
        }

ClassicUO.Game.Managers.ClassicUOInjectionApiBridge.ActivateGumpButton

Повертає значення виразу нижче.

Параметри: gumpId, buttonId

Джерело: Project_Full/src/ClassicUO.Client/Game/Managers/ClassicUOInjectionApiBridge.cs:3007.

public int ActivateGumpButton(int gumpId, int buttonId)

Результат: int.

Результат: Invoke(() => ActivateGumpButtonUnsafe(ResolveGumpUnsafe(gumpId), buttonId)).

Виклики: Invoke.

Виклики:

Внутрішній код реалізації, не самостійний скрипт.

public int ActivateGumpButton(int gumpId, int buttonId)

            => Invoke(() => ActivateGumpButtonUnsafe(ResolveGumpUnsafe(gumpId), buttonId));

ClassicUO.Game.Managers.ClassicUOInjectionApiBridge.ActivateGumpButtonUnsafe

Перевіряє умови нижче й повертає показаний результат.

Параметри: gump, buttonId

Джерело: Project_Full/src/ClassicUO.Client/Game/Managers/ClassicUOInjectionApiBridge.cs:3013.

private static int ActivateGumpButtonUnsafe(Gump gump, int buttonId)

Результат: int.

Результат: 0; 1.

Виклики: logical.Fields.FirstOrDefault, logical.ChangePage, logical.OnButtonClick, `Descendants(gump).OfType()

            .FirstOrDefault`, `Descendants(gump).OfType<Button>`, `Descendants`, `gump.ChangePage`, `gump.OnButtonClick`.

Умови: gump == null; gump is SessionServerGump logical; field == null || logical.IsDisposed; field.Action == ButtonAction.SwitchPage.

Виклики:

Внутрішній код реалізації, не самостійний скрипт.

private static int ActivateGumpButtonUnsafe(Gump gump, int buttonId)

        {

            if (gump == null)

                return 0;



            if (gump is SessionServerGump logical)

            {

                var field = logical.Fields.FirstOrDefault(f => f.IsButton && f.ButtonId == buttonId);

                if (field == null || logical.IsDisposed) return 0;

                if (field.Action == ButtonAction.SwitchPage) logical.ChangePage(field.ToPage);

                else logical.OnButtonClick(field.ButtonId);

                return 1;

            }

            Button button = Descendants(gump).OfType<Button>()

                .FirstOrDefault(control => control.ButtonID == buttonId);

            if (button == null)

                return 0;



            if (button.ButtonAction == ButtonAction.SwitchPage)

                gump.ChangePage(button.ToPage);

            else

                gump.OnButtonClick(button.ButtonID);



            return 1;

        }

ClassicUO.Game.Managers.ClassicUOInjectionApiBridge.AddObject

Виконує показані виклики та оновлення стану.

Параметри: name

Джерело: Project_Full/src/ClassicUO.Client/Game/Managers/ClassicUOInjectionApiBridge.cs:719.

public void AddObject(string name)

Результат: void.

Виклики: string.IsNullOrWhiteSpace, Error, State.Objects.Remove, SelectObject, State.Objects.Set, ReportStatus.

Умови: string.IsNullOrWhiteSpace(name) || _csharpState == null; result is Entity entity; result != null.

Виклики:

Внутрішній код реалізації, не самостійний скрипт.

public void AddObject(string name)

        {

            if (string.IsNullOrWhiteSpace(name) || _csharpState == null)

            {

                Error("UO.AddObject: object name is empty");

                return;

            }



            State.Objects.Remove(name);

            GameObject result = SelectObject();

            if (result is Entity entity)

            {

                State.Objects.Set(name, (int)entity.Serial);

                ReportStatus($"Object '{name}' = 0x{entity.Serial:X8}");

            }

            else if (result != null)

                Error("UO.AddObject: select an item or mobile, not a map tile");

        }

ClassicUO.Game.Managers.ClassicUOInjectionApiBridge.BookGetPageText

Повертає значення виразу нижче.

Параметри: page

Джерело: Project_Full/src/ClassicUO.Client/Game/Managers/ClassicUOInjectionApiBridge.cs:1795.

public string BookGetPageText(int page)

Результат: string.

Результат: Invoke(() => GetOpenBook()?.YokoGetPageText(page) ?? string.Empty).

Виклики: Invoke.

Виклики:

Внутрішній код реалізації, не самостійний скрипт.

public string BookGetPageText(int page) => Invoke(() => GetOpenBook()?.YokoGetPageText(page) ?? string.Empty);

ClassicUO.Game.Managers.ClassicUOInjectionApiBridge.CharPrintEx

Виконує показані виклики та оновлення стану.

Параметри: id, color, font, msg

Джерело: Project_Full/src/ClassicUO.Client/Game/Managers/ClassicUOInjectionApiBridge.cs:1846.

public void CharPrintEx(int id, int color, int font, string msg)

Результат: void.

Виклики: Invoke.

Виклики:

  • ClassicUO.Game.Managers.ClassicUOInjectionApiBridge.Invoke: Invoke(() => { using var journalContext = new JournalMessageContext("script"); Entity target = _world.Get(unchecked((uint)id)); if (target == null || target.IsDestroyed || string.IsNullOrEmpty(msg)) { ReportStatus($"UO.ClientPrintEx target is unavailable: 0x{(uint)id:X8}"); return; } byte selectedFont = (byte)Math.Clamp(font, byte.MinValue, byte.MaxValue); GameActions.Print(_world, target, msg, unchecked((ushort)color), GameActions.LOCAL_OVERHEAD_MESSAGE_TYPE, selectedFont, true); ReportStatus($"UO.ClientPrintEx delivered over 0x{(uint)id:X8} with font {selectedFont}"); }). Кандидати перевантаження: джерело не підтверджує вибір конкретного варіанта.
  • ClassicUO.Game.Managers.ClassicUOInjectionApiBridge.Invoke: Invoke(() => { using var journalContext = new JournalMessageContext("script"); Entity target = _world.Get(unchecked((uint)id)); if (target == null || target.IsDestroyed || string.IsNullOrEmpty(msg)) { ReportStatus($"UO.ClientPrintEx target is unavailable: 0x{(uint)id:X8}"); return; } byte selectedFont = (byte)Math.Clamp(font, byte.MinValue, byte.MaxValue); GameActions.Print(_world, target, msg, unchecked((ushort)color), GameActions.LOCAL_OVERHEAD_MESSAGE_TYPE, selectedFont, true); ReportStatus($"UO.ClientPrintEx delivered over 0x{(uint)id:X8} with font {selectedFont}"); }). Кандидати перевантаження: джерело не підтверджує вибір конкретного варіанта.
  • ClassicUO.Game.World.Get: _world.Get(unchecked((uint)id)).
  • ClassicUO.Game.Managers.ClassicUOInjectionApiBridge.ReportStatus: ReportStatus($"UO.ClientPrintEx target is unavailable: 0x{(uint)id:X8}").
  • ClassicUO.Game.GameActions.Print: GameActions.Print(_world, target, msg, unchecked((ushort)color), GameActions.LOCAL_OVERHEAD_MESSAGE_TYPE, selectedFont, true).
  • ClassicUO.Game.Managers.ClassicUOInjectionApiBridge.ReportStatus: ReportStatus($"UO.ClientPrintEx delivered over 0x{(uint)id:X8} with font {selectedFont}").

Внутрішній код реалізації, не самостійний скрипт.

public void CharPrintEx(int id, int color, int font, string msg) => Invoke(() =>

        {

            using var journalContext = new JournalMessageContext("script");

            Entity target = _world.Get(unchecked((uint)id));

            if (target == null || target.IsDestroyed || string.IsNullOrEmpty(msg))

            {

                ReportStatus($"UO.ClientPrintEx target is unavailable: 0x{(uint)id:X8}");

                return;

            }



            byte selectedFont = (byte)Math.Clamp(font, byte.MinValue, byte.MaxValue);

            GameActions.Print(_world, target, msg, unchecked((ushort)color),

                GameActions.LOCAL_OVERHEAD_MESSAGE_TYPE, selectedFont, true);

            ReportStatus($"UO.ClientPrintEx delivered over 0x{(uint)id:X8} with font {selectedFont}");

        });

ClassicUO.Game.Managers.ClassicUOInjectionApiBridge.Count

Повертає значення виразу нижче.

Параметри: type, color, containerId

Джерело: Project_Full/src/ClassicUO.Client/Game/Managers/ClassicUOInjectionApiBridge.cs:2699.

public int Count(int type, int color, int containerId)

Результат: int.

Результат: _findFullQuantity.

Виклики: FindType.

Виклики:

Внутрішній код реалізації, не самостійний скрипт.

public int Count(int type, int color, int containerId)

        {

            FindType(type, color, containerId, State.FindDistance, true);

            return _findFullQuantity;

        }

ClassicUO.Game.Managers.ClassicUOInjectionApiBridge.FindTrade

Повертає значення виразу нижче.

Параметри: index

Джерело: Project_Full/src/ClassicUO.Client/Game/Managers/ClassicUOInjectionApiBridge.cs:246.

private ISessionTrade FindTrade(int index)

Результат: ISessionTrade.

Результат: index < 0 ? null : _world.Trades.Snapshot().ElementAtOrDefault(index).

Виклики: _world.Trades.Snapshot().ElementAtOrDefault, _world.Trades.Snapshot.

Внутрішній код реалізації, не самостійний скрипт.

private ISessionTrade FindTrade(int index) => index < 0 ? null : _world.Trades.Snapshot().ElementAtOrDefault(index);

ClassicUO.Game.Managers.ClassicUOInjectionApiBridge.GetAbilityName

Повертає значення виразу нижче.

Параметри: abilityId

Джерело: Project_Full/src/ClassicUO.Client/Game/Managers/ClassicUOInjectionApiBridge.cs:2219.

public string GetAbilityName(int abilityId)

Результат: string.

Внутрішній код реалізації, не самостійний скрипт.

public string GetAbilityName(int abilityId) => abilityId >= 1 && abilityId <= AbilityData.Abilities.Length

            ? AbilityData.Abilities[abilityId - 1].Name

            : string.Empty;

ClassicUO.Game.Managers.ClassicUOInjectionApiBridge.GetCharactersForCurrentShard

Повертає значення виразу нижче.

Параметри: Немає параметрів.

Джерело: Project_Full/src/ClassicUO.Client/Game/Managers/ClassicUOInjectionApiBridge.cs:488.

public string[] GetCharactersForCurrentShard()

Результат: string[].

Виклики: Invoke.

Виклики:

  • ClassicUO.Game.Managers.ClassicUOInjectionApiBridge.Invoke: Invoke(() => { if (_world.SessionControl is { } session) return session.Characters; string account = !string.IsNullOrEmpty(LoginScene.Account) ? LoginScene.Account : Settings.GlobalSettings.Username; string server = _world.ResolveProfileServerName(); string[] known = LastCharacterManager.GetKnownCharacters(account, server); if (known.Length != 0) return known; LoginScene loginScene = Client.Game?.GetScene<LoginScene>(); if (loginScene?.Characters != null) { string[] current = loginScene.Characters .Where(name => !string.IsNullOrWhiteSpace(name)) .ToArray(); if (current.Length != 0) return current; } string currentName = _world.Player?.Name ?? string.Empty; return string.IsNullOrWhiteSpace(currentName) ? Array.Empty<string>() : new[] { currentName }; }). Кандидати перевантаження: джерело не підтверджує вибір конкретного варіанта.
  • ClassicUO.Game.Managers.ClassicUOInjectionApiBridge.Invoke: Invoke(() => { if (_world.SessionControl is { } session) return session.Characters; string account = !string.IsNullOrEmpty(LoginScene.Account) ? LoginScene.Account : Settings.GlobalSettings.Username; string server = _world.ResolveProfileServerName(); string[] known = LastCharacterManager.GetKnownCharacters(account, server); if (known.Length != 0) return known; LoginScene loginScene = Client.Game?.GetScene<LoginScene>(); if (loginScene?.Characters != null) { string[] current = loginScene.Characters .Where(name => !string.IsNullOrWhiteSpace(name)) .ToArray(); if (current.Length != 0) return current; } string currentName = _world.Player?.Name ?? string.Empty; return string.IsNullOrWhiteSpace(currentName) ? Array.Empty<string>() : new[] { currentName }; }). Кандидати перевантаження: джерело не підтверджує вибір конкретного варіанта.
  • ClassicUO.Game.World.ResolveProfileServerName: _world.ResolveProfileServerName().
  • ClassicUO.Game.Managers.LastCharacterManager.GetKnownCharacters: LastCharacterManager.GetKnownCharacters(account, server).

Внутрішній код реалізації, не самостійний скрипт.

public string[] GetCharactersForCurrentShard() => Invoke(() =>

        {

            if (_world.SessionControl is { } session)

                return session.Characters;

            string account = !string.IsNullOrEmpty(LoginScene.Account)

                ? LoginScene.Account

                : Settings.GlobalSettings.Username;

            string server = _world.ResolveProfileServerName();

            string[] known = LastCharacterManager.GetKnownCharacters(account, server);

            if (known.Length != 0)

                return known;



            LoginScene loginScene = Client.Game?.GetScene<LoginScene>();

            if (loginScene?.Characters != null)

            {

                string[] current = loginScene.Characters

                    .Where(name => !string.IsNullOrWhiteSpace(name))

                    .ToArray();

                if (current.Length != 0)

                    return current;

            }



            string currentName = _world.Player?.Name ?? string.Empty;

            return string.IsNullOrWhiteSpace(currentName)

                ? Array.Empty<string>()

                : new[] { currentName };

        });

ClassicUO.Game.Managers.ClassicUOInjectionApiBridge.GetDir

Повертає значення виразу нижче.

Параметри: id

Джерело: Project_Full/src/ClassicUO.Client/Game/Managers/ClassicUOInjectionApiBridge.cs:2727.

public int GetDir(int id)

Результат: int.

Результат: Invoke(() => (_world.Get(unchecked((uint)id)) as Mobile) is Mobile m ? (int)(m.Direction & Direction.Mask) : 0).

Виклики: Invoke.

Виклики:

Внутрішній код реалізації, не самостійний скрипт.

public int GetDir(int id) => Invoke(() => (_world.Get(unchecked((uint)id)) as Mobile) is Mobile m ? (int)(m.Direction & Direction.Mask) : 0);

ClassicUO.Game.Managers.ClassicUOInjectionApiBridge.GetGumpFullLines

Повертає значення виразу нижче.

Параметри: index

Джерело: Project_Full/src/ClassicUO.Client/Game/Managers/ClassicUOInjectionApiBridge.cs:2829.

public string[] GetGumpFullLines(int index)

Результат: string[].

Виклики: Invoke.

Виклики:

Внутрішній код реалізації, не самостійний скрипт.

public string[] GetGumpFullLines(int index) => Invoke(() =>

        {

            Gump gump = ServerGumpsUnsafe().ElementAtOrDefault(index);

            return gump == null ? Array.Empty<string>() : Descendants(gump).Select(DescribeControl).ToArray();

        });

ClassicUO.Game.Managers.ClassicUOInjectionApiBridge.GetGumpTextLines

Повертає значення виразу нижче.

Параметри: index

Джерело: Project_Full/src/ClassicUO.Client/Game/Managers/ClassicUOInjectionApiBridge.cs:2817.

public string[] GetGumpTextLines(int index)

Результат: string[].

Виклики: Invoke.

Виклики:

Внутрішній код реалізації, не самостійний скрипт.

public string[] GetGumpTextLines(int index) => Invoke(() =>

        {

            Gump gump = ServerGumpsUnsafe().ElementAtOrDefault(index);

            return gump == null ? Array.Empty<string>() : Descendants(gump).Select(GetControlText).Where(text => !string.IsNullOrWhiteSpace(text)).ToArray();

        });

ClassicUO.Game.Managers.ClassicUOInjectionApiBridge.GetLastMenuIdentity

Повертає значення виразу нижче.

Параметри: Немає параметрів.

Джерело: Project_Full/src/ClassicUO.Client/Game/Managers/ClassicUOInjectionApiBridge.cs:676.

public string GetLastMenuIdentity()

Результат: string.

Виклики: Invoke.

Виклики:

  • ClassicUO.Game.Managers.ClassicUOInjectionApiBridge.Invoke: Invoke(() => { SessionMenu menu = _world.ServerMenus.Snapshot().LastOrDefault(); if (menu == null) return string.Empty; string items = string.Join("\u001F", menu.GetYokoItemsEx()); return $"{menu.LocalSerial:X8}:{menu.ServerSerial:X8}:{menu.YokoCaption}:{items}"; }). Кандидати перевантаження: джерело не підтверджує вибір конкретного варіанта.
  • ClassicUO.Game.Managers.ClassicUOInjectionApiBridge.Invoke: Invoke(() => { SessionMenu menu = _world.ServerMenus.Snapshot().LastOrDefault(); if (menu == null) return string.Empty; string items = string.Join("\u001F", menu.GetYokoItemsEx()); return $"{menu.LocalSerial:X8}:{menu.ServerSerial:X8}:{menu.YokoCaption}:{items}"; }). Кандидати перевантаження: джерело не підтверджує вибір конкретного варіанта.

Внутрішній код реалізації, не самостійний скрипт.

public string GetLastMenuIdentity() => Invoke(() =>

        {

            SessionMenu menu = _world.ServerMenus.Snapshot().LastOrDefault();

            if (menu == null)

                return string.Empty;

            string items = string.Join("\u001F", menu.GetYokoItemsEx());

            return $"{menu.LocalSerial:X8}:{menu.ServerSerial:X8}:{menu.YokoCaption}:{items}";

        });

ClassicUO.Game.Managers.ClassicUOInjectionApiBridge.GetMaxMana

Повертає значення виразу нижче.

Параметри: id

Джерело: Project_Full/src/ClassicUO.Client/Game/Managers/ClassicUOInjectionApiBridge.cs:235.

public int GetMaxMana(int id)

Результат: int.

Результат: Invoke(() => (_world.Get(unchecked((uint)id)) as Mobile)?.ManaMax ?? 0).

Виклики: Invoke.

Виклики:

Внутрішній код реалізації, не самостійний скрипт.

public int GetMaxMana(int id) => Invoke(() => (_world.Get(unchecked((uint)id)) as Mobile)?.ManaMax ?? 0);

ClassicUO.Game.Managers.ClassicUOInjectionApiBridge.GetMultiAllParts

Повертає значення виразу нижче.

Параметри: multiId

Джерело: Project_Full/src/ClassicUO.Client/Game/Managers/ClassicUOInjectionApiBridge.cs:2329.

public int[][] GetMultiAllParts(int multiId)

Результат: int[][].

Виклики: Invoke.

Виклики:

  • ClassicUO.Game.Managers.ClassicUOInjectionApiBridge.Invoke: Invoke(() => { if (!_world.HouseManager.TryGetHouse(unchecked((uint)multiId), out House house)) return Array.Empty<int[]>(); return house.Components .Where(component => component != null && !component.IsDestroyed) .Select(component => new[] { (int)component.Graphic, (int)component.Hue, (int)component.X, (int)component.Y, (int)component.Z, component.MultiOffsetX, component.MultiOffsetY, component.MultiOffsetZ, multiId }) .ToArray(); }). Кандидати перевантаження: джерело не підтверджує вибір конкретного варіанта.
  • ClassicUO.Game.Managers.ClassicUOInjectionApiBridge.Invoke: Invoke(() => { if (!_world.HouseManager.TryGetHouse(unchecked((uint)multiId), out House house)) return Array.Empty<int[]>(); return house.Components .Where(component => component != null && !component.IsDestroyed) .Select(component => new[] { (int)component.Graphic, (int)component.Hue, (int)component.X, (int)component.Y, (int)component.Z, component.MultiOffsetX, component.MultiOffsetY, component.MultiOffsetZ, multiId }) .ToArray(); }). Кандидати перевантаження: джерело не підтверджує вибір конкретного варіанта.

Внутрішній код реалізації, не самостійний скрипт.

public int[][] GetMultiAllParts(int multiId) => Invoke(() =>

        {

            if (!_world.HouseManager.TryGetHouse(unchecked((uint)multiId), out House house))

                return Array.Empty<int[]>();



            return house.Components

                .Where(component => component != null && !component.IsDestroyed)

                .Select(component => new[]

                {

                    (int)component.Graphic,

                    (int)component.Hue,

                    (int)component.X,

                    (int)component.Y,

                    (int)component.Z,

                    component.MultiOffsetX,

                    component.MultiOffsetY,

                    component.MultiOffsetZ,

                    multiId

                })

                .ToArray();

        });

ClassicUO.Game.Managers.ClassicUOInjectionApiBridge.GetShopList

Повертає значення виразу нижче.

Параметри: Немає параметрів.

Джерело: Project_Full/src/ClassicUO.Client/Game/Managers/ClassicUOInjectionApiBridge.cs:3567.

public string[] GetShopList()

Результат: string[].

Виклики: Invoke.

Виклики:

  • ClassicUO.Game.Managers.ClassicUOInjectionApiBridge.Invoke: Invoke(() => _world.Shops.Last?.GetItems() ?? UIManager.Gumps.OfType<ShopGump>().LastOrDefault(g => g.World == _world && !g.IsDisposed && g.ShopState == null)?.GetYokoShopItems() ?? Array.Empty<string>()). Кандидати перевантаження: джерело не підтверджує вибір конкретного варіанта.
  • ClassicUO.Game.Managers.ClassicUOInjectionApiBridge.Invoke: Invoke(() => _world.Shops.Last?.GetItems() ?? UIManager.Gumps.OfType<ShopGump>().LastOrDefault(g => g.World == _world && !g.IsDisposed && g.ShopState == null)?.GetYokoShopItems() ?? Array.Empty<string>()). Кандидати перевантаження: джерело не підтверджує вибір конкретного варіанта.

Внутрішній код реалізації, не самостійний скрипт.

public string[] GetShopList() => Invoke(() => _world.Shops.Last?.GetItems()

            ?? UIManager.Gumps.OfType<ShopGump>().LastOrDefault(g => g.World == _world && !g.IsDisposed && g.ShopState == null)?.GetYokoShopItems() ?? Array.Empty<string>());

ClassicUO.Game.Managers.ClassicUOInjectionApiBridge.GetSkillLockState

Повертає значення виразу нижче.

Параметри: name

Джерело: Project_Full/src/ClassicUO.Client/Game/Managers/ClassicUOInjectionApiBridge.cs:2101.

public int GetSkillLockState(string name)

Результат: int.

Результат: Invoke(() => FindSkillUnsafe(name) is Skill skill ? (int)skill.Lock : -1).

Виклики: Invoke.

Виклики:

Внутрішній код реалізації, не самостійний скрипт.

public int GetSkillLockState(string name) => Invoke(() => FindSkillUnsafe(name) is Skill skill ? (int)skill.Lock : -1);

ClassicUO.Game.Managers.ClassicUOInjectionApiBridge.GetStamina

Повертає значення виразу нижче.

Параметри: id

Джерело: Project_Full/src/ClassicUO.Client/Game/Managers/ClassicUOInjectionApiBridge.cs:233.

public int GetStamina(int id)

Результат: int.

Результат: Invoke(() => (_world.Get(unchecked((uint)id)) as Mobile)?.Stamina ?? 0).

Виклики: Invoke.

Виклики:

Внутрішній код реалізації, не самостійний скрипт.

public int GetStamina(int id) => Invoke(() => (_world.Get(unchecked((uint)id)) as Mobile)?.Stamina ?? 0);

ClassicUO.Game.Managers.ClassicUOInjectionApiBridge.Gold

Повертає значення виразу нижче.

Параметри: Немає параметрів.

Джерело: Project_Full/src/ClassicUO.Client/Game/Managers/ClassicUOInjectionApiBridge.cs:157.

public int Gold

Результат: int.

Результат: Invoke(() => (int)(CurrentPlayer?.Gold ?? 0)).

Виклики: Invoke.

Виклики:

Внутрішній код реалізації, не самостійний скрипт.

public int Gold => Invoke(() => (int)(CurrentPlayer?.Gold ?? 0));

ClassicUO.Game.Managers.ClassicUOInjectionApiBridge.IgnoreReset

Виконує показані виклики та оновлення стану.

Параметри: Немає параметрів.

Джерело: Project_Full/src/ClassicUO.Client/Game/Managers/ClassicUOInjectionApiBridge.cs:2706.

public void IgnoreReset()

Результат: void.

Виклики: State.IgnoredSerials.Clear.

Внутрішній код реалізації, не самостійний скрипт.

public void IgnoreReset() => State.IgnoredSerials.Clear();

ClassicUO.Game.Managers.ClassicUOInjectionApiBridge.InJournalFiltered

Перевіряє умови нижче й повертає показаний результат.

Параметри: pattern, serial, color, startTime, endTime, newestOnly, caseSensitive

Джерело: Project_Full/src/ClassicUO.Client/Game/Managers/ClassicUOInjectionApiBridge.cs:1891.

public int InJournalFiltered(string pattern, int serial, int color, int startTime, int endTime, bool newestOnly, bool caseSensitive)

Результат: int.

Результат: FindJournal(pattern, start, end, -1, false, !caseSensitive, serial, color, newestOnly).

Виклики: now.AddMilliseconds, Math.Max, Math.Min, FindJournal.

Умови: startTime > 0 || endTime > 0.

Виклики:

Внутрішній код реалізації, не самостійний скрипт.

public int InJournalFiltered(string pattern, int serial, int color, int startTime, int endTime, bool newestOnly, bool caseSensitive)

        {

            DateTime? start = null;

            DateTime? end = null;

            if (startTime > 0 || endTime > 0)

            {

                DateTime now = DateTime.Now;

                start = now.AddMilliseconds(-Math.Max(startTime, endTime));

                end = now.AddMilliseconds(-Math.Min(startTime, endTime));

            }

            return FindJournal(pattern, start, end, -1, false, !caseSensitive, serial, color, newestOnly);

        }

ClassicUO.Game.Managers.ClassicUOInjectionApiBridge.JournalMessageType

Повертає значення виразу нижче.

Параметри: index

Джерело: Project_Full/src/ClassicUO.Client/Game/Managers/ClassicUOInjectionApiBridge.cs:1970.

public int JournalMessageType(int index)

Результат: int.

Результат: GetJournalEntry(index) is JournalEntry entry ? (int)entry.MessageType : 0.

Виклики: GetJournalEntry.

Виклики:

Внутрішній код реалізації, не самостійний скрипт.

public int JournalMessageType(int index) => GetJournalEntry(index) is JournalEntry entry ? (int)entry.MessageType : 0;

ClassicUO.Game.Managers.ClassicUOInjectionApiBridge.JournalName

Повертає значення виразу нижче.

Параметри: index

Джерело: Project_Full/src/ClassicUO.Client/Game/Managers/ClassicUOInjectionApiBridge.cs:1967.

public string JournalName(int index)

Результат: string.

Результат: GetJournalEntry(index)?.Name ?? string.Empty.

Виклики: GetJournalEntry.

Виклики:

Внутрішній код реалізації, не самостійний скрипт.

public string JournalName(int index) => GetJournalEntry(index)?.Name ?? string.Empty;

ClassicUO.Game.Managers.ClassicUOInjectionApiBridge.MatchesFindIdentity

Повертає значення виразу нижче.

Параметри: gameObject, wantedTypes, wantedColors, ignoredTypes

Джерело: Project_Full/src/ClassicUO.Client/Game/Managers/ClassicUOInjectionApiBridge.cs:3791.

private bool MatchesFindIdentity(Entity gameObject, HashSet<ushort> wantedTypes, HashSet<ushort> wantedColors, IgnoreTypeFilter ignoredTypes)

Результат: bool.

Виклики: State.IgnoredSerials.Contains, ignoredTypes.Matches, wantedTypes.Contains, wantedColors.Contains.

Виклики:

Внутрішній код реалізації, не самостійний скрипт.

private bool MatchesFindIdentity(Entity gameObject, HashSet<ushort> wantedTypes, HashSet<ushort> wantedColors, IgnoreTypeFilter ignoredTypes)

        {

            return gameObject != null

                && !gameObject.IsDestroyed

                && !State.IgnoredSerials.Contains(unchecked((int)gameObject.Serial))

                && !ignoredTypes.Matches(gameObject.Graphic, gameObject.Hue)

                && (wantedTypes.Count == 0 || wantedTypes.Contains(gameObject.Graphic))

                && (wantedColors.Count == 0 || wantedColors.Contains(gameObject.Hue));

        }

ClassicUO.Game.Managers.ClassicUOInjectionApiBridge.RegisterFound

Виконує показані виклики та оновлення стану.

Параметри: item

Джерело: Project_Full/src/ClassicUO.Client/Game/Managers/ClassicUOInjectionApiBridge.cs:3827.

private void RegisterFound(Item item)

Результат: void.

Виклики: Math.Max, RegisterFoundSerial.

Виклики:

Внутрішній код реалізації, не самостійний скрипт.

private void RegisterFound(Item item)

        {

            _findCount++;

            _findFullQuantity += Math.Max(1, (int)item.Amount);

            RegisterFoundSerial(unchecked((int)item.Serial));

        }

ClassicUO.Game.Managers.ClassicUOInjectionApiBridge.RequestInteractiveHideTarget

Повертає значення виразу нижче.

Параметри: Немає параметрів.

Джерело: Project_Full/src/ClassicUO.Client/Game/Managers/ClassicUOInjectionApiBridge.cs:1616.

public int RequestInteractiveHideTarget()

Результат: int.

Виклики: Invoke.

Виклики:

Внутрішній код реалізації, не самостійний скрипт.

public int RequestInteractiveHideTarget()

        {

            return Invoke(() =>

            {

                _world.TargetManager.SetTargeting(selected =>

                {

                    if (selected is not Entity entity || entity.IsDestroyed)

                    {

                        PrintInteractiveResult("UO.Hide: select a loaded item or mobile.");

                        return;

                    }



                    if (entity.Serial == _world.Player?.Serial)

                    {

                        PrintInteractiveResult("UO.Hide: the player cannot be hidden locally.");

                        return;

                    }



                    HideLocally(entity);

                    PrintInteractiveResult($"UO.Hide: hidden 0x{entity.Serial:X8} locally.");

                }, 0, TargetType.Neutral);

                PrintInteractiveResult("UO.Hide: target an item or mobile to hide locally.");

                return 1;

            });

        }

ClassicUO.Game.Managers.ClassicUOInjectionApiBridge.ResolveClassicUOAbilityId

Розбирає або знаходить значення аргументу за правилами, показаними в коді.

Параметри: abilityNameOrId

Джерело: Project_Full/src/ClassicUO.Client/Game/Managers/ClassicUOInjectionApiBridge.cs:2198.

internal static int ResolveClassicUOAbilityId(string abilityNameOrId)

Результат: int.

Результат: numericId >= 1 && numericId <= AbilityData.Abilities.Length ? numericId : 0; 0; index + 1.

Виклики: (abilityNameOrId ?? string.Empty).Trim, int.TryParse, NormalizeAbilityName, ((Ability)(index + 1)).ToString.

Умови: int.TryParse(requested, NumberStyles.Integer, CultureInfo.InvariantCulture, out int numericId); normalized.Length == 0; `NormalizeAbilityName(AbilityData.Abilities[index].Name) == normalized

                || NormalizeAbilityName(((Ability)(index + 1)).ToString()) == normalized`.

Виклики:

Внутрішній код реалізації, не самостійний скрипт.

internal static int ResolveClassicUOAbilityId(string abilityNameOrId)

        {

            string requested = (abilityNameOrId ?? string.Empty).Trim();

            if (int.TryParse(requested, NumberStyles.Integer, CultureInfo.InvariantCulture, out int numericId))

                return numericId >= 1 && numericId <= AbilityData.Abilities.Length ? numericId : 0;



            string normalized = NormalizeAbilityName(requested);

            if (normalized.Length == 0)

                return 0;



            for (int index = 0; index < AbilityData.Abilities.Length; index++)

            {

                if (NormalizeAbilityName(AbilityData.Abilities[index].Name) == normalized

                    || NormalizeAbilityName(((Ability)(index + 1)).ToString()) == normalized)

                    return index + 1;

            }



            return 0;

        }

ClassicUO.Game.Managers.ClassicUOInjectionApiBridge.ShowGumpInspector

Повертає значення виразу нижче.

Параметри: gumpId

Джерело: Project_Full/src/ClassicUO.Client/Game/Managers/ClassicUOInjectionApiBridge.cs:3039.

public int ShowGumpInspector(int gumpId)

Результат: int.

Виклики: Invoke.

Виклики:

  • ClassicUO.Game.Managers.ClassicUOInjectionApiBridge.Invoke: Invoke(() => { Gump gump = ResolveGumpUnsafe(gumpId); if (gump == null) { Error($"UO.InfoGump: gump {gumpId} was not found"); return 0; } _selectedServerGump = gump; List<Gump> gumps = ServerGumpsUnsafe(); int index = gumps.IndexOf(gump); List<Control> controls = Descendants(gump).ToList(); var document = new StringBuilder(); document.AppendLine("_____ C# InfoGump _____"); document.AppendLine($"Index={index}"); document.AppendLine($"Serial=0x{gump.LocalSerial:X8}"); document.AppendLine($"GumpID=0x{gump.ServerSerial:X8}"); document.AppendLine($"X={gump.X} Y={gump.Y} Width={gump.Width} Height={gump.Height}"); document.AppendLine($"ActivePage={gump.ActivePage}"); document.AppendLine($"CanClose={gump.CanCloseWithRightClick}"); document.AppendLine($"Controls={controls.Count}"); document.AppendLine(); document.AppendLine("Buttons:"); foreach (Control button in controls.Where(IsButtonControl)) document.AppendLine(DescribeControl(button)); document.AppendLine(); document.AppendLine("Checks / Radios:"); foreach (Control checkbox in controls.Where(c => c is Checkbox || c is SessionGumpControl { Kind: "checkbox" or "radio" })) document.AppendLine(DescribeControl(checkbox)); document.AppendLine(); document.AppendLine("Text / Entries / HTML:"); foreach (Control control in controls.Where(control => GetControlText(control) != null)) document.AppendLine(DescribeControl(control)); document.AppendLine(); document.AppendLine("All controls:"); for (int controlIndex = 0; controlIndex < controls.Count; controlIndex++) document.AppendLine($"{controlIndex}] {DescribeControl(controls[controlIndex])}"); // InfoGump is an explicit request to open the inspector. Do not gate it // behind the generic interactiveCommands flag used by target-style helpers. _infoGumpOpener(_world, $"C# Gump Inspector [{index}]", document.ToString()); return 1; }). Кандидати перевантаження: джерело не підтверджує вибір конкретного варіанта.
  • ClassicUO.Game.Managers.ClassicUOInjectionApiBridge.Invoke: Invoke(() => { Gump gump = ResolveGumpUnsafe(gumpId); if (gump == null) { Error($"UO.InfoGump: gump {gumpId} was not found"); return 0; } _selectedServerGump = gump; List<Gump> gumps = ServerGumpsUnsafe(); int index = gumps.IndexOf(gump); List<Control> controls = Descendants(gump).ToList(); var document = new StringBuilder(); document.AppendLine("_____ C# InfoGump _____"); document.AppendLine($"Index={index}"); document.AppendLine($"Serial=0x{gump.LocalSerial:X8}"); document.AppendLine($"GumpID=0x{gump.ServerSerial:X8}"); document.AppendLine($"X={gump.X} Y={gump.Y} Width={gump.Width} Height={gump.Height}"); document.AppendLine($"ActivePage={gump.ActivePage}"); document.AppendLine($"CanClose={gump.CanCloseWithRightClick}"); document.AppendLine($"Controls={controls.Count}"); document.AppendLine(); document.AppendLine("Buttons:"); foreach (Control button in controls.Where(IsButtonControl)) document.AppendLine(DescribeControl(button)); document.AppendLine(); document.AppendLine("Checks / Radios:"); foreach (Control checkbox in controls.Where(c => c is Checkbox || c is SessionGumpControl { Kind: "checkbox" or "radio" })) document.AppendLine(DescribeControl(checkbox)); document.AppendLine(); document.AppendLine("Text / Entries / HTML:"); foreach (Control control in controls.Where(control => GetControlText(control) != null)) document.AppendLine(DescribeControl(control)); document.AppendLine(); document.AppendLine("All controls:"); for (int controlIndex = 0; controlIndex < controls.Count; controlIndex++) document.AppendLine($"{controlIndex}] {DescribeControl(controls[controlIndex])}"); // InfoGump is an explicit request to open the inspector. Do not gate it // behind the generic interactiveCommands flag used by target-style helpers. _infoGumpOpener(_world, $"C# Gump Inspector [{index}]", document.ToString()); return 1; }). Кандидати перевантаження: джерело не підтверджує вибір конкретного варіанта.
  • ClassicUO.Game.Managers.ClassicUOInjectionApiBridge.ResolveGumpUnsafe: ResolveGumpUnsafe(gumpId).
  • ClassicUO.Game.Managers.ClassicUOInjectionApiBridge.Error: Error($"UO.InfoGump: gump {gumpId} was not found").
  • ClassicUO.Game.Managers.ClassicUOInjectionApiBridge.ServerGumpsUnsafe: ServerGumpsUnsafe().
  • ClassicUO.Game.Managers.ClassicUOInjectionApiBridge.Descendants: Descendants(gump).
  • ClassicUO.Game.Managers.ClassicUOInjectionApiBridge.DescribeControl: DescribeControl(button).
  • ClassicUO.Game.Managers.ClassicUOInjectionApiBridge.DescribeControl: DescribeControl(checkbox).
  • ClassicUO.Game.Managers.ClassicUOInjectionApiBridge.GetControlText: GetControlText(control).
  • ClassicUO.Game.Managers.ClassicUOInjectionApiBridge.DescribeControl: DescribeControl(control).
  • ClassicUO.Game.Managers.ClassicUOInjectionApiBridge.DescribeControl: DescribeControl(controls[controlIndex]).

Внутрішній код реалізації, не самостійний скрипт.

public int ShowGumpInspector(int gumpId) => Invoke(() =>

        {

            Gump gump = ResolveGumpUnsafe(gumpId);

            if (gump == null)

            {

                Error($"UO.InfoGump: gump {gumpId} was not found");

                return 0;

            }



            _selectedServerGump = gump;

            List<Gump> gumps = ServerGumpsUnsafe();

            int index = gumps.IndexOf(gump);

            List<Control> controls = Descendants(gump).ToList();

            var document = new StringBuilder();

            document.AppendLine("_____ C# InfoGump _____");

            document.AppendLine($"Index={index}");

            document.AppendLine($"Serial=0x{gump.LocalSerial:X8}");

            document.AppendLine($"GumpID=0x{gump.ServerSerial:X8}");

            document.AppendLine($"X={gump.X} Y={gump.Y} Width={gump.Width} Height={gump.Height}");

            document.AppendLine($"ActivePage={gump.ActivePage}");

            document.AppendLine($"CanClose={gump.CanCloseWithRightClick}");

            document.AppendLine($"Controls={controls.Count}");

            document.AppendLine();

            document.AppendLine("Buttons:");

            foreach (Control button in controls.Where(IsButtonControl))

                document.AppendLine(DescribeControl(button));

            document.AppendLine();

            document.AppendLine("Checks / Radios:");

            foreach (Control checkbox in controls.Where(c => c is Checkbox || c is SessionGumpControl { Kind: "checkbox" or "radio" }))

                document.AppendLine(DescribeControl(checkbox));

            document.AppendLine();

            document.AppendLine("Text / Entries / HTML:");

            foreach (Control control in controls.Where(control => GetControlText(control) != null))

                document.AppendLine(DescribeControl(control));

            document.AppendLine();

            document.AppendLine("All controls:");

            for (int controlIndex = 0; controlIndex < controls.Count; controlIndex++)

                document.AppendLine($"{controlIndex}] {DescribeControl(controls[controlIndex])}");



            // InfoGump is an explicit request to open the inspector. Do not gate it

            // behind the generic interactiveCommands flag used by target-style helpers.

            _infoGumpOpener(_world, $"C# Gump Inspector [{index}]", document.ToString());

            return 1;

        });

ClassicUO.Game.Managers.ClassicUOInjectionApiBridge.ShowJournal

Виконує показані виклики та оновлення стану.

Параметри: Немає параметрів.

Джерело: Project_Full/src/ClassicUO.Client/Game/Managers/ClassicUOInjectionApiBridge.cs:1668.

public void ShowJournal()

Результат: void.

Виклики: Invoke.

Виклики:

Внутрішній код реалізації, не самостійний скрипт.

public void ShowJournal() => Invoke(() => GameActions.OpenJournal(_world));

ClassicUO.Game.Managers.ClassicUOInjectionApiBridge.TileName

Перевіряє умови нижче й повертає показаний результат.

Параметри: tile

Джерело: Project_Full/src/ClassicUO.Client/Game/Managers/ClassicUOInjectionApiBridge.cs:3893.

private static string TileName(GameObject tile)

Результат: string.

Результат: land.TileData.Name ?? string.Empty.

Умови: tile is Land land.

Внутрішній код реалізації, не самостійний скрипт.

private static string TileName(GameObject tile)

        {

            if (tile is Land land)

                return land.TileData.Name ?? string.Empty;

            return tile.Graphic < Client.UO.FileManager.TileData.StaticData.Length

                ? Client.UO.FileManager.TileData.StaticData[tile.Graphic].Name ?? string.Empty

                : string.Empty;

        }

ClassicUO.Game.Managers.ClassicUOInjectionApiBridge.ToggleFly

Виконує показані виклики та оновлення стану.

Параметри: Немає параметрів.

Джерело: Project_Full/src/ClassicUO.Client/Game/Managers/ClassicUOInjectionApiBridge.cs:1445.

public void ToggleFly()

Результат: void.

Виклики: Invoke.

Виклики:

Внутрішній код реалізації, не самостійний скрипт.

public void ToggleFly() => Invoke(() => NetClient.Socket.Send_ToggleGargoyleFlying());

ClassicUO.Game.Managers.ClassicUOInjectionApiBridge.TryOpenDoorForStep

Повертає значення виразу нижче.

Параметри: direction

Джерело: Project_Full/src/ClassicUO.Client/Game/Managers/ClassicUOInjectionApiBridge.cs:1413.

public int TryOpenDoorForStep(int direction)

Результат: int.

Виклики: Invoke.

Виклики:

  • ClassicUO.Game.Managers.ClassicUOInjectionApiBridge.Invoke: Invoke(() => { if (_world.Player == null || direction < 0 || direction > 7) return 0; return _world.Player.TryOpenDoor((Direction)direction, true) ? 1 : 0; }). Кандидати перевантаження: джерело не підтверджує вибір конкретного варіанта.
  • ClassicUO.Game.Managers.ClassicUOInjectionApiBridge.Invoke: Invoke(() => { if (_world.Player == null || direction < 0 || direction > 7) return 0; return _world.Player.TryOpenDoor((Direction)direction, true) ? 1 : 0; }). Кандидати перевантаження: джерело не підтверджує вибір конкретного варіанта.

Внутрішній код реалізації, не самостійний скрипт.

public int TryOpenDoorForStep(int direction) => Invoke(() =>

        {

            if (_world.Player == null || direction < 0 || direction > 7)

                return 0;

            return _world.Player.TryOpenDoor((Direction)direction, true) ? 1 : 0;

        });

ClassicUO.Game.Managers.ClassicUOInjectionApiBridge.Weight

Повертає значення виразу нижче.

Параметри: Немає параметрів.

Джерело: Project_Full/src/ClassicUO.Client/Game/Managers/ClassicUOInjectionApiBridge.cs:155.

public int Weight

Результат: int.

Результат: Invoke(() => CurrentPlayer?.Weight ?? 0).

Виклики: Invoke.

Виклики:

Внутрішній код реалізації, не самостійний скрипт.

public int Weight => Invoke(() => CurrentPlayer?.Weight ?? 0);

ClassicUO.Game.Managers.ClientLanguageManager.TranslateUi

Перевіряє умови нижче й повертає показаний результат.

Параметри: text

Джерело: Project_Full/src/ClassicUO.Client/Game/Managers/ClientLanguageManager.cs:123.

internal static string TranslateUi(string text)

Результат: string.

Результат: text ?? string.Empty; text; translated.

Виклики: string.IsNullOrEmpty, translations.TryGetValue, text.Trim, text.IndexOf, text.Substring.

Умови: string.IsNullOrEmpty(text); translations.Count == 0; translations.TryGetValue(text, out string translated); `trimmed.Length == text.Length ||

            !translations.TryGetValue(trimmed, out translated)`.

Внутрішній код реалізації, не самостійний скрипт.

internal static string TranslateUi(string text)

        {

            if (string.IsNullOrEmpty(text))

                return text ?? string.Empty;



            Dictionary<string, string> translations = _uiTranslations;

            if (translations.Count == 0)

                return text;



            if (translations.TryGetValue(text, out string translated))

                return translated;



            string trimmed = text.Trim();

            if (trimmed.Length == text.Length ||

                !translations.TryGetValue(trimmed, out translated))

            {

                return text;

            }



            int start = text.IndexOf(trimmed, StringComparison.Ordinal);

            return text.Substring(0, start) + translated +

                   text.Substring(start + trimmed.Length);

        }

ClassicUO.Game.Managers.JournalManager.SetYokoHistoryLimit

Виконує показані виклики та оновлення стану.

Параметри: length

Джерело: Project_Full/src/ClassicUO.Client/Game/Managers/JournalManager.cs:42.

internal static void SetYokoHistoryLimit(int length)

Результат: void.

Виклики: Math.Clamp, Entries.RemoveFromFront.

Внутрішній код реалізації, не самостійний скрипт.

internal static void SetYokoHistoryLimit(int length)
        {
            _yokoHistoryLimit = Math.Clamp(length, 1, Constants.MAX_JOURNAL_HISTORY_COUNT);
            while (Entries.Count > _yokoHistoryLimit)
                Entries.RemoveFromFront();
        }

ClassicUO.Game.Managers.YokoInjectionManager.BeginScriptControlledDisconnect

Виконує показані виклики та оновлення стану.

Параметри: scriptKey

Джерело: Project_Full/src/ClassicUO.Client/Game/Managers/YokoInjectionManager.cs:777.

internal void BeginScriptControlledDisconnect(string scriptKey)

Результат: void.

Виклики: _running.TryGetValue, script.BeginControlledDisconnect.

Умови: scriptKey != null && _running.TryGetValue(scriptKey, out YokoRunningScript script).

Внутрішній код реалізації, не самостійний скрипт.

internal void BeginScriptControlledDisconnect(string scriptKey)
        {
            if (scriptKey != null && _running.TryGetValue(scriptKey, out YokoRunningScript script))
                script.BeginControlledDisconnect();
        }

ClassicUO.Game.Managers.YokoInjectionManager.FindProcedureByName

Перевіряє умови нижче й повертає показаний результат.

Параметри: name

Джерело: Project_Full/src/ClassicUO.Client/Game/Managers/YokoInjectionManager.cs:3497.

internal YokoProcedureInfo FindProcedureByName(string name)

Результат: YokoProcedureInfo.

Результат: null; qualified.

Виклики: string.IsNullOrWhiteSpace, RequestedAutoloadPath, _proceduresByKey.TryGetValue, _procedures.Where(p => p.Name.Equals(name, StringComparison.OrdinalIgnoreCase)).ToArray, _procedures.Where, Path.GetFullPath, TryGetSelectedAutoloadActionProcedures, freshDeclarations.Where(p => p.Name.Equals(name, StringComparison.OrdinalIgnoreCase)).ToArray.

Умови: string.IsNullOrWhiteSpace(name); _proceduresByKey.TryGetValue(name, out YokoProcedureInfo qualified); !string.IsNullOrWhiteSpace(selectedPath); TryGetSelectedAutoloadActionProcedures(fullPath, out var freshDeclarations).

Виклики:

Внутрішній код реалізації, не самостійний скрипт.

internal YokoProcedureInfo FindProcedureByName(string name)
        {
            if (string.IsNullOrWhiteSpace(name)) return null;
            // Every top-level file is indexed, including backups. Named calls
            // follow the character selection; explicit keys keep IDE snapshots.
            string selectedPath = RequestedAutoloadPath();
            YokoProcedureInfo[] matches;
            HashSet<string> loadedFiles;
            lock (_proceduresLock)
            {
                if (_proceduresByKey.TryGetValue(name, out YokoProcedureInfo qualified))
                    return qualified;
                matches = _procedures.Where(p => p.Name.Equals(name, StringComparison.OrdinalIgnoreCase)).ToArray();
                loadedFiles = new HashSet<string>(_ideLoadedFiles, StringComparer.OrdinalIgnoreCase);
            }
            if (!string.IsNullOrWhiteSpace(selectedPath))
            {
                string fullPath = Path.GetFullPath(selectedPath);
                if (TryGetSelectedAutoloadActionProcedures(fullPath, out var freshDeclarations))
                {
                    // Load/Reload validates a disk snapshot without replacing
                    // unsaved IDE documents. Names must use that fresh view;
                    // deleted names must not resolve to a cached backup.
                    YokoProcedureInfo[] fresh = freshDeclarations.Where(p =>
                        p.Name.Equals(name, StringComparison.OrdinalIgnoreCase)).ToArray();
                    if (fresh.Length != 0) return fresh.Length == 1
                        && !IsSelectedAutoloadExplicitlyUnloaded(fullPath) ? fresh[0] : null;
                    if (matches.Any(p => string.Equals(Path.GetFullPath(p.FilePath),
                            fullPath, StringComparison.OrdinalIgnoreCase)))
                        return null;
                    matches = matches.Where(p => !string.Equals(Path.GetFullPath(p.FilePath),
                            fullPath, StringComparison.OrdinalIgnoreCase)
                        && (!IsTopLevelAutoloadFile(p.FilePath)
                            || loadedFiles.Contains(Path.GetFullPath(p.FilePath)))).ToArray();
                }
                YokoProcedureInfo[] selected = matches.Where(p => string.Equals(
                    Path.GetFullPath(p.FilePath), fullPath, StringComparison.OrdinalIgnoreCase)).ToArray();
                if (selected.Length != 0) return selected.Length == 1
                    && !IsSelectedAutoloadExplicitlyUnloaded(fullPath) ? selected[0] : null;
            }
            // Unique separately loaded helpers remain callable. Ambiguous names
            // need an explicit key; never choose an arbitrary sorted backup.
            return matches.Length == 1 && !IsSelectedAutoloadExplicitlyUnloaded(Path.GetFullPath(matches[0].FilePath))
                ? matches[0] : null;
        }

ClassicUO.Game.Managers.YokoInjectionManager.IsTopLevelAutoloadFile

Повертає значення виразу нижче.

Параметри: filePath

Джерело: Project_Full/src/ClassicUO.Client/Game/Managers/YokoInjectionManager.cs:3552.

private bool IsTopLevelAutoloadFile(string filePath)

Результат: bool.

Виклики: string.Equals, Path.GetDirectoryName, Path.GetFullPath, Path.TrimEndingDirectorySeparator.

Внутрішній код реалізації, не самостійний скрипт.

private bool IsTopLevelAutoloadFile(string filePath) => string.Equals(
            Path.GetDirectoryName(Path.GetFullPath(filePath)),
            Path.TrimEndingDirectorySeparator(Path.GetFullPath(AutoloadPath)),
            StringComparison.OrdinalIgnoreCase);

ClassicUO.Game.Managers.YokoInjectionManager.SetScriptName

Виконує показані виклики та оновлення стану.

Параметри: index, value

Джерело: Project_Full/src/ClassicUO.Client/Game/Managers/YokoInjectionManager.cs:2830.

internal void SetScriptName(int index, string value)

Результат: void.

Виклики: ElementAt, RunningScripts, string.Equals, MarkRuntimeStateChanged.

Умови: script != null && !string.Equals(script.Name, nextName, StringComparison.Ordinal).

Виклики:

Внутрішній код реалізації, не самостійний скрипт.

internal void SetScriptName(int index, string value)
        {
            YokoRunningScript script = ElementAt(RunningScripts(), index);
            string nextName = value ?? string.Empty;
            if (script != null && !string.Equals(script.Name, nextName, StringComparison.Ordinal))
            {
                script.Name = nextName;
                MarkRuntimeStateChanged();
            }
        }

ClassicUO.Game.Managers.YokoInjectionManager.SetSpeechFilter

Виконує показані виклики та оновлення стану.

Параметри: enabled

Джерело: Project_Full/src/ClassicUO.Client/Game/Managers/YokoInjectionManager.cs:726.

internal void SetSpeechFilter(bool enabled)

Результат: void.

Внутрішній код реалізації, не самостійний скрипт.

internal void SetSpeechFilter(bool enabled) => _speechFilterEnabled = enabled;

ClassicUO.Game.Managers.YokoInjectionManager.StartScript

Перевіряє умови нижче й повертає показаний результат.

Параметри: scriptPath

Джерело: Project_Full/src/ClassicUO.Client/Game/Managers/YokoInjectionManager.cs:2878.

internal int StartScript(string scriptPath)

Результат: int.

Результат: 0xFFFF; GetScriptsCount().

Виклики: string.IsNullOrWhiteSpace, Path.IsPathRooted, Path.GetFullPath, Path.Combine, File.Exists, ReadScriptContent, SelectFileEntryPoint, DiscoverProcedures.

Умови: string.IsNullOrWhiteSpace(scriptPath); !File.Exists(fullPath); procedure == null || !RunProcedure(procedure, Array.Empty<string>()).

Виклики:

Внутрішній код реалізації, не самостійний скрипт.

internal int StartScript(string scriptPath)
        {
            if (string.IsNullOrWhiteSpace(scriptPath))
                return 0xFFFF;

            string fullPath;
            string content;
            try
            {
                fullPath = Path.IsPathRooted(scriptPath)
                    ? Path.GetFullPath(scriptPath)
                    : Path.GetFullPath(Path.Combine(AutoloadPath, scriptPath));
                if (!File.Exists(fullPath)) return 0xFFFF;
                content = ReadScriptContent(fullPath);
            }
            catch { return 0xFFFF; }

            YokoProcedureInfo procedure = SelectFileEntryPoint(
                DiscoverProcedures(content, fullPath, Path.GetFileName(fullPath)), fullPath);
            if (procedure == null || !RunProcedure(procedure, Array.Empty<string>()))
                return 0xFFFF;

            return GetScriptsCount();
        }

ClassicUO.Game.Managers.YokoInjectionManager.TryGetSelectedAutoloadActionProcedures

Повертає значення виразу нижче.

Параметри: path, procedures

Джерело: Project_Full/src/ClassicUO.Client/Game/Managers/YokoSelectedAutoloadActions.cs:69.

internal bool TryGetSelectedAutoloadActionProcedures(string path, out IReadOnlyList<YokoProcedureInfo> procedures)

Результат: bool.

Результат: procedures != null.

Виклики: string.Equals.

Внутрішній код реалізації, не самостійний скрипт.

internal bool TryGetSelectedAutoloadActionProcedures(string path, out IReadOnlyList<YokoProcedureInfo> procedures)

    {

        lock (_selectedAutoloadActionLock)

        {

            procedures = string.Equals(path, _selectedAutoloadStatePath, StringComparison.OrdinalIgnoreCase)

                ? _selectedAutoloadDeclarations : null;

            return procedures != null;

        }

    }

ClassicUO.Game.UI.Gumps.YokoScriptEditorGump.Open

Повертає значення виразу нижче.

Параметри: world, filePath

Джерело: Project_Full/src/ClassicUO.Client/Game/UI/Gumps/YokoScriptEditorGump.cs:14.

internal static YokoTheiaIdeGump Open(World world, string filePath = null)

Результат: YokoTheiaIdeGump.

Результат: YokoTheiaIdeGump.Open(world, filePath).

Виклики: YokoTheiaIdeGump.Open.

Внутрішній код реалізації, не самостійний скрипт.

internal static YokoTheiaIdeGump Open(World world, string filePath = null) => YokoTheiaIdeGump.Open(world, filePath);

InjectionScript.Runtime.InjectionApiUO.AlwaysRun

Виконує показані виклики та оновлення стану.

Параметри: enabled

Джерело: Project_Full/external/InjectionScript/src/InjectionScript/Runtime/InjectionApiUO.cs:3773.

public void AlwaysRun(int enabled)

Результат: void.

Виклики: bridge.AlwaysRun.

Виклики:

Внутрішній код реалізації, не самостійний скрипт.

public void AlwaysRun(int enabled) => bridge.AlwaysRun(enabled);

InjectionScript.Runtime.InjectionApiUO.BuildPortablePath

Перевіряє умови нижче й повертає показаний результат.

Параметри: startX, startY, startZ, finishX, finishY, finishZ, map, accuracy, accuracyZ, optimized, run, maxSteps, maxDistance, avoidMobiles, avoidStatics, allowDoors, allowDiagonal

Джерело: Project_Full/external/InjectionScript/src/InjectionScript/Runtime/InjectionApiUO.cs:2300.

`private InjectionValue BuildPortablePath(int startX, int startY, int startZ, int finishX, int finishY, int finishZ,

        int map, int accuracy, int accuracyZ = 255, bool optimized = true, bool run = false,

        int maxSteps = 0, int maxDistance = 0, bool avoidMobiles = false, bool avoidStatics = false,

        bool allowDoors = false, bool allowDiagonal = true)`

Результат: InjectionValue.

Результат: new InjectionValue(Array.Empty<InjectionValue>()).

Виклики: PortablePathSearch.ValidPoint, Array.Empty<InjectionValue>, Math.Max, Math.Min, Math.Abs, `bridge.GetMobiles()

                .Where(id => id != bridge.Self)

                .Select`, `bridge.GetMobiles()

                .Where`, `bridge.GetMobiles`.

Умови: `!PortablePathSearch.ValidPoint(startX, startY, startZ)

            || !PortablePathSearch.ValidPoint(finishX, finishY, finishZ) || map < 0 || map > byte.MaxValue`; `map != bridge.WorldNumber`; `maxDistance > 0 && requestedDistance > maxDistance`; `state.BadLocations.Count != 0 || state.BadObjects.Count != 0`.

Виклики:

Внутрішній код реалізації, не самостійний скрипт.

private InjectionValue BuildPortablePath(int startX, int startY, int startZ, int finishX, int finishY, int finishZ,
            int map, int accuracy, int accuracyZ = 255, bool optimized = true, bool run = false,
            int maxSteps = 0, int maxDistance = 0, bool avoidMobiles = false, bool avoidStatics = false,
            bool allowDoors = false, bool allowDiagonal = true)
        {
            if (!PortablePathSearch.ValidPoint(startX, startY, startZ)
                || !PortablePathSearch.ValidPoint(finishX, finishY, finishZ) || map < 0 || map > byte.MaxValue)
                return new InjectionValue(Array.Empty<InjectionValue>());
            if (map != bridge.WorldNumber) return new InjectionValue(Array.Empty<InjectionValue>());
            int safeAccuracy = Math.Max(0, Math.Min(20, accuracy));
// …
            if (maxDistance > 0 && requestedDistance > maxDistance)
                return new InjectionValue(Array.Empty<InjectionValue>());
// …
            if (state.BadLocations.Count != 0 || state.BadObjects.Count != 0)
// …
                if (bridge is IApiPathQueryScheduler snapshotScheduler)
// …
                if (forbidden?.Invoke(nextX, nextY) == true
                    || occupiedByMobiles != null && occupiedByMobiles.Contains((nextX, nextY))) return null;
                if (forbidden != null && x != nextX && y != nextY)
// …
                    if (blockedSides == 1 && state.MoveThroughCorner == 0
                        || blockedSides == 2 && state.MoveBetweenTwoCorners == 0) return null;
// …
                if (allowDoors && !doorCells.TryGetValue((nextX, nextY, z), out doorAtCell))
// …
                if (avoidStatics)
// …
                    if (!staticCells.TryGetValue((nextX, nextY), out bool hasStatics))
// …
                    if (hasStatics && !doorAtCell) return null;
// …
                if (step.Length == 0 || step[0] == 0)
// …
                    return doorAtCell ? z : (int?)null;
// …
                return step.Length > 1 ? step[1] : z;
// …
                    if (bridge is IApiPathQueryScheduler scheduler) scheduler.ExecutePathQuerySlice(slice);
// …
            return new InjectionValue(points.Select(point => new InjectionValue(new[] {
// …

Повний код зберігається у файлі джерела; нижче наведено точні фрагменти.

InjectionScript.Runtime.InjectionApiUO.CallSub

Виконує показані виклики та оновлення стану.

Параметри: subrutineName

Джерело: Project_Full/external/InjectionScript/src/InjectionScript/Runtime/InjectionApiUO.cs:5916.

public void CallSub(string subrutineName)

Результат: void.

Виклики: bridge.Exec.

Виклики:

Внутрішній код реалізації, не самостійний скрипт.

public void CallSub(string subrutineName) => bridge.Exec(subrutineName);

InjectionScript.Runtime.InjectionApiUO.CompactMoveXYZ

Перевіряє умови нижче й повертає показаний результат.

Параметри: values

Джерело: Project_Full/external/InjectionScript/src/InjectionScript/Runtime/InjectionApiUO.cs:2243.

private int CompactMoveXYZ(InjectionValue[] values)

Результат: int.

Виклики: Math.Max, NumberConversions.ToInt, ToBoolean, MoveToCanonical.

Умови: values == null || values.Length < 6 || values.Length > 10.

Виклики:

Внутрішній код реалізації, не самостійний скрипт.

private int CompactMoveXYZ(InjectionValue[] values)

        {

            if (values == null || values.Length < 6 || values.Length > 10)

                throw new NativeSubrutineException("UO.MoveXYZ expects x,y,z,accuracyXY,accuracyZ,running[,timeout[,maxSteps[,avoidMobiles[,openDoors]]]].");

            int timeout = values.Length > 6 ? Math.Max(0, NumberConversions.ToInt(values[6])) : 0;

            int maxSteps = values.Length > 7 ? Math.Max(0, NumberConversions.ToInt(values[7])) : 0;

            bool? avoidMobiles = values.Length > 8 ? ToBoolean(values[8]) : (bool?)null;

            bool? openDoors = values.Length > 9 ? ToBoolean(values[9]) : (bool?)null;

            return MoveToCanonical(NumberConversions.ToInt(values[0]), NumberConversions.ToInt(values[1]), NumberConversions.ToInt(values[2]),

                NumberConversions.ToInt(values[3]), ToBoolean(values[5]), NumberConversions.ToInt(values[4]), true, null,

                timeout, maxSteps, 0, avoidMobiles, openDoors, false);

        }

InjectionScript.Runtime.InjectionApiUO.ConvertContainer

Перевіряє умови нижче й повертає показаний результат.

Параметри: id

Джерело: Project_Full/external/InjectionScript/src/InjectionScript/Runtime/InjectionApiUO.cs:6373.

private int ConvertContainer(string id)

Результат: int.

Результат: 1; -1; GetObject(id).

Виклики: NumberConversions.TryStr2Int, id.Equals, GetObject.

Умови: NumberConversions.TryStr2Int(id, out int numeric) && numeric == 0; id.Equals("my", StringComparison.OrdinalIgnoreCase); id.Equals("ground", StringComparison.OrdinalIgnoreCase).

Виклики:

Внутрішній код реалізації, не самостійний скрипт.

private int ConvertContainer(string id)

        {

            if (NumberConversions.TryStr2Int(id, out int numeric) && numeric == 0)

                return 1;

            if (id.Equals("my", StringComparison.OrdinalIgnoreCase))

                return -1;

            else if (id.Equals("ground", StringComparison.OrdinalIgnoreCase))

                return 1;



            return GetObject(id);

        }

InjectionScript.Runtime.InjectionApiUO.ConvertGumpValue

Повертає значення виразу нижче.

Параметри: identifier, value

Джерело: Project_Full/external/InjectionScript/src/InjectionScript/Runtime/InjectionApiUO.cs:3242.

private static InjectionValue ConvertGumpValue(string identifier, string value)

Результат: InjectionValue.

Результат: new InjectionValue(NumberConversions.TryStr2Int(value ?? string.Empty, out int number) ? number : 0); new InjectionValue(value ?? string.Empty).

Виклики: (identifier ?? string.Empty).ToLowerInvariant, NumberConversions.TryStr2Int.

Виклики:

Внутрішній код реалізації, не самостійний скрипт.

private static InjectionValue ConvertGumpValue(string identifier, string value)

        {

            switch ((identifier ?? string.Empty).ToLowerInvariant())

            {

                case "buttonlen":

                case "button":

                case "textlen":

                case "injid":

                case "replyed":

                case "inclient":

                case "objectcount":

                    return new InjectionValue(NumberConversions.TryStr2Int(value ?? string.Empty, out int number) ? number : 0);

                default:

                    return new InjectionValue(value ?? string.Empty);

            }

        }

InjectionScript.Runtime.InjectionApiUO.Disarm

Повертає значення виразу нижче.

Параметри: Немає параметрів.

Джерело: Project_Full/external/InjectionScript/src/InjectionScript/Runtime/InjectionApiUO.cs:5596.

public int Disarm()

Результат: int.

Результат: Unequip(weaponLayers, "Weapons disarmed.").

Виклики: Unequip.

Виклики:

Внутрішній код реалізації, не самостійний скрипт.

public int Disarm()

            => Unequip(weaponLayers, "Weapons disarmed.");

InjectionScript.Runtime.InjectionApiUO.Dress

Виконує показані виклики та оновлення стану.

Параметри: name

Джерело: Project_Full/external/InjectionScript/src/InjectionScript/Runtime/InjectionApiUO.cs:5606.

public void Dress(string name)

Результат: void.

Виклики: Equip.

Виклики:

Внутрішній код реалізації, не самостійний скрипт.

public void Dress(string name)

            => Equip(name, dressSets, dressLayers, "Clothing set requests processed.", "No clothing set with setdress.");

InjectionScript.Runtime.InjectionApiUO.ExecuteClientApiCompatibility

Гілка обробляє лише вказане ім’я команди.

Параметри: Немає параметрів.

Джерело: Project_Full/external/InjectionScript/src/InjectionScript/Runtime/InjectionApiUO.cs:1806.

new []

Результат: [].

Виклики:

Внутрішній код реалізації, не самостійний скрипт.

case "booksettext":

                {

                    string bookText = Text(0) ?? string.Empty;

                    state.BookPages.Clear();

                    state.BookPages.AddRange(bookText.Split(new[] { '\f' }, StringSplitOptions.None));

                    bridge.BookSetText(bookText);

                    return InjectionValue.Unit;

                }

InjectionScript.Runtime.InjectionApiUO.ExecuteClientApiCompatibility

Гілка обробляє лише вказане ім’я команди.

Параметри: Немає параметрів.

Джерело: Project_Full/external/InjectionScript/src/InjectionScript/Runtime/InjectionApiUO.cs:1659.

Результат: InjectionValue.Unit.

Виклики:

Внутрішній код реалізації, не самостійний скрипт.

case "bow": bridge.Bow(); return InjectionValue.Unit;

InjectionScript.Runtime.InjectionApiUO.ExecuteClientApiCompatibility

Гілка обробляє лише вказане ім’я команди.

Параметри: Немає параметрів.

Джерело: Project_Full/external/InjectionScript/src/InjectionScript/Runtime/InjectionApiUO.cs:1570.

Результат: new InjectionValue(bridge.GetName(Arg(0, bridge.Self))).

Виклики:

Внутрішній код реалізації, не самостійний скрипт.

case "getname":

                case "charname": return new InjectionValue(bridge.GetName(Arg(0, bridge.Self)));

InjectionScript.Runtime.InjectionApiUO.ExecuteClientApiCompatibility

Гілка обробляє лише вказане ім’я команди.

Параметри: Немає параметрів.

Джерело: Project_Full/external/InjectionScript/src/InjectionScript/Runtime/InjectionApiUO.cs:1913.

Результат: InjectionValue.Unit.

Виклики:

Внутрішній код реалізації, не самостійний скрипт.

case "consoleentryreply":

                case "consoleentryunicodereply": bridge.ReplyServerPrompt(Text(0)); return InjectionValue.Unit;

InjectionScript.Runtime.InjectionApiUO.ExecuteClientApiCompatibility

Гілка обробляє лише вказане ім’я команди.

Параметри: Немає параметрів.

Джерело: Project_Full/external/InjectionScript/src/InjectionScript/Runtime/InjectionApiUO.cs:2016.

Результат: new InjectionValue(DecodeEasyUoId(Text(0))).

Виклики:

Внутрішній код реалізації, не самостійний скрипт.

case "euo2id":

                case "euo2type": return new InjectionValue(DecodeEasyUoId(Text(0)));

InjectionScript.Runtime.InjectionApiUO.ExecuteClientApiCompatibility

Гілка обробляє лише вказане ім’я команди.

Параметри: Немає параметрів.

Джерело: Project_Full/external/InjectionScript/src/InjectionScript/Runtime/InjectionApiUO.cs:1386.

Результат: new InjectionValue(bridge.FindFullQuantity()).

Виклики:

Внутрішній код реалізації, не самостійний скрипт.

case "findfullquantity": return new InjectionValue(bridge.FindFullQuantity());

InjectionScript.Runtime.InjectionApiUO.ExecuteClientApiCompatibility

Гілка обробляє лише вказане ім’я команди.

Параметри: Немає параметрів.

Джерело: Project_Full/external/InjectionScript/src/InjectionScript/Runtime/InjectionApiUO.cs:1308.

Результат: new InjectionValue(bridge.GameServerAddress).

Виклики:

Внутрішній код реалізації, не самостійний скрипт.

case "gameserveripstring": return new InjectionValue(bridge.GameServerAddress);

InjectionScript.Runtime.InjectionApiUO.ExecuteClientApiCompatibility

Гілка обробляє лише вказане ім’я команди.

Параметри: Немає параметрів.

Джерело: Project_Full/external/InjectionScript/src/InjectionScript/Runtime/InjectionApiUO.cs:1395.

Результат: new InjectionValue(Array.Empty<InjectionValue>()); new InjectionValue(items.Select(serial => new InjectionValue(serial)).ToArray()).

Умови: selection.Kind == InjectionValueKind.String; selection.Kind != InjectionValueKind.Integer && selection.Kind != InjectionValueKind.Decimal; container < 0 || container == 0 && !ground && !explicitZero.

Виклики:

Внутрішній код реалізації, не самостійний скрипт.

case "getcontent":

                case "getequipment":

                {

                    InjectionValue selection = arguments[0];

                    bool ground = false, explicitZero;

                    int container;

                    if (selection.Kind == InjectionValueKind.String)

                    {

                        string text = Text(0).Trim();

                        ground = text.Equals("ground", StringComparison.OrdinalIgnoreCase);

                        explicitZero = NumberConversions.TryStr2Int(text, out int literal) && literal == 0;

                        container = ground ? 0 : text.Equals("my", StringComparison.OrdinalIgnoreCase)

                            ? bridge.Backpack : GetObject(text);

                    }

                    else

                    {

                        if (selection.Kind != InjectionValueKind.Integer && selection.Kind != InjectionValueKind.Decimal)

                            return new InjectionValue(Array.Empty<InjectionValue>());

                        container = Arg(0);

                        explicitZero = selection.Kind == InjectionValueKind.Integer ? selection.Integer == 0 : selection.Decimal == 0d;

                    }

                    // Only an explicit ground/zero selector may query world items.

                    if (container < 0 || container == 0 && !ground && !explicitZero)

                        return new InjectionValue(Array.Empty<InjectionValue>());

                    bool equipment = name.Equals("GetEquipment", StringComparison.OrdinalIgnoreCase);

                    int[] items = equipment

                        ? container == 0 ? Array.Empty<int>() : bridge.GetEquipment(container)

                        : bridge.GetContent(container);

                    return new InjectionValue(items.Select(serial => new InjectionValue(serial)).ToArray());

                }

InjectionScript.Runtime.InjectionApiUO.ExecuteClientApiCompatibility

Гілка обробляє лише вказане ім’я команди.

Параметри: Немає параметрів.

Джерело: Project_Full/external/InjectionScript/src/InjectionScript/Runtime/InjectionApiUO.cs:1875.

Результат: new InjectionValue(bridge.GetWorldItems().Where(id => bridge.IsHouse(id) != 0).Select(id => new InjectionValue(id)).ToArray()).

Виклики:

Внутрішній код реалізації, не самостійний скрипт.

case "getmultis":

                    return new InjectionValue(bridge.GetWorldItems().Where(id => bridge.IsHouse(id) != 0).Select(id => new InjectionValue(id)).ToArray());

InjectionScript.Runtime.InjectionApiUO.ExecuteClientApiCompatibility

Гілка обробляє лише вказане ім’я команди.

Параметри: Немає параметрів.

Джерело: Project_Full/external/InjectionScript/src/InjectionScript/Runtime/InjectionApiUO.cs:1862.

Результат: new InjectionValue(bridge.GetStaticArt(ResolveType(arguments[0]), Arg(1)).Select(value => new InjectionValue(value)).ToArray()).

Виклики:

Внутрішній код реалізації, не самостійний скрипт.

case "getstaticart":

                    return new InjectionValue(bridge.GetStaticArt(ResolveType(arguments[0]), Arg(1)).Select(value => new InjectionValue(value)).ToArray());

InjectionScript.Runtime.InjectionApiUO.ExecuteClientApiCompatibility

Гілка обробляє лише вказане ім’я команди.

Параметри: Немає параметрів.

Джерело: Project_Full/external/InjectionScript/src/InjectionScript/Runtime/InjectionApiUO.cs:1563.

Результат: new InjectionValue(bridge.GetY(Arg(0, bridge.Self))).

Виклики:

Внутрішній код реалізації, не самостійний скрипт.

case "gety": return new InjectionValue(bridge.GetY(Arg(0, bridge.Self)));

InjectionScript.Runtime.InjectionApiUO.ExecuteClientApiCompatibility

Гілка обробляє лише вказане ім’я команди.

Параметри: Немає параметрів.

Джерело: Project_Full/external/InjectionScript/src/InjectionScript/Runtime/InjectionApiUO.cs:1911.

Результат: InjectionValue.Unit.

Виклики:

Внутрішній код реалізації, не самостійний скрипт.

case "gumpautotextentry": QueueGumpControl("textentry", Arg(0), Text(1)); return InjectionValue.Unit;

InjectionScript.Runtime.InjectionApiUO.ExecuteClientApiCompatibility

Гілка обробляє лише вказане ім’я команди.

Параметри: Немає параметрів.

Джерело: Project_Full/external/InjectionScript/src/InjectionScript/Runtime/InjectionApiUO.cs:2039.

Результат: new InjectionValue(selectedJournalEntry?.Serial ?? 0).

Внутрішній код реалізації, не самостійний скрипт.

case "lineid": return new InjectionValue(selectedJournalEntry?.Serial ?? 0);

InjectionScript.Runtime.InjectionApiUO.ExecuteClientApiCompatibility

Гілка обробляє лише вказане ім’я команди.

Параметри: Немає параметрів.

Джерело: Project_Full/external/InjectionScript/src/InjectionScript/Runtime/InjectionApiUO.cs:1660.

Результат: InjectionValue.Unit.

Виклики:

Внутрішній код реалізації, не самостійний скрипт.

case "salute": bridge.Salute(); return InjectionValue.Unit;

InjectionScript.Runtime.InjectionApiUO.ExecuteClientApiCompatibility

Гілка обробляє лише вказане ім’я команди.

Параметри: Немає параметрів.

Джерело: Project_Full/external/InjectionScript/src/InjectionScript/Runtime/InjectionApiUO.cs:1353.

Результат: InjectionValue.Unit.

Виклики:

Внутрішній код реалізації, не самостійний скрипт.

case "setwalkunmounttimer":

                    state.WalkUnmountTimer = ClampMoveTimer(Arg(0), 400);

                    bridge.SetMovementTimers(state.RunMountTimer, state.RunUnmountTimer, state.WalkMountTimer, state.WalkUnmountTimer);

                    return InjectionValue.Unit;

InjectionScript.Runtime.InjectionApiUO.ExecuteClientApiCompatibility

Гілка обробляє лише вказане ім’я команди.

Параметри: Немає параметрів.

Джерело: Project_Full/external/InjectionScript/src/InjectionScript/Runtime/InjectionApiUO.cs:1959.

Результат: InjectionValue.Unit.

Умови: found != 0.

Виклики:

Внутрішній код реалізації, не самостійний скрипт.

case "targetbyresource":

                {

                    int found = bridge.FindType(ResolveType(arguments[1]), -1, 0, -1, true);

                    if (found != 0) { bridge.WaitTargetObject(Arg(0)); bridge.UseObject(found); }

                    return InjectionValue.Unit;

                }

InjectionScript.Runtime.InjectionApiUO.ExecuteClientApiCompatibility

Гілка обробляє лише вказане ім’я команди.

Параметри: Немає параметрів.

Джерело: Project_Full/external/InjectionScript/src/InjectionScript/Runtime/InjectionApiUO.cs:1658.

Результат: InjectionValue.Unit.

Виклики:

Внутрішній код реалізації, не самостійний скрипт.

case "uosaycolor": bridge.Say(Text(0), Arg(1)); return InjectionValue.Unit;

InjectionScript.Runtime.InjectionApiUO.ExecuteClientApiCompatibility

Гілка обробляє лише вказане ім’я команди.

Параметри: Немає параметрів.

Джерело: Project_Full/external/InjectionScript/src/InjectionScript/Runtime/InjectionApiUO.cs:1912.

Результат: InjectionValue.Unit.

Виклики:

Внутрішній код реалізації, не самостійний скрипт.

case "waittextentry": bridge.SetGumpValue(-1, "textentry", -1, Text(0)); return InjectionValue.Unit;

InjectionScript.Runtime.InjectionApiUO.ExecuteLegacyManualAlias::LegacyList

Перевіряє умови нижче й повертає показаний результат.

Параметри: key

Джерело: Project_Full/external/InjectionScript/src/InjectionScript/Runtime/InjectionApiUO.cs:2832.

List<string> LegacyList(string key)

Результат: List<string>.

Результат: list.

Виклики: state.LegacyLists.TryGetValue.

Умови: !state.LegacyLists.TryGetValue(key, out List<string> list).

Внутрішній код реалізації, не самостійний скрипт.

List<string> LegacyList(string key)

            {

                if (!state.LegacyLists.TryGetValue(key, out List<string> list))

                {

                    list = new List<string>();

                    state.LegacyLists[key] = list;

                }

                return list;

            }

InjectionScript.Runtime.InjectionApiUO.ExecuteLegacyManualAlias

Гілка обробляє лише вказане ім’я команди.

Параметри: Немає параметрів.

Джерело: Project_Full/external/InjectionScript/src/InjectionScript/Runtime/InjectionApiUO.cs:2844.

Виклики:

Внутрішній код реалізації, не самостійний скрипт.

case "adddir":

                case "addfindlist":

                case "addgate":

                case "addrecall":

                case "addstep":

                    LegacyList(name).Add(string.Join("|", arguments.Select(value => value.ToString())));

                    break;

InjectionScript.Runtime.InjectionApiUO.ExecuteLegacyManualAlias

Гілка обробляє лише вказане ім’я команди.

Параметри: Немає параметрів.

Джерело: Project_Full/external/InjectionScript/src/InjectionScript/Runtime/InjectionApiUO.cs:2844.

Виклики:

Внутрішній код реалізації, не самостійний скрипт.

case "adddir":

                case "addfindlist":

                case "addgate":

                case "addrecall":

                case "addstep":

                    LegacyList(name).Add(string.Join("|", arguments.Select(value => value.ToString())));

                    break;

InjectionScript.Runtime.InjectionApiUO.ExecuteLegacyManualAlias

Гілка обробляє лише вказане ім’я команди.

Параметри: Немає параметрів.

Джерело: Project_Full/external/InjectionScript/src/InjectionScript/Runtime/InjectionApiUO.cs:2873.

Умови: arguments.Length >= 2.

Виклики:

Внутрішній код реалізації, не самостійний скрипт.

case "automenu":

                    if (arguments.Length >= 2) bridge.AddMenuHook(arguments[0].ToString(), arguments[1].ToString(), true);

                    break;

InjectionScript.Runtime.InjectionApiUO.ExecuteLegacyManualAlias

Гілка обробляє лише вказане ім’я команди.

Параметри: Немає параметрів.

Джерело: Project_Full/external/InjectionScript/src/InjectionScript/Runtime/InjectionApiUO.cs:2951.

Виклики:

Внутрішній код реалізації, не самостійний скрипт.

case "emoteaction": bridge.EmoteAction(Text(0)); break;

InjectionScript.Runtime.InjectionApiUO.ExecuteLegacyManualAlias

Гілка обробляє лише вказане ім’я команди.

Параметри: Немає параметрів.

Джерело: Project_Full/external/InjectionScript/src/InjectionScript/Runtime/InjectionApiUO.cs:3056.

Виклики:

Внутрішній код реалізації, не самостійний скрипт.

case "specmove": bridge.Step(Arg(0) & 7, arguments.Length > 1 && Arg(1) != 0); break;

InjectionScript.Runtime.InjectionApiUO.ExecuteLegacyManualAlias

Гілка обробляє лише вказане ім’я команди.

Параметри: Немає параметрів.

Джерело: Project_Full/external/InjectionScript/src/InjectionScript/Runtime/InjectionApiUO.cs:3058.

Виклики:

Внутрішній код реалізації, не самостійний скрипт.

case "waitgumpcheck":

                    for (int index = 0; index + 1 < arguments.Length; index += 2)

                        bridge.SetGumpValue(-1, "checkbox", Arg(index), Text(index + 1));

                    break;

InjectionScript.Runtime.InjectionApiUO.Flying

Повертає значення виразу нижче.

Параметри: Немає параметрів.

Джерело: Project_Full/external/InjectionScript/src/InjectionScript/Runtime/InjectionApiUO.cs:3777.

public int Flying()

Результат: int.

Результат: bridge.Flying(bridge.Self).

Виклики: bridge.Flying.

Виклики:

Внутрішній код реалізації, не самостійний скрипт.

public int Flying() => bridge.Flying(bridge.Self);

InjectionScript.Runtime.InjectionApiUO.GetHP

Повертає значення виразу нижче.

Параметри: Немає параметрів.

Джерело: Project_Full/external/InjectionScript/src/InjectionScript/Runtime/InjectionApiUO.cs:3591.

public int GetHP()

Результат: int.

Результат: GetHP("self").

Виклики: GetHP.

Виклики:

Внутрішній код реалізації, не самостійний скрипт.

public int GetHP() => GetHP("self");

InjectionScript.Runtime.InjectionApiUO.GetMaxHP

Повертає значення виразу нижче.

Параметри: id

Джерело: Project_Full/external/InjectionScript/src/InjectionScript/Runtime/InjectionApiUO.cs:3596.

public int GetMaxHP(string id)

Результат: int.

Результат: GetMaxHP(GetObject(id)).

Виклики: GetMaxHP, GetObject.

Виклики:

Внутрішній код реалізації, не самостійний скрипт.

public int GetMaxHP(string id) => GetMaxHP(GetObject(id));

InjectionScript.Runtime.InjectionApiUO.GetName

Повертає значення виразу нижче.

Параметри: id

Джерело: Project_Full/external/InjectionScript/src/InjectionScript/Runtime/InjectionApiUO.cs:3611.

public string GetName(string id)

Результат: string.

Результат: GetName(GetObject(id)).

Виклики: GetName, GetObject.

Виклики:

Внутрішній код реалізації, не самостійний скрипт.

public string GetName(string id) => GetName(GetObject(id));

InjectionScript.Runtime.InjectionApiUO.GetProfile

Повертає значення виразу нижче.

Параметри: serial

Джерело: Project_Full/external/InjectionScript/src/InjectionScript/Runtime/InjectionApiUO.cs:3395.

public string GetProfile(InjectionValue serial)

Результат: string.

Результат: bridge.GetProfile(GetObject(serial)).

Виклики: bridge.GetProfile, GetObject.

Виклики:

Внутрішній код реалізації, не самостійний скрипт.

public string GetProfile(InjectionValue serial) => bridge.GetProfile(GetObject(serial));

InjectionScript.Runtime.InjectionApiUO.GetRun

Повертає значення виразу нижче.

Параметри: id

Джерело: Project_Full/external/InjectionScript/src/InjectionScript/Runtime/InjectionApiUO.cs:3776.

public int GetRun(InjectionValue id)

Результат: int.

Результат: bridge.GetRun(GetObject(id)).

Виклики: bridge.GetRun, GetObject.

Виклики:

Внутрішній код реалізації, не самостійний скрипт.

public int GetRun(InjectionValue id) => bridge.GetRun(GetObject(id));

InjectionScript.Runtime.InjectionApiUO.InJournalBetweenTimes

Повертає значення виразу нижче.

Параметри: pattern, startTime, endTime

Джерело: Project_Full/external/InjectionScript/src/InjectionScript/Runtime/InjectionApiUO.cs:5380.

public int InJournalBetweenTimes(string pattern, int startTime, int endTime)

Результат: int.

Результат: InJournalBetweenTimesCore(pattern, startTime, endTime, -1, ignoreCase: false).

Виклики: InJournalBetweenTimesCore.

Виклики:

Внутрішній код реалізації, не самостійний скрипт.

public int InJournalBetweenTimes(string pattern, int startTime, int endTime)

            => InJournalBetweenTimesCore(pattern, startTime, endTime, -1, ignoreCase: false);

InjectionScript.Runtime.InjectionApiUO.InJournalBetweenTimesCore

Повертає значення виразу нижче.

Параметри: pattern, startTime, endTime, limit, ignoreCase

Джерело: Project_Full/external/InjectionScript/src/InjectionScript/Runtime/InjectionApiUO.cs:5386.

private int InJournalBetweenTimesCore(string pattern, int startTime, int endTime, int limit, bool ignoreCase)

Результат: int.

Результат: result.

Виклики: CurrentJournalTime, JournalTimestampToAge, bridge.InJournalBetweenTimesEx, SelectJournalSearchResult.

Виклики:

Внутрішній код реалізації, не самостійний скрипт.

private int InJournalBetweenTimesCore(string pattern, int startTime, int endTime, int limit, bool ignoreCase)

        {

            int now = CurrentJournalTime();

            int startAge = JournalTimestampToAge(startTime, now);

            int endAge = endTime <= 0 ? 0 : JournalTimestampToAge(endTime, now);

            int result = bridge.InJournalBetweenTimesEx(pattern, startAge, endAge, limit, ignoreCase);

            SelectJournalSearchResult(result, pattern, ignoreCase);

            return result;

        }

InjectionScript.Runtime.InjectionApiUO.InJournalCore

Повертає значення виразу нижче.

Параметри: pattern, limit, ignoreCase

Джерело: Project_Full/external/InjectionScript/src/InjectionScript/Runtime/InjectionApiUO.cs:5350.

private int InJournalCore(string pattern, int limit, bool ignoreCase)

Результат: int.

Результат: result.

Виклики: bridge.InJournalEx, SelectJournalSearchResult.

Виклики:

Внутрішній код реалізації, не самостійний скрипт.

private int InJournalCore(string pattern, int limit, bool ignoreCase)

        {

            int result = bridge.InJournalEx(pattern, limit, ignoreCase);

            SelectJournalSearchResult(result, pattern, ignoreCase);

            return result;

        }

InjectionScript.Runtime.InjectionApiUO.InfoGump

Виконує показані виклики та оновлення стану.

Параметри: Немає параметрів.

Джерело: Project_Full/external/InjectionScript/src/InjectionScript/Runtime/InjectionApiUO.cs:3196.

public void InfoGump()

Результат: void.

Виклики: bridge.ShowGumpInspector.

Виклики:

Внутрішній код реалізації, не самостійний скрипт.

public void InfoGump()

        {

            // Action command: no active server gump is a normal no-op/error-report case,

            // not a runtime exception. The ClassicUO bridge reports the condition.

            bridge.ShowGumpInspector(-1);

        }

InjectionScript.Runtime.InjectionApiUO.KeyPress

Виконує показані виклики та оновлення стану.

Параметри: key

Джерело: Project_Full/external/InjectionScript/src/InjectionScript/Runtime/InjectionApiUO.cs:5276.

public void KeyPress(int key)

Результат: void.

Виклики: KeyPress.

Виклики:

Внутрішній код реалізації, не самостійний скрипт.

public void KeyPress(int key) => KeyPress(key, 1);

InjectionScript.Runtime.InjectionApiUO.LClick

Виконує показані виклики та оновлення стану.

Параметри: x, y

Джерело: Project_Full/external/InjectionScript/src/InjectionScript/Runtime/InjectionApiUO.cs:5239.

public void LClick(int x, int y)

Результат: void.

Виклики: bridge.LClick.

Виклики:

Внутрішній код реалізації, не самостійний скрипт.

public void LClick(int x, int y) => bridge.LClick(x, y);

InjectionScript.Runtime.InjectionApiUO.LDblClick

Виконує показані виклики та оновлення стану.

Параметри: x, y

Джерело: Project_Full/external/InjectionScript/src/InjectionScript/Runtime/InjectionApiUO.cs:5241.

public void LDblClick(int x, int y)

Результат: void.

Виклики: bridge.LDblClick.

Виклики:

Внутрішній код реалізації, не самостійний скрипт.

public void LDblClick(int x, int y) => bridge.LDblClick(x, y);

InjectionScript.Runtime.InjectionApiUO.LastStatusY

Повертає значення виразу нижче.

Параметри: Немає параметрів.

Джерело: Project_Full/external/InjectionScript/src/InjectionScript/Runtime/InjectionApiUO.cs:3794.

public int LastStatusY()

Результат: int.

Результат: bridge is IStatusSnapshotBridge snapshot ? snapshot.LastStatusY : bridge.GetY(bridge.LastStatus).

Виклики: bridge.GetY.

Виклики:

Внутрішній код реалізації, не самостійний скрипт.

public int LastStatusY() => bridge is IStatusSnapshotBridge snapshot ? snapshot.LastStatusY : bridge.GetY(bridge.LastStatus);

InjectionScript.Runtime.InjectionApiUO.OpenIDE

Виконує показані виклики та оновлення стану.

Параметри: Немає параметрів.

Джерело: Project_Full/external/InjectionScript/src/InjectionScript/Runtime/InjectionApiUO.cs:5316.

public void OpenIDE()

Результат: void.

Виклики: bridge.OpenIDE.

Виклики:

Внутрішній код реалізації, не самостійний скрипт.

public void OpenIDE() => bridge.OpenIDE(string.Empty);

InjectionScript.Runtime.InjectionApiUO.PMove

Виконує показані виклики та оновлення стану.

Параметри: targetX, targetY

Джерело: Project_Full/external/InjectionScript/src/InjectionScript/Runtime/InjectionApiUO.cs:3506.

public void PMove(int targetX, int targetY)

Результат: void.

Виклики: GetX, GetY, timeSource.Now.AddSeconds, GetDirection, GetKey, bridge.MakeStepByKey, bridge.Wait, SystemMessage.

Умови: targetX != currentX || targetY != currentY.

Виклики:

Внутрішній код реалізації, не самостійний скрипт.

public void PMove(int targetX, int targetY)

        {

            var currentX = GetX();

            var currentY = GetY();

            var timeout = timeSource.Now.AddSeconds(30);



            while ((targetX != currentX || targetY != currentY) && timeSource.Now < timeout)

            {

                var direction = GetDirection(currentX, currentY, targetX, targetY);

                var key = GetKey(direction);



                bridge.MakeStepByKey(key);

                bridge.Wait(75);



                currentX = GetX();

                currentY = GetY();

            }



            if (targetX != currentX || targetY != currentY)

                SystemMessage("PMove stopped: destination was not reached in 30 seconds.");

        }

InjectionScript.Runtime.InjectionApiUO.ResolveType

Розбирає або знаходить значення аргументу за правилами, показаними в коді.

Параметри: type

Джерело: Project_Full/external/InjectionScript/src/InjectionScript/Runtime/InjectionApiUO.cs:3936.

private int ResolveType(string type)

Результат: int.

Результат: ResolveType(new InjectionValue(type)).

Виклики: ResolveType.

Виклики:

Внутрішній код реалізації, не самостійний скрипт.

private int ResolveType(string type) => ResolveType(new InjectionValue(type));

InjectionScript.Runtime.InjectionApiUO.SetEvent

Виконує показані виклики та оновлення стану.

Параметри: nameValue, stateValue, repeatValue, subNameValue

Джерело: Project_Full/external/InjectionScript/src/InjectionScript/Runtime/InjectionApiUO.cs:6013.

public void SetEvent(InjectionValue nameValue, InjectionValue stateValue, InjectionValue repeatValue, InjectionValue subNameValue)

Результат: void.

Виклики: NormalizeLegacyEventName, nameValue.ToString, string.IsNullOrEmpty, NumberConversions.ToInt, legacyEvents.Remove, IsSupportedLegacyEventName, SystemMessage, NormalizeLegacyEventHandler.

Умови: string.IsNullOrEmpty(name); !enabled; !IsSupportedLegacyEventName(name).

Виклики:

Внутрішній код реалізації, не самостійний скрипт.

public void SetEvent(InjectionValue nameValue, InjectionValue stateValue, InjectionValue repeatValue, InjectionValue subNameValue)

        {

            string name = NormalizeLegacyEventName(nameValue.ToString());

            if (string.IsNullOrEmpty(name))

                return;



            bool enabled = NumberConversions.ToInt(stateValue) != 0;

            eventStates[name] = enabled ? 1 : 0;

            if (!enabled)

            {

                legacyEvents.Remove(name);

                return;

            }



            if (!IsSupportedLegacyEventName(name))

            {

                eventStates[name] = 0;

                legacyEvents.Remove(name);

                SystemMessage($"SetEvent: unsupported event '{name}'. Supported: SeeNewPlayer, Death, ChangeHitPoints, ChangeMana, ChangeStamina.");

                return;

            }



            var subscription = new LegacyEventSubscription

            {

                Name = name,

                Repeat = NumberConversions.ToInt(repeatValue) != 0,

                Handler = NormalizeLegacyEventHandler(subNameValue.ToString())

            };

            CaptureLegacyEventSnapshot(subscription);

            legacyEvents[name] = subscription;

        }

InjectionScript.Runtime.InjectionApiUO.SystemMessage

Виконує показані виклики та оновлення стану.

Параметри: msg

Джерело: Project_Full/external/InjectionScript/src/InjectionScript/Runtime/InjectionApiUO.cs:5325.

public void SystemMessage(string msg)

Результат: void.

Виклики: bridge.Print.

Виклики:

Внутрішній код реалізації, не самостійний скрипт.

public void SystemMessage(string msg) => bridge.Print(systemMessageColor, msg);

InjectionScript.Runtime.InjectionApiUO.Target

Виконує показані виклики та оновлення стану.

Параметри: targetKey, target

Джерело: Project_Full/external/InjectionScript/src/InjectionScript/Runtime/InjectionApiUO.cs:4256.

public void Target(InjectionValue targetKey, InjectionValue target)

Результат: void.

Виклики: NumberConversions.ToInt, selector.Equals, bridge.LastTile, Array.Empty<int>, bridge.Target, SystemMessage, TryGetObject.

Умови: selector.Equals("lasttile", StringComparison.OrdinalIgnoreCase); tile.Length >= 4; TryGetObject(target, out int serial).

Виклики:

Внутрішній код реалізації, не самостійний скрипт.

public void Target(InjectionValue targetKey, InjectionValue target)

        {

            int key = NumberConversions.ToInt(targetKey);

            string selector = target.Kind == InjectionValueKind.String ? target.String : string.Empty;



            if (selector.Equals("lasttile", StringComparison.OrdinalIgnoreCase))

            {

                int[] tile = bridge.LastTile() ?? Array.Empty<int>();

                if (tile.Length >= 4)

                    bridge.Target(key, 0, 1, tile[0], tile[1], tile[2], tile[3]);

                else

                    SystemMessage("UO.Target: lasttile is unavailable");

                return;

            }



            if (TryGetObject(target, out int serial))

                bridge.Target(key, serial, 0, 0, 0, 0, 0);

            else

                SystemMessage($"UO.Target: invalid target '{selector}'");

        }

InjectionScript.Runtime.InjectionApiUO.WaitTargetObject

Виконує показані виклики та оновлення стану.

Параметри: id1, id2

Джерело: Project_Full/external/InjectionScript/src/InjectionScript/Runtime/InjectionApiUO.cs:4175.

public void WaitTargetObject(string id1, string id2)

Результат: void.

Виклики: WaitTargetObject, GetObject.

Виклики:

Внутрішній код реалізації, не самостійний скрипт.

public void WaitTargetObject(string id1, string id2) => WaitTargetObject(GetObject(id1), GetObject(id2));

InjectionScript.Runtime.InjectionApiUO.WaitTargetType

Виконує показані виклики та оновлення стану.

Параметри: type, color

Джерело: Project_Full/external/InjectionScript/src/InjectionScript/Runtime/InjectionApiUO.cs:4213.

public void WaitTargetType(InjectionValue type, InjectionValue color)

Результат: void.

Виклики: WaitTargetType, ResolveType, NumberConversions.ToInt.

Виклики:

Внутрішній код реалізації, не самостійний скрипт.

public void WaitTargetType(InjectionValue type, InjectionValue color)

            => WaitTargetType(ResolveType(type), NumberConversions.ToInt(color));

InjectionScript.Runtime.InjectionApiUO.RegisterClassMaskApi [ClearClassMask]

Виклик виконує збережений delegate обробника. Метод реєстрації створює цей delegate під час побудови API.

Параметри: Немає параметрів.

Джерело: Project_Full/external/InjectionScript/src/InjectionScript/Runtime/InjectionApiUO.ClassMasks.cs:35.

args

Результат: args.

Результат: new InjectionValue(ClearClassMask(null)).

Виклики: ClearClassMask.

Виклики:

Внутрішній код реалізації, не самостійний скрипт.

args => new InjectionValue(ClearClassMask(null))

InjectionScript.Runtime.InjectionApiUO.Register [FindType]

Виклик виконує збережений delegate обробника. Метод реєстрації створює цей delegate під час побудови API.

Параметри: Немає параметрів.

Джерело: Project_Full/external/InjectionScript/src/InjectionScript/Runtime/InjectionApiUO.cs:396.

values

Результат: values.

Результат: new InjectionValue(FindType(values[0], values[1], values[2], values[3], values[4])).

Виклики: FindType.

Виклики:

Внутрішній код реалізації, не самостійний скрипт.

values =>

                new InjectionValue(FindType(values[0], values[1], values[2], values[3], values[4]))

InjectionScript.Runtime.InjectionApiUO.RegisterCharacterGetterAliases [GetFireResist]

Виклик виконує збережений delegate обробника. Метод реєстрації створює цей delegate під час побудови API.

Параметри: Немає параметрів.

Джерело: Project_Full/external/InjectionScript/src/InjectionScript/Runtime/InjectionApiUO.cs:1043.

Результат: bridge.FireResistance.

Виклики:

Внутрішній код реалізації, не самостійний скрипт.

() => bridge.FireResistance

InjectionScript.Runtime.InjectionApiUO.RegisterCharacterGetterAliases [GetPhysicalResist]

Виклик виконує збережений delegate обробника. Метод реєстрації створює цей delegate під час побудови API.

Параметри: Немає параметрів.

Джерело: Project_Full/external/InjectionScript/src/InjectionScript/Runtime/InjectionApiUO.cs:1042.

Результат: bridge.Armor.

Виклики:

Внутрішній код реалізації, не самостійний скрипт.

() => bridge.Armor

InjectionScript.Runtime.InjectionApiUO.RegisterCharacterGetterAliases [IsAlive]

Виклик виконує збережений delegate обробника. Метод реєстрації створює цей delegate під час побудови API.

Параметри: Немає параметрів.

Джерело: Project_Full/external/InjectionScript/src/InjectionScript/Runtime/InjectionApiUO.cs:1059.

serial

Результат: serial.

Результат: serial > 0 && bridge.Exists(serial) != 0 && IsDeadState(serial) == 0 ? 1 : 0.

Виклики: bridge.Exists, IsDeadState.

Виклики:

Внутрішній код реалізації, не самостійний скрипт.

serial => serial > 0 && bridge.Exists(serial) != 0 && IsDeadState(serial) == 0 ? 1 : 0

InjectionScript.Runtime.InjectionApiUO.Register [MoveItem]

Виклик виконує збережений delegate обробника. Метод реєстрації створює цей delegate під час побудови API.

Параметри: Немає параметрів.

Джерело: Project_Full/external/InjectionScript/src/InjectionScript/Runtime/InjectionApiUO.cs:556.

values

Результат: values.

Результат: new InjectionValue(CompactMoveItem(values)).

Виклики: CompactMoveItem.

Виклики:

Внутрішній код реалізації, не самостійний скрипт.

values => new InjectionValue(CompactMoveItem(values))

InjectionScript.Runtime.InjectionApiUO.Register [MoveXYZ]

Виклик виконує збережений delegate обробника. Метод реєстрації створює цей delegate під час побудови API.

Параметри: Немає параметрів.

Джерело: Project_Full/external/InjectionScript/src/InjectionScript/Runtime/InjectionApiUO.cs:895.

values

Результат: values.

Результат: new InjectionValue(CompactMoveXYZ(values)).

Виклики: CompactMoveXYZ.

Виклики:

Внутрішній код реалізації, не самостійний скрипт.

values => new InjectionValue(CompactMoveXYZ(values))

InjectionScript.Runtime.InjectionApiUO.Register [Snap]

Виклик виконує збережений delegate обробника. Метод реєстрації створює цей delegate під час побудови API.

Параметри: Немає параметрів.

Джерело: Project_Full/external/InjectionScript/src/InjectionScript/Runtime/InjectionApiUO.cs:733.

values

Результат: values.

Результат: new InjectionValue(Snap(values[0].ToString(), NumberConversions.ToInt(values[1]), ToBoolean(values[2]))).

Виклики: Snap, values[0].ToString, NumberConversions.ToInt, ToBoolean.

Виклики:

Внутрішній код реалізації, не самостійний скрипт.

values => new InjectionValue(Snap(values[0].ToString(), NumberConversions.ToInt(values[1]), ToBoolean(values[2])))

InjectionScript.Runtime.InjectionApiUO.RegisterCharacterGetterAliases

Повертає значення виразу нижче.

Параметри: Немає параметрів.

Джерело: Project_Full/external/InjectionScript/src/InjectionScript/Runtime/InjectionApiUO.cs:1013.

value

Результат: value.

Результат: getter(GetObject(value)).

Виклики: getter, GetObject.

Виклики:

Внутрішній код реалізації, не самостійний скрипт.

value => getter(GetObject(value))

InjectionScript.Runtime.InjectionApiUO.RegisterCharacterGetterAliases

Повертає значення виразу нижче.

Параметри: Немає параметрів.

Джерело: Project_Full/external/InjectionScript/src/InjectionScript/Runtime/InjectionApiUO.cs:1007.

Результат: getter(bridge.Self).

Виклики:

Внутрішній код реалізації, не самостійний скрипт.

() => getter(bridge.Self)

InjectionScript.Runtime.Metadata.IntrinsicVariableExists

Повертає значення виразу нижче.

Параметри: name

Джерело: Project_Full/external/InjectionScript/src/InjectionScript/Runtime/Metadata.cs:24.

public bool IntrinsicVariableExists(string name)

Результат: bool.

Результат: intrinsicVariables.ContainsKey(name).

Виклики: intrinsicVariables.ContainsKey.

Внутрішній код реалізації, не самостійний скрипт.

public bool IntrinsicVariableExists(string name) => intrinsicVariables.ContainsKey(name);

InjectionScript.Runtime.PortablePathSearch.ValidPoint

Повертає значення виразу нижче.

Параметри: x, y, z

Джерело: Project_Full/external/InjectionScript/src/InjectionScript/Runtime/PortablePathSearch.cs:22.

internal static bool ValidPoint(int x, int y, int z)

Результат: bool.

Внутрішній код реалізації, не самостійний скрипт.

internal static bool ValidPoint(int x, int y, int z)

            => x >= 0 && x <= ushort.MaxValue && y >= 0 && y <= ushort.MaxValue

                && z >= sbyte.MinValue && z <= sbyte.MaxValue;

Clone this wiki locally