Beispiel #1
0
        public static void BandujCicmundy()
        {
            while (World.Player.Hits < World.Player.MaxHits)
            {
                if (UO.BandageSelf())
                {
                    Journal.WaitForText(true, 5000, "Chces vytvorit mumii?", "You put the bloody bandagess in your pack.", "You apply the bandages, but they barely help.", "Your target is already fully healed");
                    Journal.Clear();
                }
                else
                {
                    break;
                }
            }

            foreach (UOCharacter character in World.Characters)
            {
                if (character.Distance <= 6 && character.RequestStatus(1000) && character.Renamable && (character.Model == 0x00D6 || character.Model == 0x00C9))
                {
                    UO.PrintInformation("Banduju cicu {0}", character.Name);
                    while (character.Hits < character.MaxHits)
                    {
                        UO.WaitTargetObject(character.Serial);
                        UO.UseType(0x0E21);
                        UO.Wait(1500);
                    }

                    UO.PrintInformation("Cica {0} dobandovana", character.Name);
                }
            }
        }
Beispiel #2
0
        public void HideInBattle(int highlightTime, ushort highlightColor, int counterStep)
        {
            if (World.Player.Layers[Layer.LeftHand].Graphic == 0x0A15)//lantern
            {
                UOItem shield = new UOItem(Serial.Invalid);

                List <UOItem> items = new List <UOItem>();
                items.AddRange(World.Player.Backpack.Items);

                foreach (UOItem item in items)
                {
                    foreach (Graphic g in ItemLibrary.Shields.GraphicArray)
                    {
                        if (item.Graphic == g && (!shield.Exist || shield.Graphic != 0x1B76))
                        {
                            shield = item;
                        }
                    }
                }

                if (shield.Exist)
                {
                    shield.Use();
                }
                else
                {
                    World.Player.Layers[Layer.LeftHand].Move(1, World.Player.Backpack, 100, 30);
                }

                Game.Wait(250);
            }


            Journal.Clear();
            SkillValue    hidingSV  = SkillsHelper.GetSkillValue("Hiding");
            SkillValue    stealthSV = SkillsHelper.GetSkillValue("Stealth");
            StandardSkill usedSkill = StandardSkill.Hiding;

            if (stealthSV.RealValue > hidingSV.RealValue)
            {
                usedSkill = StandardSkill.Stealth;
            }

            AsyncCounter counter = new AsyncCounter();

            counter.PrefixText = "";
            if (highlightTime > 0)
            {
                counter.HighlightTime = highlightTime;
            }

            if (highlightColor > 0)
            {
                counter.HighlightColor = highlightColor;
            }

            Game.RunScript(3000);
            UO.UseSkill(usedSkill);

            if (Journal.WaitForText(true, 200, "You are preoccupied with thoughts of battle"))
            {
                Game.CurrentGame.CurrentPlayer.SwitchWarmode();
                World.Player.PrintMessage("[ Preoccupied ]", MessageType.Warning);
                Game.Wait(250);

                if (World.Player.Hits < World.Player.Strenght)
                {
                    UO.BandageSelf();
                }
                else
                {
                    UO.UseSkill(StandardSkill.Meditation);
                }

                //else if (World.Player.Mana > 4)
                //  UO.Cast(StandardSpell.MagicArrow, World.Player.Serial);
            }
            else
            {
                counter.Step        = counterStep;
                counter.StopMessage = "You can't seem to hide here,You have hidden yourself well";
                counter.StopMethod  = IsHidden;
                counter.Run();
            }


            //You are preoccupied with thoughts of battle

            //Game.RunScript(3500);



            //Hiding.HideRunning = true;

            //if (needAction)
            //{
            //  World.Player.PrintMessage("[ HID Action ]", MessageType.Warning);

            //  if (World.Player.Hits < World.Player.Strenght)
            //    UO.BandageSelf();
            //  else if (World.Player.Mana > 4)
            //    UO.Cast(StandardSpell.MagicArrow, World.Player.Serial);
            //}

            //Game.Wait(250);
            //UO.UseSkill(usedSkill);
            //Game.Wait(50);
        }
Beispiel #3
0
        public void HideRay(int highlightTime, ushort highlightColor, int counterStep)
        {
            Journal.Clear();


            StandardSkill usedSkill = StandardSkill.Hiding;

            SkillValue hidingSV  = SkillsHelper.GetSkillValue("Hiding");
            SkillValue stealthSV = SkillsHelper.GetSkillValue("Stealth");

            if (stealthSV.RealValue > hidingSV.RealValue)
            {
                usedSkill = StandardSkill.Stealth;
            }

            if (World.Player.Layers[Layer.LeftHand].Graphic == 0x0A15)//lantern
            {
                UOItem shield = new UOItem(Serial.Invalid);

                List <UOItem> items = new List <UOItem>();
                items.AddRange(World.Player.Backpack.Items);

                foreach (UOItem item in items)
                {
                    foreach (Graphic g in ItemLibrary.Shields.GraphicArray)
                    {
                        if (item.Graphic == g && (!shield.Exist || shield.Graphic != 0x1B76))
                        {
                            shield = item;
                        }
                    }
                }

                if (shield.Exist)
                {
                    shield.Use();
                }
                else
                {
                    World.Player.Layers[Layer.LeftHand].Move(1, World.Player.Backpack, 100, 30);
                }

                Game.Wait(250);
            }


            Game.RunScript(3000);

            AsyncCounter counter = new AsyncCounter();

            counter.PrefixText = "";
            if (highlightTime > 0)
            {
                counter.HighlightTime = highlightTime;
            }

            if (highlightColor > 0)
            {
                counter.HighlightColor = highlightColor;
            }

            Hiding.HideRunning = true;

            UO.BandageSelf();
            Game.Wait(100);
            UO.UseSkill(usedSkill);
            Game.Wait(50);
            counter.Step        = counterStep;
            counter.StopMessage = "You can't seem to hide here,You have hidden yourself well";
            counter.StopMethod  = IsHidden;
            counter.Run();
        }