Skip to content

Commit 04119cc

Browse files
update: font and style
1 parent f5f4781 commit 04119cc

21 files changed

Lines changed: 178 additions & 39 deletions

File tree

packages/webgal/public/game/scene/demo_zh_cn.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ pixiPerform:snow;
2525
pixiInit;
2626
WebGAL:接下来介绍一些新版本功能!
2727
WebGAL:比如这个[注](zhù)[音](yīn)功能,可以为游戏带来更好的体验!
28-
WebGAL:我们也支持了[文本拓展语法](style=color:#B5495B\;),可以为[文](wen)[本](ben)带来[富文本支持](style-alltext=font-style:italic\; style=color:#66327C\;)、交互等特性。
28+
WebGAL:我们也支持了[文本拓展语法](style=color:#B5495B\; style-alltext=-webkit-text-stroke-color:#ffffff\;),可以为[文](wen)[本](ben)带来[富文本支持](style-alltext=font-style:italic\;-webkit-text-stroke-color:#ffffff\; style=color:#66327C\;)、交互等特性。
2929
WebGAL:新版本添加了特性:获取用户输入,你要尝试一下吗?
3030
choose:尝试一下:userInput|算了吧:toNextPart;
3131

packages/webgal/public/game/template/Stage/TextBox/textbox.scss

Lines changed: 13 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,7 @@
5555
white-space: nowrap;
5656
left: 0;
5757
top: 0;
58-
background-image: linear-gradient(#005CAF 0%, #1D1D1F 100%);
58+
background-image: linear-gradient(180deg, #ffffff 0%, #f5f5f5 40%, #ebebeb 55%, #f8f8f8 100%);
5959
background-clip: text;
6060
-webkit-background-clip: text;
6161
color: transparent;
@@ -67,7 +67,9 @@
6767
position: absolute;
6868
left: 0;
6969
top: 0;
70-
-webkit-text-stroke: 0.1em rgba(255, 255, 255, 1);
70+
-webkit-text-stroke: 0.12em #2e2312;
71+
text-shadow: 0.05em 0.05em 0.02em rgba(0, 0, 0, 0.85),
72+
0.05em 0.05em 0.03em rgba(0, 0, 0, 0.5);
7173
z-index: 1;
7274
}
7375

@@ -105,7 +107,8 @@
105107
border-image: linear-gradient(
106108
to right,
107109
rgba(255, 255, 255, 0.2) 0%,
108-
rgba(255, 255, 255, 0.85) 5%,
110+
rgba(255, 255, 255, 0.95) 5%,
111+
rgba(255, 255, 255, 0) 50%,
109112
rgba(255, 255, 255, 0) 100%
110113
)
111114
1;
@@ -153,18 +156,21 @@
153156
position: absolute;
154157
left: 0;
155158
top: 0;
156-
color: #0B346E;
159+
background-image: linear-gradient(180deg, #ffffff 0%, #f5f5f5 40%, #ebebeb 55%, #f8f8f8 100%);
160+
background-clip: text;
161+
-webkit-background-clip: text;
162+
color: transparent;
157163
z-index: 2;
158-
text-shadow: 0 2px 8px rgba(255, 255, 255, 0.35), 0 2px 6px rgba(0, 0, 0, 0.18);
159164
}
160165

161166
.innerName {
162167
position: absolute;
163168
left: 0;
164169
top: 0;
165-
-webkit-text-stroke: 0.08em rgba(255, 255, 255, 0.98);
170+
-webkit-text-stroke: 0.12em #2e2312;
171+
text-shadow: 0.05em 0.05em 0.02em rgba(0, 0, 0, 0.85),
172+
0.05em 0.05em 0.03em rgba(0, 0, 0, 0.5);
166173
z-index: 1;
167-
text-shadow: 0 1px 4px rgba(0, 0, 0, 0.18);
168174
}
169175

170176
.text {

packages/webgal/public/game/template/UI/Title/title.scss

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
}
77

88
.Title_buttonList {
9-
font-family: "思源宋体", serif;
9+
font-family: "资源圆体", serif;
1010
display: flex;
1111
position: absolute;
1212
left: 0;
@@ -50,7 +50,7 @@
5050
display: inline-block;
5151
padding: 0.08em 0.55em 0.12em 0.35em;
5252
font-size: 200%;
53-
font-family: WebgalUI, -apple-system, BlinkMacSystemFont, Segoe UI, Roboto, Oxygen, Ubuntu, Cantarell, Fira Sans, Droid Sans, Helvetica Neue, sans-serif;
53+
font-family: '资源圆体', -apple-system, BlinkMacSystemFont, Segoe UI, Roboto, Oxygen, Ubuntu, Cantarell, Fira Sans, Droid Sans, Helvetica Neue, sans-serif;
5454
letter-spacing: 0.16em;
5555
line-height: 1.2;
5656
transform-origin: left center;

packages/webgal/src/Core/util/fonts/fontOptions.ts

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,11 @@ import { FontOption } from '@/store/guiInterface';
22
import { TemplateFontDescriptor } from '@/types/template';
33

44
export const DEFAULT_FONT_OPTIONS: FontOption[] = [
5+
{
6+
family: `'资源圆体', serif`,
7+
source: 'default',
8+
labelKey: 'textFont.options.resourceHanRounded',
9+
},
510
{
611
family: `'思源宋体', serif`,
712
source: 'default',
@@ -12,14 +17,9 @@ export const DEFAULT_FONT_OPTIONS: FontOption[] = [
1217
source: 'default',
1318
labelKey: 'textFont.options.SimHei',
1419
},
15-
{
16-
family: `'LXGW', serif`,
17-
source: 'default',
18-
labelKey: 'textFont.options.lxgw',
19-
},
2020
];
2121

22-
export const FALLBACK_FONT_FAMILY = DEFAULT_FONT_OPTIONS[1].family;
22+
export const FALLBACK_FONT_FAMILY = DEFAULT_FONT_OPTIONS[2].family;
2323

2424
export function buildFontOptionsFromTemplate(fonts: TemplateFontDescriptor[]): FontOption[] {
2525
const templateOptions: FontOption[] = fonts.map((font) => ({

packages/webgal/src/Stage/FullScreenPerform/fullScreenPerform.module.scss

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -76,13 +76,13 @@
7676
.fadeIn {
7777
opacity: 0;
7878
animation: intro_showSoftly 1.5s ease-out forwards;
79-
font-family: "思源宋体", serif;
79+
font-family: "资源圆体", serif;
8080
}
8181

8282
.slideIn {
8383
opacity: 0;
8484
animation: slideIn 1.5s forwards;
85-
font-family: "思源宋体", serif;
85+
font-family: "资源圆体", serif;
8686
}
8787

8888
.typingEffect {
@@ -91,19 +91,19 @@
9191
white-space: pre-line;
9292
width: 0;
9393
animation: typing 1.5s forwards, blinkCursor 1s infinite 1.5s;
94-
font-family: "思源宋体", serif;
94+
font-family: "资源圆体", serif;
9595
}
9696

9797
.pixelateEffect {
9898
opacity: 0;
9999
animation: pixelateAnimation 3s forwards;
100-
font-family: "思源宋体", serif;
100+
font-family: "资源圆体", serif;
101101
}
102102

103103
.revealAnimation {
104104
opacity: 0;
105105
animation: revealAnimation 3s forwards;
106-
font-family: "思源宋体", serif;
106+
font-family: "资源圆体", serif;
107107
}
108108

109109
@keyframes intro_showSoftly {

packages/webgal/src/Stage/TextBox/textboxFilm.module.scss

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
}
88

99
.TextBox_main {
10-
font-family: "思源宋体", serif;
10+
font-family: "资源圆体", serif;
1111
font-style: italic;
1212
position: absolute;
1313
z-index: 6;

packages/webgal/src/UI/Backlog/backlog.module.scss

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -74,6 +74,7 @@
7474
}
7575

7676
.backlog_content {
77+
font-family: "资源圆体", serif;
7778
position: absolute;
7879
height: 80%;
7980
padding: 1em 10em 1em 10em;

packages/webgal/src/UI/Extra/extra.module.scss

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -113,14 +113,14 @@
113113

114114
.bgmName {
115115
color: rgba(255, 255, 255, 0.8);
116-
font-family: "思源宋体", serif;
116+
font-family: "资源圆体", serif;
117117
font-size: 155%;
118118
margin: 5px 5px 0 15px;
119119
overflow: hidden;
120120
}
121121

122122
.bgmElement {
123-
font-family: "思源宋体", serif;
123+
font-family: "资源圆体", serif;
124124
padding: 0.5em 1em 0.5em 1em;
125125
overflow: hidden;
126126
background-color: rgba(0, 0, 0, 0.1);

packages/webgal/src/UI/GlobalDialog/globalDialog.module.scss

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111
justify-content: center;
1212
align-items: center;
1313
//font-family: "WebgalUI", -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto', 'Oxygen', 'Ubuntu', 'Cantarell', 'Fira Sans', 'Droid Sans', 'Helvetica Neue', sans-serif;
14-
font-family: "思源宋体", serif;
14+
font-family: "资源圆体", serif;
1515
}
1616

1717
.glabalDialog_container_inner {

packages/webgal/src/UI/Menu/SaveAndLoad/SaveAndLoad.module.scss

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -141,7 +141,7 @@
141141

142142

143143
.Save_Load_content_element_top {
144-
font-family: "思源宋体", serif;
144+
font-family: "资源圆体", serif;
145145
width: 100%;
146146
height: 12%;
147147
display: flex;

0 commit comments

Comments
 (0)