Fixed text positioning and removed individual character offsets

This commit is contained in:
m3rein
2020-09-11 16:32:04 +02:00
parent c732b35931
commit 8da6ef64a3
5 changed files with 23 additions and 37 deletions

View File

@@ -1310,12 +1310,6 @@ class Window_AdvancedTextPokemon < SpriteWindow_Base
for ch in fmt
chx = ch[1]+ch[3]
chy = ch[2]+ch[4]
if mkxp?
offset = (CHARACTER_OFFSETS[ch[0]] || [0, 0])
offset[1] -= 2 if offset[1]
ch[1] += offset[0] if offset[0]
ch[2] += offset[1] if offset[1]
end
width = chx if width<chx
height = chy if height<chy
if !ch[5] && ch[0]=="\n"
@@ -1343,12 +1337,6 @@ class Window_AdvancedTextPokemon < SpriteWindow_Base
for ch in @fmtchars
chx = ch[1]+ch[3]
chy = ch[2]+ch[4]
if mkxp?
offset = (CHARACTER_OFFSETS[ch[0]] || [0, 0])
offset[1] -= 2 if offset[1]
ch[1] += offset[0] if offset[0]
ch[2] += offset[1] if offset[1]
end
width = chx if width<chx
height = chy if height<chy
@textchars.push(ch[5] ? "" : ch[0])
@@ -2234,7 +2222,7 @@ class Window_CommandPokemon < Window_DrawableCommand
def drawItem(index,_count,rect)
pbSetSystemFont(self.contents) if @starting
rect=drawCursor(index,rect)
pbDrawShadowText(self.contents,rect.x,rect.y,rect.width,rect.height,
pbDrawShadowText(self.contents,rect.x,rect.y + (mkxp? ? 6 : 0),rect.width,rect.height,
@commands[index],self.baseColor,self.shadowColor)
end
end