What's new
  • Visit Rebornbuddy
  • Visit Panda Profiles
  • Visit LLamamMagic
  • Visit Resources
  • Visit Downloads
  • Visit Portal

[Question/Request] List<string> Gps.GetAllNamedPoints()

Status
Not open for further replies.

Siet

New Member
Joined
Oct 23, 2014
Messages
2
Reaction score
0
Hi,

I'm currently looking for a method to get all named GpsPoints in a Database loaded via the Gps instance.

Is there currently a way/method to get all these named points?
This would be very helpful, so that i don't have hardcode all available points inside the source code and it would greatly increase the re-usability of some of my code.

I could do it if i fiddle around with System.Data.SQLite myself, but why connect to a DB which has already been connected by the running app.
Or can i access the Gps.DB somehow?

Would be realy nice to set point names in the GPSEditor like "warehouse_mail1", "warehouse_mail2", "merchant1", etc. so i could then calculate distances to the nearest warehouse for example.

If there is currently no way to access these points i would suggest the following method to the Gps Class:
List<string> Gps.GetAllNamedPoints() //returns all names of named points
List<string> Gps.GetAllNamedPoints(string search) // returns all names of named points, which contain the argument string (e.g. "merchant" would return "merchant1", "blacksmith_merchant25", etc.)

That would be realy nice. :)

Thank you very much and keep up the good work!
 
Hi, you could access gps.db3 as standart sqlite database.
Or you can wait few days-weeks, and i add this methods (days-weeks, before you can see, that last day new problems appear ^^)
 
Thx for the quick reply, Out!
No need to hurry... ;-) I read about the ban wave and luckily none of my "bot" characters where affected. :p You have more important issues right now...

Was just curious if there is a way to get all the points without accessing the DB myself. I will try to connect to the DB myself for now, even if i am very reluctant to connect to a Db already connected... for performance reasons ;-)

I am currently working on a GpsMove() altenative which moves smarter and more "naturally" and will also have methods like MoveToNearest("merchant") for example, varies waypoints, cuts corners if possible and tries to avoid the turnaround if the movement was suspended and the point behind you is closer. Maybe it is even more convenient for me to skip the Gps Class completly... but i don't want to, because it has nice functions already implemented like GpsGetPath() and so on...

wait... i can probably inherit from the Gps class... let me decompile the ArcheBuddy.dll to have a peek ;) Nah... not possible
 
Status
Not open for further replies.
Back
Top