For anyone looking for an FS 19 version in the meantime, you may try https://github.com/sperrgebiet/FS19_VehicleExplorer which was done by another modder. He states it does not work in multiplayer, though. I may try to do an FS 19 version if I have time to figure out multiplayer in FS 19.
Please rename zip file to FS17_VehicleSort_debug.zip, then start game, enable mod for game, open and close menu, exit game, and paste log.txt to https://pastebin.com and reply with link to paste for troubleshooting. Thanks.
Thanks for the update for one of my favorite FS tools! Everything's working well now.
One question, though:
How can I change the position of the window? In the latest version it's a little too far down on the screen for my likings, so I'd like to move up towards the upper edge of the screen. However, I can't seem to find any values for xpos, ypos...just a lot of fancy entries which nooby me doesn't understand at all. ^^
It's because you have seasons. It detects seasons which has the weather bar which can block out the vehicle list if your list was big enough for many columns.
Look in the LUA file for "if g_seasons" it will show how it changes the position. You can remove that or comment it out with "--" at the beginning of those lines.
In a future update, I might look at making that change only if the list is multiple columns, I'll have to see if it would work properly (as if someone has wide entries on some resolutions they may overlap the weather bar even with 1 column)...
For those who would like to help with testing, please get latest DEV VehicleSort.lua and modDesc.xml from:
https://raw.githubusercontent.com/Slivicon/VehicleSort/dev/vehicleSort.lua https://raw.githubusercontent.com/Slivicon/VehicleSort/dev/modDesc.xml
Replace the ones in your v2 zip file with those.
Rename the zip file to FS17_VehicleSort_debug.zip
When you start the game, you will get a message that VehicleSort is no longer present (this is because zip is renamed). Make sure new VehicleSort (renamed debug) is checked as mod enabled for your game.
This special name will tell the mod to write a LOT more information to the log which you can paste (no account needed, you can paste to pastebin.com with no account) at http://pastebin.com (please do not post log in comment, only link to pastebin.com).
You will also see your screenshots will show extra information in debug mode that you can post here or at imgur.com with link to imgur.com in comments.
ok, the missing value in moddesc.xml is ok, it's just because you don't have the up to date moddesc.xml. The background not working is because my guess at how to compensate for different resolution aspect ratios was wrong :( You can try this latest dev version LUA https://github.com/Slivicon/VehicleSort/blob/dev/vehicleSort.lua but the background will likely still be wrong until I figure out the correct way to test aspect ratios when I don't have a display that can do those aspect ratios. Or I go back to the v2.0 way that was the correct height but not the correct width.
in v 2.0.0.0 is a new dark background.
but he is in the right side a little bit to short
how can i edit the lua file to make the background bigger?
is also a colour chance to a litte more brighter?
lg
andreas
It is not supposed to go all the way to the edge of the screen, but it is supposed to be wide enough for any text. If the text is going wider than the dark background, I did not see that in my testing, so I would appreciate a screenshot (you can paste to imgur.com and post link here, no account needed to upload to imgur.com) so I can see.
For making it wider, probably an easy way would be to look for the line in the LUA that says "local padSides = (2 * VehicleSort.tPos.spacing);" and change the '2' to '3' or '4'. Each increase will make it wider to the right of the screen.
I don't think there is a way to make the colour "brighter", there is no brightness control, but you can change the colour to a different colour. How you do that is look at the top of the LUA file for the lines that start with "VehicleSort.tColor." and you will see they are values of 4 decimal numbers. Each number is from 0.0 to 1.0, first number is how much RED, second is how much BLUE, third is how much GREEN, the fourth is how much alpha transparency (1.0 is no transparency, 0 is full transparency). The combination of the RED, GREEN, BLUE amounts makes the colour (RGB).
i have attachet 3 pics here.
the first is when i stand near the tractor, the second i enter the tractor
the third when i attachet the tippers
also the vehiclesort is on.
when i open vehiclesort after i enter the tractor and after i a attachet the trailers al is ok
Sorry, I got the order wrong. First is RED, second is GREEN, third is BLUE, 4th is alpha. So, for opaque colour green, the numbers are {0.0, 1.0, 0.0, 1.0}.
Another way to make it even easier to read is to make the dark background solid black (no transparency). That can be done by changing the LUA line "setOverlayColor(VehicleSort.bg, 0, 0, 0, 0.8);" - set '0.8' to be '1.0'. The side effect is now you cannot see anything through the background while the list is displayed.
In dev version I added an option to make it solid black, but I think you wanted even more transparent, so I will see if there's a way to make it an option.
Thank you for posting the screenshots. I think maybe you have an ultrawide monitor? My guess is the background width does not behave as expected with an ultrawide resolution, so I'm not sure why that is...it may have to do with aspect ratio but I am not sure how to test that...I will open an issue on my GitHub and try to investigate a way to fix... https://github.com/Slivicon/VehicleSort
to see if it fixes your issue? The text will hopefully not go over the edge of the background. Also, there is a new config option on the config screen (numpad -) to make the background solid black.
I downloaded the latest version (2.0.0.0) and put it in the Mods folder, but it doesn't appear in the mod list when loading the savegame. I have tried the .zip file, and also tried to unzip it.
Is the lates FS17 patch required, or is it something else?
I´ve loaded the new version but in the list it shows still the same. I guess the same like you that they used a different method to identify the train otherwise i think vehicle sort would see the train. But the most important for me is that the log is not full of callstacks anymore so thank you again
kind regards
Yes, until I get platinum and determine how the train is identified, it would be difficult to guess. I have some ideas, but it is difficult to test without the platinum DLC. Until I get it and can test more, at least the errors are not in the log for now :)
The newer v2.x versions have a new way of identifying trains that I am hoping will also work better for platinum map and other maps with trains. If you have a chance to try it, please let me know if it properly identified the train on the platinum map. Thanks.
-When a vehicle is reset, it changes where that vehicle is in the tab order. Also, when in multiplayer, other players performing resets or buying and selling vehicles can change order. This can cause unexpected behaviour in the VehicleSort lists between sessions.
-The game re-uses vehicle ID numbers when the game is saved after vehicles have been sold and other ones bought. This can cause unexpected behaviour in VehicleSort lists.
-VehicleSort currently will re-generate a new list if it finds that the number of steerables (vehicles) have changed since the last session.
Next task will be to look at a way to generate ID numbers for VehicleSort to use on the server/host that are saved with the save game. Then, to broadcast those ID numbers to players and for VehicleSort to use those numbers to prevent the list changing unexpectedly due to resets or multiplayer actions and changes between sessions, to try and solve these issues.
There is also a comment about it not working in platinum edition, which I did not know (as I don't have platinum right now), so that will have to be looked at as well.
I unfortunately do not have the platinum edition so I was not aware that there was an incompatibility. If/when I get it, then I will look at fixing whatever is wrong.
sorry i´m not member at pastebin but i can post a little here maybe it wil lhelp you :
dataS2/character/player/player01.i3d (761.29) ms
Error: Running LUA method 'draw'.
C:/Users/Müller/Documents/My Games/FarmingSimulator2017/pdlc/Vehicle_Sort/VehicleSort.lua:422: attempt to concatenate field 'vs_brandName' (a nil value)
Error: Running LUA method 'draw'.
C:/Users/Müller/Documents/My Games/FarmingSimulator2017/pdlc/Vehicle_Sort/VehicleSort.lua:422: attempt to concatenate field 'vs_brandName' (a nil value)
Error: Running LUA method 'draw'.
C:/Users/Müller/Documents/My Games/FarmingSimulator2017/pdlc/Vehicle_Sort/VehicleSort.lua:422: attempt to concatenate field 'vs_brandName' (a nil value)
it´s always the same issue maybe you can do something thank you for it
It looks like you have a vehicle with a brand name Vehicle Sort does not see.
Open VehicleSort.lua in "Windows Notepad" from zip file, change line 422:
sName = sName .. oAttachment.vs_brandName .. " ";
to
sName = sName .. Utils.getNoNil(oAttachment.vs_brandName, "Lizard") .. " ";
hopefully that will fix it for you, and I will add this to TODO for next update.
I changed the Line in the lua, now it works it was the train on the map but now i have in the list Steerable with Lizard(gadget). It don´t disturb me but it´s perhaps a note for you. I think i remember on the original map there were the same problems in the first version of vehicle sort so you now may know what to do. I´m glad now that the log is clean so many many thanks for your work
I've submitted an update to at least fix the error, but I do not know how to find the proper brand name and equipment name in this case.
If you would tell me what map you are using, I might be able to see for myself why it does not have the brand name and item name where the script expects to find it.
Then, maybe I can find a way to give it a better name than "Steerable with Lizard (gadget)".
However, if there is no data in the map to give it a proper name, there will be nothing I can really do to give it a better name. Perhaps in a future update I could come up with a way that players could assign custom names as another idea for this kind of situation...
The name of the map is Estancio Lapacha but unfortunately i can´t open the file of the platinum addon so i can´t give you more dates about brand names etc.. But there it is obviously the train of the map maybe you can use the dates or names of the original Goldcrest Valley map?
Very interesting, so it is the default platinum map from Giants...the issue doesn't happen with the Goldcrest map, so I think it must be that they used a different method to identify the train in that map...in the script, Dschonny originally used finding the xml config path containing "train/locomotive" to identify the train, it must be different in platinum map...and yes, as you say, it may be difficult to determine since the dlc map is embedded in the dlc file...thanks for the info, though - something to add to my todo list when I get platinum :)
If you re-join a multiplayer game and the list of owned vehicles have changed since your last session, your saved sort order and parking configuration may no longer be the same. This is because the game appears to re-generate ID numbers for the owned vehicles when they are bought/sold.
If you use the mousewheel to move the list selection, it will also cycle through chainsaws (when on foot) or change the camera zoom (when inside a vehicle), with default settings.
13 Comments for VehicleSort
For anyone looking for an FS 19 version in the meantime, you may try https://github.com/sperrgebiet/FS19_VehicleExplorer which was done by another modder. He states it does not work in multiplayer, though. I may try to do an FS 19 version if I have time to figure out multiplayer in FS 19.
Please we need this mod for LS19.
G:/Eigene Dokumente/My Games/FarmingSimulator2017/mods/FS17_VehicleSort/VehicleSort.lua:768: bad argument #3 to 'format' (number expected, got nil)
Error: Running LUA method 'update'.
this entry always only when i at open the menu or closed.
Thanks for the update for one of my favorite FS tools! Everything's working well now.
One question, though:
How can I change the position of the window? In the latest version it's a little too far down on the screen for my likings, so I'd like to move up towards the upper edge of the screen. However, I can't seem to find any values for xpos, ypos...just a lot of fancy entries which nooby me doesn't understand at all. ^^
A screenie to show you what I mean:
https://i.imgur.com/YpbRqgf.jpg
Thank you Slivicon!
Version 2.1.0.0 works perfect for me!
All issues solved! Great Job!
For those who would like to help with testing, please get latest DEV VehicleSort.lua and modDesc.xml from:
https://raw.githubusercontent.com/Slivicon/VehicleSort/dev/vehicleSort.lua
https://raw.githubusercontent.com/Slivicon/VehicleSort/dev/modDesc.xml
Replace the ones in your v2 zip file with those.
Rename the zip file to FS17_VehicleSort_debug.zip
When you start the game, you will get a message that VehicleSort is no longer present (this is because zip is renamed). Make sure new VehicleSort (renamed debug) is checked as mod enabled for your game.
This special name will tell the mod to write a LOT more information to the log which you can paste (no account needed, you can paste to pastebin.com with no account) at http://pastebin.com (please do not post log in comment, only link to pastebin.com).
You will also see your screenshots will show extra information in debug mode that you can post here or at imgur.com with link to imgur.com in comments.
There is an error inside the lua. I got callstacks like this one:
Warning (LUA): 'getXMLString': Argument 1 has wrong type. Expected: Int. Actual: Nil
..\..\..\src\base\scripting\lua\LuaScriptSystem.cpp (640): expectedType == Value::VoidType
LUA call stack:
dataS/scripts/utils/Utils.lua (1818) : getXMLString
=C:/Users/XXXXXXXXXXXX/Documents/My Games/FarmingSimulator2017/mods/FS17_VehicleSort/VehicleSort.lua (349) : getTrans
=C:/Users/XXXXXXXXXXXX/Documents/My Games/FarmingSimulator2017/mods/FS17_VehicleSort/VehicleSort.lua (810) : getName
dataS/scripts/utils/Utils.lua (1859) : newFunc
dataS/scripts/utils/Utils.lua (1858) : oldFunc
dataS/scripts/vehicles/Vehicle.lua (656)
dataS/scripts/utils/Utils.lua (1858) : oldFunc
Warning (LUA): 'getXMLString': Argument 1 has wrong type. Expected: Int. Actual: Nil
LUA call stack:
dataS/scripts/utils/Utils.lua (1820)
=C:/Users/XXXXXXXXXXXX/Documents/My Games/FarmingSimulator2017/mods/FS17_VehicleSort/VehicleSort.lua (810) : getName : newFunc
dataS/scripts/utils/Utils.lua (1858) : oldFunc
dataS/scripts/vehicles/Vehicle.lua (656)
dataS/scripts/utils/Utils.lua (1858) : oldFunc
dataS/scripts/utils/Utils.lua (1138) : asyncCallbackFunction
Warning (LUA): 'getXMLString': Argument 1 has wrong type. Expected: Int. Actual: Nil
..\..\..\src\base\scripting\lua\LuaScriptSystem.cpp (640): expectedType == Value::VoidType
LUA call stack:
dataS/scripts/utils/Utils.lua (1822) : getXMLString
=C:/Users/XXXXXXXXXXXX/Documents/My Games/FarmingSimulator2017/mods/FS17_VehicleSort/VehicleSort.lua (349) : getTrans
=C:/Users/XXXXXXXXXXXX/Documents/My Games/FarmingSimulator2017/mods/FS17_VehicleSort/VehicleSort.lua (810) : getName
dataS/scripts/utils/Utils.lua (1859) : newFunc
dataS/scripts/vehicles/Vehicle.lua (656)
dataS/scripts/utils/Utils.lua (1858) : oldFunc
dataS/scripts/utils/Utils.lua (1138) : asyncCallbackFunction
Warning (LUA): 'getXMLString': Argument 1 has wrong type. Expected: Int. Actual: Nil
: expectedType == Value::VoidType
LUA call stack:
dataS/scripts/utils/Utils.lua (1845)
=C:/Users/XXXXXXXXXXXX/Documents/My Games/FarmingSimulator2017/mods/FS17_VehicleSort/VehicleSort.lua (810) : getName
allways the same lines in lua. Get name and get trans
in v 2.0.0.0 is a new dark background.
but he is in the right side a little bit to short
how can i edit the lua file to make the background bigger?
is also a colour chance to a litte more brighter?
lg
andreas
Hi Slivicon,
I downloaded the latest version (2.0.0.0) and put it in the Mods folder, but it doesn't appear in the mod list when loading the savegame. I have tried the .zip file, and also tried to unzip it.
Is the lates FS17 patch required, or is it something else?
I´ve loaded the new version but in the list it shows still the same. I guess the same like you that they used a different method to identify the train otherwise i think vehicle sort would see the train. But the most important for me is that the log is not full of callstacks anymore so thank you again
kind regards
Development notes:
-Development can also be followed at https://github.com/Slivicon/VehicleSort , and issues can be submitted there as well.
-When a vehicle is reset, it changes where that vehicle is in the tab order. Also, when in multiplayer, other players performing resets or buying and selling vehicles can change order. This can cause unexpected behaviour in the VehicleSort lists between sessions.
-The game re-uses vehicle ID numbers when the game is saved after vehicles have been sold and other ones bought. This can cause unexpected behaviour in VehicleSort lists.
-VehicleSort currently will re-generate a new list if it finds that the number of steerables (vehicles) have changed since the last session.
Next task will be to look at a way to generate ID numbers for VehicleSort to use on the server/host that are saved with the save game. Then, to broadcast those ID numbers to players and for VehicleSort to use those numbers to prevent the list changing unexpectedly due to resets or multiplayer actions and changes between sessions, to try and solve these issues.
There is also a comment about it not working in platinum edition, which I did not know (as I don't have platinum right now), so that will have to be looked at as well.
Could you try to make it compatible with the platinum edition?
Known issues:
If you re-join a multiplayer game and the list of owned vehicles have changed since your last session, your saved sort order and parking configuration may no longer be the same. This is because the game appears to re-generate ID numbers for the owned vehicles when they are bought/sold.
If you use the mousewheel to move the list selection, it will also cycle through chainsaws (when on foot) or change the camera zoom (when inside a vehicle), with default settings.