Kane Hart Posted February 10, 2017 Share Posted February 10, 2017 It would be really nice if we could via the galaxy map have a thing we can open up or even outside of it where we can search or filter out and have it sort nearby locations for easy look up. For example if I want to find a Research Station. Link to comment Share on other sites More sharing options...
Zoltan Posted February 10, 2017 Share Posted February 10, 2017 I have been looking into this but as far as I can tell there is no way to know what's in a specific sector. Therefore we can just do a linear search through the systems. My other thought is add to a list of all stations as players enter a region. However that would only work if you had the mod from the beginning. I am also unclear how to save that data to persist between sessions. Link to comment Share on other sites More sharing options...
Juni Posted February 10, 2017 Share Posted February 10, 2017 I have been looking into this but as far as I can tell there is no way to know what's in a specific sector. Therefore we can just do a linear search through the systems. My other thought is add to a list of all stations as players enter a region. However that would only work if you had the mod from the beginning. I am also unclear how to save that data to persist between sessions. u can view ur discovered systems with stations in it all the time in ur galaxy map... so its maybe possible Link to comment Share on other sites More sharing options...
Zoltan Posted February 10, 2017 Share Posted February 10, 2017 u can view ur discovered systems with stations in it all the time in ur galaxy map... so its maybe possible I agree it should be possible but I haven't found the necessary hooks in the documentation. They are incomplete so our only recourse is to look through the game scripts. A much slower approach. Creators are aware that it is lacking: See this thread. So if we are lucky we will see it in a near future update. Link to comment Share on other sites More sharing options...
JayNic Posted February 10, 2017 Share Posted February 10, 2017 ... I am also unclear how to save that data to persist between sessions. This is where I got stuck... I'm trying to make a mod that records what goods are for sale/purchase in each sector the player enters. But... I couldn't see if I could save data to the players inner db, or whatever. I did try lua's command: function makeFiles() os.execute( "mkdir season\\week1" ) newFile = io.open( "season\\week1\\game.txt", "w+" ) newFile:write( funcThatReturnsAString() ) newFile:close() end and it creates a folder in the base game data folder (or somewhere close - can't recall) but it opens a little console window and minimizes the game. That's as far as I got. Link to comment Share on other sites More sharing options...
Zoltan Posted February 10, 2017 Share Posted February 10, 2017 I have not looked into it but the Out of sector production might save data. At least I hope it does. Link to comment Share on other sites More sharing options...
Laserzwei Posted February 10, 2017 Share Posted February 10, 2017 I have not looked into it but the Out of sector production might save data. At least I hope it does. It does save in a File the same way as JayNic suggested. With more error handling though. However here is how it should be done in Avorion. It's bugged atm you can read it here http://www.avorion.net/forum/index.php/topic,1498.0.html Link to comment Share on other sites More sharing options...
valor Posted February 28, 2017 Share Posted February 28, 2017 Using git-bash or cygwin under windows, or under any *nix system you can use this workaround until it's possible to mod this: 1. Switch to the directory for your galaxy: cd ~/AppData/Roaming/Avorion/galaxies/defaultgalaxy/sectors 2. Search for "Robot" in station/goods name: find . -name "*v" | xargs grep "Robot" 3. Output: ./222_-79v: <arg key="plural">Mining Robots</arg> ./222_-79v: <arg key="good">Mining Robot</arg> ./222_-79v: <arg key="prefix">Mining Robot /* prefix */</arg> ./356_-36v: <arg key="good">War Robot</arg> ./356_-36v: <arg key="plural">War Robots</arg> ./356_-36v: <arg key="prefix">War Robot /* prefix */</arg> ./428_-44v: <arg key="prefix">Mining Robot /* prefix */</arg> ./428_-44v: <arg key="plural">Mining Robots</arg> ./428_-44v: <arg key="good">Mining Robot</arg> It is a bit verbose and you have to consider the context of the results (might be a station name or just a type of goods that is sold). Coords are inside the file name to the left. Have fun :) Download links: * Git for windows (including git-bash) https://git-for-windows.github.io/ * Cygwin https://cygwin.com/install.html Link to comment Share on other sites More sharing options...
w00zla Posted February 28, 2017 Share Posted February 28, 2017 ... I am also unclear how to save that data to persist between sessions. This is where I got stuck... I'm trying to make a mod that records what goods are for sale/purchase in each sector the player enters. But... I couldn't see if I could save data to the players inner db, or whatever. ... You could try the secure() and restore() functions of entity scripts (like described here in the wiki), they seem to be the built-in hooks for easy persistence... Link to comment Share on other sites More sharing options...
w00zla Posted March 2, 2017 Share Posted March 2, 2017 EDIT: created own thread for "findstation" mod: http://www.avorion.net/forum/index.php/topic,2665.0.html Link to comment Share on other sites More sharing options...
Devious Posted March 3, 2017 Share Posted March 3, 2017 That looks very promising! Too bad it's such a big toll on performance in this state, even when the galaxy map becomes more of use an in-game command specifically for finding stations can never hurt in a game that's already a lot less tedious due to the hard work of the modding developers :) I am more than willing to try it out on our server once it becomes usable so I'll be looking forward to that! Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now