Пример #1
0
        public MenuManager()
        {
            TickHandler.Attach <MenuManager>(this.Render);

            Client.Instance.OnCharacterLoaded += (sender, args) =>
            {
                this.CharacterMenu.WalkingStyleMenu.Index = this.CharacterMenu.WalkingStyles.FindIndex(s => s.Value == Client.Instance.User?.Character?.WalkingStyle);
            };

            this.Pool.Add(this.CharacterMenu);
            this.Pool.RefreshIndex();
        }
Пример #2
0
        public InventoryScreen()
        {
            Nui.RegisterCallback("inventory-hide", async(a, b) => await this.Hide());

            TickHandler.Attach <InventoryScreen>(this.Render);
        }