diff --git a/config/expcore/roles.lua b/config/expcore/roles.lua index 00f849f9..2c320fc5 100644 --- a/config/expcore/roles.lua +++ b/config/expcore/roles.lua @@ -229,7 +229,6 @@ Roles.new_role('Member','Mem') 'command/save-quickbar', 'gui/vlayer-edit', 'command/personal-logistic', - 'command/personal-logistic-empty', 'command/auto-research', 'command/manual-train', 'command/lawnmower' diff --git a/modules/data/personal-logistic.lua b/modules/data/personal-logistic.lua index e1b89711..cfe95314 100644 --- a/modules/data/personal-logistic.lua +++ b/modules/data/personal-logistic.lua @@ -13,16 +13,6 @@ local function pl(type, target, amount) c = target.clear_vehicle_logistic_slot s = target.set_vehicle_logistic_slot - elseif type == 'c' then - c = target.clear_personal_logistic_slot - s = target.set_personal_logistic_slot - - for k, v in pairs(config.request) do - c(config.start + v.key) - s(config.start + v.key, {name=k, min=0, max=0}) - end - - return else return end @@ -79,11 +69,9 @@ Commands.new_command('personal-logistic', 'Set Personal Logistic (0 to cancel al :register(function(player, amount) if player.force.technologies['logistic-robotics'].researched then if player.selected ~= nil then - if player.selected.name ~= nil then - if player.selected.name == 'spidertron' then - pl('s', player.selected, amount / 10) - return Commands.success - end + if player.selected.name == 'spidertron' then + pl('s', player.selected, amount / 10) + return Commands.success end else pl('p', player, amount / 10) @@ -93,14 +81,3 @@ Commands.new_command('personal-logistic', 'Set Personal Logistic (0 to cancel al player.print('Player logistic not researched') end end) - -Commands.new_command('personal-logistic-empty', 'Set Personal Logistic to All 0') -:add_alias('ple') -:register(function(player) - if player.force.technologies['logistic-robotics'].researched then - pl('c', player, 0) - return Commands.success - else - player.print('Player logistic not researched') - end -end)