Skip to content

Commit 53d75c9

Browse files
authored
font.pgf
Support for font in ux0:data/ONETROPHY/font/font.pgf
1 parent f99be30 commit 53d75c9

6 files changed

Lines changed: 14 additions & 32 deletions

File tree

ONETROPHY/eboot.bin

3.3 KB
Binary file not shown.

ONETROPHY/git/shared.lua

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,6 @@ APP_REPO = "ONElua"
44
APP_PROJECT = "TrophyManager"
55

66
APP_VERSION_MAJOR = 0x01 -- major.minor
7-
APP_VERSION_MINOR = 0x01
7+
APP_VERSION_MINOR = 0x02
88

99
APP_VERSION = ((APP_VERSION_MAJOR << 0x18) | (APP_VERSION_MINOR << 0x10)) -- Union Binary

ONETROPHY/sce_sys/livearea/contents/template.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@
1919
<frame id="frame4">
2020
<liveitem>
2121
<text valign="top" align="left" text-align="left" text-valign="top" line-space="2" ellipsis="on">
22-
<str size="18" shadow="on">Trophy Manager v1.01 ®2018 Team ONElua - ONElua.x10.mx</str>
22+
<str size="18" shadow="on">Trophy Manager v1.02 ®2018 Team ONElua - ONElua.x10.mx</str>
2323
</text>
2424
</liveitem>
2525
</frame>

ONETROPHY/sce_sys/param.sfo

0 Bytes
Binary file not shown.

ONETROPHY/system/commons.lua

Lines changed: 12 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -27,38 +27,21 @@ else
2727
end
2828

2929
-- Creamos carpeta de trabajo para los idiomas
30-
__PATH_LANG = "ux0:data/ONETROPHY/"
30+
__PATH_LANG = "ux0:data/ONETROPHY/lang/"
31+
__PATH_FONT = "ux0:data/ONETROPHY/font/"
3132
files.mkdir(__PATH_LANG)
33+
files.mkdir(__PATH_FONT)
3234
__LANG = os.language()
3335

34-
langs = {
35-
JAPANESE = "00",
36-
ENGLISH_US = "01",
37-
FRENCH = "02",
38-
SPANISH = "03",
39-
GERMAN = "04",
40-
ITALIAN = "05",
41-
DUTCH = "06",
42-
PORTUGUESE = "07",
43-
RUSSIAN = "08",
44-
KOREAN = "09",
45-
CHINESE_T = "10",
46-
CHINESE_S = "11",
47-
FINNISH = "12",
48-
SWEDISH = "13",
49-
DANISH = "14",
50-
NORWEGIAN = "15",
51-
POLISH = "16",
52-
PORTUGUESE_BR = "17",
53-
ENGLISH_GB = "18",
54-
TURKISH = "19",
55-
}
56-
5736
-- Loading language file
5837
dofile("lang/english_us.txt")
5938
if not files.exists(__PATH_LANG.."english_us.txt") then files.copy("lang/english_us.txt",__PATH_LANG) end
6039
if files.exists(__PATH_LANG..__LANG..".txt") then dofile(__PATH_LANG..__LANG..".txt") end
6140

41+
-- Loading custom font
42+
fnt = font.load(__PATH_FONT.."font.ttf") or font.load(__PATH_FONT.."font.pgf") or font.load(__PATH_FONT.."font.pvf")
43+
if fnt then font.setdefault(fnt) end
44+
6245
--buttons asignation
6346
accept,cancel = "cross","circle"
6447
if buttons.assign()==0 then
@@ -78,3 +61,8 @@ DATA_TROPHY = "ur0:user/00/trophy/data/"
7861
TROP_TROPHY = "ur0:user/00/trophy/data/sce_trop"
7962
DB_TROPHY = "ur0:user/00/trophy/db"
8063

64+
function draw.offsetgradrect(x,y,sx,sy,c1,c2,c3,c4,offset)
65+
local sizey = sy/2
66+
draw.gradrect(x,y,sx,sizey + offset,c1,c2,c3,c4)
67+
draw.gradrect(x,y + sizey - offset,sx,sizey + offset,c3,c4,c1,c2)
68+
end

ONETROPHY/system/trophies_title.lua

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -81,12 +81,6 @@ function get_trophies()
8181

8282
end
8383

84-
function draw.offsetgradrect(x,y,sx,sy,c1,c2,c3,c4,offset)
85-
local sizey = sy/2
86-
draw.gradrect(x,y,sx,sizey + offset,c1,c2,c3,c4)
87-
draw.gradrect(x,y + sizey - offset,sx,sizey + offset,c3,c4,c1,c2)
88-
end
89-
9084
function trophies_title()
9185

9286
get_trophies()

0 commit comments

Comments
 (0)