Author Topic: [C#] rails  (Read 4436 times)

0 Members and 1 Guest are viewing this topic.

Offline smittyTopic starter

  • Jr. Member
  • **
  • Posts: 28
  • Activity:
    0%
  • Reputation Power: 1
  • smitty has no influence.
  • Respect: +1
  • Referrals: 0
    • View Profile
[C#] rails
« on: June 24, 2016, 07:11:35 AM »
0
Hello!
So im working on rails now. Ive manually walked the rail and recorded character X, Y, and Z locations in a .txt file. Looks like this:
5924,2024,1
5924,2018,3
5917,2011,1
5917,2000,4
5917,1900,4
5917,1979,2
5914,1893,0//click something at this location
and on and on.
Now i need to figure out how to actually walk the rail and click the things when it gets to that location. What is the recommended way to do this?

Offline Crome969

  • Moderator
  • *
  • *****
  • Posts: 2098
  • Activity:
    0%
  • Reputation Power: 25
  • Crome969 is on the verge of being accepted.Crome969 is on the verge of being accepted.Crome969 is on the verge of being accepted.Crome969 is on the verge of being accepted.Crome969 is on the verge of being accepted.
  • Gender: Male
  • UO Enthusiast
  • Respect: +211
  • Referrals: 10
    • View Profile
    • ScriptSDK
Re: [C#] rails
« Reply #1 on: June 24, 2016, 07:17:28 AM »
0
i would not make a textfile but make an xml. Make an object that stores your waypoint together with a selection in which order and serialize it to file..

https://msdn.microsoft.com/en-us/library/ms973893.aspx

Then you can make something working to save paths to xml and later read xml back to a pathlist

Offline smittyTopic starter

  • Jr. Member
  • **
  • Posts: 28
  • Activity:
    0%
  • Reputation Power: 1
  • smitty has no influence.
  • Respect: +1
  • Referrals: 0
    • View Profile
Re: [C#] rails
« Reply #2 on: June 24, 2016, 07:27:09 AM »
0
Wow... that link was exactly what i needed. that is kinda crazy how quickly you answered the question with so few words hah. I will read this and if i have any more problems ill post here again. thanks!

Offline smittyTopic starter

  • Jr. Member
  • **
  • Posts: 28
  • Activity:
    0%
  • Reputation Power: 1
  • smitty has no influence.
  • Respect: +1
  • Referrals: 0
    • View Profile
Re: [C#] rails
« Reply #3 on: June 25, 2016, 08:57:48 PM »
0
So heres a good question. Does moveXYZ have some type of wait built into it to stop executing the script until character is at designated location?

Offline Tidus

  • Lazy
  • Administrator
  • *
  • *
  • Posts: 1291
  • Activity:
    0%
  • Reputation Power: 15
  • Tidus is working their way up.Tidus is working their way up.Tidus is working their way up.
  • Gender: Male
  • Mind Blown
  • Respect: +151
  • Referrals: 2
    • View Profile
    • Ultimate Apparel
Re: [C#] rails
« Reply #4 on: June 26, 2016, 08:13:06 AM »
0
Yes, it is because you are going to that method in the API to move.  So until the move is done you won't be moving on in your script.  If you want to search while you move you will want to set up a different thread that it runs during it.
For those who have fought for it, freedom has a taste the protected will never know ~ Anonymous, Vietnam, 1968

Offline smittyTopic starter

  • Jr. Member
  • **
  • Posts: 28
  • Activity:
    0%
  • Reputation Power: 1
  • smitty has no influence.
  • Respect: +1
  • Referrals: 0
    • View Profile
Re: [C#] rails
« Reply #5 on: June 26, 2016, 11:58:20 AM »
0
Thank you =]. I now have a functioning rail!!!!! you guys rock.

Tags: