COMMUNITY FORUM

Locomotive Vehicle type

Forum Overview >> Farming Simulator 17

CategoryFarming Simulator 17
Created11.11.2016 12:38


Bio Medical Extetion (Unknown) 11.11.2016 12:43
Hallo,

i need to know what is the vehicle type name and specialization name of the Locomotive (the train).

my script:

for k, v in pairs(VehicleTypeUtil.vehicleTypes) do
if v ~= nil then

print(('\tadding to %q'):format(tostring(v.name)));

end;
end;

log output:
adding to "fuelTrailer"
adding to "selfPropelledSprayer"
adding to "cutter_animated"
adding to "mower_animated"
adding to "forwarderTrailer"
adding to "tractor"
adding to "sprayer_animated"
adding to "car_dynamicMountAttacher"
adding to "woodCrusherTrailer"
adding to "cutter_builtInCutterTrailer"
adding to "forwarderTrailer_steerable"
adding to "implement"
adding to "combine_animated"
adding to "loaderVehicle"
adding to "treePlanter"
adding to "strawBlower"
adding to "sowingMachine"
adding to "receivingHopper"
adding to "leveler"
adding to "plough"
adding to "cutter"
adding to "hookLiftContainerTransport"
adding to "weederSowingmachine"
adding to "wheelLoader"
adding to "conveyorTrailerDrivable"
adding to "selfPropelledMixerWagon"
adding to "manureBarrel"
adding to "woodHarvester"
adding to "baleLoader"
adding to "skidSteer"
adding to "manureSpreader"
adding to "attachableFrontloader"
adding to "baleWrapper"
adding to "combine_animated_crawler"
adding to "augerWagon"
adding to "shovel_animated"
adding to "trailer"
adding to "hookLiftContainerManureBarrel"
adding to "goldhoferFront"
adding to "dynamicMountAttacherImplement"
adding to "baler"
adding to "mower"
adding to "tractor_articulatedAxis"
adding to "shovel"
adding to "car"
adding to "mixerWagon"
adding to "ridingMower"
adding to "woodCrusherTrailerDrivable"
adding to "conveyorTrailerHireable"
adding to "tractor_crawler"
adding to "selfPropelledMower"
adding to "hookLiftTrailer"
adding to "weeder"
adding to "stumpCutter"
adding to "waterTrailer"
adding to "treeSaw_attacherJointControl"
adding to "treeSaw"
adding to "livestockTrailer"
adding to "combine_animated_articulatedAxis"
adding to "transportTrailer"
adding to "tractor_foldable"
adding to "windrower"
adding to "loadingTrailerDrivable"
adding to "tedder"
adding to "roller"
adding to "baleGrab"
adding to "hookLiftContainerManureSpreader"
adding to "attachableCombine"
adding to "combine"
adding to "selfPropelledPotatoHarvester"
adding to "implement_animated"
adding to "cultivator"
adding to "shovel_dynamicMountAttacher"
adding to "telehandler_articulatedAxis"
adding to "telehandler"
adding to "defoliater_cutter_animated"
adding to "hookLiftContainerTrailer"
adding to "forageWagon"
adding to "defoliator_animated"
adding to "forwarder"
adding to "conveyorTrailerSteerable"
adding to "hookLiftContainer"
adding to "sowingMachineSprayer"
adding to "dynamicMountAttacherTrailer"
adding to "combine_cylindered"
adding to "tractor_reverseDriving"
adding to "manureBarrelCultivator"


but i cant find the "locomotive" .... pls help thx


Jorn Hiel (fa285634) 11.11.2016 16:32
Program Files (x86)\Steam\steamapps\common\Farming Simulator 17\data\vehicles\train

have a peek in there, its rather a simple name ;)

Bio Medical Extetion (Unknown) 11.11.2016 17:53
thanks for the reply,

yes i saw those files but i need to get the vehicle "object" where i can add the my custom specialization...

into locomotive.xml i see this tag:

<specializations>
<specialization name="lights"/>
<specialization name="motorized" />
<specialization name="steerable"/>
<specialization name="drivable" />
<specialization name="animatedVehicle" />
<specialization name="honk"/>
</specializations>

but looking inside those specializations i never see the "locomotive" vehicle object... and most probably it has another name... but which? (or maybe the locomotive is not into "vehicleTypes" class)

Bio Medical Extetion (Unknown) 13.11.2016 12:52
bump

Gs Modding (kennethdarnoldjr) 14.11.2016 17:49
On my game it is in Farming simulator17\data\vehicles\train and the object is "locomotiveKI.i3d"

Bio Medical Extetion (Unknown) 14.11.2016 20:37
yes, i know...
I try to explain better my problem:

My mod have 4 files:
modDesc.xml
register.lua
mymod.lua
store.dds

register.lua script:
function mymod_Register:loadMap(name)
if self.mymod_Register == nil then
self.mymod_Register = false;

for k, v in pairs(VehicleTypeUtil.vehicleTypes) do
if v ~= nil then
for i = 1, table.maxn(v.specializations) do
local vs = v.specializations[i];
if vs ~= nil and vs == SpecializationUtil.getSpecialization("drivable") then--
table.insert(v.specializations, SpecializationUtil.getSpecialization("mymod"));

vs.turnAutoOn = g_i18n:getText("turnAutoOn");
vs.turnAutoOff = g_i18n:getText("turnAutoOff");
end;
end;
end;
end;
end;
end;

mymod.lua script:
function mymod:update(dt)

if InputBinding.hasEvent(InputBinding.Autopilot_OnOff) then
self.myflag = not self.myflag;
end;

end;
function mymod:draw()

if not self.myflag then
g_currentMission:addHelpButtonText(Drivable.turnAutoOn, InputBinding.mymod_OnOff,nil,GS_PRIO_LOW);
else
g_currentMission:addHelpButtonText(Drivable.turnAutoOff, InputBinding.mymod_OnOff,nil,GS_PRIO_LOW);
end;

end;

Now THIS works with ALL "drivable" vehicles but NOT for the TRAIN or LOCOMOTIVE... WHY?

pls hlp


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