mirror of
https://github.com/infinitefusion/infinitefusion-e18.git
synced 2025-12-06 06:01:46 +00:00
update 6.7
This commit is contained in:
@@ -129,22 +129,49 @@ class AnimatedBitmap
|
||||
@bitmap.bitmap = new_bitmap
|
||||
end
|
||||
|
||||
# def mirror
|
||||
# for x in 0..@bitmap.bitmap.width / 2
|
||||
# for y in 0..@bitmap.bitmap.height - 2
|
||||
# temp = @bitmap.bitmap.get_pixel(x, y)
|
||||
# newPix = @bitmap.bitmap.get_pixel((@bitmap.bitmap.width - x), y)
|
||||
#
|
||||
# @bitmap.bitmap.set_pixel(x, y, newPix)
|
||||
# @bitmap.bitmap.set_pixel((@bitmap.bitmap.width - x), y, temp)
|
||||
# end
|
||||
# end
|
||||
# end
|
||||
|
||||
def mirror
|
||||
@bitmap.bitmap
|
||||
mirror_horizontally
|
||||
end
|
||||
|
||||
def mirror_horizontally
|
||||
bmp = @bitmap.bitmap
|
||||
half_width = bmp.width / 2
|
||||
height = bmp.height
|
||||
|
||||
(0...half_width).each do |x|
|
||||
(0...height).each do |y|
|
||||
left_pixel = bmp.get_pixel(x, y)
|
||||
right_pixel = bmp.get_pixel(bmp.width - 1 - x, y)
|
||||
|
||||
bmp.set_pixel(x, y, right_pixel)
|
||||
bmp.set_pixel(bmp.width - 1 - x, y, left_pixel)
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
|
||||
def mirror_vertically
|
||||
bmp = @bitmap.bitmap
|
||||
width = bmp.width
|
||||
half_height = bmp.height / 2
|
||||
|
||||
(0...half_height).each do |y|
|
||||
(0...width).each do |x|
|
||||
top_pixel = bmp.get_pixel(x, y)
|
||||
bottom_pixel = bmp.get_pixel(x, bmp.height - 1 - y)
|
||||
|
||||
bmp.set_pixel(x, y, bottom_pixel)
|
||||
bmp.set_pixel(x, bmp.height - 1 - y, top_pixel)
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
|
||||
|
||||
# def mirror
|
||||
# @bitmap.bitmap
|
||||
# end
|
||||
|
||||
end
|
||||
|
||||
|
||||
|
||||
@@ -396,9 +396,9 @@ def pbGetGoldString
|
||||
moneyString = _INTL("${1}", $Trainer.money.to_s_formatted)
|
||||
rescue
|
||||
if $data_system.respond_to?("words")
|
||||
moneyString = _INTL("{1} {2}", $game_party.gold, $data_system.words.gold)
|
||||
moneyString = "#{$game_party.gold} #{$data_system.words.gold}"
|
||||
else
|
||||
moneyString = _INTL("{1} {2}", $game_party.gold, Vocab.gold)
|
||||
moneyString = "#{$game_party.gold} #{Vocab.gold}"
|
||||
end
|
||||
end
|
||||
return moneyString
|
||||
@@ -474,6 +474,8 @@ def pbDisplayHeartScalesWindow(msgwindow)
|
||||
return pointswindow
|
||||
end
|
||||
|
||||
|
||||
|
||||
def pbDisplayCoinsWindow(msgwindow, goldwindow)
|
||||
coinString = ($Trainer) ? $Trainer.coins.to_s_formatted : "0"
|
||||
coinwindow = Window_AdvancedTextPokemon.new(_INTL("Coins:\n<ar>{1}</ar>", coinString))
|
||||
@@ -506,6 +508,22 @@ def pbDisplayBattlePointsWindow(msgwindow)
|
||||
return pointswindow
|
||||
end
|
||||
|
||||
def pbDisplayQuestPointsWindow(msgwindow)
|
||||
pointsString = ($Trainer) ? $Trainer.quest_points.to_s_formatted : "0"
|
||||
pointswindow = Window_AdvancedTextPokemon.new(_INTL("Quest Points:\n<ar>{1}</ar>", pointsString))
|
||||
pointswindow.setSkin("Graphics/Windowskins/goldskin")
|
||||
pointswindow.resizeToFit(pointswindow.text, Graphics.width)
|
||||
pointswindow.width = 160 if pointswindow.width <= 160
|
||||
if msgwindow.y == 0
|
||||
pointswindow.y = Graphics.height - pointswindow.height
|
||||
else
|
||||
pointswindow.y = 0
|
||||
end
|
||||
pointswindow.viewport = msgwindow.viewport
|
||||
pointswindow.z = msgwindow.z
|
||||
return pointswindow
|
||||
end
|
||||
|
||||
#===============================================================================
|
||||
#
|
||||
#===============================================================================
|
||||
@@ -594,6 +612,12 @@ def pbMessageDisplay(msgwindow, message, letterbyletter = true, commandProc = ni
|
||||
text.gsub!(/\\pog/i, "")
|
||||
text.gsub!(/\\b/i, "<c3=3050C8,D0D0C8>")
|
||||
text.gsub!(/\\r/i, "<c3=E00808,D0D0C8>")
|
||||
text.gsub!(/\\mu\[(.*?)\]/i) do
|
||||
$Trainer && isPlayerMale() ? $1 : ""
|
||||
end
|
||||
text.gsub!(/\\fu\[(.*?)\]/i) do
|
||||
$Trainer && isPlayerFemale() ? $1 : ""
|
||||
end
|
||||
text.gsub!(/\\[Ww]\[([^\]]*)\]/) {
|
||||
w = $1.to_s
|
||||
if w == ""
|
||||
@@ -632,7 +656,7 @@ def pbMessageDisplay(msgwindow, message, letterbyletter = true, commandProc = ni
|
||||
### Controls
|
||||
textchunks = []
|
||||
controls = []
|
||||
while text[/(?:\\(f|ff|ts|cl|me|se|wt|wtnp|ch)\[([^\]]*)\]|\\(g|cn|pt|ft|hs|wd|wm|op|cl|wu|\.|\||\!|\^))/i]
|
||||
while text[/(?:\\(f|ff|ts|cl|me|se|wt|wtnp|ch)\[([^\]]*)\]|\\(g|cn|pt|ft|qp|hs|wd|wm|op|cl|wu|\.|\||\!|\^))/i]
|
||||
textchunks.push($~.pre_match)
|
||||
if $~[1]
|
||||
controls.push([$~[1].downcase, $~[2], -1])
|
||||
@@ -757,6 +781,9 @@ def pbMessageDisplay(msgwindow, message, letterbyletter = true, commandProc = ni
|
||||
when "hs" # Display heartscakes
|
||||
goldwindow.dispose if goldwindow
|
||||
goldwindow = pbDisplayHeartScalesWindow(msgwindow)
|
||||
when "qp" # Display quest points
|
||||
goldwindow.dispose if goldwindow
|
||||
goldwindow = pbDisplayQuestPointsWindow(msgwindow)
|
||||
when "cn" # Display coins window
|
||||
coinwindow.dispose if coinwindow
|
||||
coinwindow = pbDisplayCoinsWindow(msgwindow, goldwindow)
|
||||
|
||||
Reference in New Issue
Block a user