Exemplo n.º 1
0
        public static void OnSetDefaultsBegin(Terraria.Item item, int type)
        {
            var ctx = HookContext.Empty;
            var args = new HookArgs.ItemSetDefaultsByType()
            {
                State = MethodState.Begin,
                Type = type,

                Item = item
            };

            HookPoints.ItemSetDefaultsByType.Invoke(ref ctx, ref args);
        }
Exemplo n.º 2
0
        public static void OnSetDefaultsEnd(Terraria.Item item, int type = 0, bool noMatCheck = false)
        {
            var ctx = HookContext.Empty;
            var args = new HookArgs.ItemSetDefaultsByType()
            {
                State = MethodState.End,
                Type = type,
                NoMatCheck = noMatCheck,

                Item = item
            };

            HookPoints.ItemSetDefaultsByType.Invoke(ref ctx, ref args);
        }