mirror of
https://github.com/infinitefusion/infinitefusion-e18.git
synced 2026-01-22 06:06:01 +00:00
Changed functionality of running key, added compatibility with old Mystery Gifts
This commit is contained in:
@@ -114,7 +114,7 @@ class BitmapWrapper < Bitmap
|
||||
def dispose
|
||||
return if self.disposed?
|
||||
@refcount -= 1
|
||||
super if @refcount == 0
|
||||
super if @refcount <= 0
|
||||
end
|
||||
|
||||
def initialize(*arg)
|
||||
@@ -265,8 +265,8 @@ module BitmapCache
|
||||
objKey = fromCache(key)
|
||||
if !objKey
|
||||
bitmap = BitmapWrapper.new(Game_Map::TILE_WIDTH, Game_Map::TILE_HEIGHT)
|
||||
x = (tile_id - 384) % 8 * 32
|
||||
y = (tile_id - 384) / 8 * 32
|
||||
x = (tile_id - 384) % 8 * Game_Map::TILE_WIDTH
|
||||
y = (tile_id - 384) / 8 * Game_Map::TILE_HEIGHT
|
||||
rect = Rect.new(x, y, Game_Map::TILE_WIDTH, Game_Map::TILE_HEIGHT)
|
||||
tileset = yield(filename)
|
||||
bitmap.blt(0, 0, tileset, rect)
|
||||
|
||||
@@ -296,7 +296,7 @@ class GifBitmap
|
||||
end
|
||||
|
||||
def totalFrames
|
||||
@totalframes/2 # Due to frame count being incremented by 2
|
||||
@totalframes/2 # Due to frame count being incremented by 2
|
||||
end
|
||||
|
||||
def disposed?
|
||||
@@ -311,7 +311,7 @@ class GifBitmap
|
||||
@gifbitmaps.length==0 ? 0 : @gifbitmaps[0].height
|
||||
end
|
||||
|
||||
# This function must be called in order to animate the GIF image.
|
||||
# This function must be called in order to animate the GIF image.
|
||||
def update
|
||||
return if disposed?
|
||||
if @gifbitmaps.length>0
|
||||
|
||||
@@ -592,7 +592,7 @@ def getFormattedText(bitmap,xDst,yDst,widthDst,heightDst,text,lineheight=32,
|
||||
alignstack.push(0)
|
||||
nextline=1 if x>0 && nextline==0
|
||||
else
|
||||
alignstack.pop;
|
||||
alignstack.pop
|
||||
nextline=1 if x>0 && nextline==0
|
||||
end
|
||||
elsif control=="ac" # Center align
|
||||
@@ -600,7 +600,7 @@ def getFormattedText(bitmap,xDst,yDst,widthDst,heightDst,text,lineheight=32,
|
||||
alignstack.push(2)
|
||||
nextline=1 if x>0 && nextline==0
|
||||
else
|
||||
alignstack.pop;
|
||||
alignstack.pop
|
||||
nextline=1 if x>0 && nextline==0
|
||||
end
|
||||
elsif control=="icon" # Icon
|
||||
|
||||
Reference in New Issue
Block a user