Skip to content

Commit 499913f

Browse files
author
Credomane
committed
convert spaces to tabs to match original code style
1 parent 00515b5 commit 499913f

File tree

1 file changed

+18
-18
lines changed

1 file changed

+18
-18
lines changed

Files/control.lua

Lines changed: 18 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -69,10 +69,10 @@ script.on_event(defines.events.on_gui_click, function(event)
6969
-- BUTTON RESET DAYTIME
7070
if(event.element.name == "resetdaytime") then
7171
if(currentdaytime ~= nil) then
72-
--Time has advanced since we stored the time.
73-
--Add stored time to current surface time to keep ticks and day/night cycle in "sync".
74-
currentdaytime = currentdaytime + game.players[event.player_index].surface.daytime;
75-
if currentdaytime > 1 then currentdaytime = currentdaytime - 1; end
72+
--Time has advanced since we stored the time.
73+
--Add stored time to current surface time to keep ticks and day/night cycle in "sync".
74+
currentdaytime = currentdaytime + game.players[event.player_index].surface.daytime;
75+
if currentdaytime > 1 then currentdaytime = currentdaytime - 1; end
7676
game.players[event.player_index].surface.daytime = currentdaytime
7777
end
7878
end
@@ -158,7 +158,7 @@ script.on_event(defines.events.on_gui_click, function(event)
158158

159159

160160
foldernamesize = "Map" .. "("..(-1*minx + maxx) .. "," .. (-1*miny + maxy) .. ")"
161-
updatefilename()
161+
updatefilename()
162162
end
163163

164164
-- CROP BASE BUTTON
@@ -307,23 +307,23 @@ function cropbase(player_index)
307307
-- game.players[player_index].print(b.prototype.name)
308308
-- end
309309

310-
local entityFilter = {
311-
force = game.players[player_index].force.name,
312-
area = {
313-
{x-step/2, y-step/2},
314-
{x+step/2, y+step/2}
315-
}
316-
};
310+
local entityFilter = {
311+
force = game.players[player_index].force.name,
312+
area = {
313+
{x-step/2, y-step/2},
314+
{x+step/2, y+step/2}
315+
}
316+
};
317317

318318
for _,v in pairs(game.players[player_index].surface.find_entities_filtered(entityFilter)) do
319319
if (v.prototype.name ~= "player") then -- if it's not a player
320-
if v.position then
321-
minx = math.min(minx, v.position.x)
322-
miny = math.min(miny, v.position.y)
320+
if v.position then
321+
minx = math.min(minx, v.position.x)
322+
miny = math.min(miny, v.position.y)
323323

324-
maxx = math.max(maxx, v.position.x)
325-
maxy = math.max(maxy, v.position.y)
326-
end
324+
maxx = math.max(maxx, v.position.x)
325+
maxy = math.max(maxy, v.position.y)
326+
end
327327
end
328328
end
329329
end

0 commit comments

Comments
 (0)