mirror of
https://github.com/infinitefusion/infinitefusion-e18.git
synced 2025-12-10 06:34:59 +00:00
Tidied up semicolon use, refactored random dungeon generation code, fixed visual bug in Day Care debug screen
This commit is contained in:
@@ -42,11 +42,16 @@ class MiningGameTile < BitmapSprite
|
||||
@viewport.z=99999
|
||||
super(32,32,@viewport)
|
||||
r = rand(100)
|
||||
if r<10; @layer = 2 # 10%
|
||||
elsif r<25; @layer = 3 # 15%
|
||||
elsif r<60; @layer = 4 # 35%
|
||||
elsif r<85; @layer = 5 # 25%
|
||||
else; @layer = 6 # 15%
|
||||
if r < 10
|
||||
@layer = 2 # 10%
|
||||
elsif r < 25
|
||||
@layer = 3 # 15%
|
||||
elsif r < 60
|
||||
@layer = 4 # 35%
|
||||
elsif r < 85
|
||||
@layer = 5 # 25%
|
||||
else
|
||||
@layer = 6 # 15%
|
||||
end
|
||||
@image=AnimatedBitmap.new(_INTL("Graphics/Pictures/Mining/tiles"))
|
||||
update
|
||||
@@ -104,10 +109,12 @@ class MiningGameCursor < BitmapSprite
|
||||
y = 32*(@position/MiningGameScene::BOARDWIDTH)
|
||||
if @counter>0
|
||||
@counter -= 1
|
||||
toolx = x; tooly = y
|
||||
toolx = x
|
||||
tooly = y
|
||||
i = 10-(@counter/2).floor
|
||||
if ToolPositions[i][1]==1
|
||||
toolx -= 8; tooly += 8
|
||||
toolx -= 8
|
||||
tooly += 8
|
||||
elsif ToolPositions[i][1]==2
|
||||
toolx += 6
|
||||
end
|
||||
|
||||
Reference in New Issue
Block a user