Poloautolot + set bag

Datum: 20/06/2012 22:24:41

Staženo: 263x

Popis:


Hodnocení: 4.3/10 (34 hlasy)

Download file:cs

Příkazy:

  • ,exec autopololot
  • ,exec autopololot_set

Kód:

using System;
using System.Collections.Generic;
using Phoenix;
using Phoenix.WorldData;
using System.Text;
using System.Windows.Forms;
using System.Diagnostics;
using System.Runtime.InteropServices;
using Phoenix.Gui;
namespace Scripts.DarkParadis.autolotes
{
    public class autoloticek
    {
        [Executable]
        public void autopololot()
        {
            ushort[] interestedItem = new ushort[15];
            interestedItem[0] = 0x0E76; // bag
            interestedItem[1] = 0x0F86; // mr
            interestedItem[2] = 0x0f0e; // bottle
            interestedItem[3] = 0x0E21; // bandage
            interestedItem[4] = 0x0eed; // gp
            interestedItem[5] = 0x0F7A; // bp
            interestedItem[6] = 0x0F7B; // bm
            interestedItem[7] = 0x0F84; // ga
            interestedItem[8] = 0x0F85; // gi
            interestedItem[9] = 0x0F88; // ns
            interestedItem[10] = 0x0F8C; // sa
            interestedItem[11] = 0x0F8D; // ss
            interestedItem[12] = 0x0F3F; // šipy
            interestedItem[13] = 0x1BFB; // šipky
            interestedItem[14] = 0x0F87; // eon

            UOItem lootCorpse = World.GetItem(Aliases.GetObject("lastcontainer"));
            lootCorpse.Use();
            for (int i = 0; i < 15; i++)
            {
                if (lootCorpse.Items.Count(interestedItem[i]) > 0)
                {
                    UOItem somce = World.GetItem(Aliases.GetObject("poloautolot_bag"));
                    if (somce.Exist)
                    {
                        UOItem bag_poloautolot = new UOItem(Aliases.GetObject("poloautolot_bag"));

                        UO.MoveItem(lootCorpse.Items.FindType(interestedItem[i]), 10000, bag_poloautolot.Serial);
                    }
                    else
                    {
                        UO.MoveItem(lootCorpse.Items.FindType(interestedItem[i]), 10000, World.Player.Backpack);
                    }
                    UO.Print("Item sebran!");
                    return;
                }
            }
            UO.Print("Zde neni nic k sebrani.");
        }
        

 [Executable]
        public void autopololot_set()

        {//by smoce
            UO.Print(0x00B3, "Musis zvolit pytlik");
            UO.Wait(100);
            UO.Print(0x0435, "Vyber bag");
            UOCharacter aaw = new UOCharacter(UIManager.TargetObject());
            UO.AddObject("poloautolot_bag", aaw);
            UO.Wait(200);
           
            UO.Print(0x00B3, "OKej..");


        }


    }
}


Zde ještě není žádný komentář.

Nový komentář