ScriptUO

Scripting Resources & Utilities => Stealth Client => Topic started by: epsilon2 on August 16, 2016, 07:08:24 AM

Title: [c# scriptsdk 0.9.3] Do Know how to use types?
Post by: epsilon2 on August 16, 2016, 07:08:24 AM
I used this example
https://sourceforge.net/p/scriptsdk/wiki/ItemSearch/ (https://sourceforge.net/p/scriptsdk/wiki/ItemSearch/)

so i generated this class

using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using ScriptSDK;
using ScriptSDK.Data;
using ScriptSDK.Attributes;
using ScriptSDK.Configuration;
using ScriptSDK.Gumps;
using ScriptSDK.Targets;
using ScriptSDK.Utils;
using ScriptSDK.ContextMenus;
using ScriptSDK.Engines;
using ScriptSDK.Items;
using ScriptSDK.Mobiles;
using StealthAPI;
using ScriptDotNet2;

namespace ConsoleApplication1
{
    [QueryGraphic(0x0190, 0x0191)] //Possible Graphic Types for a Neclace
    public class class NPC : Mobile
    {
        public NPC(Serial serial)
            : base(serial)
        {
        }
    }
}


but QueryGraphic is not valid.

I used it for this  functions:


List<Type> types = new List<Type>();
types.Add(typeof(Cow));
types.Add(typeof(Dog));
//We designed a Class Cow and a Class Dog which inherited from Mobile and had search params
List<Mobile> mobilesearch = Mobile.Find(types,0x0,true);

thx for advancing me
Title: Re: [c# scriptsdk 0.9.3] Do Know how to use types?
Post by: Crome969 on August 16, 2016, 08:04:09 AM
i think you may use an outdated version.
Latest source you can obtain here : https://github.com/Crome696/ScriptSDK
Title: Re: [c# scriptsdk 0.9.3] Do Know how to use types?
Post by: epsilon2 on August 16, 2016, 09:27:40 AM
Were is the Proffesion of an NPC hidden found in an

List<Mobile> list ?

regards
Title: Re: [c# scriptsdk 0.9.3] Do Know how to use types?
Post by: epsilon2 on August 16, 2016, 11:00:32 AM
Title: Re: [c# scriptsdk 0.9.3] Do Know how to use types?
Post by: Tidus on August 16, 2016, 12:45:55 PM
Title: Re: [c# scriptsdk 0.9.3] Do Know how to use types?
Post by: Crome969 on August 16, 2016, 10:46:18 PM