Community Forum

Fruittype select

Forum Overview >> Farming Simulator 19

CategoryFarming Simulator 19
Created11.11.2019 16:58


Van Vynckt Dominique (NiCForce) 11.11.2019 16:58
Hi

After a year of teaching myself how to make mods.
I want to try something more now, but I am not a programmer.
Although I learn a lot how others write mods.
My mods, I do not release at the moment, because they are not all error free or not always realistic.
And half a mod is not a mod, and you shouldn't release it either.

1. As with sowing machine, you can select Seeds with the Y button.
Can someone help me on my way, from where this info comes, probably LUA but I cannot find it.

2. Is it possible to get this info automatically via Feeldinfo (yes) but can you trigger something with this?

3. Purpose
In my mod I need (<fruitPreparer fruitType = "setFruitType" />) fruitType, but in fruitType you can only have 1 fruitType.
So I would like to change with the Y key or be triggered automatically by something from Feeldinfo.

Don't think, this will go in a .XML Will probably be a LUA?

Are there modders that can help me with this?

Bilbo Beutlin (BBeutlin) 11.11.2019 20:39
For reference see LUADOCs -> Specializations -> SowingMachine.

In a sowing machine the type selection is executed by an actionEvent. The 'changeSeedInputButton' is either the default "InputAction.IMPLEMENT_EXTRA3" or can be defined in vehicle.xml "vehicle.sowingMachine.changeSeedInputButton".
This actionEvent calls the function actionEventToggleSeedType().

Though you can evaluate the fieldInfo and set the seedType accordingly, it isn't recommanded. A cultivated/plowed field doesn't have the past fruit info anymore. Furthermore the player should decide finally the seedType.

A fruitPreparer can be extended by a custom LUA script to toggle the fruitType. But it is not simple, you'll need advanced experience in FS LUA scripting. Basically you had to setup a new spec which handles fruitType selection and the fruitPreparer properties accordingly.

Van Vynckt Dominique (NiCForce) 16.11.2019 21:33
Hi
Thanks in advance for your info, I have already searched but for now I am not much further.

Bilbo Beutlin (BBeutlin) 16.11.2019 22:02
What do you expect? That others write the code for you?
You're admitting "I am not a programmer". But you'll need more than some basic knowledge about LUA and FS script methods.
Either begin to learn and enhance your experience stepwise - or forget your plans.

Van Vynckt Dominique (NiCForce) 17.11.2019 01:41
Sorry, I just wanted to thank you for the info.
And no, I did not expect this either.
But there is not much explanation at FS LUA, even though you have knowledge of LUA, it is still difficult.


Note: Log in to post. Create a new account here.