Community Forum

Register fruit/fillType not working on triggers.

Forum Overview >> Scripting

CategoryScripting
Created09.10.2015 12:41


Dirk Peeters (jengske_BE) 09.10.2015 12:56
hi,
i trying to add new filltypes to the game but for some reason its not done correct.
i did this in 2011 -2013 and in 2015 its not working.

when i check the Fillable and fruits tables, the new type is added.
i save a session and edit the vehicle.xml and add the new type to a trailer, rerun the session and the trailer is filled with the fillType no error in the log, the key(i) panel shown the filltype under FruitType silo's not fillType.

when i drive to a tiptrigger i always get the warning newFilltype not allowed here.
all triggers have the filltype correct added.

the registering is done on loadMap().
code i use:

FruitUtil.registerFruitType(newType, g_i18n:getText(newType), false, false, false, 0, 4, 6, 8, false, 0.5, 0, 0.1, true, hud); register it but not able to load/unload.

Fillable.registerFillType(newType, g_i18n:getText(newType), 0.2, false, hud, hudsmall, 0.0001);

its a fillType so no need to add them to the i3d sublayers, i just used registerFruits to see the differince but the result is the same for both functions. all paths are correct to the hud images added l10n naming in moddesc.

thx
jeng



Dirk Peeters (jengske_BE) 09.10.2015 15:29
i got it registered but the new filltypes want list in the i panel.
any ideas wy this is happening?
now the triggers load and unload the silos.

grts
jeng

Ismael Artacho Angel (Unknown) 21.10.2015 14:47
The best script for add more fruit is additional fruittype, is very easy.

Dirk Peeters (jengske_BE) 21.10.2015 16:00
Hi,
i know that, but i use registerLivestock.lua a script i made for 2011-2013.
thx
jeng


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