-- Sonnenblumen
print("register fruit type: Sonnenblumen");
local sunflowerhudFile = Utils.getFilename("map/scripte/sunflowerHud.dds", getUserProfileAppPath());
FruitUtil.registerFruitType("sunflower", g_i18n:getText("sunflower"), true, true, false, 0, 4, 6, 8, 0, 0.35, 2.5, 0.1, true, sunflowerhudFile, {0.8, 0.2, 0.6, 1});
local origSowingMachineLoad = SowingMachine.load;
local orig TrailerLoad = Trailer.load;
SowingMachine.load = function (self, xmlFile)
if origSowingMachineLoad ~= nil then
origSowingMachineLoad(self, xmlFile);
end;
for k,v in pairs(self.seeds) do
fruitTypeDesc = FruitUtil.fruitTypes["wheat"]; -- selectedSeedFruitType = "wheat" etc..
if v == fruitTypeDesc.index then
table.insert(self.seeds, FruitUtil.fruitTypes["sunflower"].index);
end;
end;
end;
-- 1 Kohlrabi
print("register fruit type: kohlrabi");
local kohlrabihudFile = Utils.getFilename("map/scripte/hud/kohlrabiHUD.png", g_currentModDirectory);
FruitUtil.registerFruitType("kohlrabi", kohlrabi, true, true, false, 0, 4, 6, 8, 0, 0.9, 1.2, 0.1, true, kohlrabihudFile, {0.8,0.6,0.4, 1});
local origSowingMachineLoad = SowingMachine.load;
local orig TrailerLoad = Trailer.load;
SowingMachine.load = function (self, xmlFile)
if origSowingMachineLoad ~= nil then
origSowingMachineLoad(self, xmlFile);
end;
for k,v in pairs(self.seeds) do
fruitTypeDesc = FruitUtil.fruitTypes["wheat"];
if v == fruitTypeDesc.index then
table.insert(self.seeds, FruitUtil.fruitTypes["kohlrabi"].index);
end;
end
end;
-- 2 Erdbeere
print("register fruit type: erdbeere");
local erdbeerehudFile = Utils.getFilename("map/scripte/hud/erdbeereHUD.png", g_currentModDirectory);
FruitUtil.registerFruitType("erdbeere", erdbeere, true, true, false, 0, 4, 6, 8, 0, 0.35, 2.5, 0.1, true, erdbeerehudFile, {0.8,0.4,0.2, 1});
local origSowingMachineLoad = SowingMachine.load;
local orig TrailerLoad = Trailer.load;
SowingMachine.load = function (self, xmlFile)
if origSowingMachineLoad ~= nil then
origSowingMachineLoad(self, xmlFile);
end;
for k,v in pairs(self.seeds) do
fruitTypeDesc = FruitUtil.fruitTypes["wheat"];
if v == fruitTypeDesc.index then
table.insert(self.seeds, FruitUtil.fruitTypes["erdbeere"].index);
end;
end
end;
local origLoadStatsFromXML = loadStatsFromXML;