mirror of
https://github.com/Refactorio/RedMew.git
synced 2025-03-03 14:53:01 +02:00
Use of on_nth_tick
This commit is contained in:
parent
d0f2fc5748
commit
7682f1967e
@ -147,17 +147,14 @@ local ore_grid = b.grid_pattern_full_overlap(ore_pattern, 50, 50, 96, 96)
|
||||
ore_grid = b.translate(ore_grid, -60, -20)
|
||||
|
||||
--spews a random turkey fact in chat every 10 minutes.
|
||||
Event.add(
|
||||
defines.events.on_tick,
|
||||
|
||||
Event.on_nth_tick(36000,
|
||||
function(event)
|
||||
if event.tick % 36000 == 0 then
|
||||
local message = turkey_message_random[math.random(#turkey_message_random)]
|
||||
game.print('[color=yellow][font=compi]' .. message .. '[/font][/color]')
|
||||
end
|
||||
end
|
||||
)
|
||||
|
||||
|
||||
pic = b.decompress(pic)
|
||||
|
||||
--idk why this works but it does, played whack a mole/whack a variable to get it to clear all errors
|
||||
|
Loading…
x
Reference in New Issue
Block a user