summaryrefslogtreecommitdiffhomepage
path: root/not/CloudGenerator.lua
diff options
context:
space:
mode:
authorAki <nthirtyone@gmail.com>2017-09-13 04:53:00 +0200
committerAki <nthirtyone@gmail.com>2017-09-13 04:53:00 +0200
commit4e3b4358bb3f8280a4739bf6a110823b029acae2 (patch)
tree6dee889bb8ec230446378e9cd6170afe08926802 /not/CloudGenerator.lua
parenta0bbf9f36db30b0c6de3480f525ee69698ba18f9 (diff)
downloadroflnauts-4e3b4358bb3f8280a4739bf6a110823b029acae2.zip
roflnauts-4e3b4358bb3f8280a4739bf6a110823b029acae2.tar.gz
roflnauts-4e3b4358bb3f8280a4739bf6a110823b029acae2.tar.bz2
CloudGenerators now can be configured to use layer with ratio
Diffstat (limited to 'not/CloudGenerator.lua')
-rw-r--r--not/CloudGenerator.lua4
1 files changed, 3 insertions, 1 deletions
diff --git a/not/CloudGenerator.lua b/not/CloudGenerator.lua
index 36ec70f..75fd180 100644
--- a/not/CloudGenerator.lua
+++ b/not/CloudGenerator.lua
@@ -9,8 +9,9 @@ function CloudGenerator:new (atlas, animations, count, world)
self.atlas = atlas
self.quads = animations
self.count = count
- self.interval = 6
+ self.interval = 8
self.timer = 0
+ self.layer = false
end
-- TODO: This was a bad idea. Move Cloud creation back to World, pass created Cloud here for configuration.
@@ -21,6 +22,7 @@ function CloudGenerator:createCloud (x, y, style)
cloud:setVelocity(13, 0)
cloud:setBoundary(340, 320)
cloud.generator = self
+ cloud.layer = self.layer
return cloud
end