Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.


Messages - Bulldog

Pages: [1]
1
Orion UO Client / Help! Casting string array elements to integers
« on: June 06, 2022, 02:17:35 AM »
Hello everyone I hope someone can help with this ..

I have a function that is returning durability on items as elements of an array these come out as arrayelement
  • /arrayelement[y] which is the durability say 234 / 255. I want to cast the strings into an integer but I am not sure what the Orion version of Integer.parseInt ?


eg:

 int numberx = Integer.parseInt(arrayelement
  • );

 int numbery = Integer.parseInt(arrayelement[y]);

2
Orion UO Scripts / Re: Building a Lumberjacking Script
« on: May 20, 2022, 12:37:51 PM »
Nice work again bud. I think in terms of suggestions you could easily adapt the same core principals to mining for example.

3
Orion UO Scripts / Post into Discord
« on: May 20, 2022, 07:18:05 AM »
Quick function that will post some text into a Discord bot server
function testDiscord()
{
    // Discord
    var bot = "https://discord.com/api/webhooks/"; // Your Webhook url goes here
    var charName = Player.Name();
    var paramText = "username="+charName+"&content=@everyone "+charName+" just made dinner";
    Orion.Wait(100);
    Orion.HttpPost(bot, paramText);
    Orion.Wait(1000);
   
}

4
New member introductions / Re: New guy!
« on: May 19, 2022, 03:37:49 PM »
Well where do I start. I am a happily married man of almost 50. Far too old to be playing video games. I am a very keen chess player. I originally started playing UO in 1999. At the time I worked for IBM at the Daresbury lab looking at safety systems primarily for the nuclear industry and completed my first PHD thesis using Q, Lisp and Assembly language. In the early days of UO I played a character called Ping and used the 'super fast' JANET to pown nubs with a gm kryss and posioning. I played in the early hero v evil system and started to discover literally 100s of exploits that could be achieved due to the architecture of the game system and its flat file regional saves.  I found UO almost unplayable at home on a 48k Modem connect to AOL and Freeserve so i payed BT 15k to install a dual ISDN line. The character Shade was born (well actually two of them one who would suffer stat loss if killed and one 'just' red chase me version) I used to really enjoy picking people off on the edge of champ spawns and wrote my first automation for uo which was for a thief that would stand by the alter :) I really got addicted to UO and team play on Europa when they introduced the faction system. Hatchet Harry's castle being literally full of Minax's finest. In 2004 I started my own company and simply didn't have the time to play anything. Fast forward to 2019 and my initial return. I tried some free shards including the excellent Outlands using Classic UO and then went back onto the official OSI servers on EC after they found 4 of my old accounts. At first there was loads (15 years worth) of new content but that quickly got boring. I dabbled in a few scripts on UOS, LUA and EasyUO to train chars and do simple tasks. I tried to pvp but alas my reflexes have gone! So again I stopped playing. Then I got a message about fixing some Java Script in the Orion client. That was a couple of weeks ago and I am so impressed with the client I am compiling a full function library and writing a guide to help people.

5
Orion UO Scripts / Re: Brute Force Egg Hunter
« on: May 18, 2022, 12:46:06 AM »
Ah did not know that! I am trying to get some archer movement going at the moment

6
New member introductions / New guy!
« on: May 18, 2022, 12:43:31 AM »
Hi Folks I am back playing UO first started in 1999 and I am loving the Orion Client and learning Java script

7
Orion UO Scripts / Re: Brute Force Egg Hunter
« on: May 17, 2022, 11:49:44 PM »
There is an inbuilt function Orion.CanWalk you can use that to see if character can reach the x,y,z before you even start the move

8
Orion UO Client / Re: Multiskill Trainer for Orion
« on: May 08, 2022, 10:13:26 AM »
I am happy to test out what you come up with I wrote a basic script to train a char but it would be nice with gump control

9
Orion UO Scripts / Re: Use Bag of Sending
« on: May 08, 2022, 10:00:17 AM »
Great little function thank you

10
Orion UO Scripts / Accept the res gump and redress the character
« on: May 08, 2022, 09:59:26 AM »
Hi folks I have just come back to Ultima after my second break from the game. I came across this client and it looks like a really solid piece of work. I am just learning the java script functions. I thought I would share this little script I wrote today. It can be run along side any other script. If you use the dress agent to record what your wearing then replace the 'Dress_Legion' with your own list then they script will accept the rez gump and redress you and thank the person. Hope you find it useful.

// Accept res gump and re-equip
function acceptRez()
{
      // Force an infinite loop so this can be run with any other script
      var LoopCount ='0'       
         while (LoopCount='0') {
            // What to do when dead
            while (Player.Dead()){
                //War mode on
                Orion.WarMode(1);
               
               // Wait for the ressurection gump to appear
               if (Orion.WaitForGump(1000)){
         
               var gump0 = Orion.GetGump('last');
               // Select 'ok'
               if ((gump0 !== null) && (!gump0.Replayed()) && (gump0.ID() === '0x000008AF')){
                  gump0.Select(Orion.CreateGumpHook(2));
                  // Wait to dress
                  Orion.Wait(3000);
                  // This is the dress agent for the char record and name this in Agents
               AgentDress();
               
                  
      } //End of gump and accept
   }} // End of While Dead
} //End of infinite loop
} // End of acceptRez
///GetDressed
function AgentDress() {
   var colour = 55;
   Orion.Print(colour, 'Dressing');
   Orion.Say('Thanks for the rez');
   // This is the dress agent for the char record and name this in Agents
   Orion.Dress('Dress_Legion');
   Orion.Wait(3000);
   
}

Pages: [1]